Self paced game

I am trying to create a game where students wager points before they see the question. I have figured out how they can wager the points and how to show if their submission is correct. Now I need to figure out how to add/subtract points from their total. So if they got it correct, it would add the points from their wager. If they got it incorrect it would subtract the points of their wager. Also, how can I make it so they can’t go to the next screen until they have selected a wager. Thanks!

Here is my activity so far:

I made one slide for the wager and question. You can copy/paste the entire slide. I also deleted the content sinks and used variables and the {#} button. Scores and answer checks are worked into the answer input.

I used a table for the final slide for multiple questions, including their answer, correct answer and their score based on their wager. You could still use the note if you preferred. You can see how you can total the wagers in the table CL. (Note the error is because there aren’t other questions so the score variables aren’t valid.)

Also, if you don’t like the side by side for the wager and question, the code will need to be changed because submit buttons disappear if you put anything below the input. You’d need to add in your own button, and change any input.submitted into button.pressCount>0.

Loving how this is coming along. Just FYI, there aren’t any concrete plans to deprecate the content sink. We’ll be phasing out use of the content sink internally and encourage using variable interpolation in its place, but theres nothing currently planned in the same way that rawExpression or table buttons were deprecated.

1 Like

Also, tune in to Desmos Live next week for more on this!

Thanks for the clarification. I DO like being able to see the majority of my note and just use variables for the conditional portions.

Wow! This is so cool! I appreciate all of your help with this and love how this looks! Is there any way to start them with 10 points and add and subtract from there?

Its sooooo much prettier, right? And that light fade in when you use a hidden sink for new lines of text? :chefs-kiss:

1 Like

Yes, for the cell with the total just add 10+ at the beginning, or what I just edited is this:

initialScore=10
cellContent(7,4): `${numericValue("${initialScore}+${score1}+${score2}+${score3}")}`

I like using variables, so later you don’t have to wonder what the 10 in the numericValue was for.

I was just trying to put +10 somewhere but defining it as initial score makes way more sense! What if my answers aren’t number and they are equations instead? Am I still able to use your template? And I’m assuming I would just copy/paste these two slides over and over and just change the question and what the answer would be, right?

You would need to have different conditions for the check variable in the answer input.

Here’s another thread using simpleFunction and evaluateAt. It also uses countNumberUsage to narrow down to a more specific form. You can use latex checking but that can be unreliable.