public EditSkillModel(ISkillData skillData, IHtmlHelper htmlHelper, IFileUploader fileUploader, ISkillPathData skillPathData)
 {
     _skillData     = skillData;
     _htmlHelper    = htmlHelper;
     _fileUploader  = fileUploader;
     _skillPathData = skillPathData;
 }
    public void SkillSwap(int changeNumber, int baseNumber)
    {
        ISkillData temp = skillDatas_[baseNumber];

        skillDatas_[baseNumber]   = skillDatas_[changeNumber];
        skillDatas_[changeNumber] = temp;
    }
Пример #3
0
    public void SkillInfoReflect(ISkillData referSkillData)
    {
        //string playPointContext = t13.Utility.HarfSizeForFullSize(referSkillData.nowPlayPoint_.ToString()) + "/" + t13.Utility.HarfSizeForFullSize(referSkillData.playPoint_.ToString());

        texts_[0].text =
            //"PP    " + playPointContext + "\n"
            "わざタイプ/" + referSkillData.elementType_.GetName() + "\n"
            + "いりょく  " + t13.Utility.HarfSizeForFullSize(referSkillData.effectValue_.ToString()) + "\n"
            + "めいちゅう " + t13.Utility.HarfSizeForFullSize(referSkillData.successRateValue_.ToString()) + "\n"
            //+ "アップ" + t13.Utility.HarfSizeForFullSize("DP") + " " + t13.Utility.HarfSizeForFullSize(referSkillData.upDpValue_.ToString())
        ;

        texts_[1].text = referSkillData.effectInfo_;
    }
 public SkillsMainModel(ISkillData skillData)
 {
     _skillData = skillData;
 }
Пример #5
0
 public SkillDetailModel(ISkillData skillData, ICertificateData certificateData)
 {
     _skillData       = skillData;
     _certificateData = certificateData;
 }
        public void PopulateSkillsDropDownList(ISkillData _skillData, object selectedSkill = null)
        {
            var skillslist = _skillData.GetAllSkills();

            SkillsSelectList = new SelectList(skillslist, "Id", "SkillName", selectedSkill);
        }
    public IProcessState Update(BattleManager mgr)
    {
        AllSceneManager allSceneMgr = AllSceneManager.GetInstance();

        //敵の思考時間の処理
        EnemyBattleData.GetInstance().ThinkingTimeCounter();

        //モンスターが交換されていたら
        if (PlayerBattleData.GetInstance().changeMonsterActive_ == true)
        {
            if (PlayerBattleData.GetInstance().changeMonsterNumber_ > 0)
            {
                //アイドル状態の停止
                mgr.GetPlayerStatusInfoParts().ProcessIdleEnd();
                mgr.GetPlayerMonsterParts().ProcessIdleEnd();

                //ウィンドウの表示
                mgr.GetNovelWindowParts().gameObject.SetActive(true);

                //イベントの最後
                AllEventManager.GetInstance().EventFinishSet();

                return(new EnemyCommandSelectProcess());
            }
            else
            {
                allSceneMgr.inputProvider_ = new InactiveInputProvider();

                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

                AllEventManager.GetInstance().UpdateGameObjectSet(mgr.GetCommandCommandParts().GetEventGameObject());
                AllEventManager.GetInstance().UpdateGameObjectsActiveSetExecute(true);

                //dpが100以上だったら
                //if (PlayerBattleData.GetInstance().GetDreamPoint() >= 100) {
                //	AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText()
                //		, "ゆめたちが \n"
                //		+ "きょうめいしている・・・");
                //	AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                //	AllEventManager.GetInstance().AllUpdateEventExecute();
                //}
                //else {
                //	AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), PlayerBattleData.GetInstance().GetMonsterDatas(0).uniqueName_ + "は どうする?");
                //	AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                //	AllEventManager.GetInstance().AllUpdateEventExecute();
                //}

                AllEventManager.GetInstance().EventStatusInfoPartsSet(mgr.GetPlayerStatusInfoParts(), new Color32(0, 0, 0, 0));
                AllEventManager.GetInstance().StatusInfoPartsUpdateExecuteSet(StatusInfoPartsEventManagerExecute.IdleMoveStart);
                AllEventManager.GetInstance().AllUpdateEventExecute();

                AllEventManager.GetInstance().EventFinishSet();

                PlayerBattleData.GetInstance().changeMonsterActive_ = false;
            }
        }

        //やけどのダメージ処理
        if (mgr.BurnsDamageProcess(PlayerBattleData.GetInstance(), mgr.GetPlayerStatusInfoParts(), mgr.GetPlayerMonsterParts()))
        {
            return(new CommandEventExecuteProcess());
        }

        if (EnemyBattleData.GetInstance().GetThinkingEnd() == false)
        {
            //やけどのダメージ処理
            if (mgr.BurnsDamageProcess(EnemyBattleData.GetInstance(), mgr.GetEnemyStatusInfoParts(), mgr.GetEnemyMonsterParts()))
            {
                return(new CommandEventExecuteProcess());
            }

            if (EnemyBattleData.GetInstance().PoinsonCounter())
            {
                //どくのダメージ処理
                mgr.PoisonDamageProcess(EnemyBattleData.GetInstance(), mgr.GetEnemyStatusInfoParts(), mgr.GetEnemyMonsterParts());
                if (mgr.PoisonDamageDown())
                {
                    return(new CommandEventExecuteProcess());
                }
            }
        }

        //こんらんの処理
        mgr.ConfusionProcess();

        if (AllEventManager.GetInstance().EventUpdate())
        {
            allSceneMgr.inputProvider_ = new KeyBoardNormalTriggerInputProvider();
        }

        //カーソルが動いていたら
        int commandSelectNumber = mgr.GetAttackCommandParts().GetCommandParts().CommandSelectForNumber(new Vector3(3.56f, 0, 0), new Vector3(0, 1.42f, 0));

        if (commandSelectNumber > -1)
        {
            //SE
            mgr.GetInputSoundProvider().UpSelect();

            mgr.AttackCommandSkillInfoTextSet(mgr.GetAttackCommandParts().GetCommandParts().SelectNumber());

            //どくのダメージ処理
            mgr.PoisonDamageProcess(PlayerBattleData.GetInstance(), mgr.GetPlayerStatusInfoParts(), mgr.GetPlayerMonsterParts());
        }
        else if (allSceneMgr.inputProvider_.UpSelect())
        {
            //選択肢が動かせたら
            if (mgr.GetAttackCommandParts().GetCommandParts().CommandSelectUp(new Vector3(0, 1.42f, 0)))
            {
                //SE
                mgr.GetInputSoundProvider().UpSelect();

                mgr.AttackCommandSkillInfoTextSet(mgr.GetAttackCommandParts().GetCommandParts().SelectNumber());

                //どくのダメージ処理
                mgr.PoisonDamageProcess(PlayerBattleData.GetInstance(), mgr.GetPlayerStatusInfoParts(), mgr.GetPlayerMonsterParts());
            }
        }
        else if (allSceneMgr.inputProvider_.DownSelect())
        {
            //選択肢が動かせたら
            if (mgr.GetAttackCommandParts().GetCommandParts().CommandSelectDown(new Vector3(0, -1.42f, 0)))
            {
                //SE
                mgr.GetInputSoundProvider().DownSelect();

                mgr.AttackCommandSkillInfoTextSet(mgr.GetAttackCommandParts().GetCommandParts().SelectNumber());

                //どくのダメージ処理
                mgr.PoisonDamageProcess(PlayerBattleData.GetInstance(), mgr.GetPlayerStatusInfoParts(), mgr.GetPlayerMonsterParts());
            }
        }
        else if (allSceneMgr.inputProvider_.RightSelect())
        {
            //選択肢が動かせたら
            if (mgr.GetAttackCommandParts().GetCommandParts().CommandSelectRight(new Vector3(3.56f, 0, 0)))
            {
                //SE
                mgr.GetInputSoundProvider().RightSelect();

                mgr.AttackCommandSkillInfoTextSet(mgr.GetAttackCommandParts().GetCommandParts().SelectNumber());

                //どくのダメージ処理
                mgr.PoisonDamageProcess(PlayerBattleData.GetInstance(), mgr.GetPlayerStatusInfoParts(), mgr.GetPlayerMonsterParts());
            }
        }
        else if (allSceneMgr.inputProvider_.LeftSelect())
        {
            //選択肢が動かせたら
            if (mgr.GetAttackCommandParts().GetCommandParts().CommandSelectLeft(new Vector3(-3.56f, 0, 0)))
            {
                //SE
                mgr.GetInputSoundProvider().LeftSelect();

                mgr.AttackCommandSkillInfoTextSet(mgr.GetAttackCommandParts().GetCommandParts().SelectNumber());

                //どくのダメージ処理
                mgr.PoisonDamageProcess(PlayerBattleData.GetInstance(), mgr.GetPlayerStatusInfoParts(), mgr.GetPlayerMonsterParts());
            }
        }
        else if (allSceneMgr.inputProvider_.SelectEnter() ||
                 mgr.GetAttackCommandParts().GetCommandParts().MouseLeftButtonTriggerActive())
        {
            mgr.playerSelectSkillNumber_ = mgr.GetAttackCommandParts().GetCommandParts().SelectNumber();

            ISkillData playerSkillData = PlayerBattleData.GetInstance().GetMonsterDatas(0).GetSkillDatas(mgr.playerSelectSkillNumber_);

            //スキルがNoneでなかったら
            if (            //playerSkillData.nowPlayPoint_ > 0
                playerSkillData.skillNumber_ != (int)SkillDataNumber.None)
            {
                //SE
                mgr.GetInputSoundProvider().SelectEnter();

                mgr.GetPlayerStatusInfoParts().ProcessIdleEnd();
                mgr.GetPlayerMonsterParts().ProcessIdleEnd();

                allSceneMgr.inputProvider_ = new InactiveInputProvider();

                //コマンドUIの非表示
                mgr.InactiveUiAttackCommand();

                //ウィンドウの表示
                mgr.GetNovelWindowParts().gameObject.SetActive(true);

                //ppの消費
                //playerSkillData.nowPlayPoint_ -= 1;

                //イベントの最後
                AllEventManager.GetInstance().EventFinishSet();

                return(mgr.nowProcessState().NextProcess());
            }
        }
        else if (allSceneMgr.inputProvider_.SelectBack() ||
                 allSceneMgr.inputProvider_.SelectMouseRightTrigger())
        {
            //こんらん状態なら
            if (PlayerBattleData.GetInstance().GetMonsterDatas(0).battleData_.firstAbnormalState_.state_ == AbnormalType.Confusion ||
                PlayerBattleData.GetInstance().GetMonsterDatas(0).battleData_.secondAbnormalState_.state_ == AbnormalType.Confusion)
            {
                allSceneMgr.inputProvider_ = new KeyBoardNormalTriggerInputProvider();
            }

            mgr.InactiveUiAttackCommand();
            mgr.ActiveUiCommand();

            return(mgr.nowProcessState().BackProcess());
        }
        else if (allSceneMgr.inputProvider_.SelectNovelWindowActive())
        {
        }

        //どくで倒れたら
        if (mgr.PoisonDamageDown())
        {
            return(new CommandEventExecuteProcess());
        }

        return(this);
    }
Пример #8
0
 public override bool EffectValueEventSet(BattleManager mgr, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
 {
     return(base.EffectValueEventSet(mgr, attackTrainerBattleData, defenseTrainerBattleData, attackEffectParts, defenseEffectParts, defenseMonsterParts, attackStatusInfoParts, defenseStatusInfoParts, attackDreamPointInfoParts, defenseDreamPointInfoParts, attackMonsterData, attackSkillData, defenseMonsterData));
 }
    /// <summary>
    ///メイン計算式
    /// </summary>
    static public int BattleDamageCalculate(IMonsterData attackMonster, IMonsterData defenseMonster, ISkillData attackSkill)
    {
        //乱数の値
        float[] randomValue = new float[16] {
            0.85f, 0.86f, 0.87f, 0.88f, 0.89f,
            0.90f, 0.91f, 0.92f, 0.93f, 0.94f, 0.95f, 0.96f, 0.97f, 0.98f, 0.99f,
            1.00f,
        };

        //乱数
        float randomResult = randomValue[AllSceneManager.GetInstance().GetRandom().Next(0, 16)];

        //モンスターのタイプと技のタイプの一致か否か
        float typeMatch = 1;

        if (attackMonster.tribesData_.firstElement_.state_ == attackSkill.elementType_.state_ ||
            attackMonster.tribesData_.secondElement_.state_ == attackSkill.elementType_.state_)
        {
            typeMatch = 1.5f;
        }

        //敵モンスターと技のタイプ相性
        float typeSimillar = defenseMonster.ElementSimillarChecker(attackSkill.elementType_);

        //補正値の初期値 4096
        //技の最終威力
        int realSkillPower = (int)(attackSkill.effectValue_ * (4096 / 4096));

        //物理か特殊か
        //EffectAttackTypeState ea = attackSkill.effectValueType_.GetEffectAttackTypeState();

        //モンスターの最終攻撃力
        int realMonsterAttack = 0;
        {
            //if (ea.state_ == EffectAttackType.Normal) {
            //	realMonsterAttack = (int)(attackMonster.RealAttack() * attackMonster.battleData_.RealAttackParameterRank() * (4096 / 4096));
            //}
            realMonsterAttack = (int)(attackMonster.RealAttack() * attackMonster.battleData_.RealAttackParameterRank() * (4096 / 4096));
        }

        //敵モンスターの最終防御力
        int realMonsterDefense = 0;
        {
            //if (ea.state_ == EffectAttackType.Normal) {
            //	realMonsterDefense = (int)(defenseMonster.RealDefense() * defenseMonster.battleData_.RealDefenseParameterRank() * (4096 / 4096));
            //}
            realMonsterDefense = (int)(defenseMonster.RealDefense() * defenseMonster.battleData_.RealDefenseParameterRank() * (4096 / 4096));
        }

        //(((レベル×2/5+2)×威力×A/D)/50+2)
        //最終ダメージ
        int realDamage = (int)((((attackMonster.level_ * 2 / 5 + 2) * realSkillPower * realMonsterAttack / realMonsterDefense) / 50)
                               * randomResult * typeMatch * typeSimillar);

        return(realDamage);
    }
Пример #10
0
    public override bool EffectValueEventSet(BattleManager mgr, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
    {
        //技のアニメーション
        attackSkillData.EffectAnimetionEventSet(defenseEffectParts);
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        return(true);
    }
    private void AbnormalEventSet(BattleManager mgr, StatusInfoParts selfStatusInfoParts, StatusInfoParts otherStatusInfoParts, BTrainerBattleData selfTrainerBattleData, BTrainerBattleData otherTrainerBattleData, IMonsterData selfMonsterData, ISkillData skillData, IMonsterData otherMonsterData)
    {
        if (skillData.addSelfAbnormalStates_[0].state_ != AddAbnormalType.None)
        {
            if (skillData.addSelfAbnormalStates_.Count > 0)
            {
                //アニメーション
                AllEventManager.GetInstance().EventWaitSet(1.0f);
            }

            //自分への状態異常の処理
            for (int i = 0; i < skillData.addSelfAbnormalStates_.Count; ++i)
            {
                //能力変化の更新
                string abnormalStateContext = skillData.addSelfAbnormalStates_[i].AddAbnormalTypeExecute(selfMonsterData);

                //文字列のイベント
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), selfTrainerBattleData.GetUniqueTrainerName() + abnormalStateContext);
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }

            //状態異常のイベントのセット
            selfMonsterData.battleData_.AbnormalSetStatusInfoPartsEventSet(selfStatusInfoParts);

            //ねむりの処理の初期化
            mgr.SleepProcessStart();
            mgr.SleepUseStart(selfTrainerBattleData);

            //こんらんの状態の初期化
            mgr.ConfusionUseStart(selfTrainerBattleData);
        }

        if (skillData.addOtherAbnormalStates_[0].state_ != AddAbnormalType.None)
        {
            if (skillData.addOtherAbnormalStates_.Count > 0)
            {
                //アニメーション
                AllEventManager.GetInstance().EventWaitSet(1.0f);
            }

            //相手への状態異常の処理
            for (int i = 0; i < skillData.addOtherAbnormalStates_.Count; ++i)
            {
                //能力変化の更新
                string abnormalStateContext = skillData.addOtherAbnormalStates_[i].AddAbnormalTypeExecute(otherMonsterData);

                //文字列のイベント
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), abnormalStateContext);
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }

            //状態異常のイベントのセット
            otherMonsterData.battleData_.AbnormalSetStatusInfoPartsEventSet(otherStatusInfoParts);

            //ねむりの処理の初期化
            mgr.SleepProcessStart();
            mgr.SleepUseStart(otherTrainerBattleData);

            //こんらんの状態の初期化
            mgr.ConfusionUseStart(otherTrainerBattleData);
        }
    }
    private void ParameterRankEventSet(BattleManager mgr, BTrainerBattleData trainerBattleData, IMonsterData selfMonsterData, ISkillData skillData, IMonsterData otherMonsterData)
    {
        if (skillData.addSelfParameterRanks_[0].state_ != AddParameterRank.None)
        {
            if (skillData.addSelfParameterRanks_.Count > 0)
            {
                //アニメーション
                AllEventManager.GetInstance().EventWaitSet(1.0f);
            }

            //自分への能力変化の処理
            for (int i = 0; i < skillData.addSelfParameterRanks_.Count; ++i)
            {
                //能力変化の更新
                string parameterRankContext = skillData.addSelfParameterRanks_[i].AddParameterExecute(selfMonsterData);

                //文字列のイベント
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), trainerBattleData.GetUniqueTrainerName() + parameterRankContext);
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }
        }

        if (skillData.addOtherParameterRanks_[0].state_ != AddParameterRank.None)
        {
            if (skillData.addOtherParameterRanks_.Count > 0)
            {
                //アニメーション
                AllEventManager.GetInstance().EventWaitSet(1.0f);
            }

            //相手への能力変化の処理
            for (int i = 0; i < skillData.addOtherParameterRanks_.Count; ++i)
            {
                //能力変化の更新
                string parameterRankContext = skillData.addOtherParameterRanks_[i].AddParameterExecute(otherMonsterData);

                //文字列のイベント
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), parameterRankContext);
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }
        }
    }
    private void SkillResultSet(BattleManager mgr, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
    {
        //ダウンしていたら
        if (!attackMonsterData.battleActive_)
        {
            return;
        }

        //交換されていたら
        //if (attackTrainerBattleData.changeMonsterActive_) return;

        //ねむりターンの消費
        mgr.SleepProcessUse(attackTrainerBattleData, attackStatusInfoParts);

        //こんらんターンの消費
        mgr.ConfusionProcessUse(attackTrainerBattleData, attackStatusInfoParts);

        //文字列の設定
        string skillUseContext = attackTrainerBattleData.GetUniqueTrainerName() + attackMonsterData.uniqueName_ + "の\n"
                                 + attackSkillData.skillName_ + "!";

        AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), skillUseContext);
        AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
        AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //技のイベントの設定
        bool skillResult = attackSkillData.effectValueType_.EffectValueEventSet(
            mgr
            , attackTrainerBattleData
            , defenseTrainerBattleData
            , attackEffectParts
            , defenseEffectParts
            , defenseMonsterParts
            , attackStatusInfoParts
            , defenseStatusInfoParts
            , attackDreamPointInfoParts
            , defenseDreamPointInfoParts
            , attackMonsterData, attackSkillData, defenseMonsterData
            );

        //技が当たっていなかったら
        if (!skillResult)
        {
            return;
        }

        //追加効果の判定
        bool optionEffectTrigger = AllSceneManager.GetInstance().GetRandom().Next(0, 100) < attackSkillData.optionEffectTriggerRateValue_;

        //追加効果の処理
        if (optionEffectTrigger)
        {
            //能力変化の処理
            ParameterRankEventSet(
                mgr
                , attackTrainerBattleData
                , attackMonsterData, attackSkillData, defenseMonsterData
                );

            //状態異常の処理
            AbnormalEventSet(
                mgr
                , attackStatusInfoParts
                , defenseStatusInfoParts
                , attackTrainerBattleData
                , defenseTrainerBattleData
                , attackMonsterData, attackSkillData, defenseMonsterData);
        }

        if (defenseMonsterData.nowHitPoint_ <= 0)
        {
            //モンスターが倒れた時のイベント
            defenseTrainerBattleData.MonsterDownEventSet(mgr);

            AllEventManager.GetInstance().EventFinishSet();
        }
    }
    public IProcessState Update(BattleManager mgr)
    {
        ////DPの演出のイベント
        //mgr.PlayerEnemyStatusInfoPartsDPEffect();

        //ウィンドウの表示
        mgr.GetNovelWindowParts().gameObject.SetActive(true);

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //パワーアップしていたら
        if (PlayerBattleData.GetInstance().dreamSyncronize_ == true)
        {
            //dpの初期化
            PlayerBattleData.GetInstance().DreamPointReset();
            PlayerBattleData.GetInstance().dreamSyncronize_ = false;

            //ゆめの文字色の変更
            mgr.GetDreamCommandSprite().color = new Color32(255, 255, 255, 255);

            //DPの演出のイベント
            mgr.GetPlayerDreamPointInfoParts().DPEffectEventSet(PlayerBattleData.GetInstance().GetDreamPoint());

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

            //BGMの音量の減少
            AllEventManager.GetInstance().BGMAudioVolumeChangeEventSet(0.15f);

            //パワーアップの演出
            mgr.GetDreamEffectParts().DreamSyncronizeEventSet(PlayerBattleData.GetInstance().GetMonsterDatas(0), new Vector3(-13.0f, 0.8f, -1.0f), new Vector3(13.0f, 0.8f, -1.0f));

            //画像の変更
            {
                List <Sprite> sprites = new List <Sprite>();
                sprites.Add(PlayerBattleData.GetInstance().GetMonsterDatas(0).tribesData_.backDreamTex_);

                AllEventManager.GetInstance().EventSpriteRendererSet(mgr.GetPlayerMonsterParts().GetEventMonsterSprite(), sprites);
                AllEventManager.GetInstance().EventSpriteRenderersUpdateExecuteSet(EventSpriteRendererEventManagerExecute.SpriteSet);
                AllEventManager.GetInstance().AllUpdateEventExecute();
            }

            //BGMの変更
            AllEventManager.GetInstance().BGMAudioClipChangeEventSet(ResourcesSoundsLoader.GetInstance().GetSounds(SoundsPathSupervisor.GetInstance().GetPathDreamers_Rock()));

            //BGMの再生
            AllEventManager.GetInstance().BGMAudioVolumeChangeEventSet(0.3f);
            AllEventManager.GetInstance().BGMAudioPlayEventSet();

            //能力変化の更新
            string abnormalStateContext = new AddAbnormalTypeState(AddAbnormalType.Hero).AddAbnormalTypeExecute(PlayerBattleData.GetInstance().GetMonsterDatas(0));

            //文字列のイベント
            AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), abnormalStateContext);
            AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
            AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

            //状態異常のイベントのセット
            PlayerBattleData.GetInstance().GetMonsterDatas(0).battleData_.AbnormalSetStatusInfoPartsEventSet(mgr.GetPlayerStatusInfoParts());

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

            //ねむりの終了処理
            mgr.SleepProcessEnd();

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
        }

        //パワーアップしていたら
        if (EnemyBattleData.GetInstance().dreamSyncronize_ == true)
        {
            //dpの初期化
            EnemyBattleData.GetInstance().DreamPointReset();
            EnemyBattleData.GetInstance().dreamSyncronize_ = false;

            //DPの演出のイベント
            mgr.GetEnemyDreamPointInfoParts().DPEffectEventSet(EnemyBattleData.GetInstance().GetDreamPoint());

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

            //BGMの音量の減少
            AllEventManager.GetInstance().BGMAudioVolumeChangeEventSet(0.15f);

            //パワーアップの演出
            mgr.GetDreamEffectParts().DreamSyncronizeEventSet(EnemyBattleData.GetInstance().GetMonsterDatas(0), new Vector3(13.0f, 0.8f, -1.0f), new Vector3(-13.0f, 0.8f, -1.0f));

            //画像の変更
            {
                List <Sprite> sprites = new List <Sprite>();
                sprites.Add(EnemyBattleData.GetInstance().GetMonsterDatas(0).tribesData_.frontDreamTex_);

                AllEventManager.GetInstance().EventSpriteRendererSet(mgr.GetEnemyMonsterParts().GetEventMonsterSprite(), sprites);
                AllEventManager.GetInstance().EventSpriteRenderersUpdateExecuteSet(EventSpriteRendererEventManagerExecute.SpriteSet);
                AllEventManager.GetInstance().AllUpdateEventExecute();
            }

            //BGMの再生
            AllEventManager.GetInstance().BGMAudioVolumeChangeEventSet(0.3f);

            //能力変化の更新
            string abnormalStateContext = new AddAbnormalTypeState(AddAbnormalType.Hero).AddAbnormalTypeExecute(EnemyBattleData.GetInstance().GetMonsterDatas(0));

            //文字列のイベント
            AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), abnormalStateContext);
            AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
            AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

            //状態異常のイベントのセット
            EnemyBattleData.GetInstance().GetMonsterDatas(0).battleData_.AbnormalSetStatusInfoPartsEventSet(mgr.GetEnemyStatusInfoParts());

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
        }

        //交換されていたら
        if (PlayerBattleData.GetInstance().changeMonsterActive_ == true)
        {
            PlayerBattleData.GetInstance().MonsterChangeEventSet(mgr);
        }

        //交換されていたら
        if (EnemyBattleData.GetInstance().changeMonsterActive_ == true)
        {
            EnemyBattleData.GetInstance().MonsterChangeEventSet(mgr);
        }

        //現在、場に出ているモンスターのデータの取得
        IMonsterData enemyMonsterData  = EnemyBattleData.GetInstance().GetMonsterDatas(0);
        IMonsterData playerMonsterData = PlayerBattleData.GetInstance().GetMonsterDatas(0);

        //現在、場に出ているモンスターの選択技のデータの取得
        ISkillData enemySkillData  = enemyMonsterData.GetSkillDatas(mgr.enemySelectSkillNumber_);
        ISkillData playerSkillData = playerMonsterData.GetSkillDatas(mgr.playerSelectSkillNumber_);

        //技の優先度で行動順を決める
        if (enemySkillData.triggerPriority_ < playerSkillData.triggerPriority_)
        {
            //プレイヤーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetPlayerEffectParts()
                , mgr.GetEnemyEffectParts()
                , mgr.GetEnemyMonsterParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , PlayerBattleData.GetInstance()
                , EnemyBattleData.GetInstance()
                , playerMonsterData, playerSkillData, enemyMonsterData
                );
            //エネミーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetEnemyEffectParts()
                , mgr.GetPlayerEffectParts()
                , mgr.GetPlayerMonsterParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , EnemyBattleData.GetInstance()
                , PlayerBattleData.GetInstance()
                , enemyMonsterData, enemySkillData, playerMonsterData
                );
        }
        else if (enemySkillData.triggerPriority_ > playerSkillData.triggerPriority_)
        {
            //エネミーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetEnemyEffectParts()
                , mgr.GetPlayerEffectParts()
                , mgr.GetPlayerMonsterParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , EnemyBattleData.GetInstance()
                , PlayerBattleData.GetInstance()
                , enemyMonsterData, enemySkillData, playerMonsterData
                );
            //プレイヤーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetPlayerEffectParts()
                , mgr.GetEnemyEffectParts()
                , mgr.GetEnemyMonsterParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , PlayerBattleData.GetInstance()
                , EnemyBattleData.GetInstance()
                , playerMonsterData, playerSkillData, enemyMonsterData
                );
        }
        //素早さで行動順を決める
        else if ((enemyMonsterData.RealSpeed() * enemyMonsterData.battleData_.RealSpeedParameterRank()) < (playerMonsterData.RealSpeed() * playerMonsterData.battleData_.RealSpeedParameterRank()))
        {
            //プレイヤーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetPlayerEffectParts()
                , mgr.GetEnemyEffectParts()
                , mgr.GetEnemyMonsterParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , PlayerBattleData.GetInstance()
                , EnemyBattleData.GetInstance()
                , playerMonsterData, playerSkillData, enemyMonsterData
                );
            //エネミーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetEnemyEffectParts()
                , mgr.GetPlayerEffectParts()
                , mgr.GetPlayerMonsterParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , EnemyBattleData.GetInstance()
                , PlayerBattleData.GetInstance()
                , enemyMonsterData, enemySkillData, playerMonsterData
                );
        }
        else if ((enemyMonsterData.RealSpeed() * enemyMonsterData.battleData_.RealSpeedParameterRank()) == (playerMonsterData.RealSpeed() * playerMonsterData.battleData_.RealSpeedParameterRank()))
        {
            if (AllSceneManager.GetInstance().GetRandom().Next(0, 2) < 1)
            {
                //プレイヤーの戦闘処理
                SkillResultSet(
                    mgr
                    , mgr.GetPlayerEffectParts()
                    , mgr.GetEnemyEffectParts()
                    , mgr.GetEnemyMonsterParts()
                    , mgr.GetPlayerStatusInfoParts()
                    , mgr.GetEnemyStatusInfoParts()
                    , mgr.GetPlayerDreamPointInfoParts()
                    , mgr.GetEnemyDreamPointInfoParts()
                    , PlayerBattleData.GetInstance()
                    , EnemyBattleData.GetInstance()
                    , playerMonsterData, playerSkillData, enemyMonsterData
                    );
                //エネミーの戦闘処理
                SkillResultSet(
                    mgr
                    , mgr.GetEnemyEffectParts()
                    , mgr.GetPlayerEffectParts()
                    , mgr.GetPlayerMonsterParts()
                    , mgr.GetEnemyStatusInfoParts()
                    , mgr.GetPlayerStatusInfoParts()
                    , mgr.GetEnemyDreamPointInfoParts()
                    , mgr.GetPlayerDreamPointInfoParts()
                    , EnemyBattleData.GetInstance()
                    , PlayerBattleData.GetInstance()
                    , enemyMonsterData, enemySkillData, playerMonsterData
                    );
            }
            else
            {
                //エネミーの戦闘処理
                SkillResultSet(
                    mgr
                    , mgr.GetEnemyEffectParts()
                    , mgr.GetPlayerEffectParts()
                    , mgr.GetPlayerMonsterParts()
                    , mgr.GetEnemyStatusInfoParts()
                    , mgr.GetPlayerStatusInfoParts()
                    , mgr.GetEnemyDreamPointInfoParts()
                    , mgr.GetPlayerDreamPointInfoParts()
                    , EnemyBattleData.GetInstance()
                    , PlayerBattleData.GetInstance()
                    , enemyMonsterData, enemySkillData, playerMonsterData
                    );
                //プレイヤーの戦闘処理
                SkillResultSet(
                    mgr
                    , mgr.GetPlayerEffectParts()
                    , mgr.GetEnemyEffectParts()
                    , mgr.GetEnemyMonsterParts()
                    , mgr.GetPlayerStatusInfoParts()
                    , mgr.GetEnemyStatusInfoParts()
                    , mgr.GetPlayerDreamPointInfoParts()
                    , mgr.GetEnemyDreamPointInfoParts()
                    , PlayerBattleData.GetInstance()
                    , EnemyBattleData.GetInstance()
                    , playerMonsterData, playerSkillData, enemyMonsterData
                    );
            }
        }
        else
        {
            //エネミーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetEnemyEffectParts()
                , mgr.GetPlayerEffectParts()
                , mgr.GetPlayerMonsterParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , EnemyBattleData.GetInstance()
                , PlayerBattleData.GetInstance()
                , enemyMonsterData, enemySkillData, playerMonsterData
                );
            //プレイヤーの戦闘処理
            SkillResultSet(
                mgr
                , mgr.GetPlayerEffectParts()
                , mgr.GetEnemyEffectParts()
                , mgr.GetEnemyMonsterParts()
                , mgr.GetPlayerStatusInfoParts()
                , mgr.GetEnemyStatusInfoParts()
                , mgr.GetPlayerDreamPointInfoParts()
                , mgr.GetEnemyDreamPointInfoParts()
                , PlayerBattleData.GetInstance()
                , EnemyBattleData.GetInstance()
                , playerMonsterData, playerSkillData, enemyMonsterData
                );
        }

        //白紙に
        AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), " ");
        AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
        AllEventManager.GetInstance().AllUpdateEventExecute();
        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(0.5f);

        //イベントの最後
        AllEventManager.GetInstance().EventFinishSet();

        //交換判定の初期化
        PlayerBattleData.GetInstance().changeMonsterActive_ = false;
        EnemyBattleData.GetInstance().changeMonsterActive_  = false;

        return(mgr.nowProcessState().NextProcess());
    }
 public SkillListModel(ISkillData skillData)
 {
     _skillData = skillData;
 }
Пример #16
0
 public EditCertificateModel(ICertificateData certificateData, ISkillData skillData, IFileUploader fileUploader)
 {
     _certificateData = certificateData;
     _skillData       = skillData;
     _fileUploader    = fileUploader;
 }
Пример #17
0
 static SkillData()
 {
     LogicServer.Instance.UpdateManager.InitStaticImpl(typeof(SkillData), typeof(SkillDataDefaultImpl),
                                                       o => { mImpl = (ISkillData)o; });
 }
Пример #18
0
 public virtual bool EffectValueEventSet(BattleManager mgr, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
 {
     return(false);
 }
    /// <summary>
    ///乱数平均、急所なし、計算式
    /// </summary>
    static public int TestDamageCalculate(IMonsterData attackMonster, IMonsterData defenseMonster, ISkillData attackSkill)
    {
        //乱数
        float randomResult = 9.5f;

        //モンスターのタイプと技のタイプの一致か否か
        float typeMatch = 1;

        if (attackMonster.tribesData_.firstElement_.state_ == attackSkill.elementType_.state_ ||
            attackMonster.tribesData_.secondElement_.state_ == attackSkill.elementType_.state_)
        {
            typeMatch = 1.5f;
        }

        //敵モンスターと技のタイプ相性
        float typeSimillar = defenseMonster.ElementSimillarChecker(attackSkill.elementType_);

        //補正値の初期値 4096
        //技の最終威力
        int realSkillPower = (int)(attackSkill.effectValue_ * (4096 / 4096));

        //物理か特殊か
        //EffectAttackTypeState ea = attackSkill.effectValueType_.GetEffectAttackTypeState();

        //モンスターの最終攻撃力
        int realMonsterAttack = 0;
        {
            //if (ea.state_ == EffectAttackType.Normal) {
            //	realMonsterAttack = (int)(attackMonster.RealAttack() * attackMonster.battleData_.RealAttackParameterRank() * (4096 / 4096));
            //}
            realMonsterAttack = (int)(attackMonster.RealAttack() * attackMonster.battleData_.RealAttackParameterRank() * (4096 / 4096));
        }

        //敵モンスターの最終防御力
        int realMonsterDefense = 0;
        {
            //if (ea.state_ == EffectAttackType.Normal) {
            //	realMonsterDefense = (int)(defenseMonster.RealDefense() * defenseMonster.battleData_.RealDefenseParameterRank() * (4096 / 4096));
            //}
            realMonsterDefense = (int)(defenseMonster.RealDefense() * defenseMonster.battleData_.RealDefenseParameterRank() * (4096 / 4096));
        }

        //(((レベル×2/5+2)×威力×A/D)/50+2)
        //最終ダメージ
        int realDamage = (int)((((attackMonster.level_ * 2 / 5 + 2) * realSkillPower * realMonsterAttack / realMonsterDefense) / 50)
                               * randomResult * typeMatch * typeSimillar);

        return(realDamage);
    }
Пример #20
0
    public override bool EffectValueEventSet(BattleManager mgr, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
    {
        //ランク補正の計算
        float monsterHitRateValue = 0;
        {
            //回避率と命中率のランク
            int monsterHitRank = attackMonsterData.battleData_.GetHitRateParameterRank() - defenseMonsterData.battleData_.GetAvoidRateParameterRank();

            //分子,分母
            float numerator = 3, denominator = 3;

            if (monsterHitRank < 0)
            {
                denominator -= monsterHitRank;
            }
            else
            {
                numerator += monsterHitRank;
            }

            //回避率と命中率のランクの倍率
            monsterHitRateValue = numerator / denominator;
        }

        //攻撃の成功判定
        //技の命中率×命中補正値M×ランク補正
        bool skillSuccess = AllSceneManager.GetInstance().GetRandom().Next(0, 100) < (int)(attackSkillData.successRateValue_ * (4096 / 4096) * monsterHitRateValue);

        //技が失敗した時の説明
        if (!skillSuccess)
        {
            AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "しかし " + attackTrainerBattleData.GetUniqueTrainerName() + attackMonsterData.uniqueName_ + "の\nこうげきは はずれた!");
            AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
            AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

            AllEventManager.GetInstance().EventWaitSet(1.0f);

            return(false);
        }

        //急所の判定
        float critical = 1;

        if (attackSkillData.criticalParameterRank_ <= 0)
        {
            if (AllSceneManager.GetInstance().GetRandom().Next(0, 24) == 13)
            {
                critical = 1.5f;
            }
        }
        else if (attackSkillData.criticalParameterRank_ == 1)
        {
            if (AllSceneManager.GetInstance().GetRandom().Next(0, 8) == 4)
            {
                critical = 1.5f;
            }
        }
        else if (attackSkillData.criticalParameterRank_ == 2)
        {
            if (AllSceneManager.GetInstance().GetRandom().Next(0, 2) == 0)
            {
                critical = 1.5f;
            }
        }
        else
        {
            critical = 1.5f;
        }

        //ヒットポイントの変動
        int realEffectValue = (int)(MonsterData.BattleDamageCalculate(attackMonsterData, defenseMonsterData, attackSkillData) * critical);

        defenseMonsterData.nowHitPoint_ -= realEffectValue;
        if (defenseMonsterData.nowHitPoint_ < 0)
        {
            defenseMonsterData.nowHitPoint_ = 0;
        }

        //DPの変動
        //PlayerBattleData.GetInstance().dreamPoint_ += playerSkillData.upDpValue_;
        int attackElementSimillarRsult = defenseMonsterData.ElementSimillarCheckerForValue(attackSkillData.elementType_);

        if (attackElementSimillarRsult == 3)
        {
            attackTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueBestSimillar());
        }
        else if (attackElementSimillarRsult == 2)
        {
            attackTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueNormalSimillar());
        }
        else if (attackElementSimillarRsult == 1)
        {
            attackTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueBadSimillar());
        }
        else if (attackElementSimillarRsult == 0)
        {
            attackTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueNotSimillar());
        }

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //DPの演出のイベント
        attackDreamPointInfoParts.DPEffectEventSet(attackTrainerBattleData.GetDreamPoint());

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //技のアニメーション
        attackSkillData.EffectAnimetionEventSet(defenseEffectParts);

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //ダメージを受けていたら
        if (realEffectValue > 0)
        {
            //ダメージアクション(点滅)
            defenseMonsterParts.GetEventMonsterSprite().blinkTimeRegulation_ = 0.06f;

            //点滅の開始
            AllEventManager.GetInstance().EventSpriteRendererSet(defenseMonsterParts.GetEventMonsterSprite());
            AllEventManager.GetInstance().EventSpriteRenderersUpdateExecuteSet(EventSpriteRendererEventManagerExecute.BlinkStart);
            AllEventManager.GetInstance().AllUpdateEventExecute();

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(0.48f);

            //点滅の終了
            AllEventManager.GetInstance().EventSpriteRendererSet(defenseMonsterParts.GetEventMonsterSprite());
            AllEventManager.GetInstance().EventSpriteRenderersUpdateExecuteSet(EventSpriteRendererEventManagerExecute.BlinkEnd);
            AllEventManager.GetInstance().AllUpdateEventExecute();

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(0.2f);

            //ヒットポイントのゲージの変動イベントの設定
            float hpGaugeFillAmount = t13.Utility.ValueForPercentage(defenseMonsterData.RealHitPoint(), defenseMonsterData.nowHitPoint_, 1);
            AllEventManager.GetInstance().HpGaugePartsSet(defenseStatusInfoParts.GetFrameParts().GetHpGaugeParts(), hpGaugeFillAmount, defenseMonsterData);
            AllEventManager.GetInstance().HpGaugePartsUpdateExecuteSet(HpGaugePartsEventManagerExecute.GaugeUpdate);
            AllEventManager.GetInstance().AllUpdateEventExecute(0.5f);

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

            if (critical > 1.0f)
            {
                //急所の説明
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "きゅうしょに あたった!");
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }

            //効果の説明
            int defenseElementSimillarResult = defenseMonsterData.ElementSimillarCheckerForValue(attackSkillData.elementType_);
            if (defenseElementSimillarResult == 3)
            {
                //DPの増加
                defenseTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueBestSimillar());

                //文字列の処理
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "こうかは ばつぐんだ!");
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                //ウェイト
                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }
            else if (defenseElementSimillarResult == 2)
            {
                //DPの増加
                defenseTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueNormalSimillar());
            }
            else if (defenseElementSimillarResult == 1)
            {
                //DPの増加
                defenseTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueBadSimillar());

                //文字列の処理
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "こうかは いまひとつの ようだ");
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                //ウェイト
                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }
            else if (defenseElementSimillarResult == 0)
            {
                //DPの増加
                defenseTrainerBattleData.DreamPointAddValue(AllSceneManager.GetInstance().GetUpDPValueNotSimillar());

                //文字列の処理
                AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "こうかが ないようだ・・・");
                AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
                AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

                //ウェイト
                AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
            }

            //DPの演出のイベント
            defenseDreamPointInfoParts.DPEffectEventSet(defenseTrainerBattleData.GetDreamPoint());

            //ウェイト
            AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());
        }

        return(true);
    }
    public override bool EffectValueEventSet(BattleManager mgr, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
    {
        //攻撃の成功判定
        //技の命中率×命中補正値M×ランク補正
        bool skillSuccess = AllSceneManager.GetInstance().GetRandom().Next(0, 100) < (int)(attackSkillData.successRateValue_ * (4096 / 4096));

        //技が失敗した時の説明
        if (!skillSuccess)
        {
            AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "しかし " + attackTrainerBattleData.GetUniqueTrainerName() + attackMonsterData.uniqueName_ + "は\nうまく きめられなかった!");
            AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
            AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

            AllEventManager.GetInstance().EventWaitSet(1.0f);

            return(false);
        }

        //ヒットポイントの変動
        attackMonsterData.nowHitPoint_ += (int)attackSkillData.effectValue_;
        if (attackMonsterData.nowHitPoint_ > attackMonsterData.RealHitPoint())
        {
            attackMonsterData.nowHitPoint_ = attackMonsterData.RealHitPoint();
        }

        //技のアニメーション
        attackSkillData.EffectAnimetionEventSet(attackEffectParts);

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //ヒットポイントのゲージの変動イベントの設定
        float hpGaugeFillAmount = t13.Utility.ValueForPercentage(attackMonsterData.RealHitPoint(), attackMonsterData.nowHitPoint_, 1);

        AllEventManager.GetInstance().HpGaugePartsSet(attackStatusInfoParts.GetFrameParts().GetHpGaugeParts(), hpGaugeFillAmount, attackMonsterData);
        AllEventManager.GetInstance().HpGaugePartsUpdateExecuteSet(HpGaugePartsEventManagerExecute.GaugeUpdate);
        AllEventManager.GetInstance().AllUpdateEventExecute(0.5f);

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //文字列の処理
        AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), attackTrainerBattleData.GetUniqueTrainerName() + attackMonsterData.uniqueName_ + "は\nたいりょくを かいふくした!");
        AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
        AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        return(true);
    }
Пример #22
0
    public override bool EffectValueEventSet(BattleManager mgr, BTrainerBattleData attackTrainerBattleData, BTrainerBattleData defenseTrainerBattleData, EffectParts attackEffectParts, EffectParts defenseEffectParts, MonsterParts defenseMonsterParts, StatusInfoParts attackStatusInfoParts, StatusInfoParts defenseStatusInfoParts, DreamPointInfoParts attackDreamPointInfoParts, DreamPointInfoParts defenseDreamPointInfoParts, IMonsterData attackMonsterData, ISkillData attackSkillData, IMonsterData defenseMonsterData)
    {
        //攻撃の成功判定
        //技の命中率×命中補正値M×ランク補正
        bool skillSuccess = AllSceneManager.GetInstance().GetRandom().Next(0, 100) < (int)(attackSkillData.successRateValue_ * (4096 / 4096));

        //技が失敗した時の説明
        if (!skillSuccess)
        {
            AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), "しかし " + attackTrainerBattleData.GetUniqueTrainerName() + attackMonsterData.uniqueName_ + "は\nうまく きめられなかった!");
            AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
            AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

            AllEventManager.GetInstance().EventWaitSet(1.0f);

            return(false);
        }

        //ドリームポイントの変動
        attackTrainerBattleData.DreamPointAddValue((int)attackSkillData.effectValue_);
        defenseTrainerBattleData.DreamPointAddValue(-(int)attackSkillData.effectValue_);

        //技のアニメーション
        attackSkillData.EffectAnimetionEventSet(attackEffectParts);

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //DPの演出のイベント
        defenseDreamPointInfoParts.DPEffectEventSet(defenseTrainerBattleData.GetDreamPoint());

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //DPの演出のイベント
        attackDreamPointInfoParts.DPEffectEventSet(attackTrainerBattleData.GetDreamPoint());

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        //文字列の処理
        AllEventManager.GetInstance().EventTextSet(mgr.GetNovelWindowParts().GetNovelWindowEventText(), attackTrainerBattleData.GetUniqueTrainerName() + attackMonsterData.uniqueName_ + "は\nドリームポイントを うばった!");
        AllEventManager.GetInstance().EventTextsUpdateExecuteSet(EventTextEventManagerExecute.CharaUpdate);
        AllEventManager.GetInstance().AllUpdateEventExecute(mgr.GetEventContextUpdateTime());

        //ウェイト
        AllEventManager.GetInstance().EventWaitSet(mgr.GetEventWaitTime());

        return(true);
    }