/// <summary> /// This Draws the right hand panel when the user is creating an item. /// The currentCategoryDataSet is populated before this is called. I don't think it's ideal to make this rely on a global variable but it's the most flexible way. /// </summary> void DrawRightHandCreateItemsPanel() { cName = EditorGUILayout.TextField("Item Name: ", cName); //have a loop to draw every variable we might have in the categories //==STRINGS== DrawCategoryDictionary(currentCategoryDataHolder.categoryStrings); //==FLOATS== DrawCategoryDictionary(currentCategoryDataHolder.categoryFloats); //==INTS== DrawCategoryDictionary(currentCategoryDataHolder.categoryInts); //==BOOLS== DrawCategoryDictionary(currentCategoryDataHolder.categoryBools); //==VECTOR3S== DrawCategoryDictionary(currentCategoryDataHolder.categoryVector3s); //!!!ADD ADDITIONAL VARIABLES HERE!!! if (GUILayout.Button("CreateTheItem")) { CreateItem.CreateItemScript(cName, currentCategoryDataHolder, currentCategory.name); SwitchRightPanel(RightPanelState.showItems, false, true); } }