Goal:
With all of our hit animation and lives lost code done, we need to add a way to actually win the game. What we are going to do is add a way for the Star Destroyer to trigger a win screen.
Steps:
- In the Star Destroyer sprite, find the IF statement that deals with what happens if the boss is out of life.
- Delete the delete this clone block.
- From Looks, place a hide block inside of the IF statement.
- From Events, place a broadcast block.
- Select “New message” and type “Win” into the window.
- Make sure the broadcast block is set to Win.