Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Simple Russian Roulette Game

Author
Message
20Glyphs
9
Years of Service
User Offline
Joined: 7th Mar 2015
Location:
Posted: 22nd Oct 2015 02:20
Hello. I'm trying to make a Russian Roulette Game, but I'm having a problem. My main randomized shooting sometimes works as it should but sometimes doesn't. I made the timer to randomize on the click of the mouse button. The problem is that it works fine, but then it randomly crashes saying Sound Number illegal at line...etc. Here's the code:



Any help would be appreciated.
wattywatts
14
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 22nd Oct 2015 02:38
rnd(2) is 3 numbers, 0, 1, 2.
20Glyphs
9
Years of Service
User Offline
Joined: 7th Mar 2015
Location:
Posted: 22nd Oct 2015 02:48
Quote: " rnd(2) is 3 numbers, 0, 1, 2. "


Thank you. I made it rnd(1) and it still does the same thing.
amigaroy
14
Years of Service
User Offline
Joined: 6th Feb 2010
Location: Mytholmroyd West Yorkshire
Posted: 22nd Oct 2015 07:16
Try rnd(1)+1
chafari
Valued Member
17
Years of Service
User Offline
Joined: 2nd May 2006
Location: Canary Islands
Posted: 22nd Oct 2015 07:29
Quote: "I made it rnd(1) and it still does the same thing."

Sounds can't be zero....
try this:

I\'m not a grumpy grandpa

Login to post a reply

Server time is: 2024-04-24 20:45:16
Your offset time is: 2024-04-24 20:45:16