1#pragma once
2
3#if defined(CSQC)
4#elif defined(MENUQC)
5#elif defined(SVQC)
6    #include <lib/warpzone/common.qh>
7    #include <common/constants.qh>
8    #include <common/teams.qh>
9    #include <common/util.qh>
10    #include <common/weapons/_all.qh>
11    #include "weapons/accuracy.qh"
12    #include "weapons/csqcprojectile.qh"
13    #include "weapons/selection.qh"
14    #include <common/t_items.qh>
15    #include "autocvars.qh"
16    #include "constants.qh"
17    #include "defs.qh"
18    #include <common/notifications/all.qh>
19    #include <common/deathtypes/all.qh>
20    #include "mutators/_mod.qh"
21    #include <common/turrets/sv_turrets.qh>
22    #include <common/vehicles/all.qh>
23    #include <lib/csqcmodel/sv_model.qh>
24    #include <common/playerstats.qh>
25    #include "g_hook.qh"
26    #include "scores.qh"
27    #include "spawnpoints.qh"
28#endif
29
30.float dmg;
31.float dmg_edge;
32.float dmg_force;
33.float dmg_radius;
34
35bool Damage_DamageInfo_SendEntity(entity this, entity to, int sf);
36
37void Damage_DamageInfo(vector org, float coredamage, float edgedamage, float rad, vector force, int deathtype, float bloodtype, entity dmgowner);
38
39float checkrules_firstblood;
40
41float yoda;
42float damage_goodhits;
43float damage_gooddamage;
44
45.float dmg_team;
46.float teamkill_complain;
47.float teamkill_soundtime;
48.entity teamkill_soundsource;
49.entity pusher;
50.float istypefrag;
51.float taunt_soundtime;
52
53float IsFlying(entity a);
54
55void UpdateFrags(entity player, int f);
56
57// NOTE: f=0 means still count as a (positive) kill, but count no frags for it
58void W_SwitchWeapon_Force(Player this, Weapon w, .entity weaponentity);
59entity GiveFrags_randomweapons;
60void GiveFrags (entity attacker, entity targ, float f, int deathtype);
61
62string AppendItemcodes(string s, entity player);
63
64void LogDeath(string mode, int deathtype, entity killer, entity killed);
65
66void Obituary_SpecialDeath(
67	entity notif_target,
68	float murder,
69	int deathtype,
70	string s1, string s2, string s3,
71	float f1, float f2, float f3);
72
73float w_deathtype;
74float Obituary_WeaponDeath(
75	entity notif_target,
76	float murder,
77	int deathtype,
78	string s1, string s2, string s3,
79	float f1, float f2);
80
81void Obituary(entity attacker, entity inflictor, entity targ, int deathtype);
82
83void Ice_Think(entity this);
84
85void Freeze (entity targ, float freeze_time, float frozen_type, float show_waypoint);
86
87void Unfreeze (entity targ);
88
89// these are updated by each Damage call for use in button triggering and such
90entity damage_targ;
91entity damage_inflictor;
92entity damage_attacker;
93
94void Damage (entity targ, entity inflictor, entity attacker, float damage, int deathtype, vector hitloc, vector force);
95
96float RadiusDamage_running;
97float RadiusDamageForSource (entity inflictor, vector inflictororigin, vector inflictorvelocity, entity attacker, float coredamage, float edgedamage, float rad, entity cantbe, entity mustbe, float inflictorselfdamage, float forceintensity, int deathtype, entity directhitentity);
98	// Returns total damage applies to creatures
99
100float RadiusDamage (entity inflictor, entity attacker, float coredamage, float edgedamage, float rad, entity cantbe, entity mustbe, float forceintensity, int deathtype, entity directhitentity);
101
102.float fire_damagepersec;
103.float fire_endtime;
104.float fire_deathtype;
105.entity fire_owner;
106.float fire_hitsound;
107.entity fire_burner;
108
109void fireburner_think(entity this);
110
111float Fire_IsBurning(entity e);
112
113float Fire_AddDamage(entity e, entity o, float d, float t, float dt);
114
115void Fire_ApplyDamage(entity e);
116
117void Fire_ApplyEffect(entity e);
118