Hi there, does enybody have any experince whit making a dice rolling? alternative dice for the board games…tnx
Hi,
May be RANDOM function like :
Value = RANDOM() * 6
thanks @Bertrand_BZH , but any tutorial or step-by-step instructions on this topic would be very much appreciated - i’m begginer and have no code knowledge
Create a container and button
Create a variable DiceResult
In the container put a title component with the variable
After the logic of the button, when component tap, set app varible, assigned value :
RANDOM_INTEGER_BETWEEN(1, 6)
You can create a rolling effect with delays between formulas
I hope it’s ok for you.
Hi, woow nice post, you are the man @Bertrand_BZH, thanks a lot, I’m very grateful.
I followed your instructions and successfully replicated your idea. I’m interested in how you would arrange colors instead of numbers… Six colors instead of six numbers? tnx
There are several ways of doing things.
You can in the container put a formula in background color/new palette/formula like:
If (DiceResult== 1, “red”, if (DiceResult == 2, “green”, if (DiceResult == … etc
I just followed your advice and it works flawlessly, thanks for your help and detailed instructions. I really appreciate.