Forum rules - please read before posting.

Camera circle rotation around the player from top view

edited July 2022 in Technical Q&A

Hello group.

I am using AC to create an RPG micro-game.
At this point of the development process, it has just some small and quick tasks you need to accomplish.

The view of the camera is from the top and it follows the player. The view and setup is similar like in the Adventure Creator tutorial "Recreating Unity's adventure game". Inside the scene, I use a GameCamera component that follows the player and the settings are similar to the ones shown in the tutorial.

My question here is, how can I create a functionality of the camera to rotate around the player, to look around the environment? The rotation can be triggered when I hold the right mouse button, for example, but after I release it the camera should keep its last position and continue to follow the player from there.

Thanks.

Comments

  • Welcome to the community, @alex_teodor.

    The GameCamera component reacts to the position of the assigned Target in the scene - by default, the Player character.

    To have a camera rotate based on input, try the GameCamera Third Person camera type instead. This is primarily intended for traditional (over-the-shoulder) third-person camera motion, but may give you what you're looking for with the correct height values.

    This camera can be spun around with the mouse by checking Is drag-controlled?. By default, this is done with a left-click of the mouse, but this can be changed by defining a new input in Unity's Input Manager (named e.g. RightClick), giving it a "Positive Button" of "mouse 1", and then assigning this input (RightClick) into the "Drag Input Override" field of the PlayerInput component on the AC GameEngine object in the scene.

  • Hi,

    Thanks for your answer.
    I will try this workaround.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.