mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
Simplify object initialization
This commit is contained in:
parent
d2eac37aa9
commit
efac99813c
@ -27,15 +27,16 @@ protected void Init()
|
||||
|
||||
spawnListProperty = serializedObject.FindProperty("spawnPrefabs");
|
||||
|
||||
spawnList = new ReorderableList(serializedObject, spawnListProperty);
|
||||
spawnList.drawHeaderCallback = DrawHeader;
|
||||
spawnList.drawElementCallback = DrawChild;
|
||||
spawnList.onReorderCallback = Changed;
|
||||
spawnList.onRemoveCallback = RemoveButton;
|
||||
spawnList.onChangedCallback = Changed;
|
||||
spawnList.onReorderCallback = Changed;
|
||||
spawnList.onAddCallback = AddButton;
|
||||
spawnList.elementHeight = 16; // this uses a 16x16 icon. other sizes make it stretch.
|
||||
spawnList = new ReorderableList(serializedObject, spawnListProperty)
|
||||
{
|
||||
drawHeaderCallback = DrawHeader,
|
||||
drawElementCallback = DrawChild,
|
||||
onReorderCallback = Changed,
|
||||
onRemoveCallback = RemoveButton,
|
||||
onChangedCallback = Changed,
|
||||
onAddCallback = AddButton,
|
||||
elementHeight = 16 // this uses a 16x16 icon. other sizes make it stretch.
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user