27 bool raw_touch_check =
true;
30 LABEL(search_racecheckpoints)
33 if(it.cnt == cp || cp == -1)
38 if (raw_touch_check && vdist(this.origin - it.nearestwaypoint.origin, <, 30))
40 cp = race_NextCheckpoint(cp);
41 raw_touch_check = false;
42 goto search_racecheckpoints;
77 float dt =
M_ARGV(1,
float);
79 player.race_movetime_frac += dt;
80 float f =
floor(player.race_movetime_frac);
81 player.race_movetime_frac -= f;
82 player.race_movetime_count += f;
83 player.race_movetime = player.race_movetime_frac + player.race_movetime_count;
87 if (player.race_penalty)
88 if (
time > player.race_penalty)
89 player.race_penalty = 0;
90 if(player.race_penalty)
92 player.velocity =
'0 0 0';
94 player.disableclientprediction = 2;
108 if(wishvel.x != 0 && wishvel.y != 0 && wishvel.x != wishvel.y)
111 wishspeed =
vlen(wishvel);
112 if(wishvel.x >= 2 * wishvel.y)
116 CS(player).movement_x = wishspeed;
118 CS(player).movement_x = -wishspeed;
119 CS(player).movement_y = 0;
121 else if(wishvel.y >= 2 * wishvel.x)
124 CS(player).movement_x = 0;
126 CS(player).movement_y = wishspeed;
128 CS(player).movement_y = -wishspeed;
157 s = GameRules_scoring_add(it, RACE_FASTEST, 0);
180 player.race_checkpoint = -1;
203 player.race_checkpoint = -1;
211 if(spawn_spot.target ==
"")
216 player.race_respawn_checkpoint = player.race_checkpoint;
217 player.race_respawn_spotref = spawn_spot;
219 player.race_place = 0;
240 int frag_deathtype =
M_ARGV(5,
int);
241 if (frag_deathtype == DEATH_KILL.m_id)
297 float frag_deathtype =
M_ARGV(3,
float);
298 float frag_damage =
M_ARGV(4,
float);
300 if(frag_target == frag_attacker || frag_deathtype == DEATH_FALL.m_id)
304 M_ARGV(4,
float) = frag_damage;
315 int record_page =
M_ARGV(0,
int);
316 string ret_string =
M_ARGV(1,
string);
318 for(
int i = record_page * 200; i <
MapInfo_count && i < record_page * 200 + 200; ++i)
332 M_ARGV(1,
string) = ret_string;
358 stuffcmd(player,
"cl_cmd settemp cl_movecliptokeyboard 2\n");
void race_SendAll(entity player, bool only_rankings)
#define GameRules_scoring(teams, spprio, stprio, fields)
#define IL_EACH(this, cond, body)
void navigation_goalrating_start(entity this)
void ClientConnect(entity this)
ClientConnect
void navigation_goalrating_end(entity this)
void cts_EventLog(string mode, entity actor)
void Score_NicePrint(entity to)
Prints the scores to the console of a player.
void ClientKill(entity this)
const int SFL_SORT_PRIO_SECONDARY
Scoring priority (NOTE: PRIMARY is used for fraglimit)
ClientState CS(Client this)
#define FOREACH_CLIENT(cond, body)
#define GameRules_scoring_add(client, fld, value)
void race_checkAndWriteName(entity player)
const int SFL_SORT_PRIO_PRIMARY
bool MapInfo_Get_ByID(int i)
MUTATOR_HOOKFUNCTION(cts, PlayerPhysics)
void ClientKill_Silent(entity this, float _delay)
void GameRules_score_enabled(bool value)
Disabling score disables the "score" column on the scoreboard.
#define TIME_ENCODED_TOSTRING(n)
const int SFL_LOWER_IS_BETTER
Lower scores are better (e.g.
void navigation_routerating(entity this, entity e, float f, float rangebias)
float autocvar_g_cts_finish_kill_delay
bool autocvar_g_cts_selfdamage
bool navigation_goalrating_timeout(entity this)
spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 f1 s1 strcat(_("Level %s: "), "^BG%s\3\, _("^BGPress ^F2%s^BG to enter the game"))
void GetPressedKeys(entity this)
void havocbot_role_cts(entity this)
IntrusiveList g_racecheckpoints
bool autocvar_g_allow_checkpoints
float race_readTime(string map, float pos)
void race_SpeedAwardFrame(entity player)
void race_PreparePlayer(entity this)
void GameLogEcho(string s)
void navigation_goalrating_timeout_set(entity this)
entity PlayerScore_Sort(.float field, int teams, bool strict, bool nospectators)
Sorts the players and stores their place in the given field, starting with.
vector(float skel, float bonenum) _skel_get_boneabs_hidden
IntrusiveList g_projectiles
const int FRAGS_PLAYER_OUT_OF_GAME
string race_readName(string map, float pos)
string MapInfo_Map_bspname
const int FRAGS_SPECTATOR
void race_RetractPlayer(entity this)
bool Item_IsLoot(entity item)
Returns whether the item is loot.
bool autocvar_g_cts_removeprojectiles
bool autocvar_sv_eventlog
Header file that describes the functions related to game items.
const int SFL_TIME
Display as mm:ss.s, value is stored as 10ths of a second (AND 0 is the worst possible value!) ...
void set_movetype(entity this, int mt)
void FixClientCvars(entity e)
void race_AbandonRaceCheck(entity p)