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

What is network ownership and how do u use it?

Asked by 5 years ago

I don't understand what NetworkOwnership is on Roblox? It's not explained well enough on the wiki, can someone briefly explain to me what it is and how it works?

1 answer

Log in to vote
1
Answered by
chomboghai 2044 Moderation Voter Community Moderator
5 years ago

ROBLOX uses only one machine to calculate physics on an object, rather than calculating it on every machine. The machine that calculates those physics has Network Ownership over that object.

For example, if we have a car in the workspace, and we set the NetworkOwnership to Player1, then Player1's machine will calculate the physics, and replicate those results over to every other machine. This saves a lot of processing power in the long run because it would be a lot more work to calculate those physics on every single machine (imagine if there were 100 players per server).

Every player has NetworkOwnership over their own character, but the server can have NetworkOwnership over parts as well. The person who has ownership over an object will see it with the least amount of lag, because their machine will be the one calculating the physics of the object, so the client will see it smoothly. However, if Player1 has NetworkOwnership and his latency is high, it will take some time to replicate his results over to the other machines, so every other player will see his car teleporting a little bit at a time rather than smoothly driving.

I hope this helps you understand the basics of network ownership! :)

1
spot on! tl;dr Network Ownership decides who calculates physics. UnanchoredPart:SetNetworkOwner(player) YTRaulByte 389 — 5y
Ad

Answer this question