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

#1 2008-09-13 14:25:34

b2bombomb
Scratcher
Registered: 2008-07-25
Posts: 1

I need help on jumping for my portal game!

ok i have been using the script from archmages "sprite movement done right" and i made it so you would have to jump on top of blocks and use portals to complete levels, well the thing that has been happening is when you hold the up arrow underneath the block you want to jump up on you go right through it to the top of the block. I tried using a wait block but that just messed everything up so i took that out. I also tried putting a different color under the block and made it so my little person would move down when it touched that color but stll if you held the up arrow long enough you just went right through it. I don't know what to do. It would be nice if a good scripter could help me out here lol!

thx 4 ur time!  big_smile

Offline

 

#2 2008-09-13 14:47:35

yambanshee
Scratcher
Registered: 2007-11-06
Posts: 500+

Re: I need help on jumping for my portal game!

i have no idea how archmage's script works but if its veriable based you could use that veriable when you hit the block by timesing it by negative 1 like this [blocks]<if><touching color[ ]
<change y by( (( <{ whtever }> <*> -1 )) )
<end>[/blocks]
Post it up and i'll have a look

Last edited by yambanshee (2008-09-13 14:48:32)

Offline

 

#3 2008-09-13 15:21:57

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

Re: I need help on jumping for my portal game!

If you don't want your character moving through the landscape try looking up my 'perfect sprite movement' project.


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

 

#4 2008-09-15 14:12:57

ShawnMcCool
Scratcher
Registered: 2008-09-15
Posts: 9

Re: I need help on jumping for my portal game!

http://scratch.mit.edu/projects/ShawnMcCool/266451

Gravity based jumping

Offline

 

Board footer