Ad
Log in to vote
1

How to make a tool to follow cursor movement

Asked by
Exsius 162
7 years ago

I want to make a object (tool) that will simply follow the cursor, also how could I make the camera follow the cursor?

Any help would be appreciated

Thanks,

Exsius,

1 answer

Log in to vote
4
Answered by 7 years ago

I believe this would work:

Supposing the tool is welded:

local Target = (Cam.CoordinateFrame * CFrame.new(0, 0, -100)).p
RightArmWeld.C1=((CFrame.new(User.Head.CFrame.p, Target) - User.Head.CFrame.p):inverse()) * (User.Head.CFrame - User.Head.Position)
0
thank you, I will try that out! Exsius 162 — 7y
Ad

Answer this question