This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2013-04-22 18:18:32

brodyrulz
Scratcher
Registered: 2013-03-02
Posts: 1

jump help

I need a script that i can use in a platformer to jump. im trying to get my game at leaset halfway done before tomorrow because i have testing at school.

Last edited by brodyrulz (2013-04-22 18:18:54)

Offline

 

#2 2013-04-22 22:40:45

OverPowered
Scratcher
Registered: 2012-07-27
Posts: 100+

Re: jump help

Try this:

when green flag clicked
set [yVelocity v] to (0)
forever
change y by (yVelocity)
if <touching color [ground]?>
set [yVelocity v] to (0)
if <key [space v] pressed?>
set [yVelocity v] to (10)
end
else
change [yVelocity v] by (-1)
end
It's simple, but it works.  smile


Newest project: Tunnel TEST ~http://blocks.scratchr.org/API.php?user=OverPowered&amp;action=onlineStatus~ On my mind: Unicameralism

Offline

 

Board footer