(Ln(x))3

The everyday blog of Richard Bartle.

RSS feeds: v0.91; v1.0 (RDF); v2.0; Atom.

Previous entry. Next entry.


3:36pm on Sunday, 7th December, 2014:

Consideration

Anecdote

A recent patch to The Secret World included a revamp of the con system. Although this sounds as if it means the mechanism by which they execute confidence tricks on people, actually it means the details about a mob given to players so they can decide whether or not to attack it: "con" is short for "consider".

We had/have a consider system in MUD2, too — the idea isn't new. However, the MUD2 system was somewhat more asymmetric than we see today.

The reason we need a con system in a modern MMO is fundamentally because all the mobs look the same. If you come across a wolf, it could be level 1, it could be level 40, it could be level 80, it could be level 100. The higher-level ones look bigger and meaner and have red eyes and spikes or whatever, but after a few rampings up like this it's hard to tell how killable the wolf you're looking at actually is for someone of your level. This is where a con system comes in. The mob's name or health bar will be colour-coded to say how powerful the mob is relative to you (as an individual), which usually comes with implications regarding what kind of reward you'll get for killing it. There may also be an indication as to whether the mob will attack or leave you alone if you stray too close.

In MUD2, from the player's point of view all you know is what the mob's name is, how healthy it looks (from "full of life" to "close to death") (yeah it's different for undead) and what it's carrying (because if it's carrying a weapon, it will usually wield it). How do you tell whether one mob is tougher than another, then? Well, you use your common sense: an eagle is more dangerous than a raven, a vampire is more dangerous than a zombie, a giant is more dangerous than a goblin. The old man won't attack you, but if you attack him then expect a hard time of it — you don't get to wander around a land infested with monsters and live to be an old man unless you can defend yourself.

As for whether other mobs will attack you, well for that MUD2's mobs use their own con system. When they encounter another creature, then if they have a vendetta against it they'll attack come what may. If not, they first consider whether it's a valid target or not; if it is, they decide whether they like it or not; if they don't, then they decide if they think they'll win or not; if they think they have a chance, they'll attack. Here's an extract of the considers part:

{ considers ?? ?? }: //
{ considers skeleton ?? }: \ ?29
{ considers rat ?? }:
        \(holdinga(second, flute)) &
        length(fighting(second)) <= level(second)/2
{ considers watersnake ?? }:
        \(holdinga(second, boat))
{ considers ?? player }:
        level(second) >= clevel(first)


What the first clause says is that by default any mob will consider any other mob a possible target (// means "true"). This is because mobs don't often rise in levels (although they can), so the antipathy function can be used to determine whether they attack or not.

The second clause says skeletons will only consider attacking anything 1 encounter in 30 (as ?29 means a random number between 0 and 29 inclusive; \ means "true if equal to zero, otherwise false").

The third clause says that rats won't consider you if you're carrying a flute (they still haven't got over Hamelin) or if you're fighting more than half your level in number of creatures already (note that MUD2 only has 12 levels in total, from 0 to 11). This is because the rats all roam close to one another and you could be set on by a pack of 20 otherwise...

The fourth clause says watersnakes won't consider attacking people in boats.

The final clause is where the mob considers whether or not to attack player characters. It will do so if its level is greater than the clevel ("consider level") of the player character. The clevel is mob-specific — for birds it's 1, for example, but for the banshee it's 4.

It's the last step of the con system where things get interesting. To figure out whether it can win the fight or not, the mob calculates how many rounds it thinks it will take to kill its opponent and vice versa, and if it will finish first then it goes for it. It does this by working out its mean damage per round against its opponent (modified for weapons) and comparing it against its opponent's current health (modified for regeneration). It's pretty accurate — or at least it would be if mobs used it properly. Some do, but most have an inaccurate sense of their own abilities and will multiply it by another number. Mobs that are over-optimistic, such as the goat, will attack stupidly often; mobs that are under-optimistic, such as the ox, will rarely attack. This pacificity rating is used for attacks, but another rating for cowardice is used for fleeing; this means you can get mobs that attack often in acts of bravado but which then flee as soon as the going gets tough (such as the mad March hare), or which rarely attack but when they do they're relentless (santa, a Christmas mob, is like this).

The result of this is that MUD2's mobs each have their own personalities. Some you get to like, especially if they rescue you when you're in trouble; some you get to respect; some you get to despise, or to fear, or to hunt. The reason for this is because the mobs have their own con system, not because the players do. For players, if it looks dangerous well then it probably is.

Ah, history...




Latest entries.

Archived entries.

About this blog.

Copyright © 2014 Richard Bartle (richard@mud.co.uk).