-
Notifications
You must be signed in to change notification settings - Fork 449
Owernship None doesn't work #3470
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @marcusx2, When a client disconnects from either type of network topology, all NetworkObjects instantiated and spawned locally on the client that disconnected will be despawned and if not registered with a network prefab handler it will be destroyed. When using a client-server network topology, to assure the NetworkObject owned by a client is not persisted when the client disconnects you should make sure don't destroy with owner is unchecked. However, the ownership permissions will have no impact on NetworkObjects when using a client-server network topology as the server/host will always have full permissions/authority over all spawned NetworkObject instances (with the only caveats being NetworkTransform when using an owner authoritative motion model and NetworkVariables when using owner write permissions). |
If it's working as intended, the documentation isn't clear about it. You say that ownership permissions is only valid for a distributed authority configuration, but we have Ownership permission settings, where we can select distributed as one of the options, so it sure doesn't seem like ownership permissions only pertain to distributed topology. |
@marcusx2 The documentation on Ownership permission settings does state:
Since we do cover the network topologies in our documentation which does state:
and
We felt that the separation between a client-server and distributed authority network topology would make sense as to why ownership permissions are not used when running a client-server network topology. Do you feel it would help if we more clearly state within the Ownership permission settings that ownership permissions, while still visible if using a client-server network topology and the multiplayer SDK is included, will have no effect/impact on ownership if running a client-server network topology since the server always has authority? |
Definitely, yes. I'm not even the only one confused by this. |
Ok, made an update to the documentation and the PR should land soon. |
Description
I have a network object owned by a client. The Ownership is set to
None
. When the client disconnects, the ownership is transferred to the server.Expected Outcome
The ownership should remain to the disconnected client. The documentation states that I should use None to avoid ownership transfer, but it's happening anyway. I am using
private void OnClientDisconnect(ulong clientId)
on the server, and I want to check if the client is the owner of something, despawn it on the server. I can't do that, because the ownership keeps being transferred to the server.The text was updated successfully, but these errors were encountered: