private void UpdateInformation(int index)
    {
        var currentSoftwareArray = GlobalObjectManager.Instance.SoftwareFileController.CurrentSoftwareArray;
        int level = currentSoftwareArray[index].Level;

        m_UpgradeInformationName.text  = currentSoftwareArray[index].Software.name;
        m_UpgradeInformationLevel.text = level + "";
        if (level < 2)
        {
            m_UpgradeInformationPriceTitle.text = "下一等级";
            m_UpgradeInformationPrice.text      = "" + currentSoftwareArray[index].Software.UpgradeCost[level];
            m_ShrinkComponent.Recover(() => m_UpgradeButton.SetActive(true));
            m_UpgradeInformationPriceSign.SetActive(true);
        }
        else
        {
            m_UpgradeInformationPriceTitle.text = "最高等级";
            m_UpgradeInformationPrice.text      = "";
            m_UpgradeInformationPriceSign.SetActive(false);
            m_UpgradeButton.SetActive(false);
            m_ShrinkComponent.Shrink();
        }
        switch (level)
        {
        case 0: m_UpgradeInformationExplain.text = currentSoftwareArray[index].Software.Explain[0]; break;

        case 1: m_UpgradeInformationExplain.text = currentSoftwareArray[index].Software.UpgradeExplain; break;

        case 2: m_UpgradeInformationExplain.text = currentSoftwareArray[index].Software.Explain[1]; break;
        }
    }
Esempio n. 2
0
 private void Reset()
 {
     m_AcceptGameObject.SetActive(true);
     m_RefuseGameObject.SetActive(true);
     m_CloseGameObject.SetActive(false);
     m_ShrinkComponent.Recover();
     m_TipGameObject.SetActive(true);
 }