Five Gods Exiled — 148 of 191

Carolyn VanEseltine

Release 1

Chapter 2 - Generating Intrinsic Mementos

To generate an intrinsic memento:

say "(Generating an intrinsic memento. ";

let the temporary count be 1 + the current danger level;

while the temporary count > 0:

let K be a random number between 1 and 12;

if K is 1:

now the attack boost of the current imemento is 1 + the attack boost of the current imemento;

otherwise if K is 2:

now the speed boost of the current imemento is 1 + the speed boost of the current imemento;

otherwise if K is 3:

now the defense boost of the current imemento is 1 + the defense boost of the current imemento;

otherwise if K is 4:

now the movement boost of the current imemento is 1 + the movement boost of the current imemento;

otherwise if K is 5:

now the awareness boost of the current imemento is 1 + the awareness boost of the current imemento;

otherwise if K is 6:

now the stealth boost of the current imemento is 1 + the stealth boost of the current imemento;

otherwise if K is 7:

now the strength boost of the current imemento is 1 + the strength boost of the current imemento;

otherwise if K is 8:

now the stamina boost of the current imemento is 1 + the stamina boost of the current imemento;

otherwise if K is 9:

now the will boost of the current imemento is 1 + the will boost of the current imemento;

otherwise if K is 10:

now the knowledge boost of the current imemento is 1 + the knowledge boost of the current imemento;

otherwise:

let L be a random number between 1 and 7;

if L is 1:

now the attack boost of the current imemento is the attack boost of the current imemento - 1;

otherwise if L is 2:

now the speed boost of the current imemento is the speed boost of the current imemento - 1;

otherwise if L is 3:

now the defense boost of the current imemento is the defense boost of the current imemento - 1;

otherwise if L is 4:

now the movement boost of the current imemento is the movement boost of the current imemento - 1;

otherwise if L is 5:

now the awareness boost of the current imemento is the awareness boost of the current imemento - 1;

otherwise if L is 6:

now the stealth boost of the current imemento is the stealth boost of the current imemento - 1;

otherwise:

now the temporary count is the temporary count + 1;

now the temporary count is the temporary count - 1;

let M be 0;

while M is 0:

let L be a random number between 1 and 3;

if L is 1:

now the consumption style of the current imemento is food-based;

say "L is [L]. The current imemento is now [consumption style of the current imemento]. ";

now the current imemento is edible;

otherwise if L is 2:

now the consumption style of the current imemento is drink-based;

say "L is [L]. The current imemento is now [consumption style of the current imemento]. ";

now the current imemento is edible;

otherwise if L is 3:

now the consumption style of the current imemento is scroll-based;

say "L is [L]. The current imemento is now [consumption style of the current imemento]. ";

let the temporary consumption style be the consumption style of the current imemento;

sort the potential name list of the temporary consumption style in random order;

say "The list of options for [temporary consumption style] is [the potential name list of the temporary consumption style]... ";

now the memento-type of the current imemento is entry 1 of the potential name list of the temporary consumption style;

say "Updating memento-type to [memento-type of the current imemento]. ";

sort the potential adjective list of the temporary consumption style in random order;

now the memento adjective of the current imemento is entry 1 of the potential adjective list of the temporary consumption style;

say "Updating memento adjective to [memento adjective of the current imemento]. ";

sort the color list in random order;

now the color of the current imemento is entry 1 of the color list;

say "Updating memento color to [color of the current imemento]. ";

repeat with target imemento running through mementos:

if the target imemento is not in Z1 and M is 0:

if (the memento-type of the current imemento is the memento-type of the target imemento) and (the memento adjective of the current imemento is the memento adjective of the target imemento) and (the color of the current imemento is the color of the target imemento):

say ". Rejecting [the current imemento] because it matches [the target imemento]; rebuilding the appearance....";

now M is 0;

otherwise:

now M is 1;

say "[the current imemento] has been accepted.)".