I have inherited some project in Unreal.
The issue is that when I run it it creates a CameraActor that is used as the main camera for the view.
I didn’t find any code in C++ or any existing camera actor that creates this CameraActor.
When I tried to create my own CameraActor_Blueprint and set it as active inside the blueprint events, it had no effect.
Many things that work on sample projects don’t work here.
Is there no way to tell what creates the camera Actor inside someone’s else project?
I could be wrong… but in my experience, it’s a bit of a nuisance, but ue4 always auto-creates an extra camera actor in the level (I haven’t found a way to turn this off). I suspect this is what is happening here.
If it is me, in Begin Play of the level BP or your custom camera actor BP… I’d use a Set View Target with Blend… to use your custom camera (I wouldn’t use Set Active or Toggle nodes…)
That’s about what I did. I had an empty object with a BP that sets the camera to target view. It also takes the index 0 playercontoler and use that.
Not sure what is the playercontroler but it works.
good! happy you solved it
ideally, I’d do the Set View Target with Blend in the BP that contains the camera (maybe your player pawn BP or custom camera BP), or in the level BP… others will work, but it’s just not as neat imho
Unreal (kind of optionally) uses the PlayerController to store various data for controlling the player pawn or character, and you can also conveniently in your custom PlayerController BP the wiring for how your pawn/character is moved about and rotated (i.e. controlled) usually by mouse/keyboard/joystick… Though, you can put this control wiring elsewhere too (like the BP of the pawn/character) itself also…
Index 0 refers to the player of this game instance (in a networked game there may be several players, the count is zero based… 0,1,2,3,4 would refer to 5 players… and player 0 is the player of this instance)