]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/server/race.qh
Merge branch 'master' into TimePath/scoreboard_elo
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / race.qh
1 #pragma once
2
3 float race_teams;
4
5 // scores
6 const float ST_RACE_LAPS = 1;
7
8 bool g_race_qualifying;
9
10 float speedaward_lastsent;
11 float speedaward_lastupdate;
12
13 float race_spawns;
14 float race_highest_place_spawn; // number of places; a place higher gets spawned at 0
15 float race_lowest_place_spawn; // where to spawn in qualifying
16 float race_fraglimit;
17 float race_leadlimit;
18 float race_timelimit;
19 .float race_place;
20 .float race_started;
21 .float race_completed;
22 .float race_laptime;
23 float race_completing;
24
25 .float race_movetime; // for reading
26 .float race_movetime_frac; // fractional accumulator for higher accuracy (helper for writing)
27 .float race_movetime_count; // integer accumulator
28
29 .float race_respawn_checkpoint;
30 .entity race_respawn_spotref; // try THIS spawn in case you respawn
31
32 // definitions for functions used outside race.qc
33 float race_PreviousCheckpoint(float f);
34 float race_NextCheckpoint(float f);
35 void race_AbandonRaceCheck(entity p);
36 void race_ImposePenaltyTime(entity pl, float penalty, string reason);
37 void race_StartCompleting();
38 float race_GetFractionalLapCount(entity e);
39 float race_readTime(string map, float pos);
40 string race_readUID(string map, float pos);
41 string race_readName(string map, float pos);
42 void race_ClearRecords();
43 void race_SendNextCheckpoint(entity e, float spec);
44 void race_PreparePlayer(entity this);
45 void race_send_recordtime(float msg);
46 void race_send_speedaward(float msg);
47
48 float speedaward_speed;
49 string speedaward_holder;
50 string speedaward_uid;
51
52 float speedaward_alltimebest;
53 string speedaward_alltimebest_holder;
54 string speedaward_alltimebest_uid;
55
56 void race_send_speedaward(float msg);
57
58 void race_send_speedaward_alltimebest(float msg);
59
60 void race_SendRankings(float pos, float prevpos, float del, float msg);
61
62 void race_RetractPlayer(entity this);
63
64 void race_InitSpectator();