-#ifndef SV_MONSTERS_H
-#define SV_MONSTERS_H
+#pragma once
+
+#include "all.qh"
// stats networking
-.int stat_monsters_killed;
-.int stat_monsters_total;
int monsters_total;
int monsters_killed;
void monsters_setstatus(entity this);
-bool Monster_Spawn(entity this, int mon_id);
+bool Monster_Spawn(entity this, bool check_appear, Monster mon);
void monster_setupcolors(entity this);
-void Monster_Touch();
+void Monster_Touch(entity this, entity toucher);
void Monster_Move_2D(entity this, float mspeed, float allow_jumpoff);
float Monster_Attack_Melee(entity this, entity targ, float damg, vector anim, float er, float animtime, int deathtype, float dostop);
-bool Monster_Attack_Leap(entity this, vector anm, void() touchfunc, vector vel, float animtime);
+bool Monster_Attack_Leap(entity this, vector anm, void(entity this, entity toucher) touchfunc, vector vel, float animtime);
entity Monster_FindTarget(entity this);
float GetMonsterSoundSampleField_notFound;
-#endif
+IntrusiveList g_monsters;
+STATIC_INIT(g_monsters) { g_monsters = IL_NEW(); }
+
+IntrusiveList g_monster_targets;
+STATIC_INIT(g_monster_targets) { g_monster_targets = IL_NEW(); }