You need a continuously running script that checks to see if your character is standing on land, and if it isn't, moves him down the screen.
For example, this would allow the character to stand on anythign green (though it has to be the right shade of green.
Forever if <NOT<touching colour green>>
- - Change Y by -1
Or, if your land is a sprite called Land:
Forever if <NOT<touching [Land]>>
- - Change Y by -1
Last edited by Mayhem (2007-08-01 04:41:44)
Offline
That really depends on how your scripting currently works.
Post your project so far, and we can have a look at what might be wrong.
Offline
Ah. What's happening is that your script is moving the sprite up if it is touching green, or down if it isn't, so it will always bounce up and down.
The best solution is to use different colours for telling it to go up or down.
If you put a band of a different colour (eg, dark green) 2 pixels below the top of your "stand on this" colour, then you can have the following checks:
If <not <touching green>>, change Y by -2
If <touching dark green> change Y by 2
Or, you can do something similar except the different colours are in your sprites feet. Make the bottoms of the feet Dark Blue, and the rest of the feet light bule.
If <not <Dark Blue over green>>, change Y by -2
If <Light Blueover green> change Y by 2
Offline
You might also want to look at usign the "repeat" function on your fire costume changes.
And also, look at creating a variable "level", that is used to position your sprites etc at the start of each level, you might save yourself a considerable number of colour-checking "If" blocks and broadcasts.
Last edited by Mayhem (2007-08-02 09:01:21)
Offline