28 bool raw_touch_check =
true;
31 LABEL(search_racecheckpoints)
34 if(it.cnt == cp || cp == -1)
39 if (raw_touch_check &&
vdist(this.
origin - it.nearestwaypoint.origin, <, 30))
42 raw_touch_check =
false;
43 goto search_racecheckpoints;
78 float dt =
M_ARGV(1,
float);
80 player.race_movetime_frac += dt;
81 float f =
floor(player.race_movetime_frac);
82 player.race_movetime_frac -= f;
83 player.race_movetime_count += f;
84 player.race_movetime = player.race_movetime_frac + player.race_movetime_count;
88 if (player.race_penalty)
89 if (
time > player.race_penalty)
90 player.race_penalty = 0;
91 if(player.race_penalty)
93 player.velocity =
'0 0 0';
95 player.disableclientprediction = 2;
109 if(wishvel.x != 0 && wishvel.y != 0 && wishvel.x != wishvel.y)
112 wishspeed =
vlen(wishvel);
113 if(wishvel.x >= 2 * wishvel.y)
117 CS(player).movement_x = wishspeed;
119 CS(player).movement_x = -wishspeed;
120 CS(player).movement_y = 0;
122 else if(wishvel.y >= 2 * wishvel.x)
125 CS(player).movement_x = 0;
127 CS(player).movement_y = wishspeed;
129 CS(player).movement_y = -wishspeed;
181 player.race_checkpoint = -1;
204 player.race_checkpoint = -1;
212 if(spawn_spot.target ==
"")
217 player.race_respawn_checkpoint = player.race_checkpoint;
218 player.race_respawn_spotref = spawn_spot;
220 player.race_place = 0;
304 float frag_deathtype =
M_ARGV(3,
float);
307 if(
frag_target == frag_attacker || frag_deathtype == DEATH_FALL.m_id)
322 int record_page =
M_ARGV(0,
int);
323 string ret_string =
M_ARGV(1,
string);
325 for(
int i = record_page * 200; i <
MapInfo_count && i < record_page * 200 + 200; ++i)
339 M_ARGV(1,
string) = ret_string;
360 stuffcmd(player,
"cl_cmd settemp cl_movecliptokeyboard 2\n");
void navigation_goalrating_start(entity this)
void navigation_goalrating_timeout_set(entity this)
bool navigation_goalrating_timeout(entity this)
void navigation_routerating(entity this, entity e, float f, float rangebias)
void navigation_goalrating_end(entity this)
#define MUTATOR_HOOKFUNCTION(...)
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
void ClientKill_Silent(entity this, float _delay)
const int SFL_LOWER_IS_BETTER
Lower scores are better (e.g.
const int SFL_TIME
Display as mm:ss.s, value is stored as 10ths of a second (AND 0 is the worst possible value!...
const int SFL_SORT_PRIO_SECONDARY
Scoring priority (NOTE: PRIMARY is used for fraglimit) NOTE: SFL_SORT_PRIO_SECONDARY value must be lo...
const int SFL_SORT_PRIO_PRIMARY
#define TIME_ENCODED_TOSTRING(n, compact)
const int FRAGS_PLAYER_OUT_OF_GAME
const int FRAGS_SPECTATOR
void GameLogEcho(string s)
bool autocvar_sv_eventlog
#define IL_EACH(this, cond, body)
Header file that describes the functions related to game items.
#define ITEM_IS_LOOT(item)
Returns whether the item is loot.
#define PutClientInServer
bool MapInfo_Get_ByID(int i)
string MapInfo_Map_bspname
void set_movetype(entity this, int mt)
strcat(_("^F4Countdown stopped!"), "\n^BG", _("Teams are too unbalanced."))
void Score_NicePrint(entity to)
Prints the scores to the console of a player.
entity PlayerScore_Sort(.float field, int teams, bool strict, bool nospectators)
Sorts the players and stores their place in the given field, starting with.
void GetPressedKeys(entity this)
void FixClientCvars(entity e)
float race_readTime(string map, float pos)
void race_SendAll(entity player, bool only_rankings)
void race_PreparePlayer(entity this)
void race_SpeedAwardFrame(entity player)
string race_readName(string map, float pos)
float race_NextCheckpoint(float f)
void race_checkAndWriteName(entity player)
IntrusiveList g_racecheckpoints
void race_RetractPlayer(entity this)
void race_AbandonRaceCheck(entity p)
bool autocvar_g_allow_checkpoints
IntrusiveList g_projectiles
ClientState CS(Client this)
bool autocvar_g_cts_selfdamage
void cts_EventLog(string mode, entity actor)
void havocbot_role_cts(entity this)
bool autocvar_g_cts_drop_monster_items
bool autocvar_g_cts_removeprojectiles
float autocvar_g_cts_finish_kill_delay
#define GameRules_score_enabled(value)
#define GameRules_scoring_add(client, fld, value)
#define GameRules_scoring(teams, spprio, stprio, fields)
#define FOREACH_CLIENT(cond, body)
#define vdist(v, cmp, f)
Vector distance comparison, avoids sqrt()