은퇴 연령 값을 GameConst로 이동

This commit is contained in:
2019-03-09 17:08:11 +09:00
parent 16a82a28ae
commit 568ff4b366
4 changed files with 8 additions and 7 deletions
+3 -3
View File
@@ -910,8 +910,8 @@ function generalInfo($no) {
if($nation['color'] == "") { $nation['color'] = "#000000"; }
if($general['age'] < 60) { $general['age'] = "<font color=limegreen>{$general['age']} 세</font>"; }
elseif($general['age'] < 80) { $general['age'] = "<font color=yellow>{$general['age']} 세</font>"; }
if($general['age'] < GameConst::$retirementYear*0.75) { $general['age'] = "<font color=limegreen>{$general['age']} 세</font>"; }
elseif($general['age'] < GameConst::$retirementYear) { $general['age'] = "<font color=yellow>{$general['age']} 세</font>"; }
else { $general['age'] = "<font color=red>{$general['age']} 세</font>"; }
$general['connect'] = Util::round($general['connect'] / 10) * 10;
@@ -2078,7 +2078,7 @@ function updateTurntime($no) {
}
}
if($general['age'] >= 80 && $general['npc'] == 0) {
if($general['age'] >= GameConst::$retirementYear && $general['npc'] == 0) {
if($admin['isunited'] == 0) {
CheckHall($no);
}
+2 -2
View File
@@ -466,8 +466,8 @@ function process_29(&$general) {
$bornyear = $admin['year'];
$deadyear = $admin['year'] + 3;
$age = 20;
$specage = Util::round((80 - $age)/12) + $age;
$specage2 = Util::round((80 - $age)/3) + $age;
$specage = Util::round((GameConst::$retirementYear - $age)/12) + $age;
$specage2 = Util::round((GameConst::$retirementYear - $age)/3) + $age;
//$specage = $age + 1 + rand() % 3;
//$specage2 = $age + 5 + rand() % 5;
// 20년 ~ 50년
+2 -2
View File
@@ -162,11 +162,11 @@ if ($genius) {
$specage2 = $age;
$special2 = getSpecial2($leader, $power, $intel);
} else {
$specage2 = Util::valueFit(Util::round((80 - $age)/4 - $relYear / 2), 3) + $age;
$specage2 = Util::valueFit(Util::round((GameConst::$retirementYear - $age)/4 - $relYear / 2), 3) + $age;
$special2 = 0;
}
//내특
$specage = Util::valueFit(Util::round((80 - $age)/12 - $relYear / 2), 3) + $age;
$specage = Util::valueFit(Util::round((GameConst::$retirementYear - $age)/12 - $relYear / 2), 3) + $age;
$special = 0;
if ($admin['scenario'] >= 1000) {
+1
View File
@@ -93,4 +93,5 @@ class GameConstBase
public static $maxTurn = 24;
public static $statGradeLevel = 5;
public static $retirementYear = 80;
}