How do you blueprint a camera Actor so that when you press a key your view goes to the camera?

Hi, im trying to get started with Unreal engine and wanted to start with something simple: the ability to walk to objects and press a key to get get a better view of them. Ive been watching tutorials, one of which even answered my question, but i cant use the solution because i cant get a refrence for the camera. Im using Unreal engine 5 and i dont know what im supposed to use or do.

For what you described you will want to use an interface.

You can access the manager like so :point_down:

image

Or the get the actor whose camera (or point of view) we’re using :point_up_2: But I do not think this is the right question to ask here, and also not the the thing you’re looking for.


How do you blueprint a camera Actor so that when you press a key your view goes to the camera?

walk to objects and press a key to get get a better view of them

To answer more directly:

  • either line trace to obtain the reference to the actor the player is looking at
  • or sphere overlap nearby actors

Once you have a desired reference, we either cast or send an interface message; and then:

  • Set View Target with Blend to switch to the object’s camera / point of view
  • or move the current camera to the object