//-----------------------------------------------------------------------

    /*!
     *  @brief		単発アクション[初回]があるか確認
     */
    //-----------------------------------------------------------------------
    public MasterDataEnemyActionParam GetActionFirstAttack()
    {
        if (m_BattleEnemy == null)
        {
            return(null);
        }


        MasterDataParamEnemy enemyParam = m_BattleEnemy.getMasterDataParamEnemy();

        if (enemyParam == null)
        {
            return(null);
        }


        //--------------------------------
        //	指定フェイズにアクションが設定されているか
        //--------------------------------
        if (enemyParam.act_first == 0)
        {
            return(null);
        }

        //		return MasterDataUtil.GetMasterDataEnemyActionParam( enemyParam.act_first );
        return(BattleParam.m_MasterDataCache.useEnemyActionParam((uint)enemyParam.act_first));
    }
Exemple #2
0
    public static void outputEnemyParty(BattleEnemy[] enemy_party)
    {
        for (int idx_enemy = 0; idx_enemy < enemy_party.Length; idx_enemy++)
        {
            BattleEnemy battle_enemy = enemy_party[idx_enemy];
            DebugBattleLog.writeText(DebugBattleLog.StrOpe + "敵情報(" + idx_enemy.ToString() + ")"
                                     + " EnemyFixID:" + battle_enemy.getMasterDataParamEnemy().fix_id.ToString()
                                     + " CharaFixID:" + battle_enemy.getMasterDataParamChara().fix_id.ToString()
                                     + " 属性:" + battle_enemy.getMasterDataParamChara().element.ToString()
                                     + " 種族1:" + battle_enemy.getMasterDataParamChara().kind.ToString()
                                     + " 種族2:" + battle_enemy.getMasterDataParamChara().sub_kind.ToString()
                                     + " [" + battle_enemy.getMasterDataParamChara().name + "]"
                                     );

            uint[] enemy_abilitys = battle_enemy.getEnemyAbilitys();
            for (int idx_ability = 0; idx_ability < enemy_abilitys.Length; idx_ability++)
            {
                uint ability_fix_id = enemy_abilitys[idx_ability];
                if (ability_fix_id != 0)
                {
                    string ability_name = "";
                    MasterDataEnemyAbility ability_master = BattleParam.m_MasterDataCache.useEnemyAbility(ability_fix_id);
                    if (ability_master != null)
                    {
                        ability_name = ability_master.name;
                    }
                    DebugBattleLog.writeText(DebugBattleLog.StrOpe + "     特性" + (idx_ability + 1).ToString()
                                             + "(FixId:" + ability_fix_id.ToString() + "):"
                                             + ability_name
                                             );
                }
            }

            DebugBattleLog.writeText(DebugBattleLog.StrOpe + "  "
                                     + " HP:" + battle_enemy.m_EnemyHP.ToString() + "/" + battle_enemy.m_EnemyHPMax.ToString()
                                     + " SkillTurn:" + battle_enemy.m_EnemyTurn.ToString() + "/" + battle_enemy.m_EnemyTurnMax.ToString()
                                     );

            // 状態変化
            StatusAilmentChara ailment = battle_enemy.m_StatusAilmentChara;
            outputAilment(ailment);
        }
    }
Exemple #3
0
    private void setInfoToWorkMaster()
    {
        m_CallCount++;
        if (m_CurrentBattleEnemy != null && m_CurrentEnemyDispInfo != null)
        {
            MasterDataParamEnemy enemy_master = m_CurrentBattleEnemy.getMasterDataParamEnemy(); // このBattleEnemyの敵マスターは一時コピーなので書き換えてOK.

            enemy_master.pos_absolute = (m_CurrentEnemyDispInfo.m_IsUsePosition ? MasterDataDefineLabel.BoolType.ENABLE : MasterDataDefineLabel.BoolType.NONE);
            enemy_master.posx_offset  = m_CurrentEnemyDispInfo.m_PositionX;
            enemy_master.posy_offset  = m_CurrentEnemyDispInfo.m_PositionY;

            enemy_master.hp_gauge_type  = m_CurrentEnemyDispInfo.m_HpGaugeType;
            enemy_master.hp_posx_offset = m_CurrentEnemyDispInfo.m_HpGaugeX;
            enemy_master.hp_posy_offset = m_CurrentEnemyDispInfo.m_HpGaugeY;

            enemy_master.target_pos_absolute = (m_CurrentEnemyDispInfo.m_IsUseTargetPosition ? (int)MasterDataDefineLabel.BoolType.ENABLE : (int)MasterDataDefineLabel.BoolType.NONE);
            enemy_master.target_posx_offset  = m_CurrentEnemyDispInfo.m_TargetX;
            enemy_master.target_posy_offset  = m_CurrentEnemyDispInfo.m_TargetY;
        }
        m_CallCount--;
    }
    public void setupEnemyAbilityInfo(BattleEnemy enemy)
    {
        //--------------------------------
        // エネミーマスターを取得
        //--------------------------------
        MasterDataParamEnemy enemyMaster = enemy.getMasterDataParamEnemy();

        if (enemyMaster == null)
        {
            return;
        }

        AddAbilityInfo(GameTextUtil.GetText("battle_infotext2"), -1);

        // 特性を配列化
        uint[] enemyAbility        = enemy.getEnemyAbilitys();
        int[]  enemy_ability_turns = enemy.getEnemyAbilityTurns();

        //--------------------------------
        // 所持特性を全チェック
        //--------------------------------
        bool is_write = false;

        for (int num = 0; num < enemyAbility.Length; ++num)
        {
            if (enemyAbility[num] == 0)
            {
                continue;
            }

            // 特性マスターを取得
            MasterDataEnemyAbility abilityMaster = MasterDataUtil.GetEnemyAbilityParamFromID((int)enemyAbility[num]);
            if (abilityMaster == null)
            {
                continue;
            }

            // 表示文を取得
            int enemy_ability_turn = enemy_ability_turns[num];
            if (abilityMaster.name != "")
            {
                AddAbilityInfo(abilityMaster.name, enemy_ability_turn);
                enemy_ability_turn = 0;
            }

            if (abilityMaster.detail != "")
            {
                AddAbilityInfo(abilityMaster.detail, enemy_ability_turn);
            }

            is_write = true;
        }

        if (is_write)
        {
            // 何か敵特性があるときは、状態異常表示の前に空行がある
            AddAbilityInfo("", -1);
        }
        else
        {
            AddAbilityInfo("-", -1);
        }
    }