How do I make an infinite scroller so that sprites randomly appear every so often?
Offline
I don't know what you mean about infinite scroller, but you can use
<when green flag clicked>
<forever>
<show>
<wait( <pick random( blah )to( blah )secsc>
Offline
this is what I did
http://scratch.mit.edu/projects/ShockTheHedgehog/1288143
you can use this if you want, yet making an object appear every so often would mean that you would need to be able to find a way to make the object that appears know what position to appear at
Take the Magic: The Gathering 'What Color Are You?' Quiz.Offline
Sorry, my explaining wasn't very good. What I mean is make sprite 'enemies' appear on an infinite scrolling base, without them disappearing while they're on screen, only once they have reached the edge.
Offline
If abs of X position over about 250
hide
else
show
Offline
Erm, I now have a different problem, caused by solving another problem.
As you can't draw pen on sprites, i've had to use the stage as the background, and have the 'enemies' scroll (y) instead of a scrolling background.
How do I make an 'enemy' sprite appear at the top the screen at a random time, then scroll down using scrolly and diasappear again at the bottom?
If I just use (wait (pick random)), the sprites usually don't appear at the top of the screen when I use scrolly+360*scrollno.
Last edited by fireballman (2010-10-17 15:01:33)
Offline
You will need to set a variable of the scroll Y when it first appears then use that instead of scroll no * 360
Last edited by colorfusion (2010-10-17 15:34:05)
Offline