self.vehicle_flags |= VHF_HEALTHREGEN;
self.think = racer_dinit;
- self.nextthink = time + 1;
+ self.nextthink = time + (autocvar_g_vehicles_delayspawn ? autocvar_g_vehicle_racer_respawntime + (random() * autocvar_g_vehicles_delayspawn_jitter) : 0.5);
}
#endif // SVQC
precache_sound ("vehicles/raptor_speed.wav");
self.think = raptor_dinit;
- self.nextthink = time + 1;
+ self.nextthink = time + (autocvar_g_vehicles_delayspawn ? autocvar_g_vehicle_raptor_respawntime + (random() * autocvar_g_vehicles_delayspawn_jitter) : 0.5);
}
#endif // SVQC
if(autocvar_g_vehicle_spiderbot_health_regen)
self.vehicle_flags |= VHF_HEALTHREGEN;
-
- self.think = vewhicle_spiderbot_dinit;
- self.nextthink = time + 0.5;
+
+ self.think = vewhicle_spiderbot_dinit;
+ self.nextthink = time + (autocvar_g_vehicles_delayspawn ? autocvar_g_vehicle_spiderbot_respawntime + (random() * autocvar_g_vehicles_delayspawn_jitter) : 0.5);
}
#endif // SVQC
float autocvar_g_vehicles_crush_dmg;
float autocvar_g_vehicles_crush_force;
float autocvar_g_vehicles_delayspawn;
+float autocvar_g_vehicles_delayspawn_jitter;
void vehicles_damage(entity inflictor, entity attacker, float damage, float deathtype, vector hitloc, vector force);
void vehicles_return();
self.PlayerPhysplug = physproc;
self.event_damage = vehicles_damage;
self.touch = vehicles_touch;
- self.think = vehicles_spawn;
-
- if(autocvar_g_vehicles_delayspawn)
- self.nextthink = time + _respawntime;
- else
- self.nextthink = time;
-
+ self.think = vehicles_spawn;
+ self.nextthink = time;
self.vehicle_respawntime = _respawntime;
self.vehicle_spawn = spawnproc;