25 lines
543 B
C#
25 lines
543 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public class CraftStation : MonoBehaviour
|
|
{
|
|
private void OnTriggerStay2D(Collider2D other)
|
|
{
|
|
if (other.tag == "Player")
|
|
{
|
|
//ui enable
|
|
// other.GetComponent<CraftManager>().ShowCraftUI(this);
|
|
}
|
|
}
|
|
|
|
private void OnTriggerExit2D(Collider2D other)
|
|
{
|
|
if (other.tag == "Player")
|
|
{
|
|
//ui disable
|
|
other.GetComponent<CraftManager>().HideCraftUI();
|
|
}
|
|
}
|
|
}
|