Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
- Racing_Alyssa
-
Scratcher
14 posts
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
This is something that someone asked me to do in https://scratch.mit.edu/studios/4119818/ 

when green flag clicked
switch costume to [The first costume]
go to x: (0) y: (0)
show
forever
if <key [Right arrow]pressed?> then
glide (1) secs to x: (-300) y: (0)
go to x: (300) y: (0)
next costume
glide (1) secs to x: (0) y: (0)
end
if <key [Left arrow] pressed?> then
glide (1) secs to x: (0) y: (300)
switch costume to ((costume #) - (1))
go to x: (-300) y: (0)
glide (1) secs to x: (0) y: (0)
end
end
Last edited by Racing_Alyssa (Aug. 14, 2017 13:23:00)
- lightedblox
-
Scratcher
73 posts
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
well i mean do you want it to be controllable?
when green flag clicked
forever
if <key [left arrow v] pressed?> then
change x by (-5)
end
if <key [right arrow v] pressed?> then
change x by (5)
end
if <(x position) > (240)> then
set x to (-240)
next costume
end
if <(x position) < (-240) >then
set x to (240)
switch costume to ((costume #) - (1))
end
- Racing_Alyssa
-
Scratcher
14 posts
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
Who are u asking?
- Leafy202
-
Scratcher
100+ posts
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
Who are u asking?
The answer varies to a thousand like tries on what to do, for your you did:
when green flag clicked
switch costume to [costume1 v]
go to x: (0) y: (0)
show
forever
if <key [ right arrow] pressed?> then
if <<key [ left arrow] pressed?>> then
end
end
end
and i just added so many blocks, as you know what you posted, and to i would be braking rules not to copy…..
but did you notice that the if is inside the other ‘if’ block? that varies on what code you do.
i may be a “New scratcher”" but i have done ‘scratch before’'….
- Soildjah_24
-
New Scratcher
1 post
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
i want to know how to make them show from the side
- deepshika123go
-
Scratcher
47 posts
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
Hi how do U make one screen like switch to another by making it slide, just look at this project to see what I mean:
https://scratch.mit.edu/projects/459199646/
https://scratch.mit.edu/projects/459199646/
- potato342343
-
Scratcher
53 posts
How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle
I wanna know how to make a sprite go off screen and come back opposite side without changing any form of variable (direction, size, etc.)
- Discussion Forums
- » Help with Scripts
-
» How to make a sprite slide of a screen and come in back from the other side of the screen using a different costume, to the middle





