this.event_damage = func_null;
RadiusDamage (this, this.realowner, this.shot_dmg, 0, this.shot_radius, this, NULL, this.shot_force, this.totalfrags, toucher);
- remove (this);
+ delete (this);
}
void vehicles_projectile_explode_think(entity this)
proj.totalfrags = _deahtype;
proj.solid = SOLID_BBOX;
set_movetype(proj, MOVETYPE_FLYMISSILE);
- proj.flags = FL_PROJECTILE;
+ proj.flags = FL_PROJECTILE;
+ IL_PUSH(g_projectiles, proj);
proj.bot_dodge = true;
proj.bot_dodgerating = _dmg;
proj.velocity = _vel;
proj.health = _health;
}
else
- proj.flags = FL_PROJECTILE | FL_NOTARGET;
+ proj.flags |= FL_NOTARGET;
if(_mzlsound != SND_Null)
sound (this, CH_WEAPON_A, _mzlsound, VOL_BASE, ATTEN_NORM);
sound (this, CH_SHOTS, SND_ROCKET_IMPACT, VOL_BASE, ATTEN_NORM);
Send_Effect(EFFECT_EXPLOSION_SMALL, randomvec() * 80 + (this.origin + '0 0 100'), '0 0 0', 1);
Send_Effect(EFFECT_EXPLOSION_SMALL, this.wp00.origin + '0 0 64', '0 0 0', 1);
- remove(this);
+ delete(this);
}
void vehicles_gib_touch(entity this, entity toucher)
{
this.alpha -= 0.1;
if(this.cnt >= time)
- remove(this);
+ delete(this);
else
this.nextthink = time + 0.1;
}
entity _slot,
int _hud,
Model _hud_model,
- bool(entity) _framefunc,
+ bool(entity,float) _framefunc,
void(entity,bool) _exitfunc, float(entity, entity) _enterfunc)
{
if(!(_owner.vehicle_flags & VHF_MULTISLOT))
if(this.waypointsprite_attached)
WaypointSprite_Kill(this.waypointsprite_attached);
- remove(this);
+ delete(this);
}
void vehicles_showwp_goaway(entity this)
if(this.waypointsprite_attached)
WaypointSprite_Kill(this.waypointsprite_attached);
- remove(this);
+ delete(this);
}
void vehicles_showwp(entity this)
void vehicle_use(entity this, entity actor, entity trigger)
{
- LOG_DEBUG("vehicle ", this.netname, " used by ", actor.classname, "\n");
+ LOG_DEBUG("vehicle ", this.netname, " used by ", actor.classname);
this.tur_head.team = actor.team;
if(this.active == ACTIVE_ACTIVE && !IS_DEAD(this) && !gameover)
{
- LOG_DEBUG("Respawning vehicle: ", this.netname, "\n");
+ LOG_DEBUG("Respawning vehicle: ", this.netname);
if(this.effects & EF_NODRAW)
{
setthink(this, vehicles_spawn);
if(vehicles_exit_running)
{
- LOG_TRACE("^1vehicles_exit already running! this is not good...\n");
+ LOG_TRACE("^1vehicles_exit already running! this is not good...");
return;
}
// initialization
void vehicles_spawn(entity this)
{
- LOG_DEBUG("Spawning vehicle: ", this.classname, "\n");
+ LOG_DEBUG("Spawning vehicle: ", this.classname);
// disown & reset
this.vehicle_hudmodel.viewmodelforclient = this;
return false;
if(!this.tur_head)
+ {
info.vr_precache(info);
+ IL_PUSH(g_vehicles, this);
+ }
if(this.targetname && this.targetname != "")
{
this.vehicle_controller = find(NULL, target, this.targetname);
if(!this.vehicle_controller)
{
- LOG_DEBUG("^1WARNING: ^7Vehicle with invalid .targetname\n");
+ LOG_DEBUG("^1WARNING: ^7Vehicle with invalid .targetname");
this.active = ACTIVE_ACTIVE;
}
else