From 1c2875e7fcd016eef5f2adab414013c62ae0e315 Mon Sep 17 00:00:00 2001 From: hide_d Date: Wed, 18 Jul 2018 04:37:00 +0900 Subject: [PATCH] =?UTF-8?q?=EB=AA=A8=EB=B3=91=EC=B0=BD=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hwe/processing.php | 7 +++++++ hwe/templates/recruitCrewForm.php | 6 +++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/hwe/processing.php b/hwe/processing.php index ba8978c6..5538bbc7 100644 --- a/hwe/processing.php +++ b/hwe/processing.php @@ -205,6 +205,13 @@ function command_11($turn, $command, bool $is모병 = false) { ); [$nationLevel, $tech] = $db->queryFirstList('SELECT level,tech FROM nation WHERE nation=%i', $me['nation']); + if(!$nationLevel){ + $nationLevel = 0; + } + + if(!$tech){ + $tech = 0; + } $lbonus = setLeadershipBonus($me, $nationLevel); diff --git a/hwe/templates/recruitCrewForm.php b/hwe/templates/recruitCrewForm.php index 75f07440..b2b254ee 100644 --- a/hwe/templates/recruitCrewForm.php +++ b/hwe/templates/recruitCrewForm.php @@ -2,7 +2,7 @@ var currentTech = ; var leader = ; var currentCrewType = ; -var currentCrew = +var currentCrew = ; var currentGold = ; var is모병 = ; @@ -12,7 +12,7 @@ window.calc = function(id) { var baseCost = $obj.data('cost'); var $cost = $obj.find('.form_cost'); - var cost = crew * baseCost.val(); + var cost = crew * baseCost; if(is모병){ cost *= 2; } @@ -68,7 +68,7 @@ window.calc = function(id) { data-rice="baseRice?>" data-cost="baseCost?>" > - + name?> attack?> defence?>