Exemplo n.º 1
0
 public void set(BattleReward.RewardType rewardType, int amount, string rewardName = "")
 {
     this.rewardType = rewardType;
     this.amount     = amount;
     this.rewardName = rewardName;
     amountText.text = amount.ToString();
 }
Exemplo n.º 2
0
    public void addReward(BattleReward.RewardType rewardType, int amount, string rewardName = "")
    {
        BattleReward createdChild = Instantiate <BattleReward>(prefab, contentsArea.transform);

        createdChild.set(rewardType, amount, rewardName);
        rewards.Add(createdChild);
    }