Animating a zoomed view
A core element of modern first-person shooters is a variable field of view (FOV) in the form of a player's ability to look down the scope of a gun to get a closer view of a target. This is a significant contributor to the feeling of accuracy and control that modern shooters provide. Let's add a simple form of this functionality to our prototype. To do that, follow these steps:
- In an empty section of the grid next to your Mouse input nodes, right-click, search for
zoom
, and add a Zoom Event node. - We want to modify the FOV value that is contained within the First Person Camera Component, so go to the Components panel and drag First Person Camera out onto Event Graph.
- Drag the output pin of First Person Camera node into empty grid space, search for the Set Field Of View node, and place it. Lowering the FOV gives the effect of zooming into a narrower area in the center of the screen. Since the
Default
FOV value is set to90
, for our zoom...