This just happened tonight and is really weird: The issue only exist in Normal(Inspector) Mode, In Debug I can edit everything.
I duplicated a CircleCaster script to make a variation (BoxCaster), and suddenly I can’t apply change on any Size int field (reset to existing value after pressing Enter) of List Property Fields in its custom editor while other fields works normally.
I can confirm that all the SerializedProperty is found correctly.
Have someone encountered this before?
public override void OnInspectorGUI()
{
BoxCaster caster = (BoxCaster)target;
GUILayout.BeginVertical();
EditorGUILayout.PropertyField(LayerMaskProp);
caster.CastSize = EditorGUILayout.Vector2Field("Size", caster.CastSize);
caster.MaxCandidate = EditorGUILayout.IntField("Max Candidates", caster.MaxCandidate);
GUILayout.BeginVertical("Box");
caster.UseDepthLimit = EditorGUILayout.Toggle("Use Depth Limit", caster.UseDepthLimit);
if (caster.UseDepthLimit) {
GUILayout.BeginHorizontal();
GUILayout.Label("Depth");
GUILayout.FlexibleSpace();
GUILayout.Label("Min", GUILayout.Width(32));
caster.MinDepth = EditorGUILayout.FloatField(caster.MinDepth, GUILayout.Width(40));
GUILayout.Space(12);
GUILayout.Label("Max", GUILayout.Width(32));
caster.MaxDepth = EditorGUILayout.FloatField(caster.MaxDepth, GUILayout.Width(40));
GUILayout.EndHorizontal();
}
GUILayout.EndVertical();
GUILayout.BeginVertical("Box");
caster.OnlyTarget = EditorGUILayout.Toggle("Ignore non-targets (Tags)", caster.OnlyTarget);
GUILayout.BeginHorizontal();
GUILayout.Space(14);
EditorGUILayout.PropertyField(TargetTagsListProp, true);
GUILayout.EndHorizontal();
if (caster.OnlyTarget) {
GUILayout.BeginHorizontal();
GUILayout.Space(14);
EditorGUILayout.PropertyField(BlackTagsListProp, true);
GUILayout.EndHorizontal();
}
GUILayout.BeginHorizontal();
GUILayout.Space(14);
EditorGUILayout.PropertyField(BlackColListProp, true);
GUILayout.EndHorizontal();
GUILayout.EndVertical();
GUILayout.EndVertical();
}