com.unity.netcode.gameobjects
com.unity.netcode.gameobjects copied to clipboard
NetworkObjectReference should be nullable
Suggested Changes Currently NetworkObjectReferences are not allowed to be null, which limits their usability in custom structs. I have some clunky workarounds in place now to deal with cases in which NetworkObjectReference would be set to null, such as setting a bool and then putting a reference to a random NetworkObjectReference instead of null in there, but it would be way more convenient if NetworkObjectReference could be set to null directly.
https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/builtin-types/nullable-value-types