This will be one of the toughest enemys to program. Unlike any other enemy(yet), it has the ability to jump freely like Stompy. This also means more complex collision code needs to be added. Most enemy objects don't even recognize that there is a ground!
I also have to make sure it doesn't do anything stupid, like jump right off a cliff. However, this will be fixed using a set of "invisible walls" for the enemy.
The animation will be pretty cool if I get it working right. Every time the PogoBot hits the floor, it will show a kindof boing animation(bounce, or whatever a pogo stick does when it hits the ground).
I don't know if I'll have it working tomorrow, but I can try.
A. Walk on
B. Not walk on
Then you would make one generic function that would check to see if your alloud to move by passing to it the x and y of the person your checking. Then the function would take those coordinates and determine where they would be placed after the move on the colision map, if the coords after the move fall on a non walkable tile, dont allow the move.
here is the code for the function: