Dice
The player picks a chance and a side; one number is rolled.
- Kind
- one draw, a range
- Largest win
- 99x the stake
- Name in the files
- dice
- Version
- ba10c380b07e
Download this engine as one file
What the player sets
- target: the chance in basis points, 100 to 9800 (1% to 98%)
- over: false to win under the target, true to win over it
Every round also takes the return dial in basis points, 9600 to 9900, and a stake.
The round, in order
- r = int_below(10000)
- under: the roll wins when r < target. over: it wins when r >= 10000 - target
int_below(m) is a whole number from 0 to m-1: limit = 2^64 - (2^64 mod m); take values until v < limit; return v mod m. shuffle: Fisher-Yates from the end, j = int_below(i+1). Words: HMAC-SHA256(key = seed, "STORM-DRBG|" || u64be(j)), cut into big-endian u64s.
What it pays
A win pays rtp x 10000 div target (x10k), a loss nothing. The chance is target / 10000, so the return is the dial, rounded down by at most one part in ten thousand of the pay.
Tables
The tables the round uses at three points of the dial, each with its exact return. A multiple is kept in the files as a whole number times 10,000, rounded down (Storm’s multX1e4); here it is written out.
Dial at 96%
chance = target/10000; pays (x10,000) = rtp*10000 // target
Eight of the 9,701 targetsexact return 95.9902% to 96% over every target · largest win 96x
| Target (chance) | Pays | Exact return |
|---|---|---|
| 100 (1%) | 96x | 96% (24/25) |
| 500 (5%) | 19.2x | 96% (24/25) |
| 1000 (10%) | 9.6x | 96% (24/25) |
| 2500 (25%) | 3.84x | 96% (24/25) |
| 5000 (50%) | 1.92x | 96% (24/25) |
| 7500 (75%) | 1.28x | 96% (24/25) |
| 9000 (90%) | 1.0666x | 95.994% (47997/50000) |
| 9800 (98%) | 0.9795x | 95.991% (95991/100000) |
Dial at 97.5%
chance = target/10000; pays (x10,000) = rtp*10000 // target
Eight of the 9,701 targetsexact return 97.4902% to 97.5% over every target · largest win 97.5x
| Target (chance) | Pays | Exact return |
|---|---|---|
| 100 (1%) | 97.5x | 97.5% (39/40) |
| 500 (5%) | 19.5x | 97.5% (39/40) |
| 1000 (10%) | 9.75x | 97.5% (39/40) |
| 2500 (25%) | 3.9x | 97.5% (39/40) |
| 5000 (50%) | 1.95x | 97.5% (39/40) |
| 7500 (75%) | 1.3x | 97.5% (39/40) |
| 9000 (90%) | 1.0833x | 97.497% (97497/100000) |
| 9800 (98%) | 0.9948x | 97.4904% (121863/125000) |
Dial at 99%
chance = target/10000; pays (x10,000) = rtp*10000 // target
Eight of the 9,701 targetsexact return 98.9903% to 99% over every target · largest win 99x
| Target (chance) | Pays | Exact return |
|---|---|---|
| 100 (1%) | 99x | 99% (99/100) |
| 500 (5%) | 19.8x | 99% (99/100) |
| 1000 (10%) | 9.9x | 99% (99/100) |
| 2500 (25%) | 3.96x | 99% (99/100) |
| 5000 (50%) | 1.98x | 99% (99/100) |
| 7500 (75%) | 1.32x | 99% (99/100) |
| 9000 (90%) | 1.1x | 99% (99/100) |
| 9800 (98%) | 1.0102x | 98.9996% (247499/250000) |
On Storm
In Storm’s core this engine is built from this page as written, with the settings and the largest win above, and is right when it reproduces the test rounds below. The rest of this part is about the templates Storm has live today, which is the way onto Storm until then.
Our reading against Storm’s templates: fits (range). One chance from 1% to 98%.
On the templates it would take: the `range` template: one chance from 1% to 98%, pays rtp*10000 // target (x10,000). Its params are not published.
Check a build against ours
36 whole rounds, each from a seed given in the file. A build is right when, from the same seed, settings, dial and actions, it makes the same draws in the same order and pays the same amount. The seed of a test round is sha256("rain-engine-vector|<engine>|<case>|<rtp_bps>|<i>"), given in hex in each vector.
The rest are in this engine’s file, with the full result of each round. The reference build plays this engine and reproduces every one of them.