beam.attack_finished_single[0] = actor.attack_finished_single[0];
actor.attack_finished_single[0] = time; // + autocvar_sys_ticrate;
- setattachment(beam,actor.tur_head, "tag_fire");
+ setattachment(beam, actor.tur_head, "tag_fire");
soundat (actor, trace_endpos, CH_SHOTS, SND(NEXIMPACT), VOL_BASE, ATTEN_NORM);
if (!isPlayer)
void beam_think(entity this)
{
- if ((time > this.cnt) || (IS_DEAD(this.owner)))
+ entity actor = this.owner;
+ if ((time > this.cnt) || (IS_DEAD(actor)))
{
- this.owner.attack_finished_single[0] = time + this.owner.shot_refire;
- this.owner.fireflag = 2;
- this.owner.tur_head.frame = 10;
+ actor.attack_finished_single[0] = time + actor.shot_refire;
+ actor.fireflag = 2;
+ actor.tur_head.frame = 10;
sound (this, CH_SHOTS_SINGLE, SND_Null, VOL_BASE, ATTEN_NORM);
delete(this);
return;
}
- turret_do_updates(this.owner);
+ turret_do_updates(actor);
if (time - this.shot_spread > 0)
{
sound (this, CH_SHOTS_SINGLE, SND_TUR_PHASER, VOL_BASE, ATTEN_NORM);
}
-
this.nextthink = time + this.ticrate;
- this.owner.attack_finished_single[0] = time + frametime;
- FireImoBeam ( this.owner, this.tur_shotorg,
- this.tur_shotorg + this.tur_shotdir_updated * this.target_range,
- '-1 -1 -1' * this.shot_radius,
- '1 1 1' * this.shot_radius,
- this.shot_force,
+ actor.attack_finished_single[0] = time + frametime;
+ FireImoBeam ( actor, actor.tur_shotorg,
+ actor.tur_shotorg + actor.tur_shotdir_updated * actor.target_range,
+ '-1 -1 -1' * actor.shot_radius,
+ '1 1 1' * actor.shot_radius,
+ actor.shot_force,
this.shot_dmg,
0.75,
DEATH_TURRET_PHASER.m_id);
- this.scale = vlen(this.owner.tur_shotorg - trace_endpos) / 256;
-
+ this.scale = vlen(actor.tur_shotorg - trace_endpos) / 256;
}
#endif