RolePlay onLine RPoL Logo

, welcome to Technical Discussions

12:18, 27th April 2024 (GMT+0)

Randomness and the die roller.

Posted by jase
jase
admin, 1316 posts
Your caring dictator
Insert feature request
Mon 21 Feb 2005
at 15:45

Randomness and the die roller.

The die roller utilises Perl and the /dev/urandom device on RPoL's Debian server.

It is seeded once, automatically, by Perl.
QuietRain
member, 53 posts
Beware my stash of pointy
d4's oh nosy one.
Thu 24 Feb 2005
at 01:21
  • msg #2

Re: Randomness and the die roller.

I hope this is the correct place to post this.  If not, I have my flame-retardant clothes on so flame away with where I should have posted if I had any sense. ;)

I was wondering if the dice roller had a feature either now or will have one in the next version, where past rolls can be seen.  I know the dice roller shows a large number of the most recent rolls, but is there a way for a GM to view all rolls that have been made in their games?
jase
member, 1325 posts
Your caring dictator
Insert feature request
Thu 24 Feb 2005
at 16:00
  • msg #3

Re: Randomness and the die roller.

No, it's a cyclic log of 100 lines.  This is because storage space isn't infinite.
QuietRain
member, 54 posts
Beware my stash of pointy
d4's oh nosy one.
Thu 24 Feb 2005
at 19:08
  • msg #4

Re: Randomness and the die roller.

*sigh*  Well, it was worth a try.  Thanks Jase!
Kalijo
member, 1 post
Mon 14 Mar 2005
at 07:57
  • msg #5

Re: Randomness and the die roller.

Is there a way to roll severall dies at once, and show the dies separately?

The DSA system (which we use for the german Borbarad campaign) uses 3 rolls of w20 for skills. But the rolls ain't added together. Each roll is equivalent to an attribute test. If you fail the roll, you can use your skill points to make up for the miss. If you have still 0 or more skill points left over after the 3 rolls, you succeeded.

Now we could always make 3 rolls with 1W20, but this will clutter the log rather fast.

So any way to do the whole roll at once?
bigbadron
member, 3222 posts
He's Big, he's Bad,
but mostly he's Ron.
Mon 14 Mar 2005
at 08:32
  • msg #6

Re: Randomness and the die roller.

Yes.  :)

Set it to 3d20, then select "One Roll Engine" from the pop-up menu of game systems.  This will give you a total, but will record the individual rolls too.

eg: Admin rolled 24 using 3d20 with rolls of 16, 5 & 3.

Note that, AFIK, the rolls are listed in descending order, so if the order is important then you're better rolling seperately.

Hope this helps.
Kalijo
member, 3 posts
Mon 14 Mar 2005
at 08:55
  • msg #7

Re: Randomness and the die roller.

Yes, it does help. Means we have to roll spearately :(.
daherm
member, 77 posts
I'm a loser baby,
so why dontcha kill me...
Tue 15 Mar 2005
at 00:17
  • msg #8

Re: Randomness and the die roller.

just out of curiousity, how would ascending/descending order make a difference? either you read it left to right, r right to the left? either you have a # above which the task fails (so you ignore all numbers above that point) or a task at which only a above a # does it succeed, so you ignore everything below that...

i'm confused as to how it would matter really
nyanthus
member, 74 posts
I hate procrastinating...
but can't seem to help it
Tue 15 Mar 2005
at 00:37
  • msg #9

Re: Randomness and the die roller.

I can see it mattering, I can't see why you don't... you want randomness in the results. Period, not a sequence.
bigbadron
member, 3227 posts
He's Big, he's Bad,
but mostly he's Ron.
Tue 15 Mar 2005
at 00:44
  • msg #10

Re: Randomness and the die roller.

Uh... the results are random, or as near as you can get.  They're just sorted into a sequence.

Yes, they could be kept in the order they were rolled, but the One Roll Engine was originally implemented for GMs who want to roll up to 20 dice, and see how many of those dice were higher than a specific number.
Having them sorted makes it easier to see that.
nyanthus
member, 75 posts
I hate procrastinating...
but can't seem to help it
Tue 15 Mar 2005
at 00:49
  • msg #11

Re: Randomness and the die roller.

Well, putting it that way, I can see some use to it...
Kalijo
member, 4 posts
Tue 15 Mar 2005
at 07:30
  • msg #12

Re: Randomness and the die roller.

I'll try to explain it.

Lets take my char Mara (a very nice, but rather small witch) and a climbing roll as example:

Climbing is rolled vs:courage/dexterity/strength. Mara has a climbing skill of 2(very low), a courage of 14(high), a dexterity of 15(very high), and a strength of 7(extremely low).

Now I throw the dices: 14, 17, 6.

OK, my courage roll is a bare success (14/14). My dexterity roll would be a miss, but I can use 2 of my climbing points to "make up" for it (17/15+2). The strength roll is a sucess (6/7). All together I barely made this climb, with 0 skill points left. The GM would describe how I reach the top, needing severall minutes to recover my senses.

Now what happens if the dice are sorted?

17, 14, 6

OK, my courage roll is a miss, and I can't make up for it (17/14+2). My dexterity roll would be a success (14/15). The strength roll is a sucess (6/7). All together I miss the climb by 1 point, so a failure. The GM would describe that I start to climb, but lose courage halfway and now sit a few steps below the top of that ravine, afraid to move further.

6, 14, 17

Now I would have no courage problem (6/14), and also would be dexterious enough (14/15). But halfway up the ravine my strength gives way, and I sit there, totally exhausted (17/7).

As you see, there is a major difference if the rolls are sorted or not.
bigbadron
member, 3228 posts
He's Big, he's Bad,
but mostly he's Ron.
Tue 15 Mar 2005
at 09:19
  • msg #13

Re: Randomness and the die roller.

Yeah, I thought it'd be something like that from your previous post.  :(

What you describe there isn't really a single roll of 3d20, but three separate rolls of 1d20, against three different target numbers.
Easy enough to do as a single roll in a tabletop environment, where you have access to different colours/sizes of dice, but here it has to be done as three separate rolls, unless jase decides to code for this system.
jase
member, 1350 posts
Your caring dictator
Insert feature request
Tue 15 Mar 2005
at 09:52
  • msg #14

Re: Randomness and the die roller.

I already have.  Well, in 1.5 I have.  I'm afraid you'll have to wait for the next version, whenever it eventually arrives.
bigbadron
member, 3230 posts
He's Big, he's Bad,
but mostly he's Ron.
Tue 15 Mar 2005
at 10:06
  • msg #15

Re: Randomness and the die roller.

There ya go, Kalijo.  What's yer problem?  :p
Kalijo
member, 6 posts
Tue 15 Mar 2005
at 11:36
  • msg #16

Re: Randomness and the die roller.

Hmm, Jase, if you are at it, mind to add the dice system that I described as "DSA"?

As I said, its easy.

3 rolls of W20 vs. 3 Attributes.
A positive skill number can be used to replace missing points.
A negative skill number is substracted from all attrributes. So in my example a skill of -1 in climbing would reduce my STR to 6 :(.

So the only imput needed would be the effective skill value (after application of all modifiers).

The "result" is how many skill points you have left over after doing the whole roll. 0 skill points is barely successfull, 10+ is a masterly success, 18+ is perfect. Also most skills (and especially spells) do use that number directly.

For example Mara just used a spell called Satuarias Magnificence. I made the roll with all 5 skill points left over. This results in a bonus of 5 points on all bewitch/charm rolls in the next 5 hours.

As you see, this system might be a bit more complicated then the usual "x dice added roll", but gives lotsa information to the GM, be it succeeding or missing.

Oh yeah, I forgot: duple or triple 1 or 20 rolls are of course rather interessting results.
This message was last edited by the user at 11:39, Tue 15 Mar 2005.
jase
member, 1351 posts
Your caring dictator
Insert feature request
Tue 15 Mar 2005
at 13:21
  • msg #17

Re: Randomness and the die roller.

The dice roller just needs to know how many die are being rolled, what size  the die are, what the modifiers are and if there's anything like a target number, re-rolling, etc etc.

If you can explain the system in those terms then I most certainly can.  Alas your current description leaves me more than just a little confused.  I don't even know what a W20 is!
Kalijo
member, 7 posts
Tue 15 Mar 2005
at 13:55
  • msg #18

Re: Randomness and the die roller.

Ups sorry, a W(ürfel)20 is of course a d(ice)20.

OK, efficently you'll need 4 input variables: the value of the 3 attributes, and the modified skill value.

Then it works like this:

If the modified skill value is a negative number, substract it from all 3 attribute values, and set the skill value (internally) to 0.

Throw 1d20, target number is the first attribut value. If unsuccessfull, substract the difference between the roll and the target number from the skill value.

Do so as well for the second and third attribute value.

If after this three rolls (and possible reductions) the skill value is still positive or 0, the whole roll is a success.

Print the left over skill value.

If the number is negative, the whole roll is a failure. Print out the amount of the skill value (allowing the GM to judge the size of the failure).

If two or more of the rolls habe been 1 or 20, print it out instead of the skill value (2*20 is always a failure, 3*20 is a catasthropic failure, with 1s the opposite).
jase
member, 1352 posts
Your caring dictator
Insert feature request
Tue 15 Mar 2005
at 16:31
  • msg #19

Re: Randomness and the die roller.

Alas I don't think the current dice roller can cope with such a complicated rolling system, there's not three input areas for the dice.  Will see what I can do...

What's the opposite of a catasthropic failure?
Kek
member, 189 posts
Denwen-Uluis-Ammit-Keku
99% these chars are me.
Tue 15 Mar 2005
at 16:43
  • msg #20

Re: Randomness and the die roller.

A miracle.
Eberhelm
member, 1 post
Tue 15 Mar 2005
at 16:59
  • msg #21

Re: Randomness and the die roller.

Hello... :)
I guess all we need is just a roller that does not arrange the values. That would already be great.

If you are interested in the rolling system of DSA (the dark eye), I made a rolling program a while ago, but it is written in C. Just translated it into english.
http://www.tu-harburg.de/~siak0539/tmp/diceroller.c
nyanthus
member, 78 posts
I hate procrastinating...
but can't seem to help it
Tue 15 Mar 2005
at 17:16
  • msg #22

Re: Randomness and the die roller.

Actually, I think just a Target Number would be nice... as an optional feature.

Target# for success of fail.

The Target number could also have the following options (or higher, or lower is equal to, is not equal to, etc)

Examples:

Stelerp needs to roll 18 or above to hit his opponent.

(Target 18 or higher) Roll 1d20+5 (Plus reason for roll)

Stelerp rolled 13, (Reason for Roll); Stelerp failed to roll above 18.

or

Stelerp rolled 23, (Reason for Roll); Stelerp succeded in rolling above 18.

If a target value isn't selected, the dice roller stays as is.
Kek
member, 190 posts
Denwen-Uluis-Ammit-Keku
99% these chars are me.
Tue 15 Mar 2005
at 17:18
  • msg #23

Re: Randomness and the die roller.

I thought there was a target number function.

Anyway, not everyone knows the number they need ot hit something.
Kalijo
member, 8 posts
Tue 15 Mar 2005
at 17:32
  • msg #24

Re: Randomness and the die roller.

Well, the opposite of a catastrophic failure isn't a miracle (except if you play a priest char). But its extremely beneficial. If you have a very nasty GM it could even be TOO beneficial. :D usually 3*1 will result in an automatic raise of the skill also.
bigbadron
member, 3233 posts
He's Big, he's Bad,
but mostly he's Ron.
Tue 15 Mar 2005
at 17:41
  • msg #25

Re: Randomness and the die roller.

Kek:
I thought there was a target number function.

Anyway, not everyone knows the number they need ot hit something.
Yes, there is a target number function, which can be used with some of the Systems that you can select, usually the ones that require the user to keep track of how many successes he achieves with a handful of dice.

Edit:  Because I forgot something.  :o
This message was last edited by the user at 18:01, Tue 15 Mar 2005.
Korel
member, 121 posts
Fri 18 Mar 2005
at 17:45
  • msg #26

Re: Randomness and the die roller.

Sorcerer system, without the sorting, would be useful in D&D/d20 areas, particularly high level ones. Instead of 5 or more attack rolls in the buffer, 1 roll. Instead of 30 or so separate rolls for a dispel magic, one roll (after a post describing their order)  etc... easier for everyone to reference, easier to read, less likelt to forget a roll since the buffer will effectively be much larger, just easier in general. Just about anything that uses sets of similar but separate rolls could use the unsorted version, I think.

I don't know about difficulty, but if a check box were in the sorcerer system for sorted or unsorted, or if the two could be labeled sorcerer sorted, and sorcerer unsorted, I'd be very happy.
bigbadron
member, 3255 posts
He's Big, he's Bad,
but mostly he's Ron.
Fri 18 Mar 2005
at 19:52
  • msg #27

Re: Randomness and the die roller.

Well, the One Roll Engine, like the Sorcerer System, will allow you to roll up to 20 dice, and will give details of what was rolled on each individual die.  There is no restriction on the type of die used, so it would work for d20, just as well as anything else.

The results are sorted into descending order.

In RPoL v1.5 there will be an unsorted version of the One Roll Engine.  :)
This message was last edited by the user at 19:56, Fri 18 Mar 2005.
Kalijo
member, 9 posts
Fri 18 Mar 2005
at 21:57
  • msg #28

Re: Randomness and the die roller.

This would be very helpful, as this shortens DSA rolls to one roll = one line.
jase
member, 1397 posts
Your caring dictator
Insert feature request
Mon 11 Apr 2005
at 23:35
  • msg #29

Re: Randomness and the die roller.

For those ever doubting the randomness of the dice roller, here's the output of a program called 'ent'.  Ent is a Pseudorandom Number Sequence Test Program.  http://www.fourmilab.ch/random

Program output is in green, my comments are in blue.

Entropy = 7.999965 bits per byte.

Optimum compression would reduce the size
of this 5000000 byte file by 0 percent.

A file that can be compressed because of predictable patterns has Entropy of about 4.9 (meaning compression would reduce it by about 38%).  Here RPoL's random generator clearly demonstrates it really has no predictable pattern (8 being a perfect score, 7.999965 being close enough!)

Chi square distribution for 5000000 samples is 242.74, and randomly
would exceed this value 50.00 percent of the times.

"The chi-square test is the most commonly used test for the randomness of data, and is extremely sensitive to errors in pseudorandom sequence generators."

50% = Win.


Arithmetic mean value of data bytes is 127.4919 (127.5 = random).
Based on a binary file, each character can range from the mathematical value of 0 to 255, inclusive.  Thus the average should be, as stated by the program, 127.5.

And for those thinking "oooh, but it's a bit below average" well two things; it's 0.006% below average, and other runs returned values above 127.5.


Monte Carlo value for Pi is 3.143094057 (error 0.05 percent).
Some complicated algorithm.  Bad algorithms will get above 1% here.

Serial correlation coefficient is 0.000065 (totally uncorrelated = 0.0).
For those who complain about groupings of similar numbers.  This is the extent to which each byte depends upon the previous byte.


The dubious and inquisitive who want to run their own analysis on the file can  find it at; http://beta.rpol.net/test/random.dat.  It's a 5,000,000 byte (~5mb) binary file.
bigbadron
member, 3436 posts
He's Big, he's Bad,
but mostly he's Ron.
Mon 11 Apr 2005
at 23:53
  • msg #30

Re: Randomness and the die roller.

That's all well and good, but nowhere in there does it say, unequivocally, that the dice roller doesn't hate me, personally, with an obsessive enmity that would make Captain Ahab look cool, calm and collected.  :(

;)
jase
member, 1399 posts
Your caring dictator
Insert feature request
Tue 12 Apr 2005
at 06:22
  • msg #31

Re: Randomness and the die roller.

Oh it's not the dice roller!
confused.brit
member, 293 posts
Beware - I bite
With poision fangs
Wed 13 Apr 2005
at 12:55
  • msg #32

Re: Randomness and the die roller.

No ron, it's the website owner ;)
bigbadron
member, 3440 posts
He's Big, he's Bad,
but mostly he's Ron.
Wed 13 Apr 2005
at 13:09
  • msg #33

Re: Randomness and the die roller.

No, it's not.  It's everybody.
confused.brit
member, 294 posts
Beware - I bite
With poision fangs
Wed 13 Apr 2005
at 13:11
  • msg #34

Re: Randomness and the die roller.

I dunno

I don't know you enough to hate you.

Mildly dislike however.... ;)
Banaticus
member, 88 posts
Lake Arrowhead, CA
Thu 14 Apr 2005
at 03:47
  • msg #35

Re: Randomness and the die roller.

bigbadron:
No, it's not.  It's everybody.
Well, we can hardly be expected to believe that after all those outpourings of "We lvoe you, bigbadron!!!111" when you were married recently. ;)
DarkwindStriker
member, 49 posts
I regret that I have
nothing witty to put here
Thu 14 Apr 2005
at 07:37
  • msg #36

Re: Randomness and the die roller.

Hey, I like him. He's amusing.

[bs]And there's nothing wrong with the dice roller, it's just on a very special diet. PCs are high in fiber while low in carbs, the ultimate food, and of course in order to work as hard as it does to roll all of the dice it does every day, it needs all the energy it can get. So be kind to the dice roller, offer it three helpings of PC daily.[/bs]

*shifty eyes* No, I was not paid by the dice roller to say that. I have no idea what you're talkig about.....
This message was last edited by the user at 07:40, Thu 14 Apr 2005.
Banaticus
member, 89 posts
Lake Arrowhead, CA
Thu 14 Apr 2005
at 18:37
  • msg #37

Re: Randomness and the die roller.

Yeah, I think he's a good guy.  Even if he is big and bad.  Did I just say an oxymoron? :)

I'm glad jase posted that stuff comparing the dice roller's randomness.  I was under the (mistaken) impression that it seeded its random function by checking out something in your system time.  So if I was rolling multiple rolls, I'd try to post like one every 5 seconds or so, so that if the first one was good I'd have something of a chance of getting the first roll again.  Superstitious?  Oh, yes.  Any truth behind it?  I don't think so.  Will I continue doing that?  Uhm, probably not.

I was under this impression from one game where I rolled up a character -- stats ranged from 1 to 8 and I rolled six 6's then a 5.
This message was last edited by the user at 18:40, Thu 14 Apr 2005.
Sign In