Computer Science Canada

Craps help

Author:  Omega42 [ Thu Apr 29, 2004 10:15 am ]
Post subject:  Craps help

I'm trying to get a game of craps working but I can't get the two different dice to roll at the same time...if anyone can help it would really be apreceiated...considering its due tomorrow I would REALLY like some help if anyone can help
Thanks
~O(\/)ega~

Author:  Delos [ Thu Apr 29, 2004 11:21 am ]
Post subject: 

Wow...talk about priorotizing!

code:

var dice1 : int := Rand.Int (1, 6)
var dice2 : int := Rand.Int (1, 6)


~or~

code:

var dice1 : int
var dice2 : int
randint (dice1, 1, 6)
randint (dice2, 1, 6)


Same thing.

Author:  Paul [ Thu Apr 29, 2004 4:01 pm ]
Post subject: 

Hmm... maybe he's talking about the animation, since Idk if he'd have problem with something as simple as above. If its animation, then just have 6 faces of dice as pictures in an array, then animate random faces on both dice for a while (you know, draw one then the other, with a bit of delay), and stop, whatever subscript it stops at, is the dice roll.


: