FILE: COMBAT.TXT

               HUB - Henry's Universe Builder
         Basic Area and Object Construction Manual

             ARMOR/WEAPONS & COMBAT EQUATIONS

This file is Copyright 1995-1997 by Henry McDaniel.  All rights
reserved.   See NOTICE for further details.
--------------------------------------------------------------------


ARMOR
@@@@@@@@@@@@@@@@@@

wear position values:

       VALUE        MAX. QTY
head	1           1
neck	2           2
torso	3           1
arms	4           1
hands	5           1
fingers	6           2
waist	7           1
legs	8           1
feet	9           1


The wear attribute, allows a player to get an object and "wear" it
in the designated position.

Use the position value as the number for the "wear" attribute.
Weapons like swords should be worn about the waist (7).

Gloves, boots, leggings - these are singular objects with plural
names.

Max Qty refers to the maximum number of items which can be worn in
the indicated position simultaneously.

The "armor" attribute may also be set for a wearable item.  It
will add strength to the wearer's resistance against damaging
assaults.  Armor strength is cumlative for the part of the body
the items are worn on.

In battle the total armor in that part of a character's body is
subtracted from the strike potential of an attacker before any
damage is figured.



WEAPONS
@@@@@@@@@@@@@@@@@@


For a simple weapon, simply set an "hit" attribute.  The numerical
value will add to the strength of the user.  DO NOT make an object
with both weapon and armor atributes.

The "msg" value can be set to a string list msg which will sometimes
be shown.  Example:  "msg: cut cuts"

The user will see:  You cut so and so.
Others will see: <Name> cuts so and so..


@@@@@@@@@@@@@@@@@@@@@
BATTLE EQUATIONS
@@@@@@@@@@@@@@@@@@@@@

This information is useful for creating reasonable stats for an
NPC which players can fight for points.

Some games have automated fight rounds.  A player iniates combat,
and then the game continues the combat by having the opponents
strike each other in regular intervals.  During this period, it
is difficult (or very bad) for a victim to flee.  In our game,
when player fights player the strikes are all controlled by the
participants (who are limited in when they can strike again
depending on their stats.)  When a player fights an NPC, the
battle is in favor of the NPC (all things being equal) since
it "knows" exactly when it can strike again, while the player
must guess.  In any event, either participant may attempt to
end combat at anytime by leaving the area.

A striker and victim (the character being hit) each have their
own stats for upper and lower body as well as energy.  

In the below equation explanations "S" represents striker, and "V"
is the victim.  The attacker may select whether he will use his
upper or lower body to hit with and even whether he will strike his
opponent in the upper or lower regions of their body.  Provisions
are also made so that one may guard against attacks on one half of
the body.

ls,ld - lower body strength and dexterity
us,ud - upper body strength and dexterity

The notaion (Xud,Xld) refers to either upper or lower dexterity
of X (depending on whether the strike is directed to the upper
or lower part of X's body.)

In the following we will see how the effect of one hit by Striker
is caclulated upon a victim.
------------------------------------------------------

Effective dexterity and strength of striker vs. victim opponent:
 Eld = (Sld - Vls) OR 1, whichever is greater
 Els = (Sls - Vld) OR 1, whichever is greater
 Eud = (Sud - Vus) OR 1, whichever is greater
 Eus = (Sus - Vud) OR 1, whichever is greater


Strike potential = Eus,Els OR (Senergy+1), whichever is greater.

Strike energy:
 Chance 1 in 20:   strike potential 
 Chance 3 in 20:   strike potential/2
 Chance 2 in 20:   strike potential/4
 Chance 14 in 20:  strike potential/5

If victim is not at least standing add to strike energy:
 Chance 1 in 4:    (Eus,Els) + (Eud,Eld)
 Chance 3 in 4:    (Eud,Eld)


Energy modification value (start with strike energy):
 Divide strike energy by 2 if victim blocked attack.
 Use strike energy otherwise.

 The energy modification value is subtracted from the
 victim's energy level.


Dexterity modification value:
 Divide strike energy by 40 if victim blocked attack.
 Divide strike energy by 20 otherwise.

 The dexterity modification value is subtracted from the
 victim's dexterity in the struck area.

-------------------------------------------------------
Time to recover for striker in seconds:

wait = | (strike energy - (Eud,Eld)) |

if wait is less than 2, wait is randomly set to between 1 and 2.
if wait is greater than 10, wait is randomly set to between 7 and 10.

Essentially, the more dexterious the striker, the less time he
will have to wait before he can hit again.
--------------------------------------------------------

Death is immediate should the victim's dexterity in either
upper or lower body fall below 0.  Death occurs around a
minute later (unless the victim is helped), should victim's
energy fall below 0 (but dexterity values do not.)


SHORT-CUT METHOD:

You can use this method and not worry at all about the above
information which is intended for *special* NPCs anyhow.

1. Decide what level the NPC will be.
2. Set energy to (level*10)+40.
3. Set UD and LD near energy/2.
4. Set US and LS near UD and LD values.
5. Set weight around (energy/4)+50
6. IF YOU DECIED TO HAVE ONE, Set value to energy*10

If you set the dexterity values less than the strength values,
the character will be slow in combat and less able to defend
itself.

Note: energy is the endurance (roughly) of the NPC.  The more
energy, the longer it can sustain battle without needing time
to recoup.

END OF COMBAT.TXT