I’m reading the source code about Advanced Locomotion System V4, When I came across the blueprint class ALS_PlayerCameraManager
, I found some code that is difficult to understand.
The Code is In the Blueprint method
CalculateAxisIndependentLag
In my opinion that the
unrotate
node transforms the position of the Current and Target location into the camera coordinate. After doing some interplate, rotate
node will transform there back to the world coordinate(I’m not sure if my understanding is correct). But what are the benefits of doing this? Or, will there be any bugs if these two nodes are not used?I was trying to delete both
unrotate
and rotate
node like this:the result doesn’t seem to be very different (By pressing ‘Y’ show debug Shapes Orange Sphere is smooth interp to Green Sphere).
I also trying to link TargetLocation directly to return node, then Orange Sphere is always on top of Green Sphere (So this method does indeed perform this functionality).