change camera from actor blueprint
Hi guys, i learned how to change cameras from inside the level blueprint.
now i want to change my main camere from inside an actor blueprint, but i cant get anywhere near a solution.
i have a mobile mesh, that i converted into a blueprint. inside this blueprint i am checking interaction with the object. so now i want to change my camera if the player interacts with the mobile mesh (means right clicks on it)
but i cant get the camera into the blueprint. (dragging a camera into the level bueprint works fine..)
why is that so ? (there must be something fundamental to learn here for me ;-) ) and can anybody tell me how to achieve it
kind regards stucki
asked Oct 26 '16 at 08:53 PM in Blueprint Scripting
There are 2 ways to do this.
You can use the get all actors of class node in blueprint, and chose to return all cameras in the scene, then if you have one camera you can use the get node and get the first element. If you have more then one camera then you need to find the right one by either adding a tag to your camera or by finding it by it's name.
The second method which I would recommend, would be to create a camera variable in your mobile blueprint, and then click the "Eye" icon next to the variable name, this will expose the variable in the mobile blueprint scene settings. Go to your Mobile Blueprint in the scene, select it and look for the camera variables in the details menu, you can use the eyedropper to select the camera in the scene
answered Oct 26 '16 at 10:20 PM
thx very much for your answer ! i have tried to do so, but noob as i am, i am not getting anywhere past the get all actors of class ... as actor class i choose camera actor. how do i get the specific camera i want now from the Out actors array ?
your second tip i dont understand even less. please try to explain it for an blueprint beginner of level 0 ;-)
best regards stucki
answered Oct 27 '16 at 04:01 PM
thx again for your detailed pictures. now i got it working ;-)
is there a reason why this must be so complicated ? couldnt cameras be something global i can point to from anywhere in the game .... guess it just does not work like this and i have to learn more about the art of blueprinting !
thx for your time and help !! stucki
answered Oct 27 '16 at 08:47 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here