- Home /
Create a custom editor window with repeating subsection (mockup included)
I'm making a game that uses a variety of self-learning units. There are tons of parameters to tweak which produce different behaviours. I want to make a custom editor window that allows me to easily adjust the number of units being trained and easily look at the parameters of each.
Here's what I currently have. This is just created using EditorGUILayout. Note that this would only allow me to spawn and adjust one unit.
What I want is for the above to behave a little like an array does in the inspector, i.e. a "size" box which creates a number of identical but unique boxes like the above, which I can then scroll through. Here's a mockup:
Maybe I could achieve this by making a simple serializable class for storing all the data and then just have an array of instances of that class? But then how would I make it show up in the window with the correct layout?
Thanks.
Your answer
Follow this Question
Related Questions
Too much space between EditorGUILayout.SelectableLabel 2 Answers
why I Cant Add Multiple Objects to the "Object Field" in Editor Window? 3 Answers
Custom Editor - Is there any way to detect whether the user is in Prefab editing mode? 1 Answer
Unity editor extension - create drag and drop (similar to Buildbox) 1 Answer
How to update a EditorGUILayout Textfield value in realtime? 0 Answers