Copy link to clipboard
Copied
I am creating a game. The idea is that the user clicks on shape buttons with incorrect apostrophe use. I have indicated whether they are right or wrong with a sound, and by the shape button changing colour, but it would be great to also display a score which would increase or decrease depending on how many they get right. I don't want this score to affect the overall lesson score. I just want to use it to give an indication to the user of how many they got right or wrong. Is this possible? Here is a screen shot of the start screen of the game:
You cannot use the score that can be attached directly to the shape button in that case. You need to create a user variable v_score for the score.
For the shape buttons I would create two shared actions: one for the correct shape buttons, which I will label SB_Correct1.... and one for the incorrect shape buttons (SB_Wrong1,....). That action will need several commands:
Copy link to clipboard
Copied
That should be easy to implement since you are already choosing which sound to play. Create a custom variable, create a text caption wit the variable and select the action 'increment' and increment by some value.
Copy link to clipboard
Copied
And how would I create a text caption with a variable?
Copy link to clipboard
Copied
Once you have created the user variable, you can insert it just like any system variable, using the X button in the Character part of the Properties panel of the text container (can be a shape or a caption). You have to be in Text Edit mode (like when you type a text in the shape or caption).
Copy link to clipboard
Copied
What do you want to show exactly: a score that is the sum of all correct answers minus the penalty of all incorrect answers? Or do you want to show the number of correct and the number of incorrect answers. Something to consider as well: will you allow multiple clicks on the same shape button? You don't tell if you disable the shape button after it has been clicked. If you do not disable it, they can increase their score without limit by clicking several times on the same shape button.
Copy link to clipboard
Copied
Good clarification. Yes, I'd like to show the sum of correct answers minus the penalty of incorrect answers. How would I disable the shape button after 1 click? Is this just by altering the 'number of attempts' to 1 in the action panel?
Copy link to clipboard
Copied
You cannot use the score that can be attached directly to the shape button in that case. You need to create a user variable v_score for the score.
For the shape buttons I would create two shared actions: one for the correct shape buttons, which I will label SB_Correct1.... and one for the incorrect shape buttons (SB_Wrong1,....). That action will need several commands:
A similar one needed for the Wrong shape buttons, but with decrement instead of increment.