Placing Copies of a Sprite

I want to place copies of a sprite on duplicates of a certain tile.

I would like to be able to place three green grass tiles in my tile map and spawn three identical enemy sprites on the green grass tiles (one enemy on each green grass tile).

My code will successfully do this sometimes, but sometime when I refresh my game it only spawns one or two enemies.

Any suggestions?

PS: I know I’ve asked multiple questions this week. I do really appreciate getting help with this stuff. Thanks. :smile:

1 Like

This piece of code
will take every tile of a certain type (the one in the array) and make a sprite and place it on that tile so every tile has a sprite on it (regardless of how many tiles are on the tilemap.) Here’s the code so you can edit it:

1 Like

Thanks! That is super helpful!

1 Like