Inform - Resources - Examples

Back to List

Inventory
Complete

Backward
Forward

Plain
Coloured
Gaudy

This code
in plain text

Browsing Balances.inf

14. The spells in Helistar's grimoire (lines 1535-1572)

1535  Spell lleps_spell
1536    with name "lleps",
1537         purpose "reverse effect of memorised spell",
1538         magic
1539         [;   if (second==0 || second notin memory)
1540                  "The spell backfires, painfully.";
1541              if (second.number==100)
1542                  "You know that spell too well for your mind to be able
1543                   to accept the change.";
1544              if (second has reversed) give second ~reversed;
1545              else give second reversed;
1546              if (second==lleps_spell)
1547              {    memory.forget_spell(second);
1548                  "Your mind wrenches as the two lleps spells
1549                   cancel each other out, leaving only a sensation
1550                   quite like a hangover.";
1551              }
1552              print_ret "Your mind wrenches as ", (the) second,
1553                        " reverses itself.";
1554         ],
1555         unmagic
1556         [;   return self.magic();         !  The reverse of "lleps" is "lleps"
1557         ];
1558   
1559  Spell mortin_spell
1560    with name "mortin",
1561         purpose "cause immediate death of caster",
1562         magic
1563         [;   deadflag = true;
1564              "You really can't fault Helistar on this one.  Death is
1565               absolutely immediate, like a sudden blackout curtain...";
1566         ],
1567         unmagic
1568         [;   prepared_flag = true;
1569              "Nothing quite happens... and yet you feel enormously more
1570               confident as you go about this dangerous world.";
1571         ];
1572   


Last updated 23 June 2004. This web site has not been fully supported since April 2008. Information may be out of date. This page was originally managed by Graham Nelson (graham@gnelson.demon.co.uk) assisted by C Knight.