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

#1 2010-11-21 20:23:15

Onyxsbayne
Scratcher
Registered: 2010-11-21
Posts: 100+

Jump?

I'm working on this game, and i'm having trouble's with the jump for my character.  When he jumps, if you hold down the button, he just rises up until you let go.  Plus, i can't make him change direction in midair.  Can someone help me out with that? 

P.S. what are "scratch blocks"?


~Desktop Ideas Inc: Little doodles, BIG ideas
http://scratch.mit.edu/static/icons/buddy/663911_med.png?t=2010-11-19+11%3A07%3A34http://pokefarm.org/_ext/YDZT0GZD4.png

Offline

 

#2 2010-11-21 20:25:19

gettysburg11
Scratcher
Registered: 2008-06-14
Posts: 1000+

Re: Jump?

Well, I can answer one of your questions. "Scratch blocks" are those blocky-looking things you snap together to make your project do whatever you want it to do.
For example, this is a Scratch block:
<if on edge, bounce>
This is as well:
<when green flag clicked>

Last edited by gettysburg11 (2010-11-21 20:25:35)


http://i256.photobucket.com/albums/hh184/mnacmilan/LOGO_ACMILAN-Splash.gif

Offline

 

#3 2010-11-21 20:25:59

ScratchReallyROCKS
Scratcher
Registered: 2009-04-22
Posts: 1000+

Re: Jump?

Could you upload it? That's the only way we'll be able to help you.

Scratch blocks are the script pieces that you connect together to make things work.


http://imageshack.us/a/img694/3806/sigmad.png

Offline

 

#4 2010-11-21 20:31:54

Onyxsbayne
Scratcher
Registered: 2010-11-21
Posts: 100+

Re: Jump?

1) All right, i'll upload the beta asap
2) what happens when you add it to a forum post


~Desktop Ideas Inc: Little doodles, BIG ideas
http://scratch.mit.edu/static/icons/buddy/663911_med.png?t=2010-11-19+11%3A07%3A34http://pokefarm.org/_ext/YDZT0GZD4.png

Offline

 

#5 2010-11-21 20:34:13

gettysburg11
Scratcher
Registered: 2008-06-14
Posts: 1000+

Re: Jump?

Onyxsbayne wrote:

2) what happens when you add it to a forum post

Nothing special really happens, adding blocks to posts is mainly used for showing other users the script(s) needed if they wanted to do something specific in Scratch.


http://i256.photobucket.com/albums/hh184/mnacmilan/LOGO_ACMILAN-Splash.gif

Offline

 

#6 2010-11-21 23:02:53

ruggboy1
Scratcher
Registered: 2010-09-24
Posts: 61

Re: Jump?

I like making a variable called "air", then setting "air" to 1 when you jump. You can not jump if "air" is 1. When you hit the ground (or didn't jump), set the "air" variable to 0.

Offline

 

#7 2010-11-22 00:49:59

2l84zwamani
Scratcher
Registered: 2010-09-27
Posts: 100+

Re: Jump?

When green flag clicked
Forever
If up arrow key pressed
Repeat until not up arrow key pressed
Change y by 2
EndIf
If not touching colour colour-of-the-ground
Change y by -2
EndIf
EndForever

and then

When green flag clicked
Forever
Put your rotation script here
EndForever

smile


I will be a Ms. Pickle Dr. Deadpebble Great Person <forever>
http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3http://is.gd/d55N3 GROB THE SLIME WILL TAKE OVER THE WORLD!

Offline

 

Board footer