W_Electro_TriggerCombo(this.origin, WEP_CVAR(electro, combo_comboradius), this.realowner);
this.event_damage = func_null;
- this.velocity = this.movedir; // particle fx and decals need .velocity
+ this.velocity = this.movedir; // .velocity must be != '0 0 0' for particle fx and decal to work
RadiusDamage(
this,
this.event_damage = func_null;
this.takedamage = DAMAGE_NO;
- this.velocity = this.movedir; // particle fx and decals need .velocity
+ this.velocity = this.movedir; // .velocity must be != '0 0 0' for particle fx and decal to work
if(this.move_movetype == MOVETYPE_BOUNCE || this.classname == "electro_orb") // TODO: classname is more reliable anyway?
{
this.takedamage = DAMAGE_NO;
if(this.move_movetype == MOVETYPE_NONE || this.move_movetype == MOVETYPE_FOLLOW)
- this.velocity = this.movedir; // particle fx and decals need .velocity
+ this.velocity = this.movedir; // .velocity must be != '0 0 0' for particle fx and decal to work
RadiusDamage(this, this.realowner, WEP_CVAR(minelayer, remote_damage), WEP_CVAR(minelayer, remote_edgedamage), WEP_CVAR(minelayer, remote_radius),
NULL, NULL, WEP_CVAR(minelayer, remote_force), this.projectiledeathtype | HITTYPE_BOUNCE, this.weaponentity_fld, NULL);
this.takedamage = DAMAGE_NO;
if(this.move_movetype == MOVETYPE_NONE)
- this.velocity = this.oldvelocity;
+ this.velocity = this.movedir; // .velocity must be != '0 0 0' for particle fx and decal to work
RadiusDamage(this, this.realowner, WEP_CVAR_PRI(mortar, damage), WEP_CVAR_PRI(mortar, edgedamage), WEP_CVAR_PRI(mortar, radius), NULL, NULL, WEP_CVAR_PRI(mortar, force), this.projectiledeathtype, this.weaponentity_fld, directhitentity);
this.takedamage = DAMAGE_NO;
if(this.move_movetype == MOVETYPE_NONE)
- this.velocity = this.oldvelocity;
+ this.velocity = this.movedir; // .velocity must be != '0 0 0' for particle fx and decal to work
RadiusDamage(this, this.realowner, WEP_CVAR_SEC(mortar, damage), WEP_CVAR_SEC(mortar, edgedamage), WEP_CVAR_SEC(mortar, radius), NULL, NULL, WEP_CVAR_SEC(mortar, force), this.projectiledeathtype, this.weaponentity_fld, directhitentity);
spamsound(this, CH_SHOTS, SND_GRENADE_STICK, VOL_BASE, ATTN_NORM);
// let it stick whereever it is
- this.oldvelocity = this.velocity;
+ this.movedir = this.velocity; // save to this temporary field, will be restored on explosion
this.velocity = '0 0 0';
set_movetype(this, MOVETYPE_NONE); // also disables gravity
this.gravity = 0; // nope, it does NOT! maybe a bug in CSQC code? TODO
spamsound(this, CH_SHOTS, SND_GRENADE_STICK, VOL_BASE, ATTN_NORM);
// let it stick whereever it is
- this.oldvelocity = this.velocity;
+ this.movedir = this.velocity; // save to this temporary field, will be restored on explosion
this.velocity = '0 0 0';
set_movetype(this, MOVETYPE_NONE); // also disables gravity
this.gravity = 0; // nope, it does NOT! maybe a bug in CSQC code? TODO