Knowledge Base - Aiming Camera
Aiming Camera
Figure 1: Following a Demon
The aiming camera is another ZDoom camera similar to the Security camera. However, this camera will aim at and follow a target. The sample wad, aimcam.wad illustrates the use of the camera.
The aiming camera (9073) takes four parameters:
- pitch: pitch of camera in degrees, 0 is straight ahead, 1-89 is down, and 166-255 is up (angle subtracted from 256).
- yaw: maximum number of degrees to turn yaw per second.
- turn: maximum number of degrees to turn pitch per second.
- tid: tid of thing to follow.
The camera is activated by using the ChangeCamera (237) special. The ChangeCamera special has three parameters:
- tag: The camera tid.
- who: 0 if the view only changes for the player activating the special, 1 if all player views change.
- revert: 1 for the view reverts back to player when player moves.