|
@@ -17,6 +17,7 @@ namespace KairoEngine.UI.Encyclopedia
|
|
|
public Transform menuContainer;
|
|
|
public Transform subMenuContainer;
|
|
|
public bool createOnStart = true;
|
|
|
+ public bool repopulateOnEnable = false;
|
|
|
public bool showDebug = false;
|
|
|
public List<EncyclopediaUiView> views;
|
|
|
private List<SelectedButton> menuButtonSelection;
|
|
@@ -34,10 +35,10 @@ namespace KairoEngine.UI.Encyclopedia
|
|
|
if(createOnStart) Populate();
|
|
|
}
|
|
|
|
|
|
- private void Update()
|
|
|
+ private void OnEnable()
|
|
|
{
|
|
|
-
|
|
|
- }
|
|
|
+ if(repopulateOnEnable) Populate();
|
|
|
+ }
|
|
|
|
|
|
[Button("Show Submenu"), ButtonGroup("EditorActions")]
|
|
|
public void ShowSubmenu() => subMenuGameObject.SetActive(true);
|