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

#1 2012-11-27 16:35:37

siltmonkey
New Scratcher
Registered: 2012-10-03
Posts: 3

Sprite moving off-screen

Hi

Is it possible for a sprite to move off screen then appear on the opposite side but still going in the same direction?  So if it went off the left-hand screen, moving left, it would appear on the right-hand screen, still moving left, and would continue ad infinitum until you commanded it to move.

Thanks

Offline

 

#2 2012-11-27 17:43:20

ErnieParke
Scratcher
Registered: 2010-12-03
Posts: 1000+

Re: Sprite moving off-screen

Yes, this is possible. Here is what you'd use:

when gf clicked
repeat until (done?)
 change x by (-1)
 if <(x position) = (-240)>//Change to make your sprite disappear at a different point.
  hide
  wait (1) secs
  set x to (240)
  show
 end
end
Command scripts here.
I hope that this helps!

Last edited by ErnieParke (2012-11-27 18:13:09)


http://i46.tinypic.com/35ismmc.png

Offline

 

Board footer