Alright, here’s a way to fake random rolls. Fake, you heard me.
I made this after I died in Breach in the middle of a fun fail state. I was a bit surprised when the story completely changed after the reload, I wanted to get back to that first version of the story. I tried dying a few times more but I never got that first scene again.
If any writer wants players to be able to retrace their steps, but keep the randomness between games and players. Here you go.
How To
The SETUP (startup.txt)
- Create a .txt file and write in the code, in this example I name the file “pseudorandom.txt”
- In startup.txt, [*create] the variable PRGseed and set it as a [*random] number at the beginning of the game, for example I set it as 3553.
- call up the generator like so:
*gosub_scene pseudorandom generator "variable name IN QUOTES" minimum_number maximum_number
for example *gosub_scene pseudorandom generator “strength” 0 20 sets the variable strength as a number between 0 and 20
The CODE (pseudorandom.txt)
>>>> create a txt file and paste this code in there!! then, delete this line<<<<
*label generator
*params variable minimum maximum
*temp a 2175143
*comment ^ multiplier
*temp c 10653
*comment ^ the increment
*temp m 1000000
*comment ^ the modulus
*set PRGseed (((PRGseed * a) + c) modulo m)
*set {variable} round((((PRGseed/m))*(maximum-minimum))+minimum)
*return
The temp variables a, c and m can all be changed but really all you need to change between games is the PRGseed variable. Remember to randomly roll that at the start of the game! Otherwise every player will have the same results as each other.
It might be a fun idea to let players input their own seed, that’s just a suggestion though!