Inheritance: BaseScreenItem
		void Awake()
		{
			highlighter = GetComponent<Highlighter>();

            if(IconPos != null)
            {
                Icon = HUDIcon.Create(HUDIconType.Exploration);
                Icon.CallbackClick = OnIconClick;
                Icon.gameObject.SetActive(false);
            }
		}
 public void ChangeIcon(int skillNum)
 {
     if (!allIcons[skillNum].gameObject.activeInHierarchy)
     {
         return;
     }
     currentIcon.TurnOff();
     currentNum  = skillNum;
     currentIcon = allIcons[currentNum];
     currentIcon.TurnOn();
 }
Beispiel #3
0
	public static void Recycle(HUDIcon icon)
	{
		if (icon != null)
		{
			icon.CallbackClick = null;
            PopupManager.Instance.RemoveItem(icon.gameObject);
		}
		else
		{
			BaseLogger.Log("Recyle a null NPCIcon!");
		}
	}
Beispiel #4
0
	void Awake()
	{
        Icon = HUDIcon.Create(HUDIconType.NPC);
		Icon.CallbackClick = OnIconClick;
		Icon.gameObject.SetActive(false);
	}
 private void Start()
 {
     currentIcon = allIcons[0];
     currentNum  = 0;
 }