]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/monsters/sv_monsters.qh
More stuff.
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / monsters / sv_monsters.qh
index 1f210235f5f7be8a0070dcb78e465926019fcfe3..239db02bd225cb3928453f7ca4bef8f4133209e7 100644 (file)
@@ -1,10 +1,7 @@
 .string spawnmob;
 .float monster_attack;
 
-float monster_skill;
-
 .entity monster_owner; // new monster owner entity, fixes non-solid monsters
-.float monstercount; // per player monster count
 
 .float stat_monsters_killed; // stats
 .float stat_monsters_total;
@@ -13,9 +10,25 @@ float monsters_killed;
 void monsters_setstatus(); // monsters.qc
 .float monster_moveflags; // checks where to move when not attacking
 
+.float wander_delay;
+.float wander_distance;
+
+.float monster_lifetime;
+
+.float spider_slowness; // special spider timer
+
+void monster_remove(entity mon); // removes a monster
+
 .float(float attack_type) monster_attackfunc;
-const float MONSTER_ATTACK_MELEE       = 1;
-const float MONSTER_ATTACK_RANGED      = 2;
+const float MONSTER_ATTACK_MELEE = 1;
+const float MONSTER_ATTACK_RANGED = 2;
+
+.float monster_skill;
+const float MONSTER_SKILL_EASY = 1;
+const float MONSTER_SKILL_MEDIUM = 3;
+const float MONSTER_SKILL_HARD = 5;
+const float MONSTER_SKILL_INSANE = 7;
+const float MONSTER_SKILL_NIGHTMARE = 10;
 
 .float fish_wasdrowning; // used to reset a drowning fish's angles if it reaches water again
 
@@ -34,6 +47,7 @@ const float MONSTER_ATTACK_RANGED     = 2;
 
 // monster sounds
 // copied from player sounds
+.float msound_delay; // temporary antilag system
 #define ALLMONSTERSOUNDS \
                _MSOUND(death) \
                _MSOUND(sight) \
@@ -41,7 +55,7 @@ const float MONSTER_ATTACK_RANGED     = 2;
                _MSOUND(melee) \
                _MSOUND(pain) \
                _MSOUND(spawn) \
-               _MSOUND(idle) 
+               _MSOUND(idle)
 
 #define _MSOUND(m) .string monstersound_##m;
 ALLMONSTERSOUNDS
@@ -49,8 +63,6 @@ ALLMONSTERSOUNDS
 
 float GetMonsterSoundSampleField_notFound;
 
-.float monster_respawned; // used to make sure we're not recounting respawned monster stats
-
 const float MONSTERSKILL_NOTEASY = 256; // monster will not spawn on skill <= 1
 const float MONSTERSKILL_NOTMEDIUM = 512; // monster will not spawn on skill 2
 const float MONSTERSKILL_NOTHARD = 1024; // monster will not spawn on skill >= 3
@@ -59,20 +71,11 @@ const float MONSTERSKILL_NOTHARD = 1024; // monster will not spawn on skill >= 3
 const float MONSTERFLAG_APPEAR = 2; // delay spawn until triggered
 const float MONSTERFLAG_NORESPAWN = 4;
 const float MONSTERFLAG_FLY_VERTICAL = 8; // fly/swim vertically
-const float MONSTERFLAG_INFRONT = 16; // only check for enemies infront of us
-const float MONSTERFLAG_MINIBOSS = 64;  // monster spawns as mini-boss (also has a chance of naturally becoming one)
+const float MONSTERFLAG_INFRONT = 32; // only check for enemies infront of us
+const float MONSTERFLAG_MINIBOSS = 64; // monster spawns as mini-boss (also has a chance of naturally becoming one)
+const float MONSTERFLAG_INVINCIBLE = 128; // monster doesn't take damage (may be used for map objects & temporary monsters)
 const float MONSTERFLAG_SPAWNED = 16384; // flag for spawned monsters
-
-.float msound_delay; // restricts some monster sounds
-.string msound_idle;
-.string msound_death;
-.string msound_attack_melee;
-.string msound_attack_ranged;
-.string msound_spawn;
-.string msound_sight;
-.string msound_pain;
-
-.void() monster_spawnfunc;
+const float MONSTERFLAG_RESPAWNED = 32768; // flag for re-spawned monsters
 
 .float monster_movestate; // used to tell what the monster is currently doing
 const float MONSTER_MOVE_OWNER = 1; // monster will move to owner if in range, or stand still
@@ -83,4 +86,3 @@ const float MONSTER_MOVE_ENEMY = 5; // used only as a movestate
 
 const float MONSTER_STATE_ATTACK_LEAP = 1;
 const float MONSTER_STATE_ATTACK_MELEE = 2;
-