how do u make something look real when it jumps, not just glide. Like gravity.
Offline
Try this:
when gf clicked set [Gravity v] to [0] repeat [however long you want it to repeat] if <touching color [color of ground]> set [Gravity v] to [0] change y by [1] set [Gravity v] to [the larger this number is, the higher your sprite will jump] else change [Gravity v] by [-1] change y by (Gravity) end end
Last edited by skippito (2012-06-20 18:34:10)
Offline
try this script in your sprite that is effected by the gravity:
forever change y by (gravity) if <touching [ground v]?> set [gravity v] to [0] else set [gravity v] to [-1] end(you can also change those forever blocks to repeat)
Last edited by cbcollab (2012-06-21 11:35:34)
Offline
Gravity script.
when gf clicked forever if <touching [ground colour]> set [y velocity v] to (0) else change [y velocity v] by (-0.4) // The lower the number the faster the sprite falls. end
when gf clicked forever if <key [up arrow] is pressed> set [y velocity v] to (9) // The higher the number the higher the sprite will jump. end
when gf clicked forever change y by <y velocity v> end
Offline