Trade Menu Spreadsheet

Implemented generic spreadsheet component for the Trade menu with sortable and resizable data columns
This commit is contained in:
Reinier Vens 2021-01-14 03:20:27 +00:00
commit 8036585ebc
46 changed files with 21429 additions and 17151 deletions

View file

@ -9,6 +9,7 @@ using UnityEngine;
public class MenuPanel : MonoBehaviour
{
public ActionGameManager GameManager;
public RectTransform TabButtons;
public Color ActiveTabColor;
public Color InactiveTabColor;
@ -40,7 +41,15 @@ public class MenuPanel : MonoBehaviour
TabChanged?.Invoke(tab);
}
private void OnEnable()
{
foreach (var tabButton in _tabs.Values)
{
tabButton.gameObject.SetActive(!tabButton.RequireParent || GameManager.CurrentShip.Parent != null);
}
}
void Awake()
{
foreach (var tabButton in TabButtons.GetComponentsInChildren<MenuTabButton>())
@ -57,5 +66,6 @@ public class MenuPanel : MonoBehaviour
public enum MenuTab
{
Map,
Inventory
Inventory,
Trade
}