Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Rotating Character To Mouse Target Solution?

Asked by 5 years ago

Hello, so i am making a script then rotates the player to the target. This is my current script:

function KeyD(key)
    if key:lower() == "e" then
    char.Head.Orientation = Vector3.new(mouse.Target)
end

game.Players.LocalPlayer:GetMouse().KeyDown:connect(KeyD)

I want to script it so the player's character rotates to the target the mouse is pointing at. But everytime i rotate a bodypart, the player dies. And everytime i try to rotate the HumanoidRootPart, the character just loses control.

The rig is R15. Any help is appreciated, thanks!

0
Are you ONLY supporting R15 or both R6 and R15. moo1210 587 — 5y
0
Only R15 EatableDragonkight 3 — 5y

Answer this question