0
Under review

camera adventure jittering / Stuttering => resonance

shadd 2 months ago in Game Creator updated by Marti (Lead Developer) 4 weeks ago 1

hello

before all thanks for you great job.

However I have an issue with my adventure camera (and also maybe on follow camera).

I've noticed movement jittering / Stuttering up to a sort of resonance for the entire scene.

(I reproduced this issue on a small scene; I could you to transfert it)

see video

2020-08-03-09-58-54-EO313.mp4

the problem is due to the smoothDamp applied on the function UpdateMotor()

1. by comment the part of code below or by setting "Position Duration" to zero the problem is "fixed.." in part

```

Transform targetTransform = this.target.GetTransform(gameObject);

/*

transform.position = Vector3.SmoothDamp(

transform.position,

targetTransform.TransformPoint(this.targetOffset),

ref this._velocityPosition,

smoothTime

);

*/

transform.position = targetTransform.TransformPoint(this.targetOffset);

```

2 . but it remains again an another issue concerning the "orbit mvt" management

If I replace Time.deltaTime by a fixed value the issue is "fixed..."

```

transform.rotation = Quaternion.Lerp(

transform.rotation,

targetRotation,

0.16f /*Time.deltaTime*/ * this.orbitSpeed

);

```

for now; I continue by these workarounds; but really I can't considering it for a production.

Regards

shadd

Unity version:
unity.2018.4.5f1
Game Creator version:
1.1.9
Under review

Hi, sorry for the late reply, but we were on vacation and our inbox got a bit cluttered. This is probably due to the camera or the motor being set as a parent of a moving object (like the player).

Can you try moving the Camera Motor and the Camera object at the root level of the scene? This should solve the problem. 


The commented code basically makes the movement feel smoother instead of instantly snapping to the desired position. Let me know if this fixes the issue.