Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: SImulation of an Inventory.

by frozenwithjoy (Priest)
on Jun 23, 2012 at 02:49 UTC ( [id://977929]=note: print w/replies, xml ) Need Help??


in reply to SImulation of an Inventory.

If you'd like to incorporate dice rolls beyond using rand(), you should take a look at Games::Dice. For example roll '3d6+1' will return a value from 4 to 19.

Replies are listed 'Best First'.
Re^2: SImulation of an Inventory.
by Dipseydoodle (Acolyte) on Jun 23, 2012 at 10:49 UTC

    Thank you all. I'll go ahead and fix those then, I didn't know there was a need for eq, or a different call (I am totally self-taught here). I like the idea of the givens to by the way.

    @Superdoc That would make perfect sense, however I used the rand() for a reason. I need only a roll of 6 at max, and this is simply for random events.

    Thanks.

        Thanks. I read the cut your developing in half one. It totally makes sense now.

        Also, I have been using perldocs.perl.org, I think that counts right?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://977929]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (5)
As of 2024-04-24 06:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found