]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/server/monsters/lib/defs.qh
8ebea2ebecfa147f7ae8144ef2146ad24827274f
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / monsters / lib / defs.qh
1 .void()         attack_melee;
2 .float()        attack_ranged;
3 .float()        checkattack;
4
5 .float candrop;
6
7 .float spawn_time; // stop monster from moving around right after spawning
8
9 .string oldtarget2;
10 .float lastshielded;
11
12 const float MONSTER_RESPAWN_SPAWNPOINT = 10; // re-spawn at original spawn point
13 const float MONSTER_RESPAWN_DEATHPOINT = 11; // re-spawn where we died
14
15 .float monster_respawned; // used to make sure we're not recounting respawned monster stats
16
17 float monsters_spawned;
18
19 const float MONSTERSKILL_NOTEASY = 256; // monster will not spawn on skill <= 2
20 const float MONSTERSKILL_NOTMEDIUM = 512; // monster will not spawn on skill 3
21 const float MONSTERSKILL_NOTHARD = 1024; // monster will not spawn on skill 4
22 const float MONSTERSKILL_NOTINSANE = 2048; // monster will not spawn on skill 5
23 const float MONSTERSKILL_NOTNIGHTMARE = 4096; // monster will not spawn on skill >= 6
24
25 // legacy flags
26 const float MONSTERFLAG_NORESPAWN = 2;
27 const float MONSTERFLAG_MINIBOSS = 64;  // monster spawns as mini-boss (also has a chance of naturally becoming one)
28 const float MONSTERFLAG_NOWANDER = 128; // disable wandering around (currently unused)
29 const float MONSTERFLAG_APPEAR = 256; // delay spawn until triggered
30 const float MONSTERFLAG_GIANT = 512; // experimental giant monsters feature
31 const float MONSTERFLAG_SPAWNED = 1024; // flag for spawned monsters
32
33 .float msound_delay; // restricts some monster sounds
34 .string msound_idle;
35 .string msound_death;
36 .string msound_attack_melee;
37 .string msound_attack_ranged;
38 .string msound_spawn;
39 .string msound_sight;
40 .string msound_pain;
41
42 .void() monster_spawnfunc;
43 .void() monster_die;
44 .void() monster_delayedattack;
45
46 .float monster_movestate; // used to tell what the monster is currently doing
47 const float MONSTER_MOVE_OWNER = 1; // monster will move to owner if in range, or stand still
48 const float MONSTER_MOVE_WANDER = 2; // monster will ignore owner & wander around
49 const float MONSTER_MOVE_SPAWNLOC = 3; // monster will move to its spawn location when not attacking
50 const float MONSTER_MOVE_NOMOVE = 4; // monster simply stands still
51 const float MONSTER_MOVE_ENEMY = 5; // used only as a movestate
52
53 const float MONSTER_STATE_ATTACK_LEAP = 1;
54 const float MONSTER_STATE_ATTACK_MELEE = 2;