Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » How to make a Scrolling Platformer
- Faith_247
- Scratcher
18 posts
How to make a Scrolling Platformer
Hi! I want to make a scrolling platformer, but I'm not sure how. Does anyone else know?
- j_a_n_t_i
- Scratcher
500+ posts
How to make a Scrolling Platformer
Tutorial on Scratch Wiki:
https://en.scratch-wiki.info/wiki/Scrolling_Platformer_Tutorial
https://en.scratch-wiki.info/wiki/Scrolling_Platformer_Tutorial
- DrDoe
- Scratcher
46 posts
How to make a Scrolling Platformer
Change ur Movement with Two New Variables X and Y and have those change the pos of the platform/ground
- Maximouse
- Scratcher
1000+ posts
How to make a Scrolling Platformer
This tutorial by griffpatch is very helpful.
- orangetheory
- Scratcher
500+ posts
How to make a Scrolling Platformer
Make 1 variable: scroll x. Go to your levels and apply this code:
Apply this code to your levels.
Then, go to your sprite/character and put in:
(for some reason I can't put the left arrow if statement out of the right arrow if statement so just make sure that you put that after the right arrow if statement and make sure to put a forever loop around the whole 2nd script I gave you.) -_-
I'm assuming you know the jumping code, so I hope this helps with your scrolling platformer
when green flag clicked
forever
set x to (scroll x)
change x by ((scroll x) * ((480) * ((1) - (1)))
end
Apply this code to your levels.
Then, go to your sprite/character and put in:
when green flag clicked
if <key [right arrow v] pressed?> then
change [scroll x v] by (-5)
if <key [left arrow v] pressed?> then
change [scroll x v] by (5)
(for some reason I can't put the left arrow if statement out of the right arrow if statement so just make sure that you put that after the right arrow if statement and make sure to put a forever loop around the whole 2nd script I gave you.) -_-
I'm assuming you know the jumping code, so I hope this helps with your scrolling platformer
-Frisbee- -Cricket--Basketball--Forums--Mapping--Coding--Trigonometry master--Mathematics King--Future Prime Minister--Intro-Maker-
I know HTML/CSS, and JavaScript, and with these coding skills I have made some decent projects! Test them out below!
~Archery~Cops + Robbers~
Want an intro, outro, music, effects, or more? Check out the intro shop!
The forum helpers, a place where we help people in the forums
- Faith_247
- Scratcher
18 posts
How to make a Scrolling Platformer
Make 1 variable: scroll x. Go to your levels and apply this code:when green flag clicked
forever
set x to (scroll x)
change x by ((scroll x) * ((480) * ((1) - (1)))
end
Apply this code to your levels.
Then, go to your sprite/character and put in:when green flag clicked
if <key [right arrow v] pressed?> then
change [scroll x v] by (-5)
if <key [left arrow v] pressed?> then
change [scroll x v] by (5)
(for some reason I can't put the left arrow if statement out of the right arrow if statement so just make sure that you put that after the right arrow if statement and make sure to put a forever loop around the whole 2nd script I gave you.) -_-
I'm assuming you know the jumping code, so I hope this helps with your scrolling platformer
Thanks!!! I'll try it
- Thinkright20man
- Scratcher
100+ posts
How to make a Scrolling Platformer
Griffpatch made a very useful tutorial one YouTube you can see: Scrolling Platformer Tutorial.
- Discussion Forums
- » Help with Scripts
- » How to make a Scrolling Platformer