Crossfire Server, Trunk  R20513
Macros
Monster movements

Macros

#define ALLRUN   6
 Always run, never attack good for sim. More...
 
#define CIRCLE1   32
 If the upper four bits of move_type / attack_movement are set to this number, the monster will move in a circle until it is attacked, or the enemy field is set, this is good for non-aggressive monsters and NPC. More...
 
#define CIRCLE2   48
 Same as CIRCLE1 but a larger circle is used. More...
 
#define DISTATT   1
 Move toward a player if far, but maintain some space, attack from a distance - good for missile users only. More...
 
#define DISTHIT   7
 Attack from a distance if hit as recommended by Frank. More...
 
#define HI4   240
 
#define HITRUN   3
 Run to then hit player then run away cyclicly. More...
 
#define LO4   15
 bitmasks for upper and lower 4 bits from 8 bit fields More...
 
#define PACEH   64
 The monster will pace back and forth until attacked. More...
 
#define PACEH2   80
 The monster will pace as above but the length of the pace area is longer and the monster stops before changing directions. More...
 
#define PACEV   128
 The monster will pace back and forth until attacked. More...
 
#define PACEV2   144
 The monster will pace as above but the length of the pace area is longer and the monster stops before changing directions. More...
 
#define PETMOVE   16
 If the upper four bits of attack_movement are set to this number, the monster follows a player until the owner calls it back or off player followed denoted by ob->owner the monster will try to attack whatever the player is attacking, and will continue to do so until the calls off the monster - a key command will be inserted to do so. More...
 
#define RANDO   96
 The monster will go in a random direction until it is stopped by an obstacle, then it chooses another direction. More...
 
#define RANDO2   112
 Constantly move in a different random direction. More...
 
#define RUNATT   2
 Run but attack if player catches up to object. More...
 
#define RUSH   5
 Rush toward player blindly, similiar to dumb monster. More...
 
#define WAIT2   8
 Monster does not try to move towards player if far. More...
 
#define WAITATT   4
 Wait for player to approach then hit, move if hit. More...
 

Detailed Description

Author
kholl.nosp@m.and@.nosp@m.sunla.nosp@m.b.ci.nosp@m.t.cor.nosp@m.nell.nosp@m..edu

if your monsters start acting wierd, mail me.

Macro Definition Documentation

#define ALLRUN   6

Always run, never attack good for sim.

of weak player.

Definition at line 512 of file define.h.

Referenced by initConstants(), and monster_move().

#define CIRCLE1   32

If the upper four bits of move_type / attack_movement are set to this number, the monster will move in a circle until it is attacked, or the enemy field is set, this is good for non-aggressive monsters and NPC.

Definition at line 532 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define CIRCLE2   48

Same as CIRCLE1 but a larger circle is used.

Definition at line 539 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define DISTATT   1

Move toward a player if far, but maintain some space, attack from a distance - good for missile users only.

Definition at line 505 of file define.h.

Referenced by initConstants(), and monster_move().

#define DISTHIT   7

Attack from a distance if hit as recommended by Frank.

Definition at line 513 of file define.h.

Referenced by initConstants(), and monster_move().

#define HI4   240
#define HITRUN   3

Run to then hit player then run away cyclicly.

Definition at line 509 of file define.h.

Referenced by initConstants(), and monster_move().

#define LO4   15

bitmasks for upper and lower 4 bits from 8 bit fields

Definition at line 566 of file define.h.

Referenced by monster_move().

#define PACEH   64

The monster will pace back and forth until attacked.

This is HORIZONTAL movement.

Definition at line 540 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define PACEH2   80

The monster will pace as above but the length of the pace area is longer and the monster stops before changing directions.

This is HORIZONTAL movement.

Definition at line 543 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define PACEV   128

The monster will pace back and forth until attacked.

This is VERTICAL movement.

Definition at line 556 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define PACEV2   144

The monster will pace as above but the length of the pace area is longer and the monster stops before changing directions.

This is VERTICAL movement.

Definition at line 559 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define PETMOVE   16

If the upper four bits of attack_movement are set to this number, the monster follows a player until the owner calls it back or off player followed denoted by ob->owner the monster will try to attack whatever the player is attacking, and will continue to do so until the calls off the monster - a key command will be inserted to do so.

Definition at line 517 of file define.h.

Referenced by change_object(), do_mood_floor(), fix_summon_pet(), initConstants(), monster_check_enemy(), monster_find_enemy(), monster_move(), monster_move_no_enemy(), mood_change(), pets_get_enemy(), pets_summon_golem(), polymorph_living(), steal(), and use_oratory().

#define RANDO   96

The monster will go in a random direction until it is stopped by an obstacle, then it chooses another direction.

Definition at line 550 of file define.h.

Referenced by initConstants(), and monster_move_no_enemy().

#define RANDO2   112

Constantly move in a different random direction.

Definition at line 555 of file define.h.

Referenced by initConstants(), monster_move_no_enemy(), and peacemaker_type_process().

#define RUNATT   2

Run but attack if player catches up to object.

Definition at line 508 of file define.h.

Referenced by initConstants(), and monster_move().

#define RUSH   5

Rush toward player blindly, similiar to dumb monster.

Definition at line 511 of file define.h.

Referenced by initConstants(), and monster_move().

#define WAIT2   8

Monster does not try to move towards player if far.

Maintains comfortable distance.

Definition at line 514 of file define.h.

Referenced by initConstants(), and monster_move().

#define WAITATT   4

Wait for player to approach then hit, move if hit.

Definition at line 510 of file define.h.

Referenced by initConstants(), and monster_move().