The Thinker

The Thinker

  • NA
  • 1
  • 2.8k

Moving Platforms in XNA using a Tiled Map

Feb 21 2012 6:45 PM
Hi, I am trying to create a platformer which uses maps created in Tiled. In order to create moving platforms, I am replacing the tiles with sprites. Each tile representing the moving platforms has a data value between 100 and 107. When the game loads the map, any tile with that value will spawn a sprite in its place, and should remove/prevent the tile itself from being loaded.. However, I can't seem to find any way to remove the original tile, which leaves a copy of each platform sitting behind the platform as it moves - can anyone help me to remove the tile?

The second problem is that, while the tiles move, my character does not move with them, which could work if I wanted them to be "ice" platforms, but I'd like the player to move with the platform. I tried adding friction to the platform sprite but it didn't work.

Thanks all!

Answers (1)