Hi
We are using the 3rd person camera.
Game is set to direct input and snap rotation.
We have free look enabled with RMB.
Our main issue is that the camera orbits and drifts around the player.
We would like it to (almost) always be behind the player. If you rotate or move such that the camera is no longer behind the player, it should orbit back to behind the player.
The current 3rd person camera will sometimes return, but other times stay in places other than behind the player. This typcially occurs when you run at a close angle to the camera, or directly at it.
There are many exposed properties (in a few locations - player controller, 3rd person camera and settings). I'm working through them and the code to understand them, but figured I would also ask.
Does the out of the box AC allow for this behavior? We would like the camera to always return back to behind the player, ideally after a short delay.
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
It supports moving behind the Player if movement is detected - i.e. it'll naturally go behind once the Player begins moving. This won't kick in if the Player is idle, however.
What's the exact behaviour you're looking for? For the camera to reset once input is released?
Hi Chris
What we would like
The camera should always return behind the players back. Ideally after a slight delay.
Free look should allow changing the pitch and orbit of the camera. Once released, it should return after a slight delay.
Even if this worked once the player started moving it would be ok
What we see
I've found that the movement sometimes triggers the camera to return, other times it only returns some percentage of the way. Once the camera is dragged (drag-control) it rarely returns.
Details
Using a fresh install of AC 179.3 using Unity 2021.3.24f1
I can reproduce this behaviour with a simple AC scene using TinPot.
Movement is Snap relative to camera.
3rd person camera has default settings (reset component, meaning Target Influence speed is set, and no limit on spin).
Notes
Ive also noticed then when I run the Unity recorder the camera does not return at all (so I cant demo the behavior to you). I havent had a change to step through the code and see why.
I need to step out for a bit so I apologize for a post without specific details - we are on different time zones and I wanted to respond today. Ill post further details later today,.
Open up GameCameraThirdPerson and add the following:
(I'll make the same change to the next release)
Then, this script should handle it:
This worked great. I'll use it along with some other modifications (dont return back if player is actively dragging, etc). I think its a good idea to integrate back into the main branch as well.
Thank you.