The idea is to fire a ghost camera at a constant distance from the player but make it able to change the distance with variables.
To start off message "startup" to set various condition at the start up of the level. Next will be "activated" and "deactivated" for controlling the zooming and stopping the zoom. The last message can be "pulse" so you can keep firing the camera all the time in front of the player to keep the view on the camera. (Zooming is not in such a way generally, but this is the best I could (or maybe JK engine) can do.
For the verbs, clearly "FireProjectile()" for firing the camera, "SetPulse()" to control the pulse message and finally "SetCameraFocus()" to change the view. Theses are the fundamental to use, others can be "VectorSet()" and "GetSourceRef()".
To keep the fired camera synchronizing to where the player is viewing, this was the best method. Which is to keep firing new cameras in front of the player at a constant distance from the player. Since FireProjectile() can deal the direction to create from the player's look vector and detects wall so fired objects don't go into walls, the following lines make the best result.
pulse: Dummy = FireProjectile(player, CameraTpl, -1, -1, ZoomFactor, '0 0 0', 0, 0, 0, 0); SetCameraFocus(0, Dummy);
By keep doing this all the time, the camera will be fired at the distance "ZoomFactor" from the player.
The cog will make it zoom while you press the button and when let go of the button, it keeps the magnification. We have following conditions.
By considering them, following are the fact I placed in the cog.
In the activated message I have placed a variable "Zooming = 1 - Zooming;", so pressing the button will change the value to either 0 or 1, so you know if it needs to zoom or unzoom.
Placed a variable "Stay = 0;" in the activated message, so the magnification will change in the pulse message. I have put lines in the pulse message under "if(!Stay)" to change the magnification.
And in the deactivated message "Stay = 1;" so no more magnification will be changed while the button is not pressed. Under "if(!Stay)" in the pulse message I have put all zooming information under "if(Zooming)" and vice versa under "else".
As a conclusion, by pressing the button, it starts the pulse in 0.01 cycle and keeps firing the camera as shown in the "Level 2" answer. Once you press the button, it will let lines in the pulse message to increase the magnification and as it increases, the variable set inside FireProjectile() will change the magnification as where it fires by the variable.
If it is zooming or not or either it needs to zoom, unzoom or stay are controlled by 2 variables set in activated and deactivated.
Click the link and see what I was talking about. The description in the cog text should help you understand more.