-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDEFS.QC
More file actions
2707 lines (2266 loc) · 94.7 KB
/
DEFS.QC
File metadata and controls
2707 lines (2266 loc) · 94.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/*
==============================================================================
SOURCE FOR GLOBALVARS_T C STRUCTURE
==============================================================================
*/
//
// system globals
//
entity self;
entity other;
entity world;
float time;
float frametime;
#ifdef QUAKE_WORLD
entity newmis; // if this is set, the entity that just
// run created a new missile that should
// be simulated immediately
#endif
float force_retouch; // force all entities to touch triggers
// next frame. this is needed because
// non-moving things don't normally scan
// for triggers, and when a trigger is
// created (like a teleport trigger), it
// needs to catch everything.
// decremented each frame, so set to 2
// to guarantee everything is touched
string mapname;
#ifndef QUAKE_WORLD
float deathmatch;
float coop;
float teamplay;
#endif
float serverflags; // propagated from level to level, used to
// keep track of completed episodes
float total_secrets;
float total_monsters;
float found_secrets; // number of secrets found
float killed_monsters; // number of monsters killed
// spawnparms are used to encode information about clients across server
// level changes
float parm1, parm2, parm3, parm4, parm5, parm6, parm7, parm8, parm9, parm10, parm11, parm12, parm13, parm14, parm15, parm16;
//
// 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;
entity msg_entity; // destination of single entity writes
//
// required prog functions
//
void() main; // only for testing
void() StartFrame;
void() PlayerPreThink;
void() PlayerPostThink;
void() ClientKill;
void() ClientConnect;
void() PutClientInServer; // call after setting the parm1... parms
void() ClientDisconnect;
void() SetNewParms; // called when a client first connects to
// a server. sets parms so they can be
// saved off for restarts
void() SetChangeParms; // call to set parms for self so they can
// be saved for a level transition
//================================================
void end_sys_globals; // flag for structure dumping
//================================================
/*
==============================================================================
SOURCE FOR ENTVARS_T C STRUCTURE
==============================================================================
*/
//
// system fields (*** = do not set in prog code, maintained by C code)
//
.float modelindex; // *** model index in the precached list
.vector absmin, absmax; // *** origin + mins / maxs
.float ltime; // local time for entity (Used for MOVETYPE_PUSH stuff)
#ifdef QUAKE_WORLD
.float lastruntime; // *** to allow entities to run out of sequence
#endif
.float movetype;
.float solid;
.vector origin; // ***
.vector oldorigin; // ***
.vector velocity;
.vector angles;
.vector avelocity;
#ifndef QUAKE_WORLD
.vector punchangle; // temp angle adjust from damage or recoil
#endif
.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 groundentity;
// stats
.float health;
.float frags;
.float weapon; // one of the IT_SHOTGUN, etc flags
.string weaponmodel;
.float weaponframe;
.float currentammo;
.float ammo_shells, ammo_nails, ammo_rockets, ammo_cells;
.float items; // bit flags
.float takedamage;
.entity chain;
.float deadflag;
.vector view_ofs; // add to origin to get eye point
.float button0; // fire
.float button1; // use
.float button2; // jump
.float impulse; // weapon changes
.float fixangle;
.vector v_angle; // view / targeting angle for players
#ifndef QUAKE_WORLD
.float idealpitch; // calculated pitch angle for lookup up slopes
#endif
.string netname;
entity temp_e; //WK 12-4-08 Use a global temp entity to keep tons of short lived ents from spawning
//This stops what Gizmo called the zombie entity effects which causes crashes when in large numbers
//WK 5-15-08 TKD duelists use this to mark their enemies
.entity enemy; //WK We use this on players now, for the martyr code
.float flags;
.float colormap;
.float team;
.float max_health; // players maximum health is stored here
.float teleport_time; // don't back up
.float armortype; // save this fraction of incoming damage
.float armorvalue; //Current NUMBER of armor being worn
.float waterlevel; // 0 = not in, 1 = feet, 2 = wast, 3 = eyes
.float watertype; // a contents value
.float ideal_yaw;
.float yaw_speed;
.entity aiment;
.entity goalentity; // a movetarget or an enemy
.float spawnflags;
.string target;
.string targetname;
// damage is accumulated through a frame. and sent as one single
// message, so the super shotgun doesn't generate huge messages
.float dmg_take;
.float dmg_save;
.entity dmg_inflictor;
.entity owner; // who launched a missile
.vector movedir; // mostly for doors, but also used for waterjump
.string message; // trigger messages
.float sounds; // either a cd track number or sound number
.string noise, noise1, noise2, noise3; // contains names of wavs to play
//================================================
void end_sys_fields; // flag for structure dumping
//================================================
/*
==============================================================================
VARS NOT REFERENCED BY C CODE
==============================================================================
*/
//
// constants
//
// edict.flags
#define FL_FLY 1
#define FL_SWIM 2
#define FL_CLIENT 8 // set for all client edicts
#define FL_INWATER 16 // for enter / leave water splash
#define FL_MONSTER 32
#define FL_GODMODE 64 // player cheat
#define FL_NOTARGET 128 // player cheat
#define FL_ITEM 256 // extra wide size for bonus items
#define FL_ONGROUND 512 // standing on something
#define FL_PARTIALGROUND 1024 // not all corners are valid
#define FL_WATERJUMP 2048 // player jumping out of water
#define FL_JUMPRELEASED 4096 // for jump debouncing
#define FL_FINALIZED 8192 // OfN - Finalized (SVC_FINALE) player (Warning: Hard coded on server!)
#define FL_FINDABLE_NONSOLID 16384 // OfN - Any entity with this can be "found" with findradius(), even if SOLID_NOT
#define FL_MACHINE 32768 // OfN - Engineer build or other mechanical thing
// edict.movetype values
#define MOVETYPE_NONE 0 // never moves
//#define MOVETYPE_ANGLENOCLIP 1
//#define MOVETYPE_ANGLECLIP 2
#define MOVETYPE_WALK 3 // players only
#define MOVETYPE_STEP 4 // discrete, not real time unless fall
#define MOVETYPE_FLY 5
#define MOVETYPE_TOSS 6 // gravity
#define MOVETYPE_PUSH 7 // no clip to world, push and crush
#define MOVETYPE_NOCLIP 8
#define MOVETYPE_FLYMISSILE 9 // fly with extra size against monsters
#define MOVETYPE_BOUNCE 10
#define MOVETYPE_BOUNCEMISSILE 11 // bounce with extra size
// edict.solid values
#define SOLID_NOT 0 // no interaction with other objects
#define SOLID_TRIGGER 1 // touch on edge, but not blocking
#define SOLID_BBOX 2 // touch on edge, block
#define SOLID_SLIDEBOX 3 // touch on edge, but not an onground
#define SOLID_BSP 4 // bsp clip, touch on edge, block
// OfN - Traceline modes
#define TL_ANY_SOLID 0 // will hit any solid, but not triggers
#define TL_BSP_ONLY 1 // will hit BSP only
// Warning: do not use 2, it's used internally by server C code
#define TL_TRIGGERS 3 // Scan for triggers (Triggers must be flagged with FL_FINDABLE_NONSOLID)
#define TL_EVERYTHING 4 // Scan for anything (Any NonSolid/Trigger entities must be flagged with FL_FINDABLE_NONSOLID)
// range values
#define RANGE_MELEE 0
#define RANGE_NEAR 1
#define RANGE_MID 2
#define RANGE_FAR 3
#define RANGE_VERYFAR 4 //- OfN - Used for sentries
// deadflag values
#define DEAD_NO 0
#define DEAD_DYING 1
#define DEAD_DEAD 2
#define DEAD_RESPAWNABLE 3
// takedamage values
#define DAMAGE_NO 0
#define DAMAGE_YES 1
#define DAMAGE_AIM 2
// items
#define IT_AXE 4096
#define IT_SHOTGUN 1
#define IT_SUPER_SHOTGUN 2
#define IT_NAILGUN 4
#define IT_LIGHT_ASSAULT 8
#define IT_SUPER_NAILGUN 8 // OfN
#define IT_GRENADE_LAUNCHER 16
#define IT_ROCKET_LAUNCHER 32
#define IT_LIGHTNING 64
#define IT_EXTRA_WEAPON 128
#define IT_SHELLS 256
#define IT_NAILS 512
#define IT_ROCKETS 1024
#define IT_CELLS 2048
#define IT_ARMOR1 8192
#define IT_ARMOR2 16384
#define IT_ARMOR3 32768
#define IT_SUPERHEALTH 65536
#define IT_KEY1 131072
#define IT_KEY2 262144
#define IT_INVISIBILITY 524288
#define IT_INVULNERABILITY 1048576
#define IT_SUIT 2097152
#define IT_QUAD 4194304
#define IT_HOOK 8388608 // Last BIT!!!
// point content values
#define CONTENT_EMPTY -1
#define CONTENT_SOLID -2
#define CONTENT_WATER -3
#define CONTENT_SLIME -4
#define CONTENT_LAVA -5
#define CONTENT_SKY -6
#define STATE_TOP 0
#define STATE_BOTTOM 1
#define STATE_UP 2
#define STATE_DOWN 3
#define VEC_ORIGIN '0 0 0'
#define VEC_HULL_MIN '-16 -16 -24'
#define VEC_HULL_MAX '16 16 32'
#define VEC_HULL2_MIN '-32 -32 -24'
#define VEC_HULL2_MAX '32 32 64'
// protocol bytes
#define SVC_SETVIEWPORT 5
#define SVC_SETANGLES 10
#define SVC_TEMPENTITY 23
#define SVC_KILLEDMONSTER 27
#define SVC_FOUNDSECRET 28
#define SVC_INTERMISSION 30
#define SVC_FINALE 31
#define SVC_CDTRACK 32
#define SVC_SELLSCREEN 33
#ifdef QUAKE_WORLD
#define SVC_SMALLKICK 34
#define SVC_BIGKICK 35
#define SVC_MUZZLEFLASH 39
#endif
#define TE_SPIKE 0
#define TE_SUPERSPIKE 1
#define TE_GUNSHOT 2
#define TE_EXPLOSION 3
#define TE_TAREXPLOSION 4
#define TE_LIGHTNING1 5
#define TE_LIGHTNING2 6
#define TE_WIZSPIKE 7
#define TE_KNIGHTSPIKE 8
#define TE_LIGHTNING3 9
#define TE_LAVASPLASH 10
#define TE_TELEPORT 11
#define TE_BLOOD 12
#define TE_LIGHTNINGBLOOD 13
// sound channels
// channel 0 never willingly overrides
// other channels (1-7) allways override a playing sound on that channel
#define CHAN_AUTO 0
#define CHAN_WEAPON 1
#define CHAN_VOICE 2
#define CHAN_ITEM 3
#define CHAN_BODY 4
#define CHAN_MUSIC 5 //WK For orff.wav
#define CHAN_MISC 6
#define CHAN_EARTHQUAKE 7
//#define CHAN_MONSTER 7
#define CHAN_NO_PHS_ADD 8 //Ofn Fix for looping sound bug
#define ATTN_NONE 0
#define ATTN_NORM 1
#define ATTN_IDLE 2
#define ATTN_STATIC 3
//#define ???? 4
// update types
#define UPDATE_GENERAL 0
#define UPDATE_STATIC 1
#define UPDATE_BINARY 2
#define UPDATE_TEMP 3
// entity effects
#define EF_BRIGHTFIELD 1
#define EF_MUZZLEFLASH 2
#define EF_BRIGHTLIGHT 4
#define EF_DIMLIGHT 8
//#define EF_FLAG1 16
//#define EF_FLAG2 32
#define EF_BLUE 64
#define EF_RED 128
#define EF_PURPLE #EF_RED | #EF_BLUE
// messages
// Since BROADCAST is never used in QW 1.5, and MULTICAST is used instead,
// just define BROADCAST as MULTICAST for QW 1.5
#define MSG_MULTICAST 4
#ifdef QUAKE_WORLD
#define MSG_BROADCAST #MSG_MULTICAST
#else
#define MSG_BROADCAST 0 // unreliable to all
#endif
#define MSG_ONE 1 // reliable to one (msg_entity)
#define MSG_ALL 2 // reliable to all
#define MSG_INIT 3 // write to the init string
// message levels
#define PRINT_LOW 0 // pickup messages
#define PRINT_MEDIUM 1 // death messages
#define PRINT_HIGH 2 // critical messages
#define PRINT_CHAT 3 // also goes to chat console
// multicast sets
#define MULTICAST_ALL 0 // every client
#define MULTICAST_PHS 1 // within hearing
#define MULTICAST_PVS 2 // within sight
#define MULTICAST_ALL_R 3 // every client, reliable
#define MULTICAST_PHS_R 4 // within hearing, reliable
#define MULTICAST_PVS_R 5 // within sight, reliable
//================================================
//
// globals
//
float movedist;
#ifndef QUAKE_WORLD
float gameover; // set when a rule exits
#endif
string string_null; // null string, nothing should be held here
float empty_float;
vector vector_null; //CH empty vector
entity activator; // the entity that activated a trigger or brush
entity damage_attacker; // set by T_Damage
float framecount;
float skill;
// cvars checked each frame
//
float teamplay;
float timelimit;
float fraglimit;
float deathmatch;
//================================================
//
// world fields (FIXME: make globals)
//
.string wad;
.string map;
.float worldtype; // 0=medieval 1=metal 2=base
//================================================
.string killtarget;
//
// quakeed fields
//
.float light_lev; // not used by game, but parsed by light util
.float style;
//
// monster ai
//
.void() th_stand;
.void() th_walk;
.void() th_run;
.void() th_missile;
.void() th_melee;
.void(entity attacker, float damage) th_pain;
.void() th_die;
.entity oldenemy; // mad at this player before taking damage
.float speed;
.float lefty;
.float search_time; //WK Used for hover boots. :/
.float attack_state; //WK Not usable?
#define AS_STRAIGHT 1
#define AS_SLIDING 2
#define AS_MELEE 3
#define AS_MISSILE 4
#define AS_FIREBALL 5
//
// player only fields
//
.float walkframe;
//WK
.float maxspeed;
.float gravity;
//WK -- Holds how much money we have left while building, and
// for toggling between engineer and spy menus in the game (hackish, yes)
//WK 1/15/08 -- And why not? We'll store our sentryguns' frags spent in this field too.
.float money;
.float custom_speed;
.float ff_count; //How many friendlies killed
.float penance_time; //Time your penance will cease
.float last_attacked_time; //Time that you were last shot at
.float connect_time; //WK 5-15-08 Time the client connected, used to reteam people who joined the most lately
.entity inspirator; //Holds pointer to your chaplan
.float has_cheated; //Holds if the user has tried to cheat or not
// SB - for demons
.float demon_blood; //WK 1/15/08 We'll appropriate this for the new building upgrades field
.entity demon_one;
.entity demon_two; //- OfN
.entity demon_three; // OfN
//WK 1/15/08 New frag upgrades for buildings -- stored in build's .demon_blood
#define BUILD_FLAME_ADDITION 1
#define BUILD_FROST_ADDITION 2
#define BUILD_AIR_ADDITION 4
#define BUILD_WOOD_ADDITION 8
#define BUILD_WEAPON_UPGRADE 16
#define BUILD_OPTIC_UPGRADE 32
#define BUILD_BLACK_HOLE 64
#define BUILD_ANTIPSIONIC_AI 128
//Gel armor is #9
//For the demon
.void() th_fireball;
#define MAX_HOVER_FUEL 5 //Boots will recharge up to this maximum
.float hover_time; //How much fuel we have left in boots
#define MAX_SHADOWSTEP_TIME 40 //WK 1/15/08 25 //Can walk full invis for 8 seconds (Constant divided by about 5 equals the constant here in seconds)
#define SHADOWSTEP_COOLDOWN 100 //After finishing, can't do it again for 20 seconds
.float shadowstep_time; //How much time left we have in shadowstep
.float shadowstep_active; //TRUE when we're shadowstepping
#define CUSTOM_ON_SPAWN 1 //When dead, rebuild
#define CUSTOM_FINISHED 2 //Normal gameplay
#define CUSTOM_BUILDING 4 //Making a class
#define CUSTOM_OVERRIDE 8 //Used internally by menu.qc
#define CUSTOM_SELLING 16 //Person wants to sell his frags for money
#define DEFAULT_MONEY 10000 //How much to start with if serverinfo m is not set
.float done_custom;
//END WK
.entity scaned; //CH used for scanner.
.float attack_finished;
.float pain_finished;
.float invincible_finished;
.float invisible_finished;
.float super_damage_finished;
.float radsuit_finished;
.float invincible_time, invincible_sound;
.float invisible_time, invisible_sound;
.float super_time, super_sound;
.float rad_time;
.float fly_sound;
.float axhitme;
.float show_hostile; // set to time+0.2 whenever a client fires a
// weapon or takes damage. Used to alert
// monsters that otherwise would let the player go
.float jump_flag; // player jump flag
.float swim_flag; // player swimming sound flag
.float air_finished; // when time > air_finished, start drowning
.float bubble_count; // keeps track of the number of bubbles
.string deathtype; // keeps track of how the player died
//
// object stuff
//
.string mdl;
.vector mangle; // angle at start
.vector oldorigin; // only used by secret door
.float t_length, t_width;
//
// doors, etc
//
.vector dest, dest1, dest2;
.float wait; // time from firing to restarting
.float delay; // time from activation to firing
.entity trigger_field; // door's trigger entity
.string noise4;
//
// monsters
//
.float pausetime;
.entity movetarget;
//
// doors
//
.float aflag;
.float dmg; // damage done by door when hit
//
// misc
//
.float cnt; // misc flag
//
// subs
//
.void() think1;
.vector finaldest, finalangle;
//
// triggers
//
.float count; // for counting triggers
//
// plats / doors / buttons
//
.float lip;
.float state;
.vector pos1, pos2; // top and bottom positions
.float height;
//
// sounds
//
.float waitmin, waitmax;
.float distance;
.float volume;
//===========================================================================
//
// builtin functions
//
void(vector ang) makevectors = #1; // sets v_forward, etc globals
void(entity e, vector o) setorigin = #2;
void(entity e, string m) setmodel = #3; // set movetype and solid first
void(entity e, vector min, vector max) setsize = #4;
// #5 was removed
void() break = #6;
float() random = #7; // returns 0 - 1
void(entity e, float chan, string samp, float vol, float atten) 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;
// sets trace_* globals
// nomonsters can be:
// An entity will also be ignored for testing if forent == test,
// forent->owner == test, or test->owner == forent
// a forent of world is ignored
void(vector v1, vector v2, float nomonsters, entity forent) traceline = #16;
entity() checkclient = #17; // returns a client to look for
entity(entity start, .string fld, string match) find = #18;
string(string s) precache_sound = #19;
string(string s) precache_model = #20;
void(entity client, string s)stuffcmd = #21;
entity(vector org, float rad) findradius = #22;
#ifndef QUAKE_WORLD
//void(string s) bprint = #23;
//void(entity client, string s) sprint = #24;
void(...) nqw_bprint = #23;
void(...) nqw_sprint = #24;
// used for QW compatibility
/*
void(float level, string s) bprint;
void(entity client, float level, string s) sprint;
void(float level, string s1, string s2) bprint2;
void(entity client, float level, string s1, string s2) sprint2;
void(float level, string s1, string s2, string s3) bprint3;
void(entity client, float level, string s1, string s2, string s3) sprint3;
void(float level, string s1, string s2, string s3, string s4) bprint4;
void(entity client, float level, string s1, string s2, string s3, string s4) sprint4;
void(float level, string s1, string s2, string s3, string s4, string s5) bprint5;
void(entity client, float level, string s1, string s2, string s3, string s4, string s5) sprint5;
void(float level, string s1, string s2, string s3, string s4, string s5, string s6) bprint6;
void(entity client, float level, string s1, string s2, string s3, string s4, string s5, string s6) sprint6;
void(float level, string s1, string s2, string s3, string s4, string s5, string s6, string s7) bprint7;
void(entity client, float level, string s1, string s2, string s3, string s4, string s5, string s6, string s7) sprint7;
void(float level, string s1, string s2, string s3, string s4, string s5, string s6, string s7, string s8) bprint8;
*/
#else
//void(float level, string s) bprint = #23;
//void(entity client, float level, string s) sprint = #24;
void(...) bprint = #23;
void(...) sprint = #24;
void(...) bprint2 = #23;
void(...) sprint2 = #24;
void(...) bprint3 = #23;
void(...) sprint3 = #24;
void(...) bprint4 = #23;
void(...) sprint4 = #24;
void(...) bprint5 = #23;
void(...) sprint5 = #24;
void(...) bprint6 = #23;
void(...) sprint6 = #24;
void(...) bprint7 = #23;
void(...) sprint7 = #24;
void(...) bprint8 = #23;
#endif
void(string s) dprint = #25;
string(float f) ftos = #26;
string(vector v) vtos = #27;
void() coredump = #28; // prints all edicts
void() traceon = #29; // turns statment trace on
void() traceoff = #30;
void(entity e) eprint = #31; // prints an entire edict
float(float yaw, float dist) walkmove = #32; // returns #TRUE or #FALSE
// #33 was removed
float() droptofloor= #34; // #TRUE if landed on floor
void(float style, string value) lightstyle = #35;
float(float v) rint = #36; // round to nearest int
float(float v) floor = #37; // largest integer <= v
float(float v) ceil = #38; // smallest integer >= v
// #39 was removed
float(entity e) checkbottom = #40; // true if self is on ground
float(vector v) pointcontents = #41; // returns a CONTENT_*
// #42 was removed
float(float f) fabs = #43;
vector(entity e, float speed) aim = #44; // returns the shooting vector
float(string s) cvar = #45; // return cvar.value
void(string s) localcmd = #46; // put string into local que
entity(entity e) nextent = #47; // for looping through all ents
void(vector o, vector d, float color, float count) particle = #48;// start a particle effect
void() ChangeYaw = #49; // turn towards self.ideal_yaw
// at self.yaw_speed
// #50 was removed
vector(vector v) vectoangles = #51;
//
// direct client message generation
//
void(float to, float f) WriteByte = #52;
void(float to, float f) WriteChar = #53;
void(float to, float f) WriteShort = #54;
void(float to, float f) WriteLong = #55;
void(float to, float f) WriteCoord = #56;
void(float to, float f) WriteAngle = #57;
void(float to, string s) WriteString = #58;
void(float to, entity s) WriteEntity = #59;
void(float step) movetogoal = #67;
string(string s) precache_file = #68; // no effect except for -copy
void(entity e) makestatic = #69;
void(string s) changelevel = #70;
//#71 was removed
void(string var, string val) cvar_set = #72; // sets cvar.value
//void(entity client, string s) centerprint = #73; // sprint, but in middle
void(...) centerprint = #73;
#ifndef STATUSBAR
void(entity pl, string s1) CenterPrint = #73;
void(entity pl, string s1, string s2) CenterPrint2 = #73;
#endif
void(vector pos, string samp, float vol, float atten) ambientsound = #74;
string(string s) precache_model2 = #75; // registered version only
string(string s) precache_sound2 = #76; // registered version only
string(string s) precache_file2 = #77; // registered version only
void(entity e) setspawnparms = #78; // set parm1... to the
// values at level start
// for coop respawn
#ifdef QUAKE_WORLD
void(entity killer, entity killee) logfrag = #79; // add to stats
string(entity e, string key) infokey = #80; // get a key value (world = serverinfo)
float(string s) stof = #81; // convert string to float
void(vector where, float set) multicast = #82; // sends the temp message to a set
// of clients, possibly in PVS or PHS
#endif
// OfN - Stuff added to cpqwsv for prozac
float(entity client) getuid = #83;
string(string st1, string st2) strcat = #84;
string(string st, float len) padstr = #85;
string(string srcstr, float action) colstr = #86;
// colstr() possible action values
#define COLSTR_WHITE 0 // converts any red chars to white
#define COLSTR_MIX1 1 // mix red and white chars
#define COLSTR_RED 2 // converts any white chars to red
#define COLSTR_MIX2 3 // mix red and white chars
#define COLSTR_NUMBER 4 // converts any numbers to special number chars
#define COLSTR_NUMBERV 5 // second variant of special number chars (only different on rare charsets)
float(string st1, string st2) strcasecmp = #87;
float(string st) strlen = #88;
entity(string st) getclient = #89;
float(entity client) mutedtime = #90;
float(string st) validatefile = #91;
void(entity client) putsaytime = #92;
string(string st) makestr = #93;
void(string st) delstr = #94;
float(float inputnum, float modes, float minnum, float maxnum, float balance, float offset, float shape) getwave = #95;
// GetWave possible mode flags
#define GWAVE_STANDARD 0
#define GWAVE_USEMINMAX 1
#define GWAVE_USEBALANCE 2 // TODO: Unimplemented yet
#define GWAVE_USEOFFSET 4
#define GWAVE_USESHAPE 8
void(entity e, float chan, string samp, float vol, float atten) clientsound = #96;
void() touchworld = #97;
//============================================================================
//
// subs.qc
//
void(vector tdest, float tspeed, void() func) SUB_CalcMove;
void(entity ent, vector tdest, float tspeed, void() func) SUB_CalcMoveEnt;
void(vector destangle, float tspeed, void() func) SUB_CalcAngleMove;
void() SUB_CalcMoveDone;
void() SUB_CalcAngleMoveDone;
void() SUB_Null;
void() SUB_UseTargets;
void() SUB_Remove;
//
// combat.qc
//
void(entity targ, entity inflictor, entity attacker, float damage) T_Damage;
float (entity e, float healamount, float ignore) T_Heal; // health function
float(entity targ, entity inflictor) CanDamage;
//===========================================================================
// TEAMFORTRESS Defs
//===========================================================================\
.float playerclass;
.float nextpc; // The playerclass you'll respawn as
.float last_impulse; // The previous impulse command from this player
.float armorclass; // Type of *special* armor being worn
.float tf_items; // Another flag for player items
.float job; // WK Yet another flag for player items //WK CAUTION: IF YOU EVER CHANGE THIS, CPQWSV THIEF CODE WILL BREAK
.float job_finished; // WK Time for job ability to end/reload
.float tf_items_flags; // Flags for the player items
.float no_grenades_1; // Number of grenades of type 1 being carried
.float no_grenades_2; // Number of grenades of type 2 being carried
.float tp_grenades_1; // 1st type of grenades being carried
.float tp_grenades_2; // 2nd type of grenades being carried
.float got_aliases; // TRUE if the player has TeamFortress aliases
.float cheat_check; // Time when we'll next check for team cheats
.float is_removed; // TRUE if the entity has been removed
.float is_undercover; // TRUE for a SPY if they're undercover
.float is_building; // TRUE for an ENGINEER if they're building something
.float is_detpacking; // TRUE for a DEMOMAN if they're setting a detpack
.float is_feigning; // TRUE for a SPY if they're feigning death
.float is_haxxxoring; // TRUE if the player is hax0ring something
.float is_toffingadet; // TRUE if the player is arming a C4 det
.float is_unabletospy; // TRUE for a SPY if they can't go undercover
.float is_malfunctioning; //- SB/OfN For buildings and cyberaug players to determine if screwed up
.float is_abouttodie; // Oh no I am a martyr and about to die
//.float is_cameraviewing; // We're gazing out of the camera
.float is_killed; // avoids stack overflow on killed() ?? (only skips killed() for buildings)
.float option; // - OfN - used for megatf effect_random_sound support, and for camera/sensor build-destroy overflow control
.float option2; // - OfN - used for megatf effect_random_sound support, and in cmnd.qc
.float is_connected; // FALSE if the player has disconnected
.float has_dispenser; // TRUE for an ENGINEER if he has a dispenser
.float has_sentry; // TRUE for an ENGINEER if he has a sentry
.float has_tesla; // TRUE for an ENGINEER if he has a tesla
.float has_camera; // TRUE for an ENGINEER if he has a camera
.float has_sensor; // TRUE for an ENGINEER if he has a motion sensor
.float has_teleporter; // contains # of teleporters
.float has_fieldgen; // contains # of field generators
.float admin_flag; // TRUE if player has admin access
.entity admin_kick; // Contains the current client to kick
.entity martyr_enemy; // The last guy that shot the martyr. self = nobody, 5-15-08 Used to track TKD enemies too
.float stored_deathmsg; // OfN - UNUSED? - ofn nope hehe
.float cluster_mode; // 0=nothing 1=normal 2=cluster
//- OfN fields ---------------------------------//
.float has_holo; // holds player's holo status
// Rotation entities fields
.vector neworigin;
.vector rotate;
.float endtime;
.float rotate_type;
.string path;
.string group;
.string event;
.float duration;
// AirFist fields -
.float AIRG_Timeout;
.float AIRG_FireCount;
.float AIRG_Flags;
.entity AIRG_FlyTracker;
// crusader fields