Please update your browser
Your browser version is not supported by this site. CS First may not work properly.
In this add-on, you expand the conversation with a new character.
This is a challenge add-on.
This video will help you get started, then you will figure out how to complete this add-on
on your own.
To start, make room for a new character.
Move the existing characters and their mouths to give the new character space to enter the scene.
To create a new character, draw one or duplicate one of the existing characters and modify it.
This example uses a sprite named Emma from the backpack.
Give the character open eyes and closed eyes costumes.
Then program it to blink by copying over the “define blink” and “forever blink” code from the Isabel or Malik sprites.
To include the new character in the conversation, add another parameter to the speak functions.
Click on the Malik talk sprite, and edit the speak function.
Add a string parameter named "person talking."
Set the “person talking” variable to the “person talking” parameter.
Each "speak" block now has another space at the end to set the next person to speak.
In this example, Isabel talks each time after Malik, so each of these values is set to Isabel.
Repeat this process for the Isabel sprite, and set the person talking to Malik after
each time Isabel speaks.
Click the flag to test.
The program works just like it did before.
Next, bring the new character into the conversation.
Duplicate one of the talk sprites to create a mouth for the new character.
Change the function so that the character broadcasts its own talking message.
This example creates a message called "Emma talking."
Change the value in the "when I receive" block to this new message.
Change the value in the "wait until" block to the new character's name.
Drag the “speak” blocks into the blocks palette to delete them.
Decide when the new character will enter the conversation.
In this example, Malik says, "awesome!" then the person talking is set to Emma.
In the new sprite, add a "speak" block.
Type in the new character's first line, emotion, and the person who will talk next.
In this example, the Emma sprite says, "Did somebody say pizza?!"
Continue to build out the conversation between the three characters.
You can also program the third character to appear off screen when the flag is clicked,
and then enter the scene at a later point.
In this example, when the flag is clicked, the Emma sprite and the Emma talk sprites
hide and start off stage.
When they receive the message "enter scene," the sprites show and glide on stage, then
the Emma talk sprite says, "Did somebody say pizza?!"
This is an example.
Have fun creating a new character and exploring how she or he can join in the conversation!
Remember to test your code often to catch potential bugs.
Now, it's your turn.
Create a new character, and copy over the blink code.
Add another parameter to the speak functions called "person talking."
Decide when the new character will enter the conversation, and program the character to
talk using the “speak” block.
Use your creativity and debugging skills to create a interesting conversation between
the three characters.