This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2010-11-28 19:58:23

mariners88
New Scratcher
Registered: 2010-11-28
Posts: 2

Quick Question

I am required to build a game that rolls a pair of dice, and the user needs to bet on the outcome.

I have made 2 dice with six different costumes, which was required. I also have 3 buttons, less than 7, equal to 7, and more than 7. Every time a button is clicked, roll dice is broadcasted.

This is the part I am having trouble with:
Create a variable named "Rolled For Die 1" that is only for the sprite that is the first die. When the first die received the message "Roll dice", the value of that variable should be set to a random number between 1 and 6. At this time, you can check that this is working by having the variable on the stage. After a while, you can make this variable "hidden" (by un-checking the box next to the variables name on the Variables tab).


Any tips or explanation would be appreciated.
Thanks

Offline

 

#2 2010-11-28 21:12:05

nextstorm
Scratcher
Registered: 2009-12-13
Posts: 1000+

Re: Quick Question

Hey.
I'll upload a project to help you soon  smile


bye

Offline

 

#3 2010-11-28 21:18:00

mariners88
New Scratcher
Registered: 2010-11-28
Posts: 2

Re: Quick Question

Thanks!

Offline

 

#4 2010-11-28 21:34:49

nextstorm
Scratcher
Registered: 2009-12-13
Posts: 1000+

Re: Quick Question

Here you go.
Dice


bye

Offline

 

#5 2010-11-29 07:05:19

-GizzardGulp-
Scratcher
Registered: 2010-03-05
Posts: 100+

Re: Quick Question

nextstorm wrote:

Here you go.
Dice

this sounds like a homework assignment, maybe you shouldn't have done it all...


http://i1118.photobucket.com/albums/k607/Max_Levine/SnoutmolStudios.png

Offline

 

#6 2010-11-29 22:41:31

nextstorm
Scratcher
Registered: 2009-12-13
Posts: 1000+

Re: Quick Question

-GizzardGulp- wrote:

nextstorm wrote:

Here you go.
Dice

this sounds like a homework assignment, maybe you shouldn't have done it all...

That's the point!
(jk)


bye

Offline

 

Board footer