示例#1
0
    //------------------------------------------------------------------------

    /*!
     *  @brief		更新処理
     */
    //------------------------------------------------------------------------
    void Update()
    {
        switch (m_TargetWindowStep)
        {
        case eTargetWindowStep.OPEN_INIT:
        {
            if (unitAilmentPanel.Ailment_obj_list.Count >= 2)
            {
                unitAilmentPanel.setupCharaAilmentInfo(BattleParam.m_EnemyParam[BattleParam.m_TargetEnemyWindow].m_StatusAilmentChara);
                m_TargetWindowStep = eTargetWindowStep.OPEN;
            }
        }
        break;

        case eTargetWindowStep.OPEN:
        {
            Window_y -= (3840 * Time.deltaTime);
            if (Window_y <= 0)
            {
                Window_y           = 0;
                m_TargetWindowStep = eTargetWindowStep.NONE;
            }
        }
        break;

        case eTargetWindowStep.CLOSE:
        {
            Window_y += (3840 * Time.deltaTime);
            if (Window_y >= 960)
            {
                m_TargetWindowStep = eTargetWindowStep.NONE;
                m_Close            = true;
                Destroy(this.gameObject);
            }
        }
        break;

        default:
            break;
        }
    }
    //------------------------------------------------------------------------

    /*!
     *      @brief		更新処理
     */
    //------------------------------------------------------------------------
    private void initPanel()
    {
        if (m_CharaIdx == GlobalDefine.PartyCharaIndex.ERROR)
        {
            return;
        }
        PacketStructUnit _unit     = null;
        PacketStructUnit _linkunit = null;
        {
            _unit               = new PacketStructUnit();
            _unit.id            = m_CharaId;
            _unit.level         = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaLevel;
            _unit.unique_id     = 1;         // ダミー
            _unit.add_pow       = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaPlusPow;
            _unit.add_def       = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaPlusDef;
            _unit.add_hp        = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaPlusHP;
            _unit.limitbreak_lv = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaLBSLv;
            _unit.limitover_lv  = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaLimitOver;
            _unit.link_info     = (uint)ServerDataDefine.CHARALINK_TYPE.CHARALINK_TYPE_NONE;
            if (InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaID != 0)
            {
                _unit.link_info        = (uint)ServerDataDefine.CHARALINK_TYPE.CHARALINK_TYPE_BASE;
                _linkunit              = new PacketStructUnit();
                _linkunit.id           = InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaID;
                _linkunit.level        = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaLv;
                _linkunit.add_pow      = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaPlusPow;
                _linkunit.add_hp       = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaPlusHP;
                _unit.link_point       = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaLinkPoint;
                _linkunit.limitover_lv = (uint)InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_LinkParam.m_CharaLOLevel;
                _linkunit.link_info    = (uint)ServerDataDefine.CHARALINK_TYPE.CHARALINK_TYPE_LINK;
            }
        }
        MasterDataParamChara _master = InGamePlayerParty.m_PlayerPartyChara[(int)m_CharaIdx].m_CharaMasterDataParam;

        // 名前パネル設定
        unitNamePanel.setup(_master);
        unitNamePanel.IsViewPremiumButton = false;

        // スキルパネル設定
        unitSkillPanel.AllClear();
        unitSkillPanel.AddLeaderSkill(_master.skill_leader);
        unitSkillPanel.AddLimitBreakSkill(_master.skill_limitbreak, (int)_unit.limitbreak_lv);
        unitSkillPanel.AddActiveSkill(_master.skill_active0);
        if (_master.skill_passive == 0)
        {
            unitSkillPanel.AddActiveSkill(_master.skill_active1);
        }
        if (_master.skill_passive != 0)
        {
            unitSkillPanel.AddPassiveSkill(_master.skill_passive);
        }

        // ステータスパネル設定
        CharaParty party      = BattleParam.m_PlayerParty;
        CharaOnce  party_unit = party.getPartyMember(m_CharaIdx, CharaParty.CharaCondition.EXIST);
        int        pow        = (int)((float)party_unit.m_CharaPow * InGameUtil.getCharaAttakPowScale(party_unit, BattleParam.m_PlayerParty.m_Ailments.getAilment(m_CharaIdx)));

        unitParamPanel.setupUnit(_unit, _linkunit, false, party.m_HPCurrent.getValue(m_CharaIdx), party.m_HPMax.getValue(m_CharaIdx), pow);
        unitParamPanel.IsViewExp = false;

        if (_linkunit != null)
        {
            // リンクパネル設定
            unitLinkPanel.setupUnit(_unit, _linkunit, UnitLinkPanel.LinkParamType.Link);
            skillWindowTag.Link_tag_active = true;
        }
        else
        {
            skillWindowTag.Link_tag_active = false;
        }

        // 状態異常パネル設定
        unitAilmentPanel.AllClear();
        unitAilmentPanel.setupCharaAilmentInfo(SceneModeContinuousBattle.Instance.m_PlayerParty.m_Ailments.getAilment(m_CharaIdx));

        UnityUtil.SetObjectEnabledOnce(heroDetailPanel.gameObject, false);

        Label_text = GameTextUtil.GetText("battle_infotext3");
    }