mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 11:00:32 +00:00
fixing syncmode not showing up in Inspector (#1820)
syncMode and syncInterval now show up in Inspector when only sync vars are used
This commit is contained in:
parent
63e61bcbf4
commit
fd929e2b6d
@ -21,6 +21,12 @@ public class NetworkBehaviourInspector : Editor
|
||||
// does this type sync anything? otherwise we don't need to show syncInterval
|
||||
bool SyncsAnything(Type scriptClass)
|
||||
{
|
||||
// syncVarNames should be set because SyncsAnything is called
|
||||
if (syncVarNames.Count > 0)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// has OnSerialize that is not in NetworkBehaviour?
|
||||
// then it either has a syncvar or custom OnSerialize. either way
|
||||
// this means we have something to sync.
|
||||
|
Loading…
Reference in New Issue
Block a user