float autocvar_g_monster_wyvern_attack_fireball_radius;
float autocvar_g_monster_wyvern_attack_fireball_speed;
-void M_Wyvern_Attack_Fireball_Explode();
-void M_Wyvern_Attack_Fireball_Touch();
+void M_Wyvern_Attack_Fireball_Explode(entity this);
+void M_Wyvern_Attack_Fireball_Touch(entity this);
SOUND(WyvernAttack_FIRE, W_Sound("electro_fire"));
METHOD(WyvernAttack, wr_think, void(WyvernAttack thiswep, entity actor, .entity weaponentity, int fire))
missile.velocity = w_shotdir * (autocvar_g_monster_wyvern_attack_fireball_speed);
missile.avelocity = '300 300 300';
missile.nextthink = time + 5;
- missile.think = M_Wyvern_Attack_Fireball_Explode;
+ setthink(missile, M_Wyvern_Attack_Fireball_Explode);
settouch(missile, M_Wyvern_Attack_Fireball_Touch);
CSQCProjectile(missile, true, PROJECTILE_FIREMINE, true);
const float wyvern_anim_death = 4;
*/
-void M_Wyvern_Attack_Fireball_Explode()
+void M_Wyvern_Attack_Fireball_Explode(entity this)
{
- SELFPARAM();
Send_Effect(EFFECT_FIREBALL_EXPLODE, this.origin, '0 0 0', 1);
entity own = this.realowner;
remove(this);
}
-void M_Wyvern_Attack_Fireball_Touch()
+void M_Wyvern_Attack_Fireball_Touch(entity this)
{
- PROJECTILE_TOUCH;
+ PROJECTILE_TOUCH(this);
- M_Wyvern_Attack_Fireball_Explode();
+ M_Wyvern_Attack_Fireball_Explode(this);
}
bool M_Wyvern_Attack(int attack_type, entity actor, entity targ)
return true;
}
-METHOD(Wyvern, mr_pain, bool(Wyvern this, entity actor))
+METHOD(Wyvern, mr_pain, float(Wyvern this, entity actor, float damage_take, entity attacker, float deathtype))
{
TC(Wyvern, this);
actor.pain_finished = time + 0.5;
setanim(actor, actor.anim_pain1, true, true, false);
- return true;
+ return damage_take;
}
METHOD(Wyvern, mr_death, bool(Wyvern this, entity actor))