how to make a game alway start with 10 points? it's very important i need to know because it's my school project.
Offline
<when green flag clicked>
<set{ score }to( 10 )
Offline
Just like Puppet Adventurer said. There are several different methods, however, using the red variables is the easiest way. Remember that operators (Green Blocks) can be used to create comparisons. For example,
When Flag Clicked,
Set Score to 10,
If: (Score > 1),
Then: If: Up Arrow Pressed
Then: Move 2 Steps,
This code allows a character to move until the Score hits 0. This is commonly used for creating RPGs, Fighting Games with HP, or timed Games. If this isn't clear enough, that's OK, I'll go more into depth. If I were to write the code out in a sentence, I would say:
"After the flag has been clicked, if the score is above 1, (I.E. not 0), then allow the character to move forwards 2 steps at a time when the up arrow is pressed." Or "The character can only move forwards by way of the up arrow when the score is above 1."
Hope that helped, and good luck with your school project.
- 3DBlenderRender
Offline