Project 93: Explosions

5. Manage Explosions

When a particle receives the explosion event it should point in a random direction and move several steps in that direction. Use random numbers and a repeat loop to accomplish your goal.
Starting point file for this challenge

Your goal

Steps

1. Grab the Event Listener

Look for the “when I receive ____” block in the Yellow Events Tab.  Make sure to switch it to the "explode" event we created last challenge. 

2. Point the Particle

Attach a "point in direction ___"  block from Motion.  This block will help tell each particle to head in a different direction.  

3. Randomize a direction

Get a "pick random 1 to 10" block from the Green Operators Tab, and switch it from 1 to 10 to 0 to 360.


4. Include Repition

Place a “repeat 10” loop below the random angle code, then switch 10 to 15.  This will help move us away from the "Target" sprite.  

5. Add a Move

Place a "move 10 steps"  to the “repeat 15" loop.  Change 10 steps to around 6.  This just makes the particle move less far.  What's wrong if we test it?

6. Fix the Remaining Particle.

Tack on a "hide" block to make the particles go away after they move.  How about we improve the looks by adding more particles.