#440174 Score: 0
Profile photo of Tim K
Tim K
Member
contributor
beginner
intermediate
advanced
friend finder
junior moderator
advocate
wise owl
curious george
Group Member
355 pts
@timk

So, you do know how variables work… the math part is simpler than what you’ve got so far. Just create a third variable, e.g. “Both_Dice”, and two actions after those that randomly set the two dice:

On: Click
Action: Modify variable
Target: Both_Dice
Type: Set equal to
Value: VAR(Dice1)

On: Click
Action: Modify variable
Target: Both_Dice
Type: Add to variable
Value: VAR(Dice2)

… make sure it matches the correct names, yours won’t have blanks have they?

“Both_Dice” now contains the sum of the two value.

Then add actions similar to those changing the images:

Action: Set state
Target: Button 1
State: Enable

If “Both_Dice” equal to “1”

You’ll need 1 for each button / for each value “Both_Dice” might have.