_TheStrongestSnail/TheStrongestSnail/Assets/Scripts/kuangChang10/NewkuangchangItem.cs

30 lines
734 B
C#
Raw Normal View History

2024-12-05 15:49:54 +08:00
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using TMPro;
using UnityEngine.UI;
public class NewkuangchangItem : MonoBehaviour
{
// Start is called before the first frame update
public MiningContract miningContract;
public TextMeshProUGUI count;
public Button BuyButton;
void Start()
{
BuyButton.onClick.AddListener(BuyItem);
}
async void BuyItem()
{
buyMiningContract103 buyMiningContract = new buyMiningContract103();
bool isBuySucceed = await buyMiningContract.BuyMiningContract((long)miningContract.voluteCoinBuy);
Debug.Log(isBuySucceed);
}
// Update is called once per frame
void Update()
{
}
}