I want to properly get the velocity vector at an attachment’s position on a part in world space.
Currently, I am facing an issue where my velocity vector does not make any sense. It is not pointing in the right direction. I expected the vector at the outer point of the propeller to be directed towards the inside.
The video below displays the problem, where the green vector visualisations are the velocity vectors of a propeller.
The code for obtaining the velocity vector that I used in the clip is the following:
local velocity = self.instance:GetVelocityAtPosition(attachment.WorldPosition)
Also, there is no documentation on the Developer Hub on what vector spaces are relevant for the output and parameter of the GetVelocityAtPosition method… I am confused and I thought that this would be easy.
The velocity vector is only incorrect for the propellors in the video. I tried to recreate this issue by making another set of propellors, but then it seemed to work properly. This is starting to look like an engine bug to me…