Pages: 1
Topic closed
I'm making my Victini OS and I have a talking Victini. When you click on him,he tells you if you need an update or not. When you click on him when you don't need an update,he just says random things when you click on him,but I can't make him say random things. I don't know how. Like he says "Nice weather we're having :)" or "I feel hungry..." when you click him. Anyone know?
Offline
When [Sprite] clicked
If 'Upgraded needed=Yes
Say "You need an update!"
Else
Say "No update needed!"
End if/else
Offline
RedRocker227 wrote:
When [Sprite] clicked
If 'Upgraded needed=Yes
Say "You need an update!"
Else
Say "No update needed!"
End if/else
And if you want it to be more condense...
Offline
Drag an "if/else" block form the control's section onto your scripting area. In the <> beside the if, drag a "<>and<>" block from the operators and snap it by the if into the <>. Add a "<mouse down?>" block in the first spot in the "and" block. In the second, grab a <>=<> block from the operators section into the other spot on the "and" block. Then make a variable called.... I don't know... maybe (as said above), call it "update needed?".
There will be a round block after you make the variable that looks like (update needed?).
Snap that into the first spot on the = block. Then in the other (you don't need a block for this part) type in "yes" without the quotes. Now in the "else" part of the if/else block, put a say block and make it say "Update not needed" for however many seconds you want. Do the same inside the if part (not beside the "if", inside it) and put another say block and put "Update needed!" for however many seconds then after that make another say block under the other one you made, and type in "updating... please wait" or something like that.
Then snap on a "If <name of your sprite" clicked" hat block. if you need more help with the variables, and how they calculate the "update needed" and the "update not needed" stuff, feel free to ask me.
Hope this helped!
Offline
If you want him to say random things:
1. Create a list, called: VictiniPhrases
2. Add all the phrases that you would like him to say in that list.
3. Put this script on the Victini Sprite:
You should change the update variable to 0 when starting the project. And if you have an update, change it to 1.
That will pick a random item from the list to say.
Last edited by fg123 (2011-12-21 16:41:04)
Offline
thanks all of you but,fg123's post was mostly what i was wanting. it'll be boring if he just says "You don't need an update!" all the time. but thanks again anyway
Offline
oh and i released it today: http://scratch.mit.edu/projects/Spbunny765/2234975
tell me what you think. i'll add more later.
Offline
Topic closed
Pages: 1