]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/monsters/monster/spider.qc
Use the sound list
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / monsters / monster / spider.qc
index dae97c187ba3a29ecc2b4894a8e79f37f0ac1307..f6c3089ce358d0c45b64e985f04d507a674d29e5 100644 (file)
@@ -3,7 +3,7 @@ bool M_Spider(int);
 #endif
 REGISTER_MONSTER_SIMPLE(
 /* MON_##id   */ SPIDER,
-/* spawnflags */ MON_FLAG_MELEE | MON_FLAG_RANGED,
+/* spawnflags */ MON_FLAG_MELEE | MON_FLAG_RANGED | MON_FLAG_RIDE,
 /* mins,maxs  */ '-18 -18 -25', '18 18 30',
 /* model      */ "spider.dpm",
 /* netname    */ "spider",
@@ -38,7 +38,7 @@ const float spider_anim_attack2               = 3;
 .float spider_web_delay;
 
 void M_Spider_Attack_Web_Explode()
-{
+{SELFPARAM();
        entity e;
        if(self)
        {
@@ -60,10 +60,10 @@ void M_Spider_Attack_Web_Touch()
 }
 
 void M_Spider_Attack_Web()
-{
+{SELFPARAM();
        monster_makevectors(self.enemy);
 
-       sound(self, CH_SHOTS, W_Sound("electro_fire2"), VOL_BASE, ATTEN_NORM);
+       sound(self, CH_SHOTS, SND_ELECTRO_FIRE2, VOL_BASE, ATTEN_NORM);
 
        entity proj = spawn ();
        proj.classname = "plasma";
@@ -98,7 +98,7 @@ void M_Spider_Attack_Web()
 }
 
 bool M_Spider_Attack(int attack_type)
-{
+{SELFPARAM();
        switch(attack_type)
        {
                case MONSTER_ATTACK_MELEE:
@@ -128,7 +128,7 @@ void spawnfunc_monster_spider() { Monster_Spawn(MON_SPIDER.monsterid); }
 #endif // SVQC
 
 bool M_Spider(int req)
-{
+{SELFPARAM();
        switch(req)
        {
                #ifdef SVQC
@@ -176,8 +176,6 @@ bool M_Spider(int req)
                }
                case MR_PRECACHE:
                {
-                       precache_model("models/monsters/spider.dpm");
-                       precache_sound (W_Sound("electro_fire2"));
                        return true;
                }
                #endif