| 936 | } |
| 937 | |
| 938 | void sethudgunperspective(bool on) |
| 939 | { |
| 940 | glMatrixMode(GL_PROJECTION); |
| 941 | glLoadIdentity(); |
| 942 | if(on) |
| 943 | { |
| 944 | glScalef(1, 1, 0.5f); // fix hudugns colliding with map geometry |
| 945 | setperspective(75.0f, aspect, 0.3f, farplane); // y fov fixed at 75 degrees |
| 946 | } |
| 947 | else setperspective(fovy, aspect, 0.15f, farplane); |
| 948 | glMatrixMode(GL_MODELVIEW); |
| 949 | } |
| 950 | |
| 951 | void drawhudgun() |
| 952 | { |
no test coverage detected