Added a clientside QuakeC base by Dresk and myself. Included an example of a networke...
[divverent/nexuiz.git] / data / qcsrc / client / old / view.c
1 float max_ups;\r
2 vector angle_alive;\r
3 \r
4 void View_Update (void)\r
5 {\r
6         vieworg = pmove_org;\r
7         angle_alive = input_angles;\r
8         makevectors(input_angles);\r
9 \r
10         if(player_flags & PFL_DEAD && !spec)\r
11         {\r
12                 R_SetView(VF_ORIGIN, vieworg+'0 0 4');\r
13                 angle_alive_z = 80;\r
14                 R_SetView(VF_ANGLES, angle_alive);\r
15                 R_SetView(VF_CL_VIEWANGLES, angle_alive);\r
16                 return;\r
17         }\r
18 \r
19         if(input_buttons & 16 && !spec)\r
20                 vieworg += PL_CROUCH_VIEW_OFS;\r
21         else\r
22                 vieworg += PL_VIEW_OFS;\r
23 \r
24         if(cvar("chase_active") && !spec)\r
25                 vieworg = vieworg + v_up * cvar("chase_up") - v_forward * cvar("chase_back");\r
26 \r
27         R_SetView(VF_ORIGIN, vieworg);\r
28         R_SetView(VF_ANGLES, input_angles);\r
29 }\r