浏览代码

Fixes in propertydrawer

/main
Thomas ICHÉ 5 年前
当前提交
87a3f07a
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 2
      Editor/PropertyDrawers/StateMachineStatePropertyDrawer.cs

2
Editor/PropertyDrawers/StateMachineStatePropertyDrawer.cs


}
int newIdx = EditorGUI.IntPopup(position, new GUIContent(property.displayName), selected, labels, indices);
if (GUI.changed && stateMachine.States[newIdx] != null)
if (GUI.changed && newIdx > 0 && stateMachine.States[newIdx] != null)
{
property.stringValue = stateMachine.States[newIdx].StateName;
}

正在加载...
取消
保存