#How do I move/lerp a child of a Transform that is being smoothed via NetworkTickSmoother?

5 messages · Page 1 of 1 (latest)

stark creek
#

For my FPS game, I have a player body transform as a child of the main player and it is being smoothed with the NetworkTickSmoother. The actual body/rig is a child of that object, since I need to modify the local position/rotation for my turn in place system.

I have tried changing from using the Update() method and Time.deltaTime to calling the method via Simulate(float delta) every tick and using the tick delta in place of Time.deltaTime but I can't seem to get rid of the jitter.

The jitter appears to be happening when the TurnInPlace script I made lerps the position/rotation of the player body which, again, is a child of an empty transform being smoothed with the NetworkTickSmoother. How do I get rid of this jitter and/or how should I be updating this TurnInPlace system?

safe swan
#

Hey there, how does moving the child in LateUpdate work?
And with the Detach On Start option in the TickSmoother enabled

stark creek
#

I tried:
-Using Simulate with tick delta + network tick smoother
-Using LateUpdate with deltaTime + network tick smoother
-Using Simulate with tick delta + detachable tick smoother
-Using LateUpdate with deltaTime + detachable tick smoother

Is the fact that I have an empty parent for the player body a problem? I used the tick smoothers on that and I tried using them on the actual play body object too. Even tried a detachable one on the parent and a network smoother on the body object

stark creek
#

Oh wait I found the issue! The turn in place was using the root player object as a reference for position and rotation constantly. I switched it to use the tick smoothed parent object and now it looks perfect.

Thank you!