Esempio n. 1
0
        // Token: 0x06014CB0 RID: 85168 RVA: 0x00546774 File Offset: 0x00544974
        private void BuyEnergyUIController_OnUseEnergyMedicine()
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_BuyEnergyUIController_OnUseEnergyMedicine_hotfix != null)
            {
                this.m_BuyEnergyUIController_OnUseEnergyMedicine_hotfix.call(new object[]
                {
                    this
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            ProjectLPlayerContext projectLPlayerContext = GameManager.Instance.PlayerContext as ProjectLPlayerContext;
            int num = projectLPlayerContext.CanUseEnergyMedicine(this.m_energyMedicineItemID, 1);

            if (num == 0)
            {
                this.StartUseEnergyMedicineNetTask();
            }
            else
            {
                CommonUIController.Instance.ShowErrorMessage(num, 2f, null, true);
            }
        }