3 #include <common/weapons/_all.qh>
4 #include <common/stats.qh>
8 float g_footsteps, g_grappling_hook;
9 float g_warmup_allguns;
10 float g_warmup_allow_timeout;
14 bool sv_ready_restart;
15 bool sv_ready_restart_after_countdown;
16 bool sv_ready_restart_repeatable;
23 .void(entity this, entity inflictor, entity attacker, float damage, int deathtype, .entity weaponentity, vector hitloc, vector force) event_damage;
25 .bool(entity targ, entity inflictor, float amount, float limit) event_heal;
32 .float pain_finished; //Added by Supajoe
33 .float pain_frame; //"
35 .float superweapons_finished; // NOTE: this field is used only by map entities, it does not directly apply the superweapons stat
36 const .float air_finished = _STAT(AIR_FINISHED);
38 .float cnt; // used in too many places
53 .float scheduledrespawntime;
55 .float respawntimejitter;
56 .float respawntimestart;
63 // for railgun damage (hitting multiple enemies)
65 .float railgunhitsolidbackup;
66 .vector railgunhitloc;
71 .float damage_dealt, typehitsound, killsound;
73 .float watersound_finished;
75 .float damagedbycontents;
76 .float damagedbytriggers;
80 .float pauseregen_finished;
81 .float pauserothealth_finished;
82 .float pauserotarmor_finished;
83 .float pauserotfuel_finished;
84 // string overrides entity
85 .string item_pickupsound;
86 .entity item_pickupsound_ent;
87 .entity item_model_ent;
92 float intermission_running;
93 float intermission_exittime;
94 float alreadychangedlevel;
99 float blockSpectators; //if set, new or existing spectators or observers will be removed unless they become a player within g_maxplayers_spectator_blocktime seconds
100 .float spectatortime; //point in time since the client is spectating or observing
103 .float jointime; // time of connecting
104 .float startplaytime; // time of switching from spectator to player
105 .float alivetime; // time of being alive
106 .float motd_actived_time; // used for both motd and campaign_message
108 .float spawnshieldtime;
111 .float noalign; // if set to 1, the item or spawnpoint won't be dropped to the floor
113 .vector death_origin;
115 float default_player_alpha;
116 float default_weapon_alpha;
118 .float cvar_cl_handicap;
119 .int cvar_cl_gunalign;
120 .float cvar_cl_clippedspectating;
121 .float cvar_cl_autoscreenshot;
122 .float cvar_cl_jetpack_jump;
123 .float cvar_cl_movement_track_canjump;
124 .float cvar_cl_newusekeysupported;
125 .float cvar_cl_cts_noautoswitch;
126 .bool cvar_cl_weapon_switch_reload;
127 .bool cvar_cl_weapon_switch_fallback_to_impulse;
129 .string cvar_g_xonoticversion;
130 .string cvar_cl_weaponpriority;
131 .string cvar_cl_weaponpriorities[10];
132 .float cvar_cl_noantilag;
134 .string weaponorder_byimpulse;
136 .float cvar_cl_allow_uid2name;
137 .float cvar_cl_allow_uidtracking;
138 .bool cvar_cl_allow_uidranking;
139 .string stored_netname;
141 string gamemode_name;
143 float bot_waypoints_for_items;
145 // speedrun: when 1, player auto teleports back when capture timeout happens
154 bool some_spawn_has_been_used;
155 int have_team_spawns; // 0 = no team spawns requested, -1 = team spawns requested but none found, 1 = team spawns requested and found
156 int have_team_spawns_forteams; // if Xth bit is 1 then team X has spawns else it has no spawns; team 0 is the "no-team"
161 #define DMG_NOWEP (weaponentities[0])
164 float sv_maxidle_spectatorsareidle;
165 int sv_maxidle_slots;
166 bool sv_maxidle_slots_countbots;
169 .float cvar_cl_autotaunt;
170 .float cvar_cl_voice_directional;
171 .float cvar_cl_voice_directional_taunt_attenuation;
173 int autocvar__independent_players;
174 bool independent_players;
175 #define INDEPENDENT_PLAYERS (autocvar__independent_players ? (autocvar__independent_players > 0) : independent_players)
176 #define IS_INDEPENDENT_PLAYER(e) ((e).solid == SOLID_TRIGGER)
177 #define MAKE_INDEPENDENT_PLAYER(e) (((e).solid = SOLID_TRIGGER), ((e).frags = FRAGS_PLAYER_OUT_OF_GAME))
186 string cvar_purechanges;
187 float cvar_purechanges_count;
189 //float game_starttime; //point in time when the countdown to game start is over
190 //float round_starttime; //point in time when the countdown to round start is over
192 .int projectiledeathtype;
196 // reset to 0 on weapon switch
197 // may be useful to all weapons
198 .float bulletcounter;
201 float g_nexball_meter_period;
203 .void(entity this) reset; // if set, an entity is reset using this
204 .void(entity this) reset2; // if set, an entity is reset using this (after calling ALL the reset functions for other entities)
210 bool radar_showenemies;
212 .int minelayer_mines;
213 .float vortex_charge;
214 .float vortex_charge_rottime;
215 .float vortex_chargepool_ammo;
217 .float oknex_charge_rottime;
218 .float oknex_chargepool_ammo;
221 .int grab; // 0 = can't grab, 1 = owner can grab, 2 = owner and team mates can grab, 3 = anyone can grab
223 #define PROJECTILE_MAKETRIGGER(e) (e).solid = SOLID_CORPSE; (e).dphitcontentsmask = DPCONTENTS_SOLID | DPCONTENTS_BODY | DPCONTENTS_CORPSE
224 // when doing this, hagar can go through clones
225 // #define PROJECTILE_MAKETRIGGER(e) (e).solid = SOLID_BBOX
227 .int spectatee_status;
238 .float cvar_cl_weaponimpulsemode;
239 .int selectweapon; // last selected weapon of the player
241 .float ballistics_density;
243 //const int FROZEN_NOT = 0;
244 const int FROZEN_NORMAL = 1;
245 const int FROZEN_TEMP_REVIVING = 2;
246 const int FROZEN_TEMP_DYING = 3;
252 .bool player_blocked;
254 .float revival_time; // time at which player was last revived
255 .float revive_speed; // NOTE: multiplier (anything above 1 is instaheal)
258 .entity frozen_by; // for ice fields
260 .float misc_bulletcounter; // replaces uzi & hlac bullet counter.
266 .string cvar_cl_physics;
268 .WepSet dual_weapons;
270 IntrusiveList g_monsters;
271 IntrusiveList g_waypoints;
272 IntrusiveList g_vehicles;
273 IntrusiveList g_turrets;
274 IntrusiveList g_mines;
275 IntrusiveList g_projectiles;
276 IntrusiveList g_items;
277 IntrusiveList g_initforplayer;
278 IntrusiveList g_clones;
279 IntrusiveList g_spawnpoints;
280 IntrusiveList g_bot_targets;
281 IntrusiveList g_bot_dodge;
282 IntrusiveList g_damagedbycontents;
283 IntrusiveList g_railgunhit;
284 IntrusiveList g_ladders;
285 IntrusiveList g_locations;
286 IntrusiveList g_saved_team;
287 IntrusiveList g_monster_targets;
288 IntrusiveList g_pathlib_nodes;
289 IntrusiveList g_moveables;
292 g_monsters = IL_NEW();
293 g_waypoints = IL_NEW();
294 g_vehicles = IL_NEW();
295 g_turrets = IL_NEW();
297 g_projectiles = IL_NEW();
299 g_initforplayer = IL_NEW();
301 g_spawnpoints = IL_NEW();
302 g_bot_targets = IL_NEW();
303 g_bot_dodge = IL_NEW();
304 g_damagedbycontents = IL_NEW();
305 g_railgunhit = IL_NEW();
306 g_ladders = IL_NEW();
307 g_locations = IL_NEW();
308 g_saved_team = IL_NEW();
309 g_monster_targets = IL_NEW();
310 g_pathlib_nodes = IL_NEW();
311 g_moveables = IL_NEW();