164 ◾ Game Magic
Tarot (seeChapter 7, Section 7.1). ere are 32 Trump spells with a variety
of eects, most of them pertaining to either teleportation or summoning.
Zangband includes a function of the form ra ndintx(y), which eec-
tively rolls a die with a number of faces equal to y. e trump spells draw
some of their unpredictability by recursively embedding random integers:
a recipe that could be emulated in other contexts. Shue, a spell-within-
a-spell, simulates the shuing of a Tarot deck with (strangely) 24cards. If
the player draws the Wheel of Fortune card, they trigger another rand-
int function that selects a wild magic eect randomly from among 32
possibilities. Wild magic could itself fall through into a function that su