Added a clientside QuakeC base by Dresk and myself. Included an example of a networke...
[divverent/nexuiz.git] / data / qcsrc / client / csqc_constants.qc
1 const entity    NULL                                                    = world;
2
3 // Mask Constants (set .drawmask on entities; use R_AddEntities to add all entities based on mask)
4 const float             MASK_ENGINE                                             = 1;
5 const float             MASK_ENGINEVIEWMODELS                   = 2;
6 const float             MASK_NORMAL                                             = 4;
7
8 // Renderflag Constants (used for CSQC entities)
9 const float             RF_VIEWMODEL                                    = 1;
10 const float             RF_EXTERNALMODEL                                = 2;
11 const float             RF_DEPTHHACK                                    = 4;
12 const float             RF_ADDITIVE                                             = 8;
13 const float             RF_USEAXIS                                              = 16;
14
15 // Viewflag Constants (use with R_SetView)
16 const float             VF_MIN                                                  = 1;    //(vector)
17 const float             VF_MIN_X                                                = 2;    //(float)
18 const float             VF_MIN_Y                                                = 3;    //(float)
19 const float             VF_SIZE                                                 = 4;    //(vector) (viewport size)
20 const float             VF_SIZE_Y                                               = 5;    //(float)
21 const float             VF_SIZE_X                                               = 6;    //(float)
22 const float             VF_VIEWPORT                                             = 7;    //(vector, vector)
23 const float             VF_FOV                                                  = 8;    //(vector)
24 const float             VF_FOVX                                                 = 9;    //(float)
25 const float             VF_FOVY                                                 = 10;   //(float)
26 const float             VF_ORIGIN                                               = 11;   //(vector)
27 const float             VF_ORIGIN_X                                             = 12;   //(float)
28 const float             VF_ORIGIN_Y                                             = 13;   //(float)
29 const float             VF_ORIGIN_Z                                             = 14;   //(float)
30 const float             VF_ANGLES                                               = 15;   //(vector)
31 const float             VF_ANGLES_X                                             = 16;   //(float)
32 const float             VF_ANGLES_Y                                             = 17;   //(float)
33 const float             VF_ANGLES_Z                                             = 18;   //(float)
34 const float             VF_DRAWWORLD                                    = 19;   //(float)
35 const float             VF_DRAWENGINESBAR                               = 20;   //(float)
36 const float             VF_DRAWCROSSHAIR                                = 21;   //(float)
37 const float             VF_PERSPECTIVE                                  = 200;  //(float)
38
39 const float             VF_CL_VIEWANGLES                                = 33;   //(vector)
40 const float             VF_CL_VIEWANGLES_X                              = 34;   //(float)
41 const float             VF_CL_VIEWANGLES_Y                              = 35;   //(float)
42 const float             VF_CL_VIEWANGLES_Z                              = 36;   //(float) 
43
44 // Server Autosent Stat Constants
45 const float             STAT_HEALTH                                             = 0;
46 const float             STAT_WEAPONMODEL                                = 2;
47 const float             STAT_AMMO                                               = 3;
48 const float             STAT_ARMOR                                              = 4;
49 const float             STAT_WEAPONFRAME                                = 5;
50 const float             STAT_SHELLS                                             = 6;
51 const float             STAT_NAILS                                              = 7;
52 const float             STAT_ROCKETS                                    = 8;
53 const float             STAT_CELLS                                              = 9;
54 const float             STAT_ACTIVEWEAPON                               = 10;
55 const float             STAT_TOTALSECRETS                               = 11;
56 const float             STAT_TOTALMONSTERS                              = 12;
57 const float             STAT_SECRETS                                    = 13;
58 const float             STAT_MONSTERS                                   = 14;
59 const float             STAT_ITEMS                                              = 15;
60 const float             STAT_VIEWHEIGHT                                 = 16;
61
62 // Sound Constants
63 const float             CHAN_AUTO                                               = 0;
64 const float             CHAN_WEAPON                                             = 1;
65 const float             CHAN_VOICE                                              = 2;
66 const float             CHAN_ITEM                                               = 3;
67 const float             CHAN_BODY                                               = 4;
68
69 const float             ATTN_NONE                                               = 0;
70 const float             ATTN_NORM                                               = 1;
71 const float             ATTN_IDLE                                               = 2;
72 const float             ATTN_STATIC                                             = 3;
73
74 // Quake-style Point Contents
75 const float             CONTENT_EMPTY                                   = -1;
76 const float             CONTENT_SOLID                                   = -2;
77 const float             CONTENT_WATER                                   = -3;
78 const float             CONTENT_SLIME                                   = -4;
79 const float             CONTENT_LAVA                                    = -5;
80 const float             CONTENT_SKY                                             = -6;
81
82 // Boolean Constants
83 const float             true                                                    = 1;
84 const float             false                                                   = 0;
85 const float     TRUE                                                    = 1;
86 const float     FALSE                                                   = 0;
87
88 // Vector / Hull Constants
89 const vector    VEC_1                                                   = '1 1 1';
90 const vector    VEC_0                                                   = '0 0 0';
91 const vector    VEC_M1                                                  = '-1 -1 -1';
92
93 const vector    VEC_HULL_MIN                                    = '-16 -16 -24';
94 const vector    VEC_HULL_MAX                                    = '16 16 32';
95
96 // Effect Constants
97 const float     EF_NODRAW                                               = 16;
98 const float     EF_ADDITIVE                                             = 32;
99 const float     EF_BLUE                                                 = 64;
100 const float     EF_RED                                                  = 128;
101 const float     EF_FULLBRIGHT                                   = 512;
102 const float     EF_FLAME                                                = 1024;
103 const float     EF_STARDUST                                             = 2048;
104 const float     EF_NOSHADOW                                             = 4096;
105 const float     EF_NODEPTHTEST                                  = 8192;
106
107 // Quake Player Flag Constants
108 const float     PFL_ONGROUND                                    = 1;
109 const float     PFL_CROUCH                                              = 2;
110 const float     PFL_DEAD                                                = 4;
111 const float     PFL_GIBBED                                              = 8;
112
113 // Quake Temporary Entity Constants
114 const float             TE_SPIKE                                                = 0;
115 const float             TE_SUPERSPIKE                                   = 1;
116 const float             TE_GUNSHOT                                              = 2;
117 const float             TE_EXPLOSION                                    = 3;
118 const float             TE_TAREXPLOSION                                 = 4;
119 const float             TE_LIGHTNING1                                   = 5;
120 const float             TE_LIGHTNING2                                   = 6;
121 const float             TE_WIZSPIKE                                             = 7;
122 const float             TE_KNIGHTSPIKE                                  = 8;
123 const float             TE_LIGHTNING3                                   = 9;
124 const float             TE_LAVASPLASH                                   = 10;
125 const float             TE_TELEPORT                                             = 11;
126 const float     TE_EXPLOSION2                                   = 12;
127 // Darkplaces Additions
128 const float     TE_EXPLOSIONRGB                                 = 53;
129 const float             TE_GUNSHOTQUAD                                  = 57;
130 const float             TE_EXPLOSIONQUAD                                = 70;
131
132 // Math Constants
133 const float     M_PI                                                    = 3.14159265358979323846;
134 const float     EXTRA_LOW                                               = -99999999;
135 const float     EXTRA_HIGH                                              = 99999999;
136
137 // Frik File Constants
138 const float             FILE_READ                                               = 0;
139 const float             FILE_APPEND                                             = 1;
140 const float             FILE_WRITE                                              = 2;