Hosting and domain costs until October 2024 have been generously sponsored by dumptruck_ds. Thank you!
Difference between revisions of "EXT CSQC System Globals Fields and Builtins List"
From Quake Wiki
(→Builtins) |
|||
Line 102: | Line 102: | ||
</pre> | </pre> | ||
==Builtins== | ==Builtins== | ||
+ | <pre> | ||
+ | void(vector ang) makevectors = #1; | ||
+ | void(entity e, vector o) setorigin = #2; | ||
+ | void(entity e, string m) setmodel = #3; | ||
+ | void(entity e, vector min, vector max) setsize = #4; | ||
+ | void(entity e, vector min, vector max) setabssize = #5; | ||
+ | void() break = #6; | ||
+ | float() random = #7; | ||
+ | void(entity e, float chan, string samp) sound = #8; | ||
+ | vector(vector v) normalize = #9; | ||
+ | void(string e) error = #10; | ||
+ | void(string e) objerror = #11; | ||
+ | float(vector v) vlen = #12; | ||
+ | float(vector v) vectoyaw = #13; | ||
+ | entity() spawn = #14; | ||
+ | void(entity e) remove = #15; | ||
+ | float(vector v1, vector v2, float tryents) traceline = #16; | ||
+ | entity() checkclient = #17; | ||
+ | entity(entity start, .string fld, string match) find = #18; | ||
+ | void(string s) precache_sound = #19; | ||
+ | void(string s) precache_model = #20; | ||
+ | void(entity client, string s, ...) stuffcmd = #21; | ||
+ | entity(vector org, float rad) findradius = #22; | ||
+ | |||
+ | string(float f) ftos = #26; | ||
+ | string(vector v) vtos = #27; | ||
+ | void() coredump = #28; | ||
+ | void() traceon = #29; | ||
+ | void() traceoff = #30; | ||
+ | void(entity e) eprint = #31; | ||
+ | float(float yaw, float dist) walkmove = #32; | ||
+ | |||
+ | float() droptofloor = #34; | ||
+ | void(float style, string value) lightstyle = #35; | ||
+ | float(float v) rint = #36; | ||
+ | float(float v) floor = #37; | ||
+ | float(float v) ceil = #38; | ||
+ | |||
+ | float(entity e) checkbottom = #40; | ||
+ | float(vector v) pointcontents = #41; | ||
+ | |||
+ | float(float f) fabs = #43; | ||
+ | float(string s) cvar = #45; | ||
+ | void(string s) localcmd = #46; | ||
+ | entity(entity e) nextent = #47; | ||
+ | void(vector o, vector d, float color, float count) particle = #48; | ||
+ | void() ChangeYaw = #49; | ||
+ | |||
+ | vector(vector v) vectoangles = #51; | ||
+ | |||
+ | string(string s) precache_file = #68; | ||
+ | void(entity e) makestatic = #69; | ||
+ | |||
+ | void(string var, string val) cvar_set = #72; | ||
+ | |||
+ | void(vector pos, string samp, float vol, float atten) ambientsound = #74; | ||
+ | string(string s) precache_model2 = #75; | ||
+ | string(string s) precache_sound2 = #76; | ||
+ | string(string s) precache_file2 = #77; | ||
+ | </pre> |
Revision as of 17:37, 17 January 2008
System Globals
entity self; entity other; entity world; float time; float frametime; float player_localentnum; //the entnum float player_localnum; //the playernum float maxclients; //a constant filled in by the engine float clientcommandframe; //player movement float servercommandframe; //clientframe echoed off the server string mapname; // // global variables set by built in functions // vector v_forward, v_up, v_right; // set by makevectors() // set by traceline / tracebox float trace_allsolid; float trace_startsolid; float trace_fraction; vector trace_endpos; vector trace_plane_normal; float trace_plane_dist; entity trace_ent; float trace_inopen; float trace_inwater; // // required prog functions // void() CSQC_Init; void() CSQC_Shutdown; float(float f, float t) CSQC_InputEvent; void() CSQC_UpdateView; float(string s) CSQC_ConsoleCommand; //these fields are read and set by the default player physics vector pmove_org; vector pmove_vel; vector pmove_mins; vector pmove_maxs; //retrieved from the current movement commands (read by player physics) float input_timelength; vector input_angles; vector input_movevalues; //forwards, right, up. float input_buttons; //attack, use, jump (default physics only uses jump) float movevar_gravity; float movevar_stopspeed; float movevar_maxspeed; float movevar_spectatormaxspeed; //used by NOCLIP movetypes. float movevar_accelerate; float movevar_airaccelerate; float movevar_wateraccelerate; float movevar_friction; float movevar_waterfriction; float movevar_entgravity; //the local player's gravity field. Is a multiple (1 is the normal value)
System Fields
.float modelindex; // *** model index in the precached list .vector absmin, absmax; // *** origin + mins / maxs .float entnum; // *** the ent number as on the server .float drawmask; .void() predraw; .float movetype; .float solid; .vector origin; // *** .vector oldorigin; // *** .vector velocity; .vector angles; .vector avelocity; .string classname; // spawn function .string model; .float frame; .float skin; .float effects; .vector mins, maxs; // bounding box extents reletive to origin .vector size; // maxs - mins .void() touch; .void() use; .void() think; .void() blocked; // for doors or plats, called when can't push other .float nextthink; .entity chain; .string netname; .entity enemy; .float flags; .float colormap; .entity owner;
Builtins
void(vector ang) makevectors = #1; void(entity e, vector o) setorigin = #2; void(entity e, string m) setmodel = #3; void(entity e, vector min, vector max) setsize = #4; void(entity e, vector min, vector max) setabssize = #5; void() break = #6; float() random = #7; void(entity e, float chan, string samp) sound = #8; vector(vector v) normalize = #9; void(string e) error = #10; void(string e) objerror = #11; float(vector v) vlen = #12; float(vector v) vectoyaw = #13; entity() spawn = #14; void(entity e) remove = #15; float(vector v1, vector v2, float tryents) traceline = #16; entity() checkclient = #17; entity(entity start, .string fld, string match) find = #18; void(string s) precache_sound = #19; void(string s) precache_model = #20; void(entity client, string s, ...) stuffcmd = #21; entity(vector org, float rad) findradius = #22; string(float f) ftos = #26; string(vector v) vtos = #27; void() coredump = #28; void() traceon = #29; void() traceoff = #30; void(entity e) eprint = #31; float(float yaw, float dist) walkmove = #32; float() droptofloor = #34; void(float style, string value) lightstyle = #35; float(float v) rint = #36; float(float v) floor = #37; float(float v) ceil = #38; float(entity e) checkbottom = #40; float(vector v) pointcontents = #41; float(float f) fabs = #43; float(string s) cvar = #45; void(string s) localcmd = #46; entity(entity e) nextent = #47; void(vector o, vector d, float color, float count) particle = #48; void() ChangeYaw = #49; vector(vector v) vectoangles = #51; string(string s) precache_file = #68; void(entity e) makestatic = #69; void(string var, string val) cvar_set = #72; void(vector pos, string samp, float vol, float atten) ambientsound = #74; string(string s) precache_model2 = #75; string(string s) precache_sound2 = #76; string(string s) precache_file2 = #77;