Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Third Person Follow Mode with Look at Mode Simple, Follow Damping and Look at Damping results in tilted camera with wrong rotation when not changing third person rotation #450

Open
CentiGames opened this issue Jan 21, 2025 · 2 comments
Labels
3D Issues concerning 3D scenes bug Something isn't working phantom camera Related to PhantomCamera nodes
Milestone

Comments

@CentiGames
Copy link

CentiGames commented Jan 21, 2025

Issue description

When using a Phantom Camera 3D with Follow Mode Third Person, Look at Mode Simple, and Follow Damping enabled as well as Look At Damping enabled, then the camera tilts, faces the wrong direction and generally has a wrong direction/rotation.
However, when you move your mouse, thus changing the third_person_rotation_degrees and the damping for that is actively doing something everything works fine, it's only once you stop moving your mouse (i.e. stop changing rotation of camera) then the camera is somehow offset/tilted/wrong. Sometimes the camera then does not even show the target. Sometimes there also appears to be some sort of flickering going on/fighting between camera angles.

I am also not a PhantomCamera super pro yet, so it could also very well be that these settings are not intended to be used together? However, if that is the case then I would suggest displaying some warning or not allowing this sort of combination.

Here a demo video (I move the mouse every few seconds, then am not touching it for a few moments before moving it again):
https://github.com/user-attachments/assets/49f375f6-0d5f-49f4-85a9-dfbbc1d7e205

And here is a plain example screenshot how it looks when moving the mouse/rotation:
Image

And here are some screenshots how it looks like when not moving the mouse:
Image

Steps to reproduce

  1. Have some sort of 3rd Person scene, I used the 3d_follow_third_person_attributes_example demo.
  2. Change the Look at Mode to Simple
  3. Change Look at Target to PlayerCharacterBody3D
  4. Enable Follow Damping
  5. Enable Look at Damping
  6. Start the project, move the mouse, then stop moving it -> tilted screen

(Optional) Minimal reproduction project

Here is a minimal reproduction project: phantomcameratilt.zip
It's just the demo scene changed in the ways described above. Thanks for your help! The add-on is really awesome!

@CentiGames CentiGames changed the title Third Person Follow Mode with Loot at Mode Simple, Follow Damping and Look at Damping results in tilted camera with wrong rotation when not changing third person rotation Third Person Follow Mode with Look at Mode Simple, Follow Damping and Look at Damping results in tilted camera with wrong rotation when not changing third person rotation Jan 21, 2025
@ramokz
Copy link
Owner

ramokz commented Jan 22, 2025

You kinda hit the nail on the head.

The intent is to allow them to work together, however each follow mode and look at combination hasn't been properly tested together.

Third Person Follow, in particular, requires some additional tweaks to make Look At work well with it, as it functions a fair bit differently than the other follow modes.

It's something I'm hoping to start looking at with #161, or around that time, as the refactor for that follow mode should ideally be a more consistent version of the existing one, which includes proper support for rotational changes when using, e.g., a Look At Mode.

I would suggest displaying some warning or not allowing this sort of combination.

I think that's a good suggestion until the various combinations have been thoroughly tested.
A warning log should suffice for now, which isn't difficult to add.

@CentiGames
Copy link
Author

Thank you for your quick reply! Good to know!
A warning would totally be a big time saver already!

@ramokz ramokz added this to the 0.9 milestone Jan 24, 2025
@ramokz ramokz added bug Something isn't working phantom camera Related to PhantomCamera nodes 3D Issues concerning 3D scenes labels Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3D Issues concerning 3D scenes bug Something isn't working phantom camera Related to PhantomCamera nodes
Projects
Status: No status
Development

No branches or pull requests

2 participants