TileMapLayer not visible in debug

Godot Version

4.6.1

Question

I have 40 years of experience in coding games (yikes, I know) going back to TMS9900 assembler code. However, I’m a complete newbie to Godot, and I keep getting stuck on one of the simplest things. I’m sure this is just a stupid oversight on my part, but I can’t get what I’ve painted in a TileMapLayer to show up in debug.

  • I’ve created a scene and made sure that scene is the main scene.
  • I’ve created a TileMapLayer within that scene, created a tileset for that layer, selected tiles, and drawn some basic scribbles on the TileMapLayer to represent part of the play area.
  • I’ve added a camera2D to the scene and dragged it into the middle of my scribble.
  • Everything looks fine in the editor.

But when I run debug, I get a blank screen. I’ve checked to see that the TileMapLayer is visible, and I’ve never fiddled with the other settings (terrain, z-order, etc). No errors are appearing, but I just don’t get anything. I’ve watched half a dozen tutorials looking for the magic missing step, but it seems every tutorial out there uses a TileMap, which shows up as a deprecated class. I did what the editor told me and went straight to the TileMapLayer … but darn.

Now, knock me in the head with a board and explain what simple step I’ve missed. Thanks.

I might be able to help, is it showing up gray or another color? (Sorry if i missed that)

1 Like

What if you remove the camera?

1 Like

Im sorry if this seems obvious lol but ill give you what i do to get my tilemaplayer, and you can see if you missed a step in there :slight_smile:

  1. make a new scene with a node 2d as the root node
  2. add tilemaplayer as a child of the node2d
  3. double click on the tilemap to get to the tilemap editor, should be at the bottom of your screen
  4. click ‘tileset’ and drag the tileset you have into the area
  5. (Only if the orange boxes arent the same size as your blocks, im assuming you only have blocks here sorry) you can change the pixel size on the left side of the editor. For special blocks, im not sure off the top of my head (its been a while since ive made a fully 2d game, not just a 2d portion of a 3d game, so i never really have to use that specific feature but there is tutorials)
  6. click tilemap again
  7. press the pencil looking thing on the top of the editor
  8. just place a few within the constraints of the purple box, which would be the camera

I hope something in that helped :slight_smile: it seems like another one of your problems is you’re using outdated tutorials, id recommend looking for 4.4 tutorials or above just because usually those have most of the features we have now. They’re much less confusing, at least for me, but then again I’m me, not you.

Anyways i hoped that helped and good luck on your Godot journey!!

Also, and most likely a stupid quiestion, but how are you running debug? hat button are you pressing? Only reason i ask is because i wasnt doing it right when i started so :slight_smile:

1 Like

Instantiation. That was my problem — and it should have been an obvious one. I wanted to create a series of levels as scenes, and had instantiated them as child scenes below the root scene. But I did so before I actually built out the first child scene and its TileMapLayers. Once I dropped the original instance and added it again, all was well.

Thank you for the assistance. And yes, so many tutorials out there for 4.2 and earlier. I need to slow down and watch some folks build out basic projects in 4.4 or later before I dive in and end up back here begging for help.

1 Like

If your looking for a realy good tutorial, How to make a Video Game - Godot Beginner Tutorial by Brackeys is what taught me everything, he has a bunch of other stuff too for gdscript i believe, he was really helpful :smiley:

1 Like