diff --git a/Mirror/Editor/NetworkBehaviourInspector.cs b/Mirror/Editor/NetworkBehaviourInspector.cs index 5360132cd..d38fd4aa2 100644 --- a/Mirror/Editor/NetworkBehaviourInspector.cs +++ b/Mirror/Editor/NetworkBehaviourInspector.cs @@ -69,7 +69,7 @@ void Init(MonoScript script) } int numSyncLists = 0; - foreach (FieldInfo field in serializedObject.targetObject.GetType().GetFields()) + foreach (FieldInfo field in scriptClass.GetFields()) { if (field.FieldType.BaseType != null && field.FieldType.BaseType.Name.Contains("SyncList")) {