- Home /
[INSPECTOR ARRAY] Replace 'Element 0' by 'Map 0' with auto increase
Hello, I have searched a lot about changing the label 'Element 0' in the array in the inspector, and i have successfully changed it, but in another case it cannot be changed. see the photo and the code.
and thats my code https://pastebin.com/bK531CS1
and thats the photo which my code do, work with just 2 array, and gives errors with the other 2 array, i think because they in another class with Mono Beauvoir or it needs some edit, i really don't know!
EDIT:
with a lot of updates and edits, i have successfully made what i want to make but need just one edit, see the photo- i just want to put the 'Material 1, Material 2' in the 'Map *' array
and thats the inspector code
public override void OnInspectorGUI() {
ShowArrayProperty_MapMainObject(serializedObject.FindProperty("MaterialMainObject"));
ShowArrayProperty_MAP(serializedObject.FindProperty("ListOfMaterials.Array.data[0].Maps"));
for(int i = 0; i < MapManager.NODays; i++) {
ShowArrayProperty_MAT(serializedObject.FindProperty("ListOfMaterials.Array.data[0].Maps.Array.data[" + i + "].Materials")); //HERE THE CODE I WANT TO EDIT TO MAKE IT INSIDE THE MAP
}
}
I want some help, please. Thanks in advance.
Your answer
Follow this Question
Related Questions
Add elements to array/list in inspector? 1 Answer
How to get a List of Color Arrays? 2 Answers
A node in a childnode? 1 Answer
Is it possible to drag/drop/increment into editor array? 1 Answer
Inspector issue 1 Answer