Discuss Scratch

ScratchDyder
Scratcher
32 posts

why cant the player jump when on a platform?

https://scratch.mit.edu/projects/727258781 the player cant jump while on a platform but on the floor it can perfectly fine
legendary34678
Scratcher
1000+ posts

why cant the player jump when on a platform?

That's because falling is at 9 when you are touching the top of the platform. Since it's not 0, the player cannot jump. I would recommend checking out the Scratch Wiki's Platformer Tutorial for help regarding creating a platformer game.
shadow_amalgam
Scratcher
70 posts

why cant the player jump when on a platform?

Delete these blocks first:
if <touching [ Top of platform] ?> then
change y by (10)
set [ falling] to [9]
end
Then change these blocks:

To this:

Hope this helps!

Last edited by shadow_amalgam (Sept. 2, 2022 20:38:55)

ScratchDyder
Scratcher
32 posts

why cant the player jump when on a platform?

legendary34678 wrote:

That's because falling is at 9 when you are touching the top of the platform. Since it's not 0, the player cannot jump. I would recommend checking out the Scratch Wiki's Platformer Tutorial for help regarding creating a platformer game.
but when i set it to zero the player wont fall
ScratchDyder
Scratcher
32 posts

why cant the player jump when on a platform?

shadow_amalgam wrote:

Delete these blocks first:
if <touching [ Top of platform] ?> then
change y by (10)
set [ falling] to [9]
end
Then change these blocks
To this:
Hope this helps!
it works, but now it doesnt fall off the platform, how do i make it so that it falls off the platform too? thanks!

Powered by DjangoBB