I have a very specific problem. I attach a weapon to a character using a physics constraint. The goal is to get the location of a specific socket on the attached weapon mesh (the weapon is simulating physics). Everything works fine until the character moves in which case the socket location seems to lag behind the visible movement of the weapon (pictures attached). I’m trying to make a partially physics based game and I encounter this problem a lot. I have tried setting the attachment using blueprints and c++, fiddled with substepping and other physics settings and used interpolation to try and correct the offset to no avail. Any help would be appreciated, thanks in advance.
the white cube represents the socket location using the following code (in blueprints but c++ gives exact same result. Also the cube has no collision)
I also need to mention that I fiddled with all tick groups in the aforementioned components, non of it makes any difference