private static SkillTexture DoFsmTexturePopup(GUIContent label, Skill fsm, SkillTexture fsmObject) { ActionEditor.DoVariableSelector(label, fsm, 10, fsmObject, -1, null); fsmObject.set_UseVariable(true); return(fsmObject); }
private static SkillObject DoFsmObjectPopup(GUIContent label, Skill fsm, SkillObject fsmObject, Type objectType) { ActionEditor.DoVariableSelector(label, fsm, 12, fsmObject, 12, objectType); fsmObject.set_UseVariable(true); return(fsmObject); }
private static SkillMaterial DoFsmMaterialPopup(GUIContent label, Skill fsm, SkillMaterial fsmObject) { ActionEditor.DoVariableSelector(label, fsm, 9, fsmObject, -1, null); fsmObject.set_UseVariable(true); return(fsmObject); }
private static SkillColor DoFsmColorPopup(GUIContent label, Skill fsm, SkillColor fsmColor) { ActionEditor.DoVariableSelector(label, fsm, 7, fsmColor, -1, null); fsmColor.set_UseVariable(true); return(fsmColor); }
private static SkillGameObject DoFsmGameObjectPopup(GUIContent label, Skill fsm, SkillGameObject fsmGameObject) { ActionEditor.DoVariableSelector(label, fsm, 3, fsmGameObject, -1, null); fsmGameObject.set_UseVariable(true); return(fsmGameObject); }
private static SkillVector2 DoFsmVector2Popup(GUIContent label, Skill fsm, SkillVector2 fsmVector2) { ActionEditor.DoVariableSelector(label, fsm, 5, fsmVector2, -1, null); fsmVector2.set_UseVariable(true); return(fsmVector2); }
private static SkillVector3 DoFsmVector3Popup(GUIContent label, Skill fsm, SkillVector3 fsmVector3) { ActionEditor.DoVariableSelector(label, fsm, 6, fsmVector3, -1, null); fsmVector3.set_UseVariable(true); return(fsmVector3); }
public static SkillString FsmStringField(GUIContent label, Skill fsm, SkillString fsmString, object[] attributes) { if (fsmString.get_UseVariable()) { EditorGUILayout.BeginHorizontal(new GUILayoutOption[0]); fsmString = VariableEditor.DoFsmStringPopup(label, fsm, fsmString); } else { if (fsmString.get_Value() == null) { fsmString.set_Value(string.Empty); } EditorGUILayout.BeginHorizontal(new GUILayoutOption[0]); UIHint uIHint = CustomAttributeHelpers.GetUIHint(attributes); switch (uIHint) { case 1: { GUILayout.BeginVertical(new GUILayoutOption[0]); GUILayout.Label(label, new GUILayoutOption[0]); Rect rect = GUILayoutUtility.GetRect(SkillEditorContent.TempContent(fsmString.get_Value(), ""), SkillEditorStyles.TextArea, new GUILayoutOption[] { GUILayout.MinHeight(44f) }); rect.set_width(340f); fsmString.set_Value(EditorGUI.TextArea(rect, fsmString.get_Value())); GUILayout.EndVertical(); goto IL_363; } case 2: fsmString.set_Value(ActionEditor.EditComponentName(label, fsmString.get_Value(), typeof(Behaviour))); goto IL_363; case 3: fsmString.set_Value(ActionEditor.EditComponentName(label, fsmString.get_Value(), typeof(MonoBehaviour))); ActionEditor.TrySetBehaviourContext(fsmString.get_Value()); goto IL_363; case 4: fsmString.set_Value(ActionEditor.EditMethodName(label, fsmString.get_Value(), false)); goto IL_363; case 6: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.AnimationNamePopup(fsmString); goto IL_363; case 7: fsmString.set_Value(EditorGUILayout.TagField(label, fsmString.get_Value(), new GUILayoutOption[0])); goto IL_363; case 8: StringEditor.LayerNamePopup(label, fsmString, null, null); goto IL_363; case 11: { fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); EditorGUI.BeginChangeCheck(); string text = SkillEditorGUILayout.ScriptListPopup(); if (EditorGUI.EndChangeCheck() && text != "") { fsmString.set_Value(text); goto IL_363; } goto IL_363; } case 15: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.FsmNamePopup(fsmString); goto IL_363; case 16: fsmString.set_Value(ActionEditor.EditFsmEvent(label, fsmString.get_Value())); goto IL_363; case 17: case 18: case 19: case 20: case 21: case 22: case 23: case 24: case 25: case 26: case 27: case 28: case 29: case 30: case 31: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.VariablePopup(fsmString, uIHint); goto IL_363; case 32: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.AnimatorFloatPopup(fsmString); goto IL_363; case 33: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.AnimatorBoolPopup(fsmString); goto IL_363; case 34: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.AnimatorIntPopup(fsmString); goto IL_363; case 35: fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); ActionEditor.AnimatorTriggerPopup(fsmString); goto IL_363; case 36: StringEditor.SortingLayerNamePopup(label, fsmString, null, null); goto IL_363; } fsmString.set_Value(EditorGUILayout.TextField(label, fsmString.get_Value(), new GUILayoutOption[0])); } IL_363: fsmString = (SkillString)VariableEditor.VariableToggle(fsmString, label.get_text()); VariableEditor.EndVariableEditor(fsmString); return(fsmString); }
private static SkillQuaternion DoFsmQuaternionPopup(GUIContent label, Skill fsm, SkillQuaternion fsmQauternion) { ActionEditor.DoVariableSelector(label, fsm, 11, fsmQauternion, -1, null); fsmQauternion.set_UseVariable(true); return(fsmQauternion); }
private static SkillString DoFsmStringPopup(GUIContent label, Skill fsm, SkillString fsmString) { ActionEditor.DoVariableSelector(label, fsm, 4, fsmString, -1, null); fsmString.set_UseVariable(true); return(fsmString); }
private static SkillBool DoFsmBoolPopup(GUIContent label, Skill fsm, SkillBool fsmBool) { ActionEditor.DoVariableSelector(label, fsm, 2, fsmBool, -1, null); fsmBool.set_UseVariable(true); return(fsmBool); }
private static SkillInt DoFsmIntPopup(GUIContent label, Skill fsm, SkillInt fsmInt) { ActionEditor.DoVariableSelector(label, fsm, 1, fsmInt, -1, null); fsmInt.set_UseVariable(true); return(fsmInt); }
public ActionEditor addAction() { actionCreator = new ActionEditor(this); return(actionCreator); }
public void OnDestroy() { ActionEditor._instance = null; }