Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » Scrolling Platformer Level Clones
- XxShazammxX
-
100+ posts
Scrolling Platformer Level Clones
Hello,
I am making a Scrolling Platformer.
This is the code in the level Sprite:

However, because of the forever loop in the “When I Start as a Clone” script, the levels appear on top of eachother.
Is there anyway to prevent this from happening?
Thanks
I am making a Scrolling Platformer.
This is the code in the level Sprite:

However, because of the forever loop in the “When I Start as a Clone” script, the levels appear on top of eachother.
Is there anyway to prevent this from happening?
Thanks

- openPoll
-
1000+ posts
Scrolling Platformer Level Clones
I think it's because you are trying to go off-screen - and to my knowledge, you can't do that. Try setting the x to -240 before cloning Hello,
I am making a Scrolling Platformer.
This is the code in the level Sprite:
However, because of the forever loop in the “When I Start as a Clone” script, the levels appear on top of eachother.
Is there anyway to prevent this from happening?
Thanks
- XxShazammxX
-
100+ posts
Scrolling Platformer Level Clones
I don't actually think that's why; Levels in Scrolling Platformers always go off screen. snip
- openPoll
-
1000+ posts
Scrolling Platformer Level Clones
Also, they are (probably) all going to the same place since there is nothing to check what costume is being used
- openPoll
-
1000+ posts
Scrolling Platformer Level Clones
All the clones are actually going to the same location - you need to make a variable that tells clones apart
- XxShazammxX
-
100+ posts
Scrolling Platformer Level Clones
I'll see if that works. All the clones are actually going to the same location - you need to make a variable that tells clones apart
- games-void-2
-
14 posts
Scrolling Platformer Level Clones
think [ttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttt(rrrrrrrrrrrrrrrrrrr)] for (foo) secs
- games-void-2
-
14 posts
Scrolling Platformer Level Clones
my barriers
when green flag clicked
forever
if <key [a v] pressed?> then
move (4) steps
if <touching color [#c3ed18] ?> then
move (-4) steps
end
end
end
- games-void-2
-
14 posts
Scrolling Platformer Level Clones
when green flag clicked
point in direction (((() - (0((((((((((((((((((((((((((((((((((((((((((((((((((((((((((() - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)) - (0)))) - (0)) v)
- games-void-2
-
14 posts
Scrolling Platformer Level Clones
define walk
forever
if <(direction) = []5000> then
change [your mom v] by (0)
say [yay!] for (2) secs
if on edge, bounce
else
set [not lisin v] to [100000000000000]
when green flag clicked
forever
if <key [q v] pressed?> then
say (your mom) for (2) secs
Last edited by games-void-2 (May 3, 2020 19:16:55)
- GuineaGod
-
500+ posts
Scrolling Platformer Level Clones
define walk
forever
if <(direction) = []5000> then
change [your mom v] by (0)
say [yay!] for (2) secs
if on edge, bounce
else
set [not lisin v] to [100000000000000]
when green flag clicked
forever
if <key [q v] pressed?> then
say (your mom) for (2) secs
Please stay on topic
- Discussion Forums
- » Help with Scripts
-
» Scrolling Platformer Level Clones