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

#1 2008-02-17 16:28:02

WEESTRAWZ
Scratcher
Registered: 2007-09-17
Posts: 5

A REALLY REALLY Simple way to make your sprite jump!

<if><key[ Space ]pressed?>
<glide( 1 )secs to x sad <x position>)y sad  (( <y position> <+> 150 ))
<wait( 0.0000001 )secsc>
<glide( 1 )secs to x sad <x position>)y sad  (( <y position> <-> 150 ))

That is the EASYEST way to make a sprite jump!!!!!!!!!!
Hope it helped!

For the peeps who can't understand that:-
<<If>>(key[Space]pressed?)
<<glide(1)sec to x: (<x position>)y sad  (<y position> <+> 150))
<<Wait(0.0000001)secs>>
<<glide(1)sec to x: (<x position>)y sad  (<y position> <-> 150))

And for muppits who can't understand THAT:-
If key space pressed
Glide 1 sec to x: (x position)y sad (y position) plus 150)
wwait(0.0000001)secs
glide 1 sec to x: (x position)y sad (y position) minus 150)


And thats it!

P.S. This is only for the peeps who are making a scrolling background but a static Character! Soz

Last edited by WEESTRAWZ (2008-02-17 16:40:10)

Offline

 

#2 2008-02-17 16:31:47

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: A REALLY REALLY Simple way to make your sprite jump!

If you do that then you won't be able to move left or right while jumping.

Try this if you want a really simple jump.

<when[ space ]key pressed>
<repeat( 10
<change y by( 4
<end>
<repeat( 10
<change y by( 4
<end>
<end>


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#3 2008-02-17 16:43:53

WEESTRAWZ
Scratcher
Registered: 2007-09-17
Posts: 5

Re: A REALLY REALLY Simple way to make your sprite jump!

Yeh but thats for a MOVING sprite this is for a moving background but a STATIC Character so you can move!

Its not your fault though i didn't put that in first!
---->Strawz<----

_________________________________________________________________________________
Copy and paste this into your Signature if you think people that STEAL your project and say it was them who done it, can't really program on scratch coz they have to steal other peoples projects!

Last edited by WEESTRAWZ (2008-02-17 16:44:31)

Offline

 

#4 2008-02-17 20:43:51

le_cassie_d
Scratcher
Registered: 2008-02-17
Posts: 15

Re: A REALLY REALLY Simple way to make your sprite jump!

I tried the one that archmage posted and it is easier(sorry strawz). But I still need to know how to move left and right while jumphing. Please help me this is my first day on Scratch!

Offline

 

#5 2008-02-17 21:16:42

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: A REALLY REALLY Simple way to make your sprite jump!

le_cassie_d wrote:

I tried the one that archmage posted and it is easier(sorry strawz). But I still need to know how to move left and right while jumphing. Please help me this is my first day on Scratch!

Heres a simple movement script.

<when green flag clicked>
<forever>
<if> <key[ right ]pressed?>
<change x by( 5
<end>
<if> <key[ left ]pressed?>
<change x by(- 5
<end>
<end>


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#6 2008-02-17 23:55:12

le_cassie_d
Scratcher
Registered: 2008-02-17
Posts: 15

Re: A REALLY REALLY Simple way to make your sprite jump!

Thank You Sooo Much!

Offline

 

#7 2008-03-15 19:14:51

glough_guy
Scratcher
Registered: 2008-03-11
Posts: 91

Re: A REALLY REALLY Simple way to make your sprite jump!

archmage, you should be a forum moderator, helping people out.


please be nice to me on scratch.

Offline

 

#8 2008-03-15 19:32:29

FPSFelix
Scratcher
Registered: 2008-02-06
Posts: 100+

Re: A REALLY REALLY Simple way to make your sprite jump!

if you want a simple jump script that is actually useful, then try this<when green flag clicked><forever><if>key up arrow pressed<change{ y vel}by( 5)
<change y by( y vel


this is what i brought you, this you can keep.
this is what i brought, you may forget me.
i promise to depart, just promise one thing...
kiss my eyes and lay me to sleep.

Offline

 

#9 2008-03-15 19:35:25

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: A REALLY REALLY Simple way to make your sprite jump!

FPSFelix wrote:

if you want a simple jump script that is actually useful, then try this<when green flag clicked><forever><if>key up arrow pressed<change{ y vel}by( 5)
<change y by( y vel

That script will make a sprite move up but not back down.


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#10 2008-03-16 10:17:02

FPSFelix
Scratcher
Registered: 2008-02-06
Posts: 100+

Re: A REALLY REALLY Simple way to make your sprite jump!

yeah, but then you have
if not touching<whatever ground color or sprite is>
change y vel by -0.1

and

if touching<whatever ground color or sprite is>
set y vel to 0


this is what i brought you, this you can keep.
this is what i brought, you may forget me.
i promise to depart, just promise one thing...
kiss my eyes and lay me to sleep.

Offline

 

#11 2008-03-16 12:24:02

archmage
Scratcher
Registered: 2007-05-18
Posts: 1000+

Re: A REALLY REALLY Simple way to make your sprite jump!

Why didn't you mention that in your other post then? You can't expect people to already know these things.


Hi, I am Archmage coder extraordinaire. I do Scratch,pascal,java,php,html, AS2 and AS3. Leave me a message if you want coding advice. Also check out my personal website, lots of good stuff about web development, Flash, and Scratch (v1 and v2) !

Offline

 

#12 2008-03-16 16:58:20

zachandrew0123
Scratcher
Registered: 2008-02-28
Posts: 500+

Re: A REALLY REALLY Simple way to make your sprite jump!

thanks you all

Offline

 

#13 2008-03-16 17:02:31

zachandrew0123
Scratcher
Registered: 2008-02-28
Posts: 500+

Re: A REALLY REALLY Simple way to make your sprite jump!

now im gonna make a game called cyclone

Offline

 

#14 2008-03-16 17:31:21

FPSFelix
Scratcher
Registered: 2008-02-06
Posts: 100+

Re: A REALLY REALLY Simple way to make your sprite jump!

well, i figured that with a little experimentation, they could figure it out themselves instead of being handed everything by other people


this is what i brought you, this you can keep.
this is what i brought, you may forget me.
i promise to depart, just promise one thing...
kiss my eyes and lay me to sleep.

Offline

 

#15 2008-03-16 20:31:27

adityasm9
Scratcher
Registered: 2008-03-12
Posts: 100+

Re: A REALLY REALLY Simple way to make your sprite jump!

I combined som idas here and got a pretty smooth jump. I'll post it soon.
big_smile

Offline

 

#16 2008-08-30 08:03:32

Oddworld
Scratcher
Registered: 2008-08-30
Posts: 1

Re: A REALLY REALLY Simple way to make your sprite jump!

Yes It helped Its out team Oddworld if you got an of us games comment massage us.

Offline

 

Board footer