public void ShowBig(CatItem catItem) { if (catItem.type.onFreeFX != null) { bigCatSlot.Init(catItem, сatItemView => { Instantiate(сatItemView.catItem.type.onFreeFX, bigCatSlot.itemView.catButton.transform.position, Quaternion.identity); }); } else { bigCatSlot.Init(catItem); } bigNameText.text = catItem.type.localizedName; bigLevelText.text = catItem.level.ToString(); if (catItem.isMaxLevel) { bigExpSliderBack.SetActive(false); maximum.SetActive(true); } else { maximum.SetActive(false); bigExpSliderBack.SetActive(true); bigExpSlider.fillAmount = (float)catItem.exp / (float)balance.catLevelsExp[catItem.level - 1]; } bigDescriptionText.text = catItem.localizedDescription; bigCoinCost.text = catItem.cost.ToString(); }
public override void Init() { levelUpCatText.text = Localization.Get("levelUpCat", user.lastGetCat.type.localizedName); catSlot.Init(user.lastGetCat); levelText.text = (user.lastGetCat.level - 1).ToString(); StartCoroutine(LevelUp()); }
public void Init(CatItem catItem) { catItem.expGame = (int)(catItem.expGame * achievements.moreExpCat * balance.expMultiplier); if (gameplay.boosts.experience.ON) { catItem.expGame *= gameplay.boosts.experience.power; } catSlot.Init(catItem); nameText.text = catItem.type.localizedName; levelText.text = catItem.level.ToString(); StartCoroutine(ShowGettingExp(catItem.level, catItem.type.levelPower.Length, catItem.exp, catItem.expGame)); GetExp(catItem); }