@#INSTALL @eventname The Bandit @author Donald Tidmore @authid BANDIT112 @codebegin @runsub BANDIT &filename @codeend @target FOREST @#UNINSTALL ; ============================================================== ; The Bandit v1.12: By Donald Tidmore. ; Email: ktidmore@bellsouth.net. Fidonet: 1:123/450 ; WWW: http://camelot.legendarydragons.com/. As of mid-June 2007. ; ============================================================== ; @#Bandit @display `c `! Special Event In The Forest `0 `l `%While adventuring in the Forest, you are jumped from behind by a very strong `#Bandit, `%and are severely injured and robbed of your valuable possessions. @enddisplay @math &N30 = &Pwn + 0 ; Store weapon type number. @math &N31 = &Pgo + 0 ; Store Gold on Hand. @math &N32 = &Pge + 0 ; Store Gems. @math &N33 = &Pht + 0 ; Store Current Hitpoints. @math &N34 = &Psr + 0 ; Store Player's Strength points. ; Take player's Gold - Bandits always take your money. @set &Pgo to 0 ; Reset Gold on Hand (01/24/03 change) ; Take player's Gems - most Bandits will take jewelry also. @set &Pge to 0 ; Reset Gems stat. (01/24/03 change) ; Start processing to determine if they lose Weapon. @set &N3 to &rnd3 @if &N3 = 0 1 @begin @set &N3 to 1 @end @endif 1 @case &N3 1 1: @begin @writeln ; Take half of player's Current Hitpoints. @math &N4 = &N33 / 2 ; Compute half of Current HP. @math &N6 = &N33 - &N4 ; Deduct HP loss caused by injuries. @set &Pht to &N6 ; Reset Current Hitpoints. @display `%You put up a good fight, but the `#Bandit `%wins the fight. He leaves you severely injured, and takes your `$Gold and Gems. `%As you lie there bleeding, you wonder, `0"Why me?" `@&nick `$loses `!&N4 `0Hitpoints `%due to severity of the `#Bandit's `%attack. @enddisplay @goto Bandit_END @end ; Ends first scenario code. 2: @begin @writeln ; Take three quarters of player's Current Hitpoints. @math &N4 = &N33 / 4 ; Compute one quarter of Current HP. @math &N5 = &N4 * 3 ; Compute 3/4 Current HP amount. @math &N6 = &N33 - &N5 ; Deduct HP loss caused by injuries. @set &Pht to &N6 ; Reset Current Hitpoints. @display `2When the Bandit attacks, you try to resist, and receive a severe beating. He takes your `!Gold and Gems. `2As you lie on the ground, bleeding heavily and lapse into unconsciousness, you wonder, "Why me?" `@&nick `$loses `!&N5 `@Hitpoints `%due to severity of `#Bandit's `%attack. @enddisplay @goto Bandit_END @end ; Ends second scenario code. 3: @begin @writeln ; Drops player to 1 usable Hitpoint. And "damage" their weapon. @math &N4 = &N33 - 1 ; Determine Hitpoints Lost to injury. @math &N5 = &N33 - &N4 ; Deduct all but 1 Hitpoint. @set &Pht to &N5 ; Reset Current Hitpoints. @display `%You valiantly fight with him, but he's too strong for you, and he beats you nearly to death. As you slip into unconsciousness, you hear him say, `#"Thanks for the Gold and Gems, warrior." `0Sometime later, you come to, and realize that your luck was really lousy today. `%You see that your `@&Pwe `%got damaged in the fight. `@&nick `$loses `#&N4 Hitpoints `%due to severity of `#Bandit's `%attack. "You better get to the `!HEALER FAST!", `%you hear a mysterious voice say. @enddisplay @writeln @hitakey ; 01/29/03 Change. Allow Level 1-3 players to escape with one-half ; of stated strength points damage for their weapon. Up to weapon ; #10. Anyone at a low-level with Weapons #11 upward, will NOT be ; be given special handling. ; ================================================================= ; Store the amount of Strength point loss in &N35 variable. ; ========================================================== @set &N35 to 0 ; Preset field to zero. ; Weapon levels #1-#3 - process weapon damage: @if &N30 < 4 2 @begin @math &N7 = &N34 - 5 ; Take away 5 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln `#You also LOST `@5 `0Strength points. @writeln `#Player's Strength REDUCED to `$&N7 points. @writeln @set &N35 to 5 @goto BANDIT_LOSS @end ; Short sword yields 10 points. Loss set at 5 pts. @endif 2 ; Second 3-weapon level group - process weapon damage: @if &N30 < 7 3 @begin @math &N7 = &N34 - 10 ; Take away 10 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln `%You also lost `@10 `0Strength points. @writeln `%Player's Strength reduced to `$&N7 points. @writeln @set &N35 to 10 @goto BANDIT_LOSS @end @endif 3 ; Bone Cruncher yields 20 points. Loss set at 10 pts. ; For weapon levels #7 and #8 - process weapon damage: @if &N30 < 9 4 @begin @math &N7 = &N34 - 15 ; Take away 15 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln `%You also lost `@15 `0Strength points. @writeln `%Player's Strength reduced to `$&N7 points. @writeln @set &N35 to 15 @goto BANDIT_LOSS @end ; Power Axe yields 40 points. Loss set at 15 pts. @endif 4 ; For weapon levels #9 and #10 - process weapon damage: @if &N30 < 11 5 @begin @math &N7 = &N34 - 20 ; Take away 20 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln `%You also lost `@20 `0Strength points. @writeln `%Player's Strength reduced to `$&N7 points. @writeln @set &N35 to 20 @goto BANDIT_LOSS ; Bypass other weapon IF tests. @end ; Wan's Weapon yields 70 points. Loss set at 20 pts. @endif 5 ; For weapon levels #11 and #12 - process weapon damage: @if &N30 < 13 6 @begin @math &N7 = &N34 - 40 ; Take away 40 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln `%You also lost `@40 `0Strength points. @writeln `%Player's Strength reduced to `$&N7 points. @writeln @set &N35 to 40 ; 03/19: fixed error. @goto BANDIT_LOSS ; Bypass other weapon IF tests. @end ; Crystal Shard yields 150 points. Loss set at 40 pts. @endif 6 ; For weapon levels #13 and #14 - process weapon damage: @if &N30 < 15 7 @begin @math &N7 = &N34 - 75 ; Take away 75 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln `%You also lost `@75 `0Strength points. @writeln `%Player's Strength reduced to `$&N7 points. @writeln @set &N35 to 75; 03/19: fixed error. @goto BANDIT_LOSS ; Bypass other weapon IF tests. @end ; Blood Sword yields 400 points. Loss set at 75 pts. @endif 7 ; For top weapon level - process weapon damage: @if &N30 = 15 8 ; removed > symbol. @begin @math &N7 = &N34 - 100 ; Take away 100 Strength points. @set &Psr to &N7 ; Reset their Strength points. @writeln @writeln `%You also lost `@100 `0Strength points. @writeln `%Your Strength was reduced to `$&N7 points. @writeln @set &N35 to 100 ; 03/19: fixed error. @goto BANDIT_LOSS @end ; Death Sword yields 600 points. Loss set at 100 pts. @else 8 ; Should handle weapon # above 15. @begin @math &N7 = &N34 - 150 @set &Psr to &N7 @writeln @writeln `%You also lost `@150 `0Strength points. @writeln `%Your Strength was reduced to `$&N7 points. @writeln @set &N35 to 150 ; 03/19: fixed error. @goto BANDIT_LOSS @end @endif 8 @end ; End third scenario code. @endcase 1 @label BANDIT_LOSS @display `%As you struggle off to find a healer, you wonder what kind of magical armour the Bandit was wearing. Time to visit the `0Blacksmith `%for some weapon repair work. @enddisplay ; 01/29/03 Change: Allow 50% refund of Strength points lost to ; those victims who are at Levels 1 through 4. @if &Plv < 5 9 @begin @goto Bandit_Restore @end @endif 9 @goto Bandit_End @label Bandit_Restore ; Created March 19, 2003 @writeln @display `@ = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = `$Suddenly you spot one of the special `!"Hammer Stones". `$As you strike your `@&Pwe `$upon it, you wish for the special magic to restore your lost Strength. ..... @enddisplay @if &N35 > 0 10 ; N35 is amount of Strength Loss @begin @math &N36 = &N35 / 2 @math &N7 = &Psr + &N36 ; Restore 50% of lost Strength. @set &Psr to &N7 @writeln @display `0You feel a small increase in your `!Strength Points `0as the stone's magic takes effect. Your `!Strength `0is restored to `#&N7 `%points. `%As you leave, you are thankful that the stone retained its power. @enddisplay @end @else 10 @begin @math &N7 = &Psr + 2 @set &Psr to &N7 @writeln @display `0You feel a tiny increase in your `!Strength Points `0as the stone's magic takes effect. Your `!Strength `0is restored to `#&Psr `%points. `%As you leave, you realize the stone must have lost most of its power. @enddisplay @end @endif 10 @label Bandit_END @writeln @hitakey ; Needed for viewing screen under LORD 4.06. @endquest ; ===================================================================== ; Summary: You are ambushed by an Bandit and robbed. There are ; three scenarios. In all of them, you lose all Gold on Hand, ; and your Gems. In #1, you have 50% hitpoint injury from wounds. ; In #2, you have 75% hitpoint injury. And in #3, you lose all ; but 1 hitpoint, and suffer weapon damage. The weapon damage is ; assessed in Strength points, based on each weapon's overall value. ; ; Requires LORD v4.05+. Tested under LORD v4.07 beta by author. ; v1.03: Changed LABEL names. v1.04: Tested under LORD 4.06 ; (some scenarios not re-tested under LORD 4.06 yet). ; ; v1.05: Allow limited 50% refund of lost Strength points for weapons ; #1-#10 inclusive, as long as player is Level 1-4. Allow limited ; gift of 2 strength points for those who don't qualify for the full ; 50% strength points refund. v1.06. Worked on ending code. The N35 ; variable was not properly set for most of the scenarios based upon ; the player's weapon number. Fixed that, along with the Hammer Stone ; secondary ending not working properly earlier. 03/19/2003 ; ============================================================= ; ; v1.08: Renamed script Label End_Loss to Bandit_Loss. 12/05/04. ; ============================================================== ; 04/12/05: Added number identifier to the @else statements. ; 04/12/05: Changed to version 1.10. ; 07/23/05: Moved all Comments to end of file. ; 07/23/05: Added INSTALL and UNINSTALL sections to script. ; 05/31/07: v1.12: Revised Email/WWW info; Changed version #.