ROLL THE DICE !!
Hello friends !!
I am Anupriya.M
I have done a project called " ROLL THE DICE !! "
This is a two player game. In my project the microbit works as a dice. Each time when we give shake, the microbit will give us a random number upto six in each microbit. And when we click the button "A" , it'll show us the sum of the numbers rolled in each dice.
For example : If I get the number 5 and my opponent has 2 and when we roll again and at that time if I get the number 3 and my opponent has 4, if we click the button "A", the microbit will sum the numbers and give us the answer , as 5 + 3 = 8 and 2 + 4 = 6 . And goes on calculating....
IF YOU SCORE MORE THAN YOUR OPPONENT, THEN YOU WIN THE GAME !
You can also have a healthy challenge between your friends that " I AM SURE THAT 2 + 4 + 7 = 13 ! "
And then check your Answer whether is it correct !
COMPONENTS USED : 2 Microbits
Downloads
STEP 1 :
First , I have dragged ON START and Inside that I have attached the set block and show string " me ".
And then I dragged ON ' SHAKE ' and Inside that I have attached set roll to pick random 1 to 6, and below that I have attached that change sum by roll and below that I have attached the If block and below that I have gave clear and then I have given wait for 2 seconds, below that I have attached the show led block .Then I have done the same for six numbers. And then I have dragged ON BUTTON ' A ' and below that I have given show string sum.
STEP 2 :
I HAVE DONE THE SAME THING WHICH IS IN THE MICROBIT 1 !!
I have just duplicated it.