From dadc2c5604b104118ec18b9f1545c66729cb2be7 Mon Sep 17 00:00:00 2001 From: TORISOUP Date: Sun, 24 Jan 2016 19:00:00 +0900 Subject: [PATCH] =?UTF-8?q?=E3=82=AB=E3=83=83=E3=83=88=E3=82=B7=E3=83=BC?= =?UTF-8?q?=E3=83=B3=E6=99=82=E3=81=AE=E3=82=AB=E3=82=AA=E3=82=B9=E5=8C=96?= =?UTF-8?q?=E3=81=AE=E9=A0=BB=E5=BA=A6=E3=82=92=E8=AA=BF=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Inferno/ChaosMode/ChaosMode.cs | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/Inferno/ChaosMode/ChaosMode.cs b/Inferno/ChaosMode/ChaosMode.cs index a7510202..21d4a1c4 100644 --- a/Inferno/ChaosMode/ChaosMode.cs +++ b/Inferno/ChaosMode/ChaosMode.cs @@ -210,28 +210,24 @@ private IEnumerable ChaosPedAction(Ped ped) //攻撃する PedRiot(ped, equipedWeapon); - if (ped.IsCutsceneOnlyPed()) - { - yield return WaitForSeconds(2); - } - else + + //適当に待機 + foreach (var s in WaitForSeconds(2 + (float)Random.NextDouble() * 3)) { - //適当に待機 - foreach (var s in WaitForSeconds(2 + (float)Random.NextDouble() * 3)) + if (ped.IsSafeExist() && ped.IsFleeing()) { - if (ped.IsSafeExist() && ped.IsFleeing()) - { - //市民が攻撃をやめて逃げ始めたら再度セットする - break; - } - yield return s; + //市民が攻撃をやめて逃げ始めたら再度セットする + break; } + yield return s; } + } while (ped.IsSafeExist() && ped.IsAlive); chaosedPedList.Remove(pedId); } + /// /// カオス化時の攻撃対象を取得する ///