arrow_back Second Scene
In this add-on, program a second scene for your story. This video will show you how to change the scene, then it’ll be up to you to tell the next part of your story.
To start, choose a setting for your next scene. Click choose backdrop from library, select a backdrop, and click “OK.” Think about where your characters might want to go next.
Underwater? School? This example will use a beach.
Next, program the backdrop to change after your characters finish their conversation.
Select the sprite that talks last, and click the scripts tab. Click the looks menu, add a “switch backdrop to” block to the end of the stack, and select your new backdrop from the dropdown. Click the flag. When you added the backdrop, it changed on the stage, so when the flag is clicked, it also shows the new backdrop.
To fix this, start on the clear sky backdrop by adding a “switch backdrop to” block after the “when flag clicked” block and selecting the “clear sky” backdrop.
Click the flag to test. Great, now the backdrop changes to a new scene at the end of the story, but the water and boat sprites still show. Hide these sprites when the backdrop changes.
Click the “water” sprite, and from events, add a “when backdrop switches to" block.
Select the name of your new backdrop. Then, click looks, and add a “hide” block.
Because the water sprite hides when the backdrop changes, it should also show at the start of the program. Add a “show” block under the “when flag clicked” block.
Click the flag to test. Great, when the backdrop changes the water sprite hides.
Next, program the boat sprite to hide and show. Click the boat sprite, select events, drag out a “when backdrop switches to” block, and check that the backdrop you selected matches the new scene. From looks, add a “hide” block. Then, place a “show” block under the “when flag clicked” block. Click the flag to test. Great.
To reposition the sprites in your new scene, add a “go to” block under the “when flag clicked” block for each sprite. Click and drag each sprite to where it will be in the second scene. Add a “when backdrop switches to” block from events and a “go to” block from motion. Click the flag to test. Nice! The sprites are in a different position for each scene. Now that the scene changes, add more dialogue to continue the story. For each talking sprite, add more “say” and “wait” blocks to continue your story after the backdrop switches.
Now, it’s your turn: Program the stage to start on a backdrop, and change to a new scene with “switch backdrop to” blocks.
Show the boat and water sprites at the start of the program, and hide them when the scene changes. Set each sprite’s position using “go to” and “when backdrop switches to” blocks. Create dialogue for your second scene using “say” and “wait” blocks.