14 // 0 = keydown, key, character (EXT_CSQC)
15 // 1 = keyup, key, character (EXT_CSQC)
16 // 2 = mousemove relative, x, y (EXT_CSQC)
17 // 3 = mousemove absolute, x, y (DP_CSQC)
18 bool CSQC_InputEvent(int eventtype, int x, int y);
20 void CSQC_UpdateView(int width, int height);
21 // catch commands registered with registercommand
22 bool CSQC_ConsoleCommand(string cmd);
23 bool CSQC_Parse_TempEntity();
24 bool CSQC_Parse_StuffCmd(string msg);
25 bool CSQC_Parse_Print(string msg);
26 bool CSQC_Parse_CenterPrint(string msg);
27 bool CSQC_Event_Sound(int ent, int channel, string sample, float volume, float attenuation, vector pos, float speed, int flags);
29 entity CSQC_Ent_Spawn(int entnum);
30 void CSQC_Ent_Update(bool isnew);
31 void CSQC_Ent_Remove();
47 // trace_endpos: visorigin
48 .vector camera_transform(vector pos, vector ang);
50 // control start position of sound()
51 // calculated as ofs = time - sound_starttime
52 float sound_starttime;
65 void ClientDisconnect();
73 void SV_PausedTic(float elapsed);
78 void SV_ChangeTeam(int color);
90 // Called when a client connects to the server
97 // Called when a client spawns in the server
102 void PutClientInServer();
104 // return false to remove
105 .bool SendEntity(entity to, int sf);
110 void SV_OnEntityPreSpawnFunction();
115 void SV_OnEntityNoSpawnFunction();
120 void SV_OnEntityPostSpawnFunction();
131 .bool customizeentityforclient();
138 void SetChangeParms();
149 // trace_endpos: self.origin
150 // trace_plane_normal
153 // trace_dpstartcontents
154 // trace_dphitcontents
155 // trace_dphitq3surfaceflags
156 // trace_dphittexturename
159 // when .watertype changes:
160 .void contentstransition(int prev, int current);
171 .void movetypesteplandevent(vector vel);
176 void PlayerPreThink();
181 void PlayerPostThink();
195 void SV_PlayerPhysics();
200 void SV_ParseClientCommand(string cmd);
208 void m_keydown(int key, int ascii);
210 void m_keyup(int key, int ascii);
212 void m_draw(int width, int height);
214 void m_toggle(int mode);
216 int m_gethostcachecategory(int entry);
228 void URI_Get_Callback(int id, int status, string data);
230 void GameCommand(string cmd);
240 void tracebox(vector v1, vector min, vector max, vector v2, int tryents, entity ignoreentity);
242 attempt to move an object from v1 to v2 of given size
246 * MOVE_NOMONSTERS (1): ignore monsters
247 * MOVE_MISSILE (2): +15 to every extent
248 * MOVE_WORLDONLY (3): ignore everything except bsp
249 * MOVE_HITMODEL (4): hit model, not bbox
253 void traceline(vector v1, vector v2, int tryents, entity ignoreentity);
255 degenerate case of tracebox when min and max are equal
261 trace never left solid
263 bool trace_startsolid;
265 trace started inside solid
267 float trace_fraction;
269 distance before collision: 0..1, 1 if no collision
273 v1 + (v2 - v1) * trace_fraction
275 vector trace_plane_normal;
277 normalized plane normal, '0 0 0' if no collision.
278 May be present if edges touch without clipping, use `trace_fraction < 1` as a determinant instead
280 float trace_plane_dist;
296 int trace_dpstartcontents;
298 DPCONTENTS_ value at start position of trace
300 int trace_dphitcontents;
302 DPCONTENTS_ value of impacted surface (not contents at impact point, just contents of the surface that was hit)
304 int trace_dphitq3surfaceflags;
306 Q3SURFACEFLAG_ value of impacted surface
308 string trace_dphittexturename;
310 texture name of impacted surface
312 int trace_networkentity;