Creating mesh lags 1 frame

trail1
trail1wireframe

I’m wanting to create sword trails, the problem is when I create the mesh they lag one frame behind when the sword is, if the sword is moving fast as the pictures show (same picture, 1 in wireframe, I’m tessellate the curves) there can be quite a large distance from the sword and its trail. I assume the above picture sword trail is built from maybe 5 frames of animation movement
How to solve this?

I’m building the trail in weaponTrail.LateUpdate()
also I’ve experimented with changing the script execution order of the weaponTrail.cs class (both as < 0 and > 0)

quasi code

LateUpdate()
{
     grab current sword tippos
     grab current sword basepos

     construct a spline mesh based on all the tip,base verts, tessellatted
}

I’ve en tried do drawMeshNow() but it still always lags 1 frame

A little bump here. To see if anyone has any ideas as I’m all out of them
Heres me from 2022 asking the same Question
https://discussions.unity.com/t/transform-position-is-a-frame-behind/886987/4

LateUpdate() ← Is not the answer

Surely someone has built a mesh that attaches to another mesh in the scene, if so Did it also lag 1 frame behind? Or did you solve it

EDIT: I think I’m just going to ignore it as I’ve spent enuf hours trying to fix it.

as 1 frame is only really visible unless you’ve paused the game
(thus I’ve checked/hacked it so if the game is paused and then I will rebuild the mesh then)
OK its not going to look alright with the 1 frame delay if they take a screenshot / video in the middle of the game but hey what can I do :slight_smile: