X-Git-Url: https://git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fg_damage.qh;h=aee4a93df80da7cecde86899592331cd79b55777;hb=7e474d576080259e21690de30778b17029b5c0f2;hp=1f4f3b5d2b94ffd1b60d4c619cbdfd60d18e2f89;hpb=724a41faf2cbfd86d41f3ab59ff8326a831a8326;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/g_damage.qh b/qcsrc/server/g_damage.qh index 1f4f3b5d2..aee4a93df 100644 --- a/qcsrc/server/g_damage.qh +++ b/qcsrc/server/g_damage.qh @@ -1,28 +1,29 @@ -#ifndef G_DAMAGE_H -#define G_DAMAGE_H +#pragma once #if defined(CSQC) #elif defined(MENUQC) #elif defined(SVQC) - #include "../lib/warpzone/common.qh" - #include "../common/constants.qh" - #include "../common/teams.qh" - #include "../common/util.qh" - #include "../common/weapons/all.qh" + #include + #include + #include + #include + #include + #include + #include #include "weapons/accuracy.qh" #include "weapons/csqcprojectile.qh" #include "weapons/selection.qh" - #include "../common/t_items.qh" + #include #include "autocvars.qh" #include "constants.qh" #include "defs.qh" - #include "../common/notifications.qh" - #include "../common/deathtypes/all.qh" - #include "mutators/all.qh" - #include "../common/turrets/sv_turrets.qh" - #include "../common/vehicles/all.qh" - #include "../lib/csqcmodel/sv_model.qh" - #include "../common/playerstats.qh" + #include + #include + #include "mutators/_mod.qh" + #include + #include + #include + #include #include "g_hook.qh" #include "scores.qh" #include "spawnpoints.qh" @@ -53,10 +54,10 @@ float damage_gooddamage; float IsFlying(entity a); -void UpdateFrags(entity player, float f); +void UpdateFrags(entity player, int f); // NOTE: f=0 means still count as a (positive) kill, but count no frags for it -void W_SwitchWeapon_Force(entity e, Weapon w); +void W_SwitchWeapon_Force(Player this, Weapon w, .entity weaponentity); entity GiveFrags_randomweapons; void GiveFrags (entity attacker, entity targ, float f, int deathtype); @@ -81,17 +82,12 @@ float Obituary_WeaponDeath( void Obituary(entity attacker, entity inflictor, entity targ, int deathtype); -void Ice_Think(); +void Ice_Think(entity this); void Freeze (entity targ, float freeze_time, float frozen_type, float show_waypoint); void Unfreeze (entity targ); -// these are updated by each Damage call for use in button triggering and such -entity damage_targ; -entity damage_inflictor; -entity damage_attacker; - void Damage (entity targ, entity inflictor, entity attacker, float damage, int deathtype, vector hitloc, vector force); float RadiusDamage_running; @@ -107,7 +103,7 @@ float RadiusDamage (entity inflictor, entity attacker, float coredamage, float e .float fire_hitsound; .entity fire_burner; -void fireburner_think(); +void fireburner_think(entity this); float Fire_IsBurning(entity e); @@ -116,6 +112,3 @@ float Fire_AddDamage(entity e, entity o, float d, float t, float dt); void Fire_ApplyDamage(entity e); void Fire_ApplyEffect(entity e); - -void fireburner_think(); -#endif