Skip to content
AnonXS edited this page Mar 3, 2023 · 9 revisions

Back to world database list of tables.

The `creature` table

contains individual creature spawn data. Spawn of a creature is an instance of the creature object in the world.

Structure

Field Type Null Key Default Extra
guid int(10) unsigned NO PRI None auto_increment
id mediumint(8) unsigned NO MUL 0
map smallint(5) unsigned NO MUL 0
spawnMask tinyint(3) unsigned NO 1
phaseMask smallint(5) unsigned NO 1 (WotLK+)
position_x float NO 0
position_y float NO 0
position_z float NO 0
orientation float NO 0
spawntimesecsmin int(10) unsigned NO 120
spawntimesecsmax int(10) unsigned NO 120
spawndist float NO 5
MovementType tinyint(3) unsigned NO 0

Description of the fields

guid

A unique identifier given to each creature to distinguish one creature from another. Two creatures can NOT have same GUID.

id

The id of the template that is used when instantiating this creature. See creature_template.entry

map

The Map ID of the position of the creature. See Map.dbc

spawnMask

Controls under which difficulties the creature will be spawned.

Value Comment
0 Not spawned
1 Spawned only in 10-man-normal versions of maps (includes maps without a heroic mode)
2 Spawned only in 25-man-normal versions of maps (or heroics pre 3.2)
4 Spawned only in 10-man heroic versions of maps
8 Spawned only in 25-man-heroic versions of maps
15 Spawned in all versions of maps

phaseMask

Defines which phase the creature belongs. 1 is default phase, rest are from spell’s aura 261, (Aura #261) (4) = phasemask = 4.

position_x

The X position of the creature.

position_y

The Y position of the creature.

position_z

The Z position of the creature.

orientation

The orientation of the creature. (North = 0.0; South = pi (3.14159))

spawntimesecsmin

The minimum respawn time of the creature in seconds.

spawntimesecsmax

The maximum respawn time of the creature in seconds.

If both spawntimesecsmin and spawntimesecsmax are 0, creature will not respawn. only scripted respawn

spawndist

The maximum distance that the creature should spawn from its spawn point. Also controls how far away the creature can walk from its spawn point if its MovementType = 1.

Value Comment
-1 Orientation change only – not implemented currently
5 Default random movement value

MovementType

See creature_template.MovementType for possible values.

creature_movement and creature_movement_template need to have MovementType set to 2,3,4 for a guid.

spawn_group / waypoint_path spawns should use 0 for all creatures of that spawn_group.

Value Name Comment
0 IDLE_MOTION_TYPE No Movement – IdleMovementGenerator
1 RANDOM_MOTION_TYPE Random Movement with spawndist – RandomMovementGenerator
2 WAYPOINT_MOTION_TYPE 123.123 – WaypointMovementGenerator
3 PATH_MOTION_TYPE 123.123 – Spline Movement, All Waypoints are send in creature update packet (e.g flight paths) – PathMovementGenerator
4 LINEAR_WP_MOTION_TYPE 123.21.23.21.23.21 – WaypointMovementGenerator
Clone this wiki locally