« All Events
3 PM – Scratch Level 2 – Allison
January 15, 2022 @ 3:00 pm - 4:00 pm
Today we:
- Continued the Spaceship 2.0 project
- Coded Fireball clones to delete when touching the Asteroid clones
- Create the fireball variable
- Set it the fireball variable to 2 when the Green Flag is clicked
- Set a limit on how many fireballs we can create. Once the fireball variable reaches 0, we cannot create any more fireballs
- Coded the fireball variable to go up by 1 when the Rocketship sprite touches Fireball Power-up clones
- Coded the Fireball Power-up clones to delete when touching the Rocketship sprite
- Created the Bomb Power-up sprite
Homework:
- Kevin:
- Try to figure out why your Bomb clones are not showing so it’ll be easier for you to do your homework. Don’t worry if you can’t figure it out, we will go over it next week
- Everyone:
- Set a limit on how many bombs we can use by following the instructions below:
- Create a bomb variable and set the bomb variable to 2 when the Green Flag is clicked
- Add codes so Bomb clones can only be created when the bomb variable is greater than 0
- Code the bomb variable to go up by 1 when the Rocketship sprite touches the Bomb Power-up clones
- Code Bomb Power-up clones to delete when touching Rocketship sprite
- You can look at codes in the Rocketship sprite and Fireball Power-up sprite for help
- Contact us if you have any questions or need any help