For finding out the level, I got this idea:
Find out the height and width for the level.
Warp the bot to each one of the coordinates.
Now, if the bot isn't able to move at all, he's standing in a masked block. If he's able to the block is unmasked. If the ammo count for a weapon increases, you know he's the tile contains ammo. If he suddenly moves upwards or sidewards you know you hit a spring, belt or wind. To find out wether he's on a diagonal block, you can walk left or right and see if he also moves up or down.
This way you can create a ".ai" map of the entire level without having to code too much.
|