Dragging objects with mouse server side

I need help with dragging objects with mouse server side. I thought of just firing a remote event to the server every render stepped but that could cause issues and I was wondering if there’s a better way to do this?

You might want to check Starmaq’s post:

1 Like

That doesn’t help, he did it all client sided.

Are you talking about using :GetMouse on Server Side, if thats the case then its not possible.

It isn’t needed to implement in the server.

4 Likes

This is no longer true unfortunately. When you drag an object client side and then go and check the sever/another client the object has not moved. Or do I just have a really weird version of Roblox Studio?

This is no longer true unfortunately.

The way replication works will always be the same, and no you don’t have a weird version of the Studio! That’s not a valid thing to say.

I think it’s my fault that I didn’t bring this up, not sure why I missed it. In order for the physics to replicate, the client has to have Network Ownership over the dragged part. Meaning whenever you drag a part, you need to do

part:SetNetworkOwner(player)

where player is LocalPlayer, else the position of the part will not change! It might also be wise to give back the Network Ownership to the server after we’re done dragging, which is done by setting the NetworkOwner to nil.

part:SetNetworkOwner(nil)

https://developer.roblox.com/en-us/articles/Network-Ownership

1 Like

Thank you for the information. The link however is taking me to an article titled: GetProductInfo().Sales returns on the developer forum.

That’s super strange, no idea how it got to that post, I don’t think I accidently copied the wrong link. Anywho, just search for “roblox Network Ownersip” for more info.