]> icculus.org git repositories - divverent/nexuiz.git/blob - TeamNexuiz/game/gamec/tn_misc.c
- Feigning spy can no longer throw TF grenades and can no longer switch weapons
[divverent/nexuiz.git] / TeamNexuiz / game / gamec / tn_misc.c
1 /*-----===================================-------\r
2                 Team:Nexuiz Misc. Items/Functions\r
3                                 -=[ by avirox ]=-\r
4 -------===================================-----*/\r
5 \r
6 // Ice/Slippery ground\r
7 .vector area_min;\r
8 .vector area_max;\r
9 .float slip_time;\r
10 .float slip_amount;\r
11 \r
12 void () slippery_touch =\r
13 {\r
14         other.slip_time = time + .2;                            // amount of time the player is slipping (this gets constantly updated)\r
15         other.slip_amount = self.slip_amount;           // handled in cl_physics.c\r
16 };\r
17 \r
18 void () func_slippery =\r
19 {\r
20         if (self.area_min != '0 0 0')\r
21         {\r
22                 setsize(self, self.area_min, self.area_max);\r
23         }\r
24         else\r
25         {\r
26                 setsize(self, '-16 -16 -24', '16 16 32');\r
27         }\r
28         self.solid = SOLID_TRIGGER;\r
29         self.touch = slippery_touch;\r
30 };\r
31 \r
32 void () func_ice =\r
33 {\r
34         self.classname = "func_slippery";\r
35         func_slippery();\r
36 };