You read my mind. I spent hours this past week researching tiled and looking for isometric Python tutorials but couldn't find much in regards to logic behind character collision etc. It is tough to figure out. This is one of the better Tiled guides out there so thanks
Awesome vid! I learned about the functionality of Tiled, which I have only played with, learned a new module to bring my tmx files over, saving a lot of work later on in the game I am making; and I logical way of thinking to bring the map to the game... Thanks for all the tutorials!
Superb video, thank you for this. You can use isinstance() to determine if a layer is a tilelayer: from pytmx import * ... layer = tmx_data.get_layer_by_name("Water") print(isinstance(layer,pytmx.TiledTileLayer ) )
thankuo sir , completed the whole tutorial , completed it till the last second , not in one go but still , managed to complete it thankyou for posting such informative video
Super excited to watch yet another great tutorial! Just want to suggest you to cover tile-based movement design (how games like Baba Is You, Helltaker, Crypt of the Necromancer etc are working).
Wow! I was really looking to use it in some of my future projects (also in Pygame)! And, I got your tutorials... the best and clearest tutorials! Thankssss!
thank you so much for your free and super high quality tutorials as always. you are helping me learn to program. I'm having trouble finishing this video. when I tryto get the object's type rather than showing the type (for example: 'shape') python is just prints it out as 'None'. I assume this is something I did wrong inside of Tiled. thanks for your videos again and thanks in advance to anyone who might help
how can I get the tileset to show up on the side on the same window as the game map? I accidentally crossed it and I don't know how to get it back. the tile sets keep opening in a new window so I cant use them
Great tutorial but something is wrong with the module for me. It's found my tmx file but it's giving me a bunch of errors from within the module itself instead of my code
This has been suuuper helpful! The only remaining question I have about this program is, am I able to select a chunk of tiles and drag them to a new position? (As opposed to manually erasing and re-stamping a section) The selection tool works a bit differently than I'm used to and I only seem to be able to drag the entire layer.
you can totally do that, there is a select tool at the top, or the hotkey r (I think) to select an area. Then you can cut it out and paste it with Ctrl + x and Ctrl + v
Came back to this a year later to solve a bug that meant only Objects and Floor showed up. Floor, Ground, Plant and rocks, Pipes layers are render order dependent, so the Floor needs to happen first and the hasattr is not as good as selecting the layer names individually, because of the Floor overwriting things. I removed 'Floor' from the tuple and everything turned up. Having now got the ground, vegetation, pipes and objects to appear in the top corner, I still have to figure out why the floor is rendered in grey rather than brown. I think it is processing but not rendering, but I'd expect to see black in that case, but commenting out the floor loop is also grey. So more debugging, but at least progress. Also found the continuous path thing seems to not be working now - maybe something in Tiled 10.2? Maybe I overlooked something. It worked fine a year ago, but I updated the Tiled version. So did some manual placement to get a few pipes into the top corner.
I tried to import one of those png with multiple images inside it and when i import it it is all clumped together in a 64 x 64 tile size. How do i work around that.
I have the same problem. There were update of Tiled program and it doesn't work as in tutorail anymore. I can't figure it out how to make it work. Did you find solution allready? @ClearCode mayby you can help with that?
@@PSMaster1991 Hi I tryed to solve it too, but I can only figure out one solution to make more or less something like on the tutorial: for obj in self.tmxData.objects: position = obj.x, obj.y if obj.__getattribute__("class") in "Building": Building(position, obj.image, self.all_sprites, self.collision_sprites, z=LAYERS["BUILDING"]) I used the obj.__getattribute__("class") to use the class attribute from the object, I dont know if this works for you, I hope it is.
Hi there! I was just facing the same issue and on Tiled forum I found this solution: discourse.mapeditor.org/t/the-atribute-class-of-my-objects-are-none/5772/2 Basically if you setup a project, and go to Project -> Project Properties and change Compatibility version to Tiled 1.8, then the class property in Tiled will be accessed in Python through pytmx object.type! It worked for me, hope it works as well!
there is no way to make a tile go to certain layer automatically? like grass will be always layer0 while stones will be on layer1 so if I pick stones they get setted on layer1
Not sure if anyone can help me, but im getting a ValueError after trying to add the tmx file to my pygame, for some reason it says : ValueError invalid literal for int() with bas 10: '3.63636'. Even though there shouldnt be any numbers or integers
Please if possible can you make a tutorial on importing isometric data from tiled to pygame as there is not much information on how to go about it. Thanks
Very detailed video🔥, but I still got the problem. I can't draw. Just a transparent blue square running after the cursor even though the Tileset has loaded. Please tell me what could be the problem?
If you have problem loading infinite map please consider that pygame is not compatible with infonite map, just resize them and change the infinite property on the map and dont wase 1,5h of your life as i did :D
I realized that the object layers did not export, when you used the .csv option? Anyway to fix that so you can export the object layers as a .csv file?
is there a setting Called Program*, its default is set to *Agressive TEwNice tutorialch is making that sNice tutorialtty static soft, change that one, once to
Hello, good tutorial!! I just need help with something and idk if anyone here can help me but i have a problem. Im at 1:48:33 and im getting that sprite_group isint defined. Does anyone know what k can be doing wrong? Its the sprite_group.draw(screen) thats worng for me. Do i need this part of the code or can i remove it?
Hello! I'm having an error with the PyTMX module, when I install it (with pip ir even pip3) and wanna call it in the code I get an error: NoModuleName 'pytmx' Heelp :/
Thank you for this video, it is very helpful, but I have a question, how could the shapes created in the object layer be used for things like collisions or detecting elements in that area? Because I would like to use them that way but I don't know whether to do so that this shape like a sprite is the most recommended
sorry for a sad question, but you state you have used CSV import (yep done that) but also the other method (pytmx) & have an example of using this. I can only find the CSV used & don't quite understand the pytmx thingy- can someone point me at this please? Cheers!
@@ClearCode Yes. it game a concise explanation of the various attributes & stuff you can pull out, but I couldn't see how to use this to import graphic to position other than in the same way one would for a CSV (which you said was tedious). I may be having a dense moment though! ;-)
Everything's amazing except that when i load my 2d tile map, its small. I have no idea how to make it bigger so it could be full screen. Is there a way to make the map bigger using the pygame or pytmx modules???
tryingt o follo your tutorial, which has been great....until.....Tiled. Downloaded latest version for Mac OS and went to give it a spin and it literally dies constantly. just flat out freezes, or ui fails to respond or it just locks up and crashes. Very frustrating piece of software.
Question, can you make fake tiles? when I say fake tiles I mean tiles that are like in the background(behind he terrain tiles), are slightly dimmed and you cant collide with them?
i love you other tutorials but this one is very confusing. it is soooo strung out and a bit all over the place. can you make a more structured of this is how you do it step 1, 2, 3? more planned out?
I love that you're doing these tutorials, but could you do some of this stuff through Godot engine, or something where -- we might actually be able to publish to a platform such as Android/iOS? PyGame is really nice and all, but using it in Mobile -- which is the largest gaming industry right now, is neigh impossible.
Im pretty sure example unity, especially Godot has everything needed for tiling making this program useless, in 2024 i dont really see why i should use this...
It's great for me, because my course doesn't allow usage of drag and drop features, so using something like unity for tiles is the same as using tiled, plus I don't run the risk of accidentally losing marks
You read my mind. I spent hours this past week researching tiled and looking for isometric Python tutorials but couldn't find much in regards to logic behind character collision etc. It is tough to figure out. This is one of the better Tiled guides out there so thanks
Man truly amazing work...you explain to the point...no fuss...just precise programming
Amazing man.
edge set feel more like for 2D view/platformers while corner is more for "view from above" / RPG like.
also super clear tutorial thanks
I sponsored the Tiled project for about two years. Finally starting to use it. LOL. Great tutorial.
Awesome vid! I learned about the functionality of Tiled, which I have only played with, learned a new module to bring my tmx files over, saving a lot of work later on in the game I am making; and I logical way of thinking to bring the map to the game... Thanks for all the tutorials!
Superb video, thank you for this. You can use isinstance() to determine if a layer is a tilelayer:
from pytmx import *
...
layer = tmx_data.get_layer_by_name("Water")
print(isinstance(layer,pytmx.TiledTileLayer ) )
thankuo sir , completed the whole tutorial , completed it till the last second , not in one go but still , managed to complete it
thankyou for posting such informative video
YES. Just the tutorial I needed. Thank you so much. You are my favorite channel on CZcams.
again THE FINE EXAMPLE OF THE BEST TUTORIAL
👍👍👍👍👍👍👍👍👍👍👍👍👍👍👍👍
Super excited to watch yet another great tutorial!
Just want to suggest you to cover tile-based movement design (how games like Baba Is You, Helltaker, Crypt of the Necromancer etc are working).
Wow! I was really looking to use it in some of my future projects (also in Pygame)! And, I got your tutorials... the best and clearest tutorials! Thankssss!
Salvou minha vida moço, vc não é um youtuber, é um pai💪
Thanks for this guide, i have just watched a first video about mario platformer and want to learning Tiled! Thanks, really
Great tutorial! Thanks for taking the time to share your experience
thank you so much for your free and super high quality tutorials as always. you are helping me learn to program. I'm having trouble finishing this video. when I tryto get the object's type rather than showing the type (for example: 'shape') python is just prints it out as 'None'. I assume this is something I did wrong inside of Tiled. thanks for your videos again and thanks in advance to anyone who might help
how to check collision in Tiled?
You really make good videos, i am not a engish speaker but i understand almost everything so good job
Hello Clear Code. You mentioned a while ago you'll be doing DOOM with pygame after Zelda. When could we expect this course to come out?
beautiful video, thank you for your time
how can I get the tileset to show up on the side on the same window as the game map? I accidentally crossed it and I don't know how to get it back. the tile sets keep opening in a new window so I cant use them
did you ever figure it out, i’m here for the same reason
Thank you for everything you do
THANKS FOR THIS IV BEEN SEARCHING FO SOOO LONG
Great video, the menu works great
I love it. excellent work.
Frrrrr tNice tutorials man just straight forward !
Really amazing !!! best and clear tutorial :)
Thank you so much for the video ❤
i needed this so much .. thank you ♥️
Wonderful. Thank you very much for your time and effort. You made it so easy to understand Tiled. Great tutorial and very well-prepared presentation.
Your channel is amazing!
Thank you!
I like your tutorials Very much
this video is amazing
thank you
really nice video!
Great tutorial but something is wrong with the module for me. It's found my tmx file but it's giving me a bunch of errors from within the module itself instead of my code
This has been suuuper helpful! The only remaining question I have about this program is, am I able to select a chunk of tiles and drag them to a new position? (As opposed to manually erasing and re-stamping a section) The selection tool works a bit differently than I'm used to and I only seem to be able to drag the entire layer.
you can totally do that, there is a select tool at the top, or the hotkey r (I think) to select an area. Then you can cut it out and paste it with Ctrl + x and Ctrl + v
OMG OMG OMG!!! U RE THE BEST!!!!!! THX U for this video!!!!
may I ask on 1:20:54 why you're using forward slash instead of backslash? does the path string for pytmx work different compared to pygame.image.load?
Thanks for the vid! it's super helpful!! One question though, where did you get the tileset from?
Came back to this a year later to solve a bug that meant only Objects and Floor showed up.
Floor, Ground, Plant and rocks, Pipes layers are render order dependent, so the Floor needs to happen first and the hasattr is not as good as selecting the layer names individually, because of the Floor overwriting things.
I removed 'Floor' from the tuple and everything turned up.
Having now got the ground, vegetation, pipes and objects to appear in the top corner, I still have to figure out why the floor is rendered in grey rather than brown. I think it is processing but not rendering, but I'd expect to see black in that case, but commenting out the floor loop is also grey. So more debugging, but at least progress.
Also found the continuous path thing seems to not be working now - maybe something in Tiled 10.2? Maybe I overlooked something. It worked fine a year ago, but I updated the Tiled version.
So did some manual placement to get a few pipes into the top corner.
Thanks very much.
Take ti, enjoy it most of all and results will follow
I tried to import one of those png with multiple images inside it and when i import it it is all clumped together in a 64 x 64 tile size. How do i work around that.
Hi! I have a problem, when using the TMX file on python, I cant get the object type, on tiled it says class insted of type, so python returns None :(
I have the same problem. There were update of Tiled program and it doesn't work as in tutorail anymore. I can't figure it out how to make it work. Did you find solution allready? @ClearCode mayby you can help with that?
@@PSMaster1991
Hi I tryed to solve it too, but I can only figure out one solution to make more or less something like on the tutorial:
for obj in self.tmxData.objects:
position = obj.x, obj.y
if obj.__getattribute__("class") in "Building":
Building(position, obj.image, self.all_sprites, self.collision_sprites, z=LAYERS["BUILDING"])
I used the obj.__getattribute__("class") to use the class attribute from the object, I dont know if this works for you, I hope it is.
Hi there! I was just facing the same issue and on Tiled forum I found this solution: discourse.mapeditor.org/t/the-atribute-class-of-my-objects-are-none/5772/2
Basically if you setup a project, and go to Project -> Project Properties and change Compatibility version to Tiled 1.8, then the class property in Tiled will be accessed in Python through pytmx object.type! It worked for me, hope it works as well!
Legend
amazing russ
there is no way to make a tile go to certain layer automatically? like grass will be always layer0 while stones will be on layer1
so if I pick stones they get setted on layer1
Not sure if anyone can help me, but im getting a ValueError after trying to add the tmx file to my pygame, for some reason it says : ValueError invalid literal for int() with bas 10: '3.63636'. Even though there shouldnt be any numbers or integers
Please if possible can you make a tutorial on importing isometric data from tiled to pygame as there is not much information on how to go about it. Thanks
Yeah bro me too
i don't have the tilesets section under layers. and none of the UI options i tried restore it
Very detailed video🔥, but I still got the problem. I can't draw. Just a transparent blue square running after the cursor even though the Tileset has loaded. Please tell me what could be the problem?
If you have problem loading infinite map please consider that pygame is not compatible with infonite map, just resize them and change the infinite property on the map and dont wase 1,5h of your life as i did :D
how to copy and pased tiles? ctrl c v don't work
Thanks for VERY usefull tutorial!!! But, I can't undersand how to import animated tiles. Please help!)
I realized that the object layers did not export, when you used the .csv option? Anyway to fix that so you can export the object layers as a .csv file?
And how do you tackle the terrain problem? Nothing was said about that :(
Nice man ty
When i print tmx_data.layers it says cant find Sprite sheet :(
? so where's the playing of the map that was created in tiled?
Other than making the graphics myself, where can I find the graphics for tiled?
anyone knows how to get the terrain to work with a platformer/sidescroller tileset?
is there a setting Called Program*, its default is set to *Agressive TEwNice tutorialch is making that sNice tutorialtty static soft, change that one, once to
I will never afford a keysight dishclothe but I don't let that get me down or have gear envy haha
Bro similarly, can you make a tutorial for importing isometric tilemap in python. It's really difficult 😔
Hello, good tutorial!! I just need help with something and idk if anyone here can help me but i have a problem. Im at 1:48:33 and im getting that sprite_group isint defined. Does anyone know what k can be doing wrong? Its the sprite_group.draw(screen) thats worng for me. Do i need this part of the code or can i remove it?
You are truly great.
Btw, do you use tiled map editor app?
yes
@@kiyu3229
You use that?
@@SkyFly19853 yes
@@kiyu3229
Oh, I see.
Hello! I'm having an error with the PyTMX module, when I install it (with pip ir even pip3) and wanna call it in the code I get an error: NoModuleName 'pytmx'
Heelp :/
if you are on mac i think the pip install is different i could be wrong tho
Thank you for this video, it is very helpful, but I have a question, how could the shapes created in the object layer be used for things like collisions or detecting elements in that area? Because I would like to use them that way but I don't know whether to do so that this shape like a sprite is the most recommended
I have the same question, and I also create my objects layer but after that I try to export it as a csv file but it does not work for me...
getting the error: No module named 'pytmx'
i have installed pytmx
nvm i was using the wrong interpreter
how to scroll through the thing
Hey Chris, is it possible to use tiled to auto tile the top and bottom tiles of platforms in a 2d platformer type game?
yes, totally
sorry for a sad question, but you state you have used CSV import (yep done that) but also the other method (pytmx) & have an example of using this. I can only find the CSV used & don't quite understand the pytmx thingy- can someone point me at this please? Cheers!
the second half of the video is about using pytmx in pygame, did you watch that?
@@ClearCode Yes. it game a concise explanation of the various attributes & stuff you can pull out, but I couldn't see how to use this to import graphic to position other than in the same way one would for a CSV (which you said was tedious).
I may be having a dense moment though! ;-)
please make a video on how to scroll tmx file maps
Everything's amazing except that when i load my 2d tile map, its small. I have no idea how to make it bigger so it could be full screen. Is there a way to make the map bigger using the pygame or pytmx modules???
Btw, I also cant get the objects in my game, they wont pop up, only the tiles layers.
@@dragon._.9646 maybe try to blit the map onto a different surface and then scale that surface to the full window size?
tryingt o follo your tutorial, which has been great....until.....Tiled. Downloaded latest version for Mac OS and went to give it a spin and it literally dies constantly. just flat out freezes, or ui fails to respond or it just locks up and crashes. Very frustrating piece of software.
I desperately need something like this but for the ipad :(
what is load pygame?
(Lo-Fi, Trapsoul, CNice tutorialllstep, Trip Hop, Rap, Trap, Nice tutorialp Hop)
working bro! Thanks a lot, +sub +like
Nice thumbnail. Xd
1:48:24
52:14 "That's what she said"
xD
wow
Question, can you make fake tiles? when I say fake tiles I mean tiles that are like in the background(behind he terrain tiles), are slightly dimmed and you cant collide with them?
sure, when you import them to pygame just make sure to not add any collision logic and you can also control the alpha values of any surface.
New tileset button doesn't exist this program is so annoying to use with not enough straight forward guides
i love you other tutorials but this one is very confusing. it is soooo strung out and a bit all over the place. can you make a more structured of this is how you do it step 1, 2, 3? more planned out?
Word
Bro nothing on making a 2d platforming map but you touch on iso.
I love that you're doing these tutorials, but could you do some of this stuff through Godot engine, or something where -- we might actually be able to publish to a platform such as Android/iOS? PyGame is really nice and all, but using it in Mobile -- which is the largest gaming industry right now, is neigh impossible.
first yay
Show to us how make one "mario style" in rust. xD
Make video talk about 'ursina' 3d how to make animation in blender and make game and thankkkkkkkkks
Im pretty sure example unity, especially Godot has everything needed for tiling making this program useless, in 2024 i dont really see why i should use this...
It's great for me, because my course doesn't allow usage of drag and drop features, so using something like unity for tiles is the same as using tiled, plus I don't run the risk of accidentally losing marks
second
soft... isn't it much harder to hear everytNice tutorialng as you go tNice tutorials way?
"So tNice tutorials is our channel rack..."
?
, during the second wave..
Pause.