Hi! So I’m trying to make a Sword-Slash system but for some reason my BodyPosition prints 0, 0, 0 even though I set it to Vector3.new(char.HumanoidRootPart.CFrame.LookVector * 50 + Vector3.new(0, 10, 0))
Code:
local Remote = script.Parent
local Slash = game.ReplicatedStorage.Slash
Remote.OnServerInvoke = function(player)
--Clone the Slash
local char = workspace[player.Name]
local clone = Slash:Clone()
clone.Parent = workspace
clone.Position = char.HumanoidRootPart.CFrame.LookVector * 2 + Vector3.new(0, 10, 0)
local BP = Instance.new("BodyPosition", char)
BP.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
BP.Position = Vector3.new(char.HumanoidRootPart.CFrame.LookVector * 50 + Vector3.new(0, 10, 0))
print(BP.Position) -- prints 0, 0, 0
end
If you want to see the localScript, tell me.
Thank you!