To finish this project, we will add a few more details to prepare for the next project. In the next project, we want to add a boss fight to this game; but when should the boss appear? I've decided to make this a timed event. The player should survive for a certain amount of time, shooting enemies along the way to increase the power of the spear. After 90 seconds, the starfish will disappear and a boss monster will appear.
You may have also noticed that the scrolling images tend to stick to the sides of the stage before disappearing. This is a feature of Scratch to prevent you from completely losing sight of sprites. To get rid of these lingering sprites, we use a visual trick to obscure them.
Let's first work on the time limit to complete our game. We will use the built-in timer to count the seconds until the boss appears.
90
in the wait until timer > () block.To get rid of the lingering images, we will draw curtains similar to what you would see on a theater stage. This narrows the effective stage area somewhat, but that's not a problem, and the sprites can safely stay behind the curtains, out of view.
We add a short script to correctly position the sprite at the start of the game using the following steps:
0
and 0
in the go to x: () y: () block respectively.With these additions, we conclude this project. There is still more work to do, but what we have created in this project already makes for an enjoyable game. Adding the timer gives us a clear endpoint for the game and emphasizes the game goal—gather as many points as possible before the timer runs out.
3.12.136.63