Xonotic
generic.qh
Go to the documentation of this file.
1 #pragma once
2 
3 #include <common/constants.qh>
4 
5 // =========================================================
6 // Declarations for common command code, written by Samual
7 // Last updated: December 28th, 2011
8 // =========================================================
9 
11 
12 float GenericCommand_macro_command(int argc, string command);
13 
14 float GenericCommand_macro_usage(int argc);
15 
17 
18 // Used by other game command systems for common commands,
19 // and it returns true if handled, false if not.
20 // Note: It tokenizes its input, so be careful!
21 float GenericCommand(string command);
22 
23 // Returns command prefix specific for whatever program it is compiled in
24 #ifdef SVQC
25  #define GetProgramCommandPrefix() "sv_cmd"
26 #elif defined(CSQC)
27  #define GetProgramCommandPrefix() "cl_cmd"
28 #elif defined(MENUQC)
29  #define GetProgramCommandPrefix() "menu_cmd"
30 #endif
31 
32 // used by common/command/generic.qc:GenericCommand_dumpcommands to list all commands into a .txt file
33 #define CMD_Write(s) fputs(fh, s)
34 #define CMD_Write_Alias(execute,command,description) CMD_Write(sprintf("alias %-20s \"%-13s %-20s ${* ?}\" // %s\n", command, execute, command, description))
36 
37 void Curl_URI_Get_Callback(int id, float status, string data);
void GenericCommand_macro_help()
Definition: generic.qc:546
int curl_uri_get_pos
Definition: generic.qh:38
void Curl_URI_Get_Callback(int id, float status, string data)
Definition: generic.qc:31
void GenericCommand_macro_write_aliases(float fh)
Definition: generic.qc:571
const int URI_GET_CURL
Definition: urllib.qh:7
float GenericCommand_macro_command(int argc, string command)
Definition: generic.qc:551
float GenericCommand_macro_usage(int argc)
Definition: generic.qc:561
const int URI_GET_CURL_END
Definition: urllib.qh:8
float curl_uri_get_exec[URI_GET_CURL_END - URI_GET_CURL+1]
Definition: generic.qh:39
float GenericCommand(string command)
Definition: generic.qc:582
string curl_uri_get_cvar[URI_GET_CURL_END - URI_GET_CURL+1]
Definition: generic.qh:40