X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Fvehicles%2Fsv_vehicles.qh;h=0cc9da56ea11a57779850fc85f1bdd53ca0864e1;hb=4096ab0591cbd7fac803e022375cd3c221511d8b;hp=0ddd02aa7e0ce77125b2a9dc835df604c54d8cf0;hpb=1b0decb9afb829407eae763b3053a122e2ae3de6;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/vehicles/sv_vehicles.qh b/qcsrc/common/vehicles/sv_vehicles.qh index 0ddd02aa7..0cc9da56e 100644 --- a/qcsrc/common/vehicles/sv_vehicles.qh +++ b/qcsrc/common/vehicles/sv_vehicles.qh @@ -45,14 +45,14 @@ float autocvar_g_vehicles_weapon_damagerate = 2; .entity gunner1; .entity gunner2; -.float vehicle_health = _STAT(VEHICLESTAT_HEALTH); /// If ent is player this is 0..100 indicating precentage of health left on vehicle. If ent is vehile, this is the real health value. -.float vehicle_energy = _STAT(VEHICLESTAT_ENERGY); /// If ent is player this is 0..100 indicating precentage of energy left on vehicle. If ent is vehile, this is the real energy value. -.float vehicle_shield = _STAT(VEHICLESTAT_SHIELD); /// If ent is player this is 0..100 indicating precentage of shield left on vehicle. If ent is vehile, this is the real shield value. +.float vehicle_health = _STAT(VEHICLESTAT_HEALTH); /// If ent is player this is 0..100 indicating precentage of health left on vehicle. If ent is vehicle, this is the real health value. +.float vehicle_energy = _STAT(VEHICLESTAT_ENERGY); /// If ent is player this is 0..100 indicating precentage of energy left on vehicle. If ent is vehicle, this is the real energy value. +.float vehicle_shield = _STAT(VEHICLESTAT_SHIELD); /// If ent is player this is 0..100 indicating precentage of shield left on vehicle. If ent is vehicle, this is the real shield value. -.float vehicle_ammo1 = _STAT(VEHICLESTAT_AMMO1); /// If ent is player this is 0..100 indicating percentage of primary ammo left UNLESS value is already stored in vehicle_energy. If ent is vehile, this is the real ammo1 value. -.float vehicle_reload1 = _STAT(VEHICLESTAT_RELOAD1); /// If ent is player this is 0..100 indicating percentage of primary reload status. If ent is vehile, this is the real reload1 value. -.float vehicle_ammo2 = _STAT(VEHICLESTAT_AMMO2); /// If ent is player this is 0..100 indicating percentage of secondary ammo left. If ent is vehile, this is the real ammo2 value. -.float vehicle_reload2 = _STAT(VEHICLESTAT_RELOAD2); /// If ent is player this is 0..100 indicating percentage of secondary reload status. If ent is vehile, this is the real reload2 value. +.float vehicle_ammo1 = _STAT(VEHICLESTAT_AMMO1); /// If ent is player this is 0..100 indicating percentage of primary ammo left UNLESS value is already stored in vehicle_energy. If ent is vehicle, this is the real ammo1 value. +.float vehicle_reload1 = _STAT(VEHICLESTAT_RELOAD1); /// If ent is player this is 0..100 indicating percentage of primary reload status. If ent is vehicle, this is the real reload1 value. +.float vehicle_ammo2 = _STAT(VEHICLESTAT_AMMO2); /// If ent is player this is 0..100 indicating percentage of secondary ammo left. If ent is vehicle, this is the real ammo2 value. +.float vehicle_reload2 = _STAT(VEHICLESTAT_RELOAD2); /// If ent is player this is 0..100 indicating percentage of secondary reload status. If ent is vehicle, this is the real reload2 value. .float sound_nexttime; const float VOL_VEHICLEENGINE = 1; @@ -79,7 +79,6 @@ const int MAX_AXH = 4; .float lock_strength; .float lock_time; .float lock_soundtime; -const float DAMAGE_TARGETDRONE = 10; // vehicle functions .void(int _spawnflag) vehicle_spawn; /// Vehicles custom fucntion to be efecuted when vehicle (re)spawns @@ -87,7 +86,7 @@ const float DAMAGE_TARGETDRONE = 10; .void(entity this, int exit_flags) vehicle_exit; .bool(entity this, entity player) vehicle_enter; const int VHEF_NORMAL = 0; /// User pressed exit key -const int VHEF_EJECT = 1; /// User pressed exit key 3 times fast (not implemented) or vehile is dying +const int VHEF_EJECT = 1; /// User pressed exit key 3 times fast (not implemented) or vehicle is dying const int VHEF_RELEASE = 2; /// Release ownership, client possibly allready dissconnected / went spec / changed team / used "kill" (not implemented) float force_fromtag_power; @@ -107,6 +106,7 @@ bool vehicle_initialize(entity this, Vehicle info, float nodrop); bool vehicle_impulse(entity this, int imp); bool vehicles_crushable(entity e); float vehicle_altitude(entity this, float amax); +void vehicles_enter(entity pl, entity veh); IntrusiveList g_vehicle_returners; STATIC_INIT(g_vehicle_returners) { g_vehicle_returners = IL_NEW(); }