Skip to content

Please update your browser

Your browser version is not supported by this site. CS First may not work properly. Learn more

arrow_back Alternate Ending

Transcript

In this add-on, you will create an alternate ending to your storyboard based on user input.

To do this, you will create a decision point in your story, and create a new scene.

In an interactive story or game, a decision point lets the user decide what action the character will take next, such as whether it will turn right or left, swim the moat or climb the castle wall, or fight an enemy or retreat.

First, choose the spot in your story where the decision point will be, then select the sprite there.

This example uses the third scene so that the user’s decision will decide the story’s end.

Next, decide what the decision point will be.

Will the sprite choose which way to move, such as right or left?

Or, will the sprite perform one action or another?

Then, ask the user to choose.

At any point in your scene, add an “ask” block to present the choice.

Detach the code below it.

Add an “if/else” block under the “ask” block.

Drag out an “equals” block, and add it to the "if/else” block.

Add the “answer” variable in the first value of the "equals" block.

In the other value, type in the decision.

Place the code you detached in the first part of the “if/else” statement.

Test it out.

Click on the stack.

The story plays, and the user answers a question.

Type in your response, and the original ending plays.

It works!

Next, provide an alternate ending.

In this example, the backdrop of scene 4 changes depending on the user’s decision.

To make a new scene, click on the stage, then the costumes tab.

Right click the backdrop you are using, and select “duplicate.”

Click the new backdrop.

Edit the new backdrop to include a different scene.

Click on “add,” and find a backdrop you like.

Click OK.

The new backdrop is much too big.

Drag the corner of the new backdrop to make it slightly larger than a fourth of the stage.

Then, position the backdrop so that it doesn’t overlap with the other scenes.

Zoom into the center to make the adjustment precise.

Nice!

Next, program the “else” portion to make an alternate ending.

Based on the user’s decision, come up with another storyline.

Place the blocks you use in the “else” portion.

Once scene 3 ends, add a “broadcast” block, and create a new message.

Name it “alternate ending."

Select your fourth scene sprite.

Drag out a “when I receive” block, and select “alternate ending” from the dropdown.

From the looks menu, add a “switch backdrop” block, and change the dropdown to the new backdrop.

At this point, add blocks to finish the story.

Use the characters that you have or make new ones to complete the story.

When you finish, a decision point will change the backdrop and the story based on the user’s answer to a question.

Now, it’s your turn.

Program a decision point using “ask,” “answer,” “equals” and “if/else” blocks.

Create a new backdrop.

Program an alternate ending using “broadcast” and "switch backdrop” blocks.

Choose an Add-On
Reveal the Frames
Alternate Ending
Music Scoring
arrow_backward Back
Next arrow_forward
Instructions
  1. Watch the video to preview the add-ons.
  2. Choose an add-on, and click "watch" to learn how to build it.
  3. After you finish, come back to this page and try another one!