I have simple problem. I like to make platform enemies. They would walk and change their direction when collides walls and also they should fall when there is no floor below them.
Right, this can be done in a few events, but you have to pay attention.
First of all, make him walk in the direction he's facing. If he's facing left, subtract 1 from his x coordinate or the opposite for right. Only do this if flag 0 = off.
Then, if he collides with a backdrop, set his direction to +16 to make him flip around.
Next we need to check if he has wandered over a hole. So "always" put his y coordinate +1 and flag 0= = on, check for a collision in the next event, if it is positive, put his y coordinate to -1 to make him pop back up again and put flag 0 = off to make him keep walking. This all happens before MMF draws the screen, so it should be fine.
Also you can always make detectors and place them on the walls where they collide, using 'collides with backdrop' can be a bit freakish, especially with your level and what you're doing, as they will change direction upon falling on to a new backdrop so will not touch the walls before turning.
Originally Posted by SilverNova / Tim Also you can always make detectors and place them on the walls where they collide, using 'collides with backdrop' can be a bit freakish, especially with your level and what you're doing, as they will change direction upon falling on to a new backdrop so will not touch the walls before turning.
Yeah, it is possible to get around that turning on touching the floor. Also you don't need detectors on walls either.