Log in to vote

how to make part follow mouse???

Asked by 3 days ago

im trying to make a magical ability like the one here

i've tried absolutely everything and it just wont work, can someone please help? i want it to be on the server for eveyrone to see, and i want it to cause damage when it hits someone. i want it to only last 5 seconds before the player is forced to let go. please help!!!

1 answer

Log in to vote
Answered by
rabbi99 617 Moderation Voter
3 days ago

The magical ability the video is showing is very advanced, and I am unable to explain all of it.

On the server, there's the part with a BodyPosition in it. The part's NetworkOwner is set to the player that controls it. The player has a localscript that (per RenderStep) sets the BodyPosition's position to Mouse.Hit.Position.


local Part = workspace.Part
local Player = game.Players.LocalPlayer
local Mouse = Player:GetMouse()
local RunServ = game:GetService("RunService")

    Part.BodyPosition.Position = Mouse.Hit.Position

This is the way it kind of works. But then again, I'm unable to explain all of it.

best answer Xapelize 1835 — 2d
by the way if you see this, dont act smart and do Mouse.Move because if your mouse doesnt move and your character moves it doesnt work, like build a boat lol Xapelize 1835 — 2d
i have upvoted your answer Xapelize 1835 — 2d

Answer this question