From 86b40695e6b11c6abcd18e2756a097e4ec0a2747 Mon Sep 17 00:00:00 2001 From: hide_d Date: Mon, 21 May 2018 12:16:02 +0900 Subject: [PATCH] =?UTF-8?q?=EC=99=B8=EA=B5=90=20=EC=84=9C=EC=8B=A0=20?= =?UTF-8?q?=EC=95=88=20=EB=B0=9B=EC=95=84=EC=A7=80=EB=8A=94=20=EB=B2=84?= =?UTF-8?q?=EA=B7=B8=20=EC=88=98=EC=A0=95.=20=EC=9D=98=EB=B3=91,=20m?= =?UTF-8?q?=EC=9E=A5=20=EC=8A=A4=ED=83=AF=20=EB=B2=84=EA=B7=B8=20=ED=95=B4?= =?UTF-8?q?=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/func_process_chief.php | 18 +++++++++--------- hwe/func_process_personnel.php | 18 +++++++++--------- hwe/sammo/Engine/Diplomacy.php | 1 + hwe/sammo/Engine/Personnel.php | 1 + 4 files changed, 20 insertions(+), 18 deletions(-) diff --git a/hwe/func_process_chief.php b/hwe/func_process_chief.php index 3a9737c4..390441f8 100644 --- a/hwe/func_process_chief.php +++ b/hwe/func_process_chief.php @@ -2076,17 +2076,17 @@ function process_76(&$general) { } // 국내 최고능치 기준으로 랜덤성 스케일링 if($avgGen['lpi'] > 210) { - $leader = Util::round($leader * $avgGen['lpi'] / 150 * (60+rand()%31)/100); - $power = Util::round($power * $avgGen['lpi'] / 150 * (60+rand()%31)/100); - $intel = Util::round($intel * $avgGen['lpi'] / 150 * (60+rand()%31)/100); + $leader = Util::round($leader * $avgGen['lpi'] / GameConst::$defaultStatTotal * (60+rand()%31)/100); + $power = Util::round($power * $avgGen['lpi'] / GameConst::$defaultStatTotal * (60+rand()%31)/100); + $intel = Util::round($intel * $avgGen['lpi'] / GameConst::$defaultStatTotal * (60+rand()%31)/100); } elseif($avgGen['lpi'] > 180) { - $leader = Util::round($leader * $avgGen['lpi'] / 150 * (75+rand()%21)/100); - $power = Util::round($power * $avgGen['lpi'] / 150 * (75+rand()%21)/100); - $intel = Util::round($intel * $avgGen['lpi'] / 150 * (75+rand()%21)/100); + $leader = Util::round($leader * $avgGen['lpi'] / GameConst::$defaultStatTotal * (75+rand()%21)/100); + $power = Util::round($power * $avgGen['lpi'] / GameConst::$defaultStatTotal * (75+rand()%21)/100); + $intel = Util::round($intel * $avgGen['lpi'] / GameConst::$defaultStatTotal * (75+rand()%21)/100); } else { - $leader = Util::round($leader * $avgGen['lpi'] / 150 * (90+rand()%11)/100); - $power = Util::round($power * $avgGen['lpi'] / 150 * (90+rand()%11)/100); - $intel = Util::round($intel * $avgGen['lpi'] / 150 * (90+rand()%11)/100); + $leader = Util::round($leader * $avgGen['lpi'] / GameConst::$defaultStatTotal * (90+rand()%11)/100); + $power = Util::round($power * $avgGen['lpi'] / GameConst::$defaultStatTotal * (90+rand()%11)/100); + $intel = Util::round($intel * $avgGen['lpi'] / GameConst::$defaultStatTotal * (90+rand()%11)/100); } $over1 = 0; $over2 = 0; diff --git a/hwe/func_process_personnel.php b/hwe/func_process_personnel.php index ad22b2c6..d377627d 100644 --- a/hwe/func_process_personnel.php +++ b/hwe/func_process_personnel.php @@ -312,17 +312,17 @@ function process_29(&$general) { } // 국내 최고능치 기준으로 랜덤성 스케일링 if($avgGen['lpi'] > 210) { - $leader = Util::round($leader * $avgGen['lpi'] / 150 * (60+rand()%31)/100); - $power = Util::round($power * $avgGen['lpi'] / 150 * (60+rand()%31)/100); - $intel = Util::round($intel * $avgGen['lpi'] / 150 * (60+rand()%31)/100); + $leader = Util::round($leader * $avgGen['lpi'] / GameConst::$defaultStatTotal * (60+rand()%31)/100); + $power = Util::round($power * $avgGen['lpi'] / GameConst::$defaultStatTotal * (60+rand()%31)/100); + $intel = Util::round($intel * $avgGen['lpi'] / GameConst::$defaultStatTotal * (60+rand()%31)/100); } elseif($avgGen['lpi'] > 180) { - $leader = Util::round($leader * $avgGen['lpi'] / 150 * (75+rand()%21)/100); - $power = Util::round($power * $avgGen['lpi'] / 150 * (75+rand()%21)/100); - $intel = Util::round($intel * $avgGen['lpi'] / 150 * (75+rand()%21)/100); + $leader = Util::round($leader * $avgGen['lpi'] / GameConst::$defaultStatTotal * (75+rand()%21)/100); + $power = Util::round($power * $avgGen['lpi'] / GameConst::$defaultStatTotal * (75+rand()%21)/100); + $intel = Util::round($intel * $avgGen['lpi'] / GameConst::$defaultStatTotal * (75+rand()%21)/100); } else { - $leader = Util::round($leader * $avgGen['lpi'] / 150 * (90+rand()%11)/100); - $power = Util::round($power * $avgGen['lpi'] / 150 * (90+rand()%11)/100); - $intel = Util::round($intel * $avgGen['lpi'] / 150 * (90+rand()%11)/100); + $leader = Util::round($leader * $avgGen['lpi'] / GameConst::$defaultStatTotal * (90+rand()%11)/100); + $power = Util::round($power * $avgGen['lpi'] / GameConst::$defaultStatTotal * (90+rand()%11)/100); + $intel = Util::round($intel * $avgGen['lpi'] / GameConst::$defaultStatTotal * (90+rand()%11)/100); } $over1 = 0; $over2 = 0; diff --git a/hwe/sammo/Engine/Diplomacy.php b/hwe/sammo/Engine/Diplomacy.php index 26a1b432..60e8e7a9 100644 --- a/hwe/sammo/Engine/Diplomacy.php +++ b/hwe/sammo/Engine/Diplomacy.php @@ -3,6 +3,7 @@ namespace sammo\Engine; use \sammo\DB; use \sammo\DiplomaticMessage; +use \sammo\KVStorage; //NOTE: A가 B에게 항복, 통합 서신을 보냈을 때 통합 후 대상이 A이므로 A가 주체임. class Diplomacy{ diff --git a/hwe/sammo/Engine/Personnel.php b/hwe/sammo/Engine/Personnel.php index b220a03c..d2dc56b7 100644 --- a/hwe/sammo/Engine/Personnel.php +++ b/hwe/sammo/Engine/Personnel.php @@ -3,6 +3,7 @@ namespace sammo\Engine; use \sammo\DB; use \sammo\ScoutMessage; +use \sammo\KVStorage; /** * 인사(등용, 추방, 임명, 망명) 헬퍼 클래스?