Hyperlink Combat System

version 1 by Philip Black

  • Home page
  • Beginning
  • Previous
  • Next



  • SECTION ----- COMBAT BEGINS ----- COMBAT BEGINS ----- COMBAT BEGINS ----- COMBAT BEGINS ----- COMBAT BEGINS ----- COMBAT BEGINS ----- COMBAT BEGINS ----- COMBAT BEGINS
    A person can be Warrior. A person is usually not Warrior.
    A person can be Cleric. A person is usually not Cleric.
    A person can be Mage. A person is usually not Mage.
    Definition: a person is Classed if they are Warrior or they are Cleric or they are Mage.
    Carry out attacking:
        clear only the main screen;
        Say "[paragraph break]";
        Now the Global Attacker is the player;
        Now the Target is the Noun;
        StandardAttackSequence;
    Focusing is an action applying to nothing. Understand "Focus" as Focusing.
    Carry out Focusing:
        clear only the main screen;
        Say "[paragraph break]";
        Now the Global Attacker is the player;
        If the Concentration of the player is not at least 6:
            Increase the Concentration of the player by 2;
            If Defensive Focus of the player is at least 2:
                Decrease Defensive Focus of the player by 2;
            Say "[Concentrating Text of the player]";
        Otherwise:
            Say "You are already fully focused on attacking! [bold type]Attack Focus:[roman type] +[Concentration of the player] [bold type]Defense Focus:[roman type] +[Defensive Focus of the player]";
        Now the Global Attacker is Reset Dummy;
        
    Defending is an action applying to nothing. Understand "Defend" as Defending.
    Carry out Defending:
        clear only the main screen;
        Say "[paragraph break]";
        Now the Global Attacker is the player;
        If the Defensive Focus of the player is not at least 6:
            Increase the Defensive Focus of the player by 2;
            If Concentration of the player is at least 2:
                Decrease Concentration of the player by 2;
            Say "[Focus Defence Text of the player]";
        Otherwise:
            Say "Your defenses are already fully focused! [bold type]Attack Focus:[roman type] +[Concentration of the player] [bold type]Defence Focus:[roman type] +[Defensive Focus of the player]";
        Now the Global Attacker is Reset Dummy;
    Divine Power is an action applying to nothing. Understand "Divine Power" and "pray" and "call God" and "call gods" as Divine Power.
    Casting is an action applying to nothing. Understand "Magic" and "Spells" as Casting.
    Check the player Casting:
        If the player is NOT Mage:
            Say "You don't know any magic yet!";
            Reject the player's command.
    [
    Casting is an action applying to one visible thing. Understand "Cast [something]" or "Magic [something]" or "Enchant [something]" and "Cast at [something]" or "Magic on [something]" or "Cast Spell at [something]" as Casting.
    Combat Magic is a kind of thing.
    Carry out Casting something (called the spell):
        If the player is not Mage:
            Say "You don't know magic yet!";
        Otherwise:
            If the spell is person:
                Now the spell is Target;
                Say "";
            Otherwise if the spell is Combat Magic:
                [clear only the main screen;]
                Say "[paragraph break]-------------------------------------------------------------[line break][line break]";
                Now AttackerOrder is 1;
                repeat through the Table of IntFoes:
                    say " [AttackerOrder]: [o][spell] [CAttacker entry][x][line break]";
                    Increment AttackerOrder;]
    [Carry out Divine Power:
        clear only the main screen;
        Say "[paragraph break]-------------------------------------------------------------[line break]Divine Powers";
        Now the Global Attacker is the player;]
        
    [A Mage Spell is a kind of thing. ][Cast is an object based rulebook. Known Magic is a list of objects that varies.]
    [
    Casting is an action applying to nothing and one visible thing. Understand "Cast [something]" or "Magic [something]" or "Enchant [something]" and "Cast at [something]" or "Magic on [something]" or "Cast Spell at [something]" as Casting.
    Sorcery is an action applying to nothing. Understand "Magic" and "cast spell" and "cast magic" as Sorcery.
    Check Casting: [Cast a spell AT something]
        If the player is not Mage:
            Say "You don't know magic yet!";
            reject the player's command;
            
    Check Sorcery: [Cast a directionless spell]
        If the player is not Mage:
            Say "You don't know magic yet!";
            reject the player's command;
    A thing can be MagicKnown. A thing is usually NOT MagicKnown.
    Sparking-Missile-Known is a truth state that varies. Sparking-Missile-Known is true.
    Carry out Casting:
        Now the noun is Target;
        Say "[paragraph break]-------------------------------------------------------------[line break]";
        If Sparking-Missile-Known is true:
            Say "[o]Sparking Missile[x] (Ranged attack spell - normal damage)";
    Sparking Missile is an action applying to nothing. Understand "Sparking Missile" as Sparking Missile.
    Check Sparking Missile: [Cast a spell AT something]
        If the player is not Mage or Sparking-Missile-Known is false:
            Say "You don't know that magic yet!";
            reject the player's command;
    Carry out Sparking Missile:
        let d20 be a random number between 1 and 20; [ATTACK ROLL]
        Let Aim Total be d20 plus accuracy bonus of Global Attacker plus Base Accuracy of the Global Attacker plus the concentration of the Global Attacker; [ATTACK ROLL]
        Now DTotal is the Evasion of the Target plus the Dodge Bonus of the Target plus the Defensive Focus of the Target;
        let D be the dice number of Global Attacker; [DAMAGE]
        let y be the damage die of Global Attacker;
        Let PP be 0;
        If d20 is 1:
            let Crit be the Level times 5;
            Decrease the health of Global Attacker by Crit;
            If the Global Attacker is the player:
                Say "You gather magic to attack but it EXPLODES in your FACE, dealing [Crit] damage!";
            Otherwise:
                Say "[MAGIC Attacking Text] but it EXPLODES in their FACE, dealing [Crit] damage!";
        Otherwise if Aim Total is greater than DTotal or d20 is 20:
            Let Q be D times y;
            let Damage Total be a random number between D and Q;
            Let TT be Level;
            Let PP be a random number between 1 and TT;
            Increase Damage Total by PP;
            If d20 is 20:
                let Crit be the Level times 5;
                Increase Damage Total by Crit;
            Decrease the health of Target by Damage Total;
            If the Global Attacker is the player:
                Say "You gather pure magic in your hand and shoot it towards [Target], blasting them[If d20 is 20] HARD[end if] with sparks of light for [Damage Total] Damage! [if d20 is 20]CRIT![end if]";
            Otherwise:
                Say "[Global Attacker] shoots a rush of sparks towards [Target], blasting them[If d20 is 20] HARD[end if] for [Damage Total] Damage! [if d20 is 20]CRIT![end if]";
        Otherwise:
            If the Global Attacker is the player:
                Say "You shoot some sparks towards [Target], missing them completely!";
            Otherwise:
                Say "[Global Attacker] shoots sparks towards [Target], missing them completely!";
        If numbers boolean is true:
            Say "[line break]d20 + Accuracy Bonus + Concentration + Base Accuracy -VS- [if Target is the Player]Your[otherwise][Target Name]'s[end if] Evasion + Dodge Bonus + Defensive Focus[line break][italic type]([d20] + [accuracy bonus of Global Attacker] + [Concentration of Global Attacker] + [Base Accuracy of Global Attacker] = [Aim Total] ~VS~ [bold type][DTotal][roman type][italic type] = [Evasion of the Target] + [Dodge Bonus of the Target] + [Defensive Focus of the Target])[roman type][line break][line break] [if Aim Total is greater than DTotal or d20 is 20] Damage: [D]d[y]+[PP] = [Damage Total][end if]";
        Now the Global Attacker is Reset Dummy;
        
    [ [line break][if d20 is 20]CRIT![otherwise if d20 is 1]Critical MISSFIRE!![otherwise if Aim Total is greater than DTotal]HIT![Otherwise]MISS![end if]]
        
        [EndSpell;
    To ScriptReset:
        add Sparking Missile to Available Scripts;
    To EndSpell:]
    ]