31 lines
727 B
C#
31 lines
727 B
C#
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
public class RentierItem : MonoBehaviour
|
|
{
|
|
public int id = -1;
|
|
|
|
public Text moneyText;
|
|
|
|
public Text expText;
|
|
|
|
public Text questPointText;
|
|
|
|
public void RentierRewardButton()
|
|
{
|
|
GameManager.Instance._playerData.AddSubPlayerCashValue(GameManager.Instance.rentierRewards[id].cash);
|
|
GameManager.Instance._playerData.AddSubPlayerExp(GameManager.Instance.rentierRewards[id].exp);
|
|
GameManager.Instance._playerData.AddSubPlayerQuestPoints(GameManager.Instance.rentierRewards[id].questPoint);
|
|
Object.Destroy(base.gameObject);
|
|
}
|
|
|
|
public void DisableParentItem(GameObject g)
|
|
{
|
|
g.GetComponentInParent<Image>().gameObject.SetActive(value: false);
|
|
}
|
|
|
|
private void Start()
|
|
{
|
|
}
|
|
}
|