]> icculus.org git repositories - divverent/nexuiz.git/blob - attic/TeamNexuiz/game/gamec/defs.h
moved navnodeedit & TeamNexuiz to attic
[divverent/nexuiz.git] / attic / TeamNexuiz / game / gamec / defs.h
1 \r
2 // Globals\r
3 \r
4 entity  activator;\r
5 string  string_null;\r
6 \r
7 //entity        casing;\r
8 //entity dest;\r
9 \r
10 // Fields\r
11 \r
12 .void(entity inflictor, entity attacker, float damage, float deathtype, vector hitloc, vector force) event_damage;\r
13 \r
14 //.string       wad;\r
15 //.string       map;\r
16 \r
17 //.float        worldtype;\r
18 .float  delay;\r
19 .float  wait;\r
20 .float  lip;\r
21 //.float        light_lev;\r
22 .float  speed;\r
23 //.float        style;\r
24 //.float        skill;\r
25 \r
26 .string killtarget;\r
27 \r
28 .vector pos1, pos2;\r
29 .vector mangle;\r
30 \r
31 .float  jump_flag;                              // storing velocity_z for falling damage\r
32 .float  attack_finished;\r
33 .float  pain_finished;                  //Added by Supajoe\r
34 .float  pain_frame;                     //"\r
35 .float  statdraintime;                  // record the one-second intervals between draining health and armour when they're over 100\r
36 .float  crouch; // Crouching or not?\r
37 \r
38 .float  strength_finished;\r
39 //.float        speed_finished;\r
40 .float  invincible_finished;\r
41 //.float        slowmo_finished;\r
42 \r
43 .vector         finaldest, finalangle;          //plat.qc stuff\r
44 .void()         think1;\r
45 .float state;\r
46 .float          t_length, t_width;\r
47 \r
48 .vector dest1;\r
49 .vector dest2;\r
50 .vector destvec;                // for rain\r
51 .float cnt;             // for rain\r
52 .float count;\r
53 //.float cnt2;\r
54 \r
55 .float death_time;\r
56 .float dead_time;\r
57 .float dead_frame;\r
58 .float die_frame;\r
59 .float fade_time;\r
60 .float fade_rate;\r
61 \r
62 .string mdl;\r
63 \r
64 .string playermodel;\r
65 .string playerskin;\r
66 \r
67 .float  respawntime;\r
68 //.float        chasecam;\r
69 \r
70 .float electrocount;\r
71 //.float crylinkcount;\r
72 \r
73 .float  damageforcescale;\r
74 \r
75 //.float          gravity;\r
76 \r
77 .float          dmg;\r
78 \r
79 // for railgun damage (hitting multiple enemies)\r
80 .float railgunhit;\r
81 .float railgunhitsolidbackup;\r
82 .vector railgunhitloc;\r
83 \r
84 .float          air_finished;\r
85 .float          dmgtime;\r
86 \r
87 .float          killcount;\r
88 \r
89 // definistions for weaponsystem\r
90 \r
91 .entity weaponentity;\r
92 .entity exteriorweaponentity;\r
93 .float switchweapon;\r
94 void(float wpn, float wrequest) weapon_action;\r
95 float(entity cl, float wpn, float andammo) client_hasweapon;\r
96 void() w_clear;\r
97 // VorteX: standalone think for weapons, so normal think on weaponentity can be reserved by weaponflashes (which needs update even player dies)\r
98 .float weapon_nextthink;\r
99 .void() weapon_think;\r
100 .vector shotdir, shotorg; // new generic aiming system for all weapons (not finished yet, can be removed)\r
101 float   weapon_hasammo; // sets by WR_CHECKAMMO request\r
102 \r
103 //float PLAYER_WEAPONSELECTION_DELAY = );\r
104 float   PLAYER_WEAPONSELECTION_SPEED = 18;\r
105 vector  PLAYER_WEAPONSELECTION_RANGE = '0 20 -40';\r
106 \r
107 // weapon states (self.weaponentity.state)\r
108 float WS_CLEAR                  = 0; // no weapon selected\r
109 float WS_RAISE                  = 1; // raise frame\r
110 float WS_DROP                   = 2; // deselecting frame\r
111 float WS_INUSE                  = 3; // fire state\r
112 float WS_READY                  = 4; // idle frame\r
113 \r
114 // weapon requests\r
115 float WR_SETUP            = 1;  // setup weapon data\r
116 float WR_UPDATECOUNTS = 2;  // update ammo display\r
117 float WR_IDLE             = 3;  // idle frame\r
118 float WR_DROP             = 4;  // deselect frame\r
119 float WR_RAISE            = 5;  // select frame\r
120 float WR_FIRE1            = 6;  // primary fire frame\r
121 float WR_FIRE2            = 7;  // secondary fire\r
122 float WR_FIRE3            = 8;  // third fire\r
123 float WR_CHECKAMMO        = 9;  // checks ammo for weapon\r
124 float WR_CLEAR            = 10;  // runs afted deselecting frames, remove weapon parts (if presented). This useful for quake3-style chaingun\r
125 \r
126 // not part of weapon requests, but almost was, thus the naming convention\r
127 float WR_GRENADE1         = 11;\r
128 float WR_GRENADE2         = 12;\r
129 \r
130 // Weapon indexes\r
131 float WEP_LASER                         =  1; // float  IT_LASER                                = 4096;\r
132 float WEP_SHOTGUN                       =  2; // float  IT_SHOTGUN                              = 1;\r
133 float WEP_UZI                           =  3; // float  IT_UZI                                  = 2;\r
134 float WEP_GRENADE_LAUNCHER      =  4; // float  IT_GRENADE_LAUNCHER             = 4;\r
135 float WEP_ELECTRO                       =  5; // float  IT_ELECTRO                              = 8;\r
136 float WEP_CRYLINK                       =  6; // float  IT_CRYLINK                              = 16;\r
137 float WEP_NEX                           =  7; // float  IT_NEX                                  = 32;\r
138 float WEP_HAGAR                         =  8; // float  IT_HAGAR                                = 64;\r
139 float WEP_ROCKET_LAUNCHER       =  9; // float  IT_ROCKET_LAUNCHER              = 128;\r
140 float WEP_BOMBLETTS                     = 10;\r
141 float WEP_ROCKET_INCENDIARY     = 11;\r
142 float WEP_FLAMER                        = 12;\r
143 float WEP_HOTBOMBS                      = 13;\r
144 float WEP_GRAPPLE                       = 14;\r
145 float WEP_NAMEK                         = 15;\r
146 float WEP_RAILGUN                       = 16;\r
147 float WEP_HEALGUN                       = 17;\r
148 float WEP_MAC                           = 18;\r
149 float WEP_PISTOL                        = 19;\r
150 \r
151 float WEP_SCOUT_SPECIAL         = 50;\r
152 float WEP_SPY_SPECIAL           = 51;\r
153 float WEP_SOLDIER_SPECIAL       = 52;\r
154 float WEP_PYRO_SPECIAL          = 53;\r
155 float WEP_MEDIC_SPECIAL         = 54;\r
156 float WEP_ENGINEER_SPECIAL      = 55;\r
157 \r
158 float WEP_GRENADE_MIRV          = 60;\r
159 float WEP_GRENADE_FRAG          = 61;\r
160 \r
161 float WEP1      = 1;\r
162 float WEP2      = 2;\r
163 float WEP3      = 3;\r
164 float WEP4      = 4;\r
165 float WEP5      = 5;\r
166 \r
167 // For weapon cycling commands\r
168 float WEP_FIRST                         = 1;\r
169 float WEP_LAST                          = 5;//9;\r
170 \r
171 \r
172 \r
173 \r
174 \r
175 \r
176 \r
177 // class definitions\r
178 // (TF-numbered class defs in tfdefs.c)\r
179 float   CLASS_SCOUT             =  1;\r
180 float   CLASS_SPY               =  2;\r
181 float   CLASS_SOLDIER   =  4;\r
182 float   CLASS_PYRO              =  8;\r
183 float   CLASS_MEDIC             = 16;\r
184 float   CLASS_ENGINEER  = 32;\r
185 float   CLASS_CIVILIAN  = 64;\r
186 \r
187 .float team_no;\r
188 \r
189 .float  class;\r
190 .float  max_health;\r
191 .float  max_armor;\r
192 .float  mass;\r
193 .float  wpn;    // the weapon that's in the slot I've selected\r
194 .entity wpn5;   // what weapon I'm holding in my extra (5th) slot\r
195 //.float        oldclass;\r
196 .string change_mdl_on_respawn; // for changing class after death\r
197 \r
198 .float  special_active;\r
199 .float  special_time;\r
200 \r
201 .float  grenade_time;\r
202 \r
203 .float  jump_pad;       // true if just hit a jump pad (don't slow player when jump pads launch him)\r
204 \r
205 .entity onfire;         // world if not on fire, otherwise points to entity burning you\r
206 .float flame_heat;      // starts at 0.  Being near someone on fire raises it.  When it hits 1, the flame spreads to you.\r
207 .float flame_heat_time; // set when near a fire so code elsewhere knows to heat up instead of cool down\r
208 \r
209 .float  poison_damage;  // total damage poison will deal over time\r
210 .float  poison_rate;    // how fast to deal the poison\r
211 \r
212 .float create_time;     // tracks the time an entity was created to we can know which\r
213                                         // is the oldest when limiting the player's # of turrets or\r
214                                         // hotbombs, for example\r
215 \r
216 \r
217 .float buttonuse;       // 1 if player is using +use\r
218 \r
219 \r
220 // health regen/rot\r
221 .float  health_regen_delay;\r
222 .float  health_rot_delay;\r
223 .float  armor_regen_delay;\r
224 .float  armor_rot_delay;\r
225 \r
226 void DelayHealthRegen(entity e);\r
227 void DelayHealthRot(entity e);\r
228 void DelayArmorRegen(entity e);\r
229 void DelayArmorRot(entity e);\r
230 \r
231 \r
232 // grappling hook\r
233 .entity         hook;\r
234 void GrapplingHookFrame();\r
235 void RemoveGrapplingHook(entity pl);\r
236 \r
237 \r
238 \r
239 string NameOfClass(float cl);\r
240 float GetPlayerClass();\r
241 void ResetPlayerModel(entity pl);\r
242 void SetPlayerSpeed(entity pl);\r
243 \r
244 \r
245 // entity limiting function, to limit # of bombs etc a player can have.\r
246 float W_LimitNumEnts(string clname, float num_allowed, void() DeathFunc);\r
247 \r
248 // functions to let players cross lasergates\r
249 void PlayerLasergatePreThink();\r
250 void PlayerLasergatePostThink();\r
251 \r
252 void SpyCloakFlicker(entity pl);\r
253 \r
254 // BH Test Var\r
255 .float air_time;