Next Previous Contents

4. Mobile Creation


4.1 Creating a new mobile

If the mobile you want to create doesn't already exist, create it with the @NEW MOBILE command. Creating a new mobile will also set it as the mobile you are working on. Please use your virtual numbers assigned to you in order. Don't leave large gaps between used virtual numbers.

< O:-1 M:-1 R:14000 > @new mobile 14000
Ok, you are now modifying mobile #14000.

< O:-1 M:14000 R:14000 >

4.2 Loading an existing mobile to be editted

If you want to edit an existing mobile, use the @LOAD MOB command. Switching between mobiles to edit does not lose unsaved changes.

< O:-1 M:-1 R:14000 > @load mob 14001
Ok, you are now modifying mobile #14001.

< O:-1 M:14001 R:14000 >

4.3 Examining mobiles

The mobile is created with default descriptions and stats and is loaded into your modification buffer. You can see the mobile's status with the @EXAMINE MOBILE command:

< O:-1 M:-1 R:14000 > @examine mobile
#14000     Last modified by: Mobius
   --- descriptions ---
new~
a new mobile created by Mobius~
Null mobile.
~
Null description.
~
   --- action flags ---
NO-BITS

   --- affection flags ---
NO-BITS


   --- resistance flags ---
NO-BITS

ALIGNMENT  : 0
CLASS      : Other
LEVEL      : 0
THAC0      : 20
AC         : 10
HITPOINTS  : 0d0 + 0
DAMAGE     : 0d0 + 0
GOLD       : 0
POSITION   : STANDING
DEF POS    : STANDING
GENDER     : neutral
SIZE       : 0
MOVE TYPE  : walks
(EXPERIENCE : 5)

< O:-1 M:14000 R:14000 >

4.4 Describing mobiles

We are going to create a gate guard for the citadel. We will need to describe how this mobile will appear during the different parts of game play such as appearing in a room, moving around and combat.

The first thing we will need to do is provide the mobile with keywords. These keywords are what players use to interact with the mobile with commands like "look", "kill" or "steal". Do not capitalize keywords. Even if the mobile has a proper name such as "Quenyarhun", you would give the mobile at least the keyword "quenyarhun". Multiple keywords as separated by a single space. These keywords are usually found in the other descriptive texts for the mobile such as their long name. Using the @NAME MOBILE command we will give the guard some keywords such as "guard" and "man".

Next, we will set the short name of the mobile with the @SHORT MOBILE command. This is the string used by the game to display the actions of the mobile during events such as combat or spell casting. The short name is not a complete sentence and can be a proper name. Examples include "an orc", or "the fearsome lava beast". If the mobile has a proper name go ahead and capitalize it, like "Quenyarhun".

The long name of the mobile is used by the game to display the mobile in the contents of a room. Long names are complete sentences with capitalization and punctuation. They are typically one sentence in length and fit inside 80 character columns. It is helpful to have at least one of the keywords in the mobile's long name appear in the mobile's keyword list. The @LONG MOBILE opens up the multi-line editor. Enter the long name and then enter an "@" on a line by itself to leave the editor.

Finally we will enter the mobile's description with the @DESCRIBE MOBILE command which opens up the multi-line editor. Enter the description and then enter an "@" on a line by itself to leave the editor. Mobile descriptions are blocks of text that are one or more complete sentences that are not indented. End your lines before column 80 so it doesn't wrap in terminals. Please your descriptions short and to the point. 3 to 5 sentences is enough to get your point across.

After you've entered in your strings, don't forget to check your spelling with the @SPELL MOBILE command.

< O:-1 M:14000 R:14000 > @name mobile guard man
Ok.

< O:-1 M:14000 R:14000 > @short mobile a gate guard
Ok.

< O:-1 M:14000 R:14000 > @long mobile
Old long description:
Null mobile.
Enter text, end with a '@' on a line by itself.
] A tall man watches the gate with perfectly stoic gaze.
] @

< O:-1 M:14000 R:14000 > @describe mobile
Old description:
Null description.

Enter text, end with a '@' on a line by itself.
] The gate guard is a tall and stalwart man. He has been charged with the task of
] preventing riff-raff from entering the citadel. He appears to be quite capable
] of performing his duties.
] @

< O:-1 M:14000 R:14000 > @spell mobile
@(#) International Ispell Version 3.1.20 10/10/95
& riff 3 11: miff, rift, tiff
& raff 2 16: Graff, raft

< O:-1 M:14000 R:14000 >

4.5 Level and default combat stats

Our guard is going into an area designed for levels 10 through 15. We are going to make this guard level 11 with the @MOB LEVEL command. Then we set his default stats with the @MOB DEFAULT command which sets the mobile's armor class (AC), to hit armor class zero (THAC0), and bare-hand damage dice. The default settings are used to set the mobile's power in combat for balance purposes. We want all of level 11 mobiles in the game to be roughly the same difficulty.

< O:-1 M:14000 R:14000 > @mob level 11
Ok.

< O:-1 M:14000 R:14000 > @mob default
Specs for mobile #14000 set to defaults for level 11.

< O:-1 M:14000 R:14000 >

4.6 Tweaking level and combat stats

Although it is highly recommended to use the default combat stats for a mobile's level, you can change them individually.

Armor Class (AC)

Armor Class (AC) is the mobile's rating of how much armor and spell protection it has for melee combat. Someone wearing a flanel shirt is much less protected than someone wearnig a suit of chain mail armor. The lower the AC, the better their protection is. AC ranges from -10 to 10. In the game, this number is reflected as a multiple of 10 (-100 to 100). AC is used in combat to determing if they get hit at each round of melee combat. Use the @MOB AC command to change the mobile's Armor Class.

< O:-1 M:14000 R:14000 > @mob ac 11
Ok.

< O:-1 M:14000 R:14000 >

To Hit AC 0 (THAC0)

To Hit AC 0 (THACO) reflects the base chance a mobile has of hitting in melee combat. The opponent AC and the mobile THAC0 are used in calculating the mobile's chance of hitting. The lower the THAC0, the better chance the mobile has of hitting its opponent. THAC0 ranges from 0 to 20. Use the @MOB THACO command to change the mobile's THAC0.

< O:-1 M:14000 R:14000 > @mob thaco 9
Ok.

< O:-1 M:14000 R:14000 >

Hitpoints

Hitpoints is a dice roll to determine how much health a mobile will start out with when loaded in the game. Hitpoints have a current and max value. When the current value of a mobile's hitpoints reaches 0, it is stunned. When it reaches -10, it is dead. The higher the hitpoints a mobile has, the more difficult it is to kill. Use the @MOB HITPOINTS command to set the mobile's hitpoints.

< O:-1 M:14000 R:14000 > @mob hitpoints 2d12+150
Ok.

< O:-1 M:14000 R:14000 >

Bare-hand damage

Bare-hand damage is a dice roll to determine how much damage a mobile will inflict on a succesful melee combat hit. Bare-hand damage is not used it a mobile is wielding a weapon, instead the damage dice for the weapon object is used. The higher the bare-hand damage average roll value, the more powerful the mobile is. Use the @MOB DAMAGE command to set the mobile's bare-hand damage. The bare-hand damage type shows up as a "hit" in command. If you wish to have your mobile use a different bare-hand attack type, use the @CREATE MOB_ATTACK command to create custom attack type with associated damage dice. If you do use a custom attack, be sure to zero out the bare-hand attack setting so it doesn't show up in combat.

< O:-1 M:14000 R:14000 > @mob damage 2d7+3
Ok.

< O:-1 M:14000 R:14000 >

4.7 Alignment

The gate guard is guarding the citadel which is a fortress of protection against evil. He is one of the "good guys" so we'll give him a high alignment with the @MOB ALIGN command setting to 1000. Remember that alignment is broken down roughly into three groups: good (1000 to 350), neutral (349 to -349), and evil (-350 to -1000). Alignment modification of players is a function of the difference in alignment and difference of levels for the two opponents in combat. In nutshell, killing good aligned mobiles close to your level will make you evil, and vice-versa.

Mobiles of polar alignments can be affected by align-specific spells. The clerical spells "dispel good", "detect good" and "projection from good" only works against mobiles that are of good alignment. Objects that are anti-good cannot he equipped by mobiles that are of good alignment. Good aligned mobiles are given a "blue aura", evil mobiles appear with a "red aura".

< O:-1 M:14000 R:14000 > @mob align 1000
Ok.

< O:-1 M:14000 R:14000 >

4.8 Class

The gate guard is human so we'll set his class to humanoid with the @MOB CLASS command. The class of a mobile determines whether or not their corpse is edible.

Currently available mobile classes:
class attributes
other corpse inedible
humanoid corpse inedible
animal corpse edible
magical corpse inedible
elemental corpse edible
dragon corpse edible

< O:-1 M:14000 R:14000 > @mob class humanoid
Ok.

< O:-1 M:14000 R:14000 >

4.9 Gold

Since civilized humans tend to carry around a bit of gold from time to time, we'll have him load with 30 coins using the @MOB GOLD command. Gold should be relative to level of the mobile. The balance matrix should be consulted first before setting gold on a mobile. Also, gold should be realistic in the sense that a dog or a lizard is probably not going to be carrying any gold around. In other words, don't give gold to mobiles that wouldn't normally be carrying gold. Use the value 0 to have the mobile loaded without any gold.

< O:-1 M:14000 R:14000 > @mob gold 30
Ok.

< O:-1 M:14000 R:14000 >

4.10 Position and default position

Most gate guards spend their time standing. At least they should be standing. However, you can customize the position they are loaded into the game by setting their position and default position with the commands @MOB POSITION and @MOB DEFAULT_POS respectively. The difference is that the games uses the position placeholder for in-game position. The default position is a setting for how the mobile loads into the game what they revert back to should they find themselves in another position (affected by mage "sleep" spell). If you want your mobile to enter and stay in the game in a position other than standing, change them both to the desired position.

< O:-1 M:14000 R:14000 > @mob position resting
Ok.

< O:-1 M:14000 R:14000 > @mob default_pos resting
Ok.

< O:-1 M:14000 R:14000 >

4.11 Gender

Also, the guard is a male human so we'll set his sex with the @MOB SEX command. Sex has no direct impact on any game functions other than pronoun usage in mobile actions.

< O:-1 M:14000 R:14000 > @mob sex male
Ok.

< O:-1 M:14000 R:14000 >

4.12 Size

Humans have a height that is typically taller than that of the default mob size. Use the @MOB SIZE command to set his size to 6. Size impacts combat in ways such that the number of relatively large creatures is lower when attacking relatively small creatures. For example, fewer humans can attack a dog at the same time but more humans can attack a dragon. Relative size also determines whether or not warriors can kick or bash an opponent. Size also determines ability to move around in a tunnel room. Smaller creatures may not be restricted in movement direction in a line inside a room flagged as tunnel.

< O:-1 M:14000 R:14000 > @mob size 6
Ok.

< O:-1 M:14000 R:14000 >

4.13 Move

When a mobile travels from room to room it displays their movement type. The default is walking, however some mobiles such as snakes and birds don't exactly walk when they move around. A custom movement type can be set using the @MOB MOVE command. A mobile can only have one movement type assigned to it. Please use mobile movement types that are geographically (fish swim in water) and physically (fish don't walk).

< O:-1 M:14000 R:14000 > @mob move march
Ok.

< O:-1 M:14000 R:14000 > 

4.14 Custom attack types

By default, mobiles are given bare-hand damage dice. This attack type shows up as "hit" in combat. However, some mobiles such as wolves and bees have a different attack type. Using the @CREATE MOB_ATTACK command you can assign one or more attack types and their respective damage dice. Adding additional attack types does not automatically replace the existing bare-hand attack type. If you wish to have the new attack type(s) added replace the existing bare-hand attack you will need to zero it out by setting the damage dice values to 0 using the @MOB DAMAGE command. You can get a list of available custom attack types by typig "wizhelp @create mob_attack."

Currently available mobile custom attack types:
hit
pound
pierce
slash
whip
claw
bite
sting
crush

< O:-1 M:14000 R:14000 > @create mob_attack claw 1d8+5
Ok.

< O:-1 M:14000 R:14000 > @mob damage 0d0+0
Ok.

< O:-1 M:14000 R:14000 >

4.15 Assigning action flags

Different mobiles should behave different depending on what they are, where they are and who they are interacting with. Using the @FLAG ACT command we can assign action flags to customize the mobile behavior and attributes.

< O:-1 M:14000 R:14000 > @flag act sentinel
Flag is SET.

< O:-1 M:14000 R:14000 > @flag act wa
Flag is SET.

< O:-1 M:14000 R:14000 > 

4.16 Action flags explained

Mobile behavior can be set using one or more of the mobile action flags set with the @FLAG ACT command. Mobiles can have more than one action flag. Unwanted action flags can be removed by calling the @FLAG ACT command with an "!" placed in front of the flag to be removed. The more enhancing action flags a mobile has, the more experience points it is worth.

action flag effects
sentinel will not wander but stay in the same room unless otherwise motivated to leave (charmed, hunter, fleeing, etc.)
scavenger picks up objects inside room they can carry/see
pack aids mobiles in combat of same virtual number in same room
nice-thief will not attack thieves for failed steal attempts
aggressive attempts to attack any player inside the same room they can "see"
stay-zone wandering mobile (not sentinel) will not wander outside of the zone they were loaded in
wimpy attempts to flee out of combat when current hitpoints reach a certain percentage
aggr-e attempts to attack evil aligned players (must have aggressive flag set as well)
aggr-g attempts to attack good aligned players (must have aggressive flag set as well)
aggr-n attempts to attack neutral aligned players (must have aggressive flag set as well)
memory remembers and attempts to attack any player that they remember as having attacked them when in same room, memory goes away when player or mobile dies (or game resets)
hunter attempts to track down players that attacked them that they remember and attack them (used in conjunction with memory)
rideable able to be used as a mount (do not use in conjunction with tameable)
gas gets special breath attack of gas
fire gets special breath attack of fire (similar to mage spell "fireball")
lightning gets special breath attack of lightning (similar to mage spell "lightning bolt")
drain gets special attack of drain (similar to mage spell "energy drain")
poison gets special attack of poison (similar to clerical spell "poison")
cl able to cast clerical spells of mobile level and lower
mu able to cast mage spells of mobile level and lower
th able use thief skills such as sneak, steal and backstab if wielding a pierce type weapon
wa able use warrior skills such as bash, kick rescue and guard
has_dr able to cast druid spells of mobile level and lower
acid gets special breath attack of acid (causes physical damage as well as corrodes equipment)
frost gets special breath attack of frost
nocturnal returns to room loaded in at before daybreak and falls sleep until night
looter gets all from the corpse of their victims and attempts to wear their equipment
stone-gaze gets special attack of stone gaze will can turn a player into a stone statue reversible by the mage spell "stone to flesh" and can be turned back on the mobile with a objected flagged as mirror
fear-aura will attempt to cause players of half their level or lower to flee from combat (similar to the mage spell "fear")
diurnal returns to room loaded in at before nightfall and falls sleep until day
protect attempts to guard mobiles of same virtual number and alignment from attackers
marine able to live in rooms flag as underwater and will not exit to non-underwater rooms
no-charm not able to be affected by the mage spell "charm person" at any level of caster
no-sleep not able to be affected by the mage spell "sleep" at any level of caster
tameable able to be trained into a mount that is rideable (do not use in conjunction with rideable flag)
citizen defines mobile as a citizen of the city in which they are loaded in, guards will come to their aid if attacked (requires implementor assistance)
wimpy-aggr will only attack players that are sleeping (used in conjunction with aggressive and wimpy mobile act flags)

4.17 Assigning affection flags

Mobiles that would affected by certain spells and/or skills can be set using the @FLAG AFFECT command. The spell affects of these flags are permanent in nature, unless the mobile becomes affected by something like the mage spell "dispel magic". The more enhancing affection flags a mobile has, the more experience points it is worth.

< O:-1 M:14000 R:14000 > @flag affect detect-invisible
Flag is SET.

< O:-1 M:14000 R:14000 > @flag affect anti-summon
Flag is SET.

< O:-1 M:14000 R:14000 > 

4.18 Affection flags explained

Mobile affections can be set using the @FLAG AFFECT command. These affect flags are similar to being affected by certain spells. Mobiles can have more than one affection flag. Unwanted flags can be removed by calling the @FLAG AFFECT command with an "!" placed in front of the flag to be removed.

affection flag effects
undead doesn't leave a corpse when "killed"
can be affected by clerical skill "turn"
resistence flags immune_norm, immune_poison immune_cold should be set as well using the @FLAG RESISTANCE command.
invisible affected indefinitely by mage spell "improved invisibility" and can only be seen by those affected by "detect invisible"
detect-evil able to detect evil aligned players and mobiles
detect-invisible able to see invisible mobiles/players indefinitely as per the mage spell "detect invisibility"
detect-magic able to detect magicial objects
sense-life able to sense hidden life forms in room (something affected by sneak entering the room, something affected by hide in the room)
sanctuary affected indefinitely by clerical spell "sanctuary"
faerie-fire affected indefinitely by clerical spell "faerie fire"
water-breathing affected indefinitely by clerical spell "water breathing"
blind affected indefinitely by clerical spell "blindness"
poison affected indefinitely by clerical spell "poison"
protect-evil affected indefinitely by clerical spell "protection from evil"
petrify affected indefinitely by "flesh to stone"
detect-good able to detect good aligned players and mobiles, they appear as haveing a "blue aura"
water-walking affected indefinitely by clerical spell "water walking"
sleep affected indefinitely by mage spell "sleep"
evade affected indefinitely by thief skill "evade"
sneak affected indefinitely by thief skill "sneak"
hide affected indefinitely by thief skill "hide"
protect-good affected indefinitely by clerical spell "protection from good"
charm affected indefinitely by mage spell "charm person"
haste affected indefinitely by mage spell "haste"
light affected indefinitely by mage spell "remove darkness"
anti-summon unable to be summoned by clerics at any level
infravision affected indefinitely by mage spell "infravision"
globe-of-invulnerability affected indefinitely by mage spell "globe of invulnerability"
non-detection affected indefinitely by mage spell "non-detection"
allsight able to "see" all invisible, hidden and non-detect mobiles/objects/players
farsee affected indefinitely by mage spell "farsee"

4.19 Assigning resistance flags

Mobiles that would not be affected by certain spells and combat types can be set using the @FLAG RESISTANCE command. The resistance affects of these flags are permanent in nature. The more resistance flags a mobile has, the more experience points it is worth.

< O:-1 M:14000 R:14000 > @flag resistance resist-norm
Flag is SET.

< O:-1 M:14000 R:14000 > @flag resistance immune-cold
Flag is SET.

< O:-1 M:14000 R:14000 > 

4.20 Resistance flags explained

Mobile resistances can be set using the @FLAG RESISTANCE command. Mobiles can have more than one resistance flag. Unwanted flags can be removed by calling the @FLAG RESISTANCE command with an "!" placed in front of the flag to be removed.

resistance flag effects
resist-norm takes half-damage from any bare-hand attack, weapon not flagged as silver, weapon not flagged as magic
resist-silver takes half-damage from any bare-hand attack, weapon not flagged as silver, weapon flagged as magic
resist-magic takes half-damage from any bare-hand attack, weapon flagged as silver, weapon flagged as maigc
resist-fire takes half-damange from any fire-based spell or skill attack (burning hands, fireball, fire breath, firestorm, etc.)
resist-water takes half-damange from any water-based spell or skill attack (?)
resist-air takes half-damange from any air-based spell or skill attack (shocking grasp, lightning bolt, gas breath, etc.)
resist-earth takes half-damange from any earth-based spell or skill attack (earthquake, etc.)
resist-cold takes half-damange from any cold-based spell or skill attack (frost breath)
resist-electric takes half-damange from any electric-based spell or skill attack (lightning bolt, etc.)
resist-acid takes half-damange from any acid-based spell or skill attack (acid breath, etc.)
resist-poison takes half-damange from any poison-based spell or skill attack (cause poison, poison bite, poison food, etc.)
immune-norm takes no damage from any bare-hand attack, weapon not flagged as silver, weapon not flagged as magic
immune-silver takes no damage from any bare-hand attack, weapon flagged as silver, weapon not flagged as magic
immune-magic takes no damage from any bare-hand attack, weapon flagged as silver, weapon flagged as magicn
immune-fire takes no damange from any fire-based spell or skill attack (burning hands, fireball, fire breath, firestorm, etc.)
immune-water takes no damange from any water-based spell or skill attack ()
immune-air takes no damange from any air-based spell or skill attack ()
immune-earth takes no damange from any earth-based spell or skill attack ()
immune-cold takes no damange from any cold-based spell or skill attack ()
immune-electric takes no damange from any electric-based spell or skill attack ()
immune-acid takes no damange from any acid-based spell or skill attack ()
immune-poison takes no damange from any poison-based spell or skill attack ()

4.21 Finding unused mobiles

Sometimes when creating large areas, the virtual number you left off at can become lost. You can find unused mobile virtual numbers with the @FIND command.

< O:-1 M:-1 R:14003 > @find mobile 14003
There are TODO: finish output here

< O:-1 M:-1 R:14002 > 

4.22 Executing commands across multiple mobiles

Use the @NUMBERS MOBILE command to execute a single command across multiple mobiles. This is useful when forgetting an action flag that needs to placed in all mobiles in a given section of your area. A command response will be returned for each command executed.

< O:-1 M:-1 R:14002 > @numbers mobile 14000 14003 @flag act stay-zone
Ok...
Flag is SET.
Flag is SET.
Flag is SET.
Flag is SET.

< O:-1 M:-1 R:14002 > 

4.23 Scripting mobile commands

Mobiles can be made to execute action commands as if their were "forced" to do them. Use the @SCRIPT command open a line editor to enter in individual commands for the mobile to execute. The commands will be executed as if the mobile typed them. The commands will be executed at random and at limited interval. If you wish to have an action performed more than others, include it more than once in the list.

< O:-1 M:14000 R:14002 > @script
Old script:

Enter text, end with a '@' on a line by itself.
] salute
] emote checks his equipment.
] flex
] say We don't need to do anything, apart from just stop him entering the room.
] yawn
] @

< O:-1 M:14000 R:14002 > 

4.24 Saving your changes

Don't forget to save the mobiles after your work using the @SAVE MOBILE command. Saving the mobile file takes a while and uses a lot of system resources. Save often but not too often.

< O:-1 M:-1 R:14002 > @save mobile
Saving mobile index to file.

< O:-1 M:-1 R:14002 > 


Next Previous Contents