- Refactor items from predefined scriptables only, to template based into item instances - Added equipped item tooltip to facilitate comparing items - Added modular craftable items
25 lines
658 B
C#
25 lines
658 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public class TooltipDisabler : MonoBehaviour
|
|
{
|
|
[SerializeField] private GameObject itemTooltip;
|
|
[SerializeField] private GameObject equippedItemTooltip;
|
|
[SerializeField] private GameObject statTooltip;
|
|
|
|
[SerializeField] private UIKeyBinder keyBinder;
|
|
|
|
private void Awake()
|
|
{
|
|
keyBinder.OnUIVisibilityChanged.AddListener((isVisible) =>
|
|
{
|
|
if (isVisible) return;
|
|
|
|
itemTooltip.SetActive(isVisible);
|
|
statTooltip.SetActive(isVisible);
|
|
equippedItemTooltip.SetActive(isVisible);
|
|
});
|
|
}
|
|
}
|