Forum rules - please read before posting.

Issue with Game Camera Movement

edited January 28 in Technical Q&A

I'm trying to get a Game Camera to follow the player along the X axis (Affected by: Target X). It works unconstrained, but there is a possibility the camera can go out of the scene boundaries, so I've applied min and max constraints. However, I cannot get the camera to move at all when constraints are applied, even though the player's position would put the camera's X position within the two constraint values.

Here are the camera's settings

AC 1.77.4
Unity 2018.4.3

Comments

  • The constraint values aren't always straight match for position values - the offset and Player's original position are also factored in.

    Try altering the X direction's offset value, and/or unchecking Use default PlayerStart?.

  • edited January 29

    Yes, altering the offset value (by a surprisingly large amount) has fixed it somewhat. However I've run into another issue caused by player starts. Activating the camera from one end of the scene the camera works fine, but since the player can enter from the other end, when switching to the camera it is already at it's max constraint value, as it has already started moving as soon as the player started moving along X from the other end of the scene - if that makes sense.

    Edit: Ah, seems to be fixed by unchecking the Use default PlayerStart? option, thank you.

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.