Fw: [DESIGN] Combat system

Richard Woolcock KaVir at dial.pipex.com
Fri Apr 17 17:33:02 New Zealand Standard Time 1998

This post is quite long.

Alex Bertoglio wrote:
> Forgot to cutout the nospam. sorry.
> -----Original Message-----
> From: Alex Bertoglio <alexb at internetcds.com>
> To: Richard Woolcock <KaVir at dial.pipex.comNOSPAM>
> Date: Thursday, April 16, 1998 10:22 PM
> Subject: Re: [DESIGN] Combat system
> >Richard:
> >
> >Thank you for the comments and suggestions.  Though I would respond outside
> >the group if that is alright.

Well I'm going to take it to mud-dev, for reasons I will explain in a moment.

> >-----Original Message-----
> >From: Richard Woolcock <KaVir at dial.pipex.comNOSPAM>
> >Newsgroups: rec.games.mud.misc
> >Date: Thursday, April 16, 1998 7:48 PM
> >Subject: [DESIGN] Combat system
> >
> >
> >>I know some people on this list have coded this sort of thing; hopefully                               ^^^^
Of course I actually mean't 'newsgroup' ;)

> >>they will add their comments.
> >
> >I have seen modified auto combat but not the ability to override or change
> >settings within a given encounter. Could you point me to a good example?

I can't remember which of the people on mud-dev have done this, but I remember
reading examples of such things.  My favourite was written by J C Lawrence
some time ago, and - while not serious - is still an example of how you could
go about writing non-automatic combat:

  UggUgg slashes at you with his Sword of Instant Beheading
  and minor discomfort!
  > cast soakhole on uggugg
  You cast the dreaded mana eater soakhole on UggUgg!
  UggUgg sneezes and buries your in green snot!
  Your armour suddenly dissappears!
  Your spell of magical summon protection fails!
  Your spell of magical sight fails!
  UggUgg's Nose Ring of Killer Snot dissappears!
  UggUgg's Belt of Gas Containment dissappears!  Phew!
  UggUgg's dagger of wart removal dissappears!
  > cast create mana
  You create 5,000 units of mana!
  Your mana stores are now empty.
  >cast $my_protections
  You are now magically potected from summons.
  You can now see all magically hidden objects.
  UggUgg thows a blade of painful castration at you!
  > jump!
  You leap mightily.
  The blade misses!  You are still a baritone.
  > attack uggugg with spear
  You ram UggUgg through with the spear of Icy Death!
  UggUgg now has the flu and looks a bit watery about the eyes.
  UggUgg picks up a rock.
  UggUgg bases you with a rock!  Ouch!  That hurt!
  > throw TC at uggugg
  You throw the charmed trash collector at UggUgg.
  The TC englobes UggUgg!
  UggUgg gives you the Sword of Instant Beheading and minor
  UggUgg gives you the Boots of Mighty Chilblains,
  UggUgg gives you the Goggles of Big Farts.
  UggUgg gives you Super Nose Hair Puller.
  The TC has eaten everything UggUgg was carrying!  Yech!
  UggUgg is naked!
  Your spell of magical summon protection fails!
  Your spell of magical sight fails!
  Your spell of magical tummy tuck fails!
  Your spell of power voice fails!
  Your spell of land control fails!
  Your spell of bowel control fails!
  Your spell of toe cheese protection fails!
  > stat spells
  You have no spells.
  > stat mana
  There is no mana here.
  > strangle uggugg
  You wrap your hands about UggUgg's neck and begin to squeeze!
  UggUgg prays to the Great God GooGoo!
  GooGoo mana blesses the area!
  There is a LOT of mana here!  You skin prickles!
  > i
  You have a mana shielding sack
  > l in sack
  There are 5,000,000 TC spores in the sack.
  >empty sack on UggUgg
  The spores eat all the mana!
  There are 5,000,000 TC's here!  Wow.
  All the mana is gone!

When questioned more seriously, Mr Lawrence said:

   Combat currently consists of a stateless form, and a stated form.  In
   the major case I have no concept of a character being "in combat".
   This is due to the fact that most of the commands used to fight are
   identical to the commands they would use for more normal and less
   damaging purposes (see UggUgg's fight again).

   However a character can define himself as "fighting", which is then a
   state unique to him.  This then invokes the various combat packages he
   has written or installed on his character, which on a timed round
   basis attempt to analyse the actions of his opponents and propose
   possible scripted action sequences (attacks, defences, feints,
   sequences etc) to attempt during the next round (at the end of the
   round the script is thrown away and a new one generated).  The result
   is that his own combat participation is then somewhat timed, due to
   the fact that he's making tactical combat decisions every round.
   However the fact that he's in combat state does not prevent him from
   doing anything else he may wish, including dancing the polka, or
   juggling under ripe apples, or clobbering poor Bubba over the head
   with his mace, as the combat packages only define to-be-attempted
   tactics, not strategy, or an inability to do anything else.

I don't know much about Nathan Yospe's combat system, but judging from
the following, it sounds very interesting:

   A note toward Jeff's concerns with lifting and swinging bodies... the
   center of mass is tracked as a four dimensional cooridinate in any case
   of assembled objects, with the fourth dimension being a projection in time
   (my collision detection system), and the motions of a struggle do not add
   much more difficulty than the simulated chaotic motion of (for example) a
   blanket or net being swung. More to the point, its hardly any more
   unnatural that, for example, riding on a horse (or a gyrocycle, for that
   matter), and it adds sooo much.

There are many other people on this list with various systems, some of
which may well be of interest to you.  This is the reason I am carrying
this over to mud-dev.

> >>> Choose primary weapon. Secondary weapon. Backup weapon.
> >>
> >>You could go into more detail here - for example, if I'm shooting someone
> >>with my crossbow and a bandit leaps at me, I would want to drop the
> >crossbow
> >>and draw my two swords.  Equally, if someone shoots an arrow from their
> >>bow, they would probably want to retrieve another arrow automatically (or
> >>reach for another throwing knife, etc).
> >>
> >
> >A great idea. One inovation we have already coded (I know, nothing is
> >really new here)  is the notion of a "fast access" container. Things like 
> >quivers, scabbards, boot tops and even sleeves. These allow the player to 
> >wield a weapon with far few "action points" than rummaging three container 
> >levels deep into a backpack or sack. We have also added concealed weapons 
> >which loose some of the fast access bonus but allow the player to get the
> >"unarmed" reaction bonus form those NPC's  (and players, for that matter)
> >who can't see through the deception.

I take it different locations have different access speeds?  Perhaps you 
could even take this opportunity to make socials DO something useful?  Bubba, 
while scratching his head, might draw the sabre from his shoulder when attacked.
If he had been 'adjusting' another part of his anatomy, he might instead draw
the dagger from his belt.  This is probably going into too much detail of course,
but it could make standoffs quite interesting:

Boffo's fingers twitch near his right holster.
Bubba puts his hands behind his head, yawns, and says "take your best shot"
Boffo draws his gun from his right holster.
Bubba's hand snakes down to his left holster.
Bubba draws his gun from his left holster.
Boffo points his gun at Bubba's head.
Bubba points his gun at Boffo's right hand.
Bubba shoots Boffo in the right hand!  Boffo's gun falls to the ground.
Bubba spins his gun around his finger and returns it to his left holster.

Of course this would have to be set up with some sort of script/autoresponse
code, unless you want people going around claiming to be 'the fastest typist
in the west' ;)  You've certainly given me some ideas...

> >>You could also include general style of combat -
> >>does your character just hack people to pieces or fight with precision?
> >
> >
> >I agree, totally.  I am tired of huge weapons ruling muds. There are
> >advantages and disadvantages to every weapon. 20th century hit-men use 22
> >cal as the weapon of choice....the equivilant of a traditional rogue
> >backstab. Small weapon but really slows you down if you take one in the
> >back of the head at a one foot range.

I agree that different types of weapons should all be good for different
purposes, although there *will* still be better quality weapons.  Ideally
this would result in each player chosing a weapon that suits their style
of character.

> >>Perhaps he is famous for going for decapitation, or disembowelling
> >maneovers?
> >
> >This tracks with my earlier post. As weapon skill increases, you don't
> >suddenly become able to chop boulders in half. This kind of stuff (above)
> >is what legends are made of. Perhaps a quality 95 blade is more capable of
> >these exotic "called shots" in the hands of a skilled user.

Definately!  You'll notice that most people, when learning archery, shooting,
fencing etc IRL, will start with a pretty rubbish training weapon.  At that 
point it really makes very little difference, as they are only learning the
basics.  As the person increases with skill, they generally start moving on
to better and better equipment.  A high quality weapon will always give an
advantage, but that advantage is dependant on skill.

> >Hit location is part of the profile. You select the prefered location/s
> >using check boxes on a human or quadrapedal form. These can be changed on
> >the fly during an attack. The changes are written to the database (we use a
> >RDBMS as a core) and the next time the combat engine looks for instructions
> >they have changed.

I assume your locations affect the chance of a hit/miss?  Is it possible to
hit an alternative location with a 'miss'?  Could you accidently fatally shoot
someone through the eye while attempting to simply knock their hat off?

> >>> Defense profile. Convert attack attempts in to parrys? Whimpy code.
> >Convert
> >>> hits to fatigue (fatigue lowers stats but heals faster). Flee if weapon
> >>> breaks, shield breaks, etc.
> >>
> >>You could also have retreating and following-up on attacks.  Does your
> >character
> >>slowly back away or just turn and run?
> >
> >I like the ranged combat code I have seen which allows for withdrawals and
> >advances. Overruns become possible, ambushes, etc

What about back kicks?  What about being able to flip backwards over someone
standing directly behind you?  What about accidently hitting someone with the
backswing of your weapon?  What about dodging the person in front of you, 
causing them to impale the person behind you?

> >>Indeed - allowing weapons (and non-weapons) to be used in different ways
> >>would add an interesting twist to fighting tactics (perhaps you could even
> >>let untrained fighters pick up bad habbits, such as holding the sword
> >slightly
> >>wrong, leaving their guard open, etc).
> >
> >Virtually everthing with mass can be wielded in our system. This will lead
> >to some goofy possiblities like attacking with a leg of lamb...but should
> >make for fun bar fights.

Even been HIT with a leg of lamb? ;)  If you have this, I assume you also
have objects with different strengths - hitting a huge rock troll with a
wooden sword is going to do more damage to the sword than the troll.

> >>> The server reports the actions of combat as it develops but the player
> >>> can interact by issuing commands like close, withdraw, attack full, etc
> >>> which change the situation and activate new triggers. As a side benefit, 
> >>> the readiness profile adds to RP. A player who walks into a bar with weapons
> >>> drawn, visor down, etc. will be treated differently than if he come in
> >>> with a more peaceful affect.
> >>
> >>Yup, read my Syndicate comment earlier ;)
> >
> >An even more interesting side benefit is as these function are coded, they
> >become essentially like mob programs which can also be used along with
> >branching logic to form a primitive AI for the player's computer controlled
> >opponents. AI kind of scares me but this approach seems workable because of
> >its incremental nature.

This is something I would love to develop.  Unfortunately even my most responsive
of mobs only react to situations 'on the spot', and don't really store any long
term strategy.

> >>> Internal complexity is cool. External complexity is work.
> >>
> >>Quite, but that doesn't mean you should make it too simple, otherwise
> >>you're back to the original problem - combat which requires no thinking.
> >>
> >The real reason for my message. This was a miss statement. Given the state
> >of the public newsgroup, I doubt many more will notice it. Of course you
> >are right. I am trying to build an what could easily become an excessively
> >complex system. What I ment to suggest was the designer's responsibliity to
> >balance the compexity with a well designed interface. Using HTML gives us
> >some real advantages. A complex pick list allows a player to drop, take
> >wield and store items from the same screen in a single action. This is not
> >because we are so clever, but because the form elements allow us the let
> >the player do a dozen things at once. Sorry I goofed up.

Ah, but of course the more you simplify the interface, the more complex you
can make the combat system.  Ideally it should be easy for players to learn
the basics (just walk up to someone and start punching and kicking), while
difficult to learn the advanced stuff.  Players who experiment excessively
might even be able to learn new tricks that nobody else has considered.

The important part is getting the learning curve balanced.


More information about the MUD-Dev mailing list