+Fixed a bug that created MH's and Admin's villages with wrong resource
fields, during the installation
This commit is contained in:
iopietro
2018-07-25 18:39:39 +02:00
parent b9a442b423
commit 6a963d0ba3
+3 -3
View File
@@ -63,7 +63,7 @@
if($status == 0) { if($status == 0) {
$database->setFieldTaken($wid); $database->setFieldTaken($wid);
$database->addVillage($wid, $uid, $_POST['aname'], 1); $database->addVillage($wid, $uid, $_POST['aname'], 1);
$database->addResourceFields($wid, $database->getVillageType($wid)); $database->addResourceFields($wid, $database->getVillageType($wid, false));
$addUnitsWrefs[] = $wid; $addUnitsWrefs[] = $wid;
$addTechWrefs[] = $wid; $addTechWrefs[] = $wid;
$addABTechWrefs[] = $wid; $addABTechWrefs[] = $wid;
@@ -84,8 +84,8 @@
$status = $database->getVillageState($wid); $status = $database->getVillageState($wid);
if($status == 0) { if($status == 0) {
$database->setFieldTaken($wid); $database->setFieldTaken($wid);
$database->addVillage($wid, $uid, 'Multihunter', '0'); $database->addVillage($wid, $uid, 'Multihunter', 0);
$database->addResourceFields($wid, $database->getVillageType($wid)); $database->addResourceFields($wid, $database->getVillageType($wid, false));
$database->addUnits($wid); $database->addUnits($wid);
$database->addTech($wid); $database->addTech($wid);
$database->addABTech($wid); $database->addABTech($wid);