I have the unit/direction vector according to the bush, but how would I correctly apply it on the bush so that it faces away from the character using the X and Z rotation?
To calculate the direction the bush should shake, you will want to get the direction of the corresponding player’s torso relative to the bush using the unit vector as shown in the image.
To get the shake direction, you can use the cross product to determine relative direction for the shake:
local bushUnit = (bush.Position - Player.Character.Humanoid.RootPart.Position).unit:Cross(-bush.CFrame.UpVector)
Your solution did not immediately resolve the issue, but once I messed with the values a bit it worked, and I tried to do it without using yours and it also worked so, thanks anyways!
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.