mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-09-18 08:07:18 +00:00
Artifacts fixes
+Fixed a bug that assigned a wrong village name, when returning a WW building plans to Natars' account
This commit is contained in:
@@ -91,7 +91,7 @@ class Artifacts
|
|||||||
* @var array WW building plans Natars' artifacts
|
* @var array WW building plans Natars' artifacts
|
||||||
*/
|
*/
|
||||||
|
|
||||||
NATARS_WW_BUILDING_PLANS = [PLAN_DESC => [["type" => 11, "size" => 1, "name" => PLAN,"vname" => PLANVILLAGE, "effect" => "", "quantity" => 13, "img" => 1]]],
|
NATARS_WW_BUILDING_PLANS = [PLAN_DESC => [["type" => 11, "size" => 1, "name" => PLAN, "vname" => PLANVILLAGE, "effect" => "", "quantity" => 13, "img" => 1]]],
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var array Natars' normal artifacts buildings
|
* @var array Natars' normal artifacts buildings
|
||||||
@@ -411,10 +411,11 @@ class Artifacts
|
|||||||
global $database;
|
global $database;
|
||||||
|
|
||||||
//Set the village arrays
|
//Set the village arrays
|
||||||
|
$artifactArrays = array_merge(self::NATARS_ARTIFACTS, self::NATARS_WW_BUILDING_PLANS);
|
||||||
$villageArrays = [['wid' => 0, 'mode' => $artifactArray['size'] + 1, 'type' => 3,
|
$villageArrays = [['wid' => 0, 'mode' => $artifactArray['size'] + 1, 'type' => 3,
|
||||||
'kid' => rand(1, 4), 'capital' => 0, 'pop' => 163,
|
'kid' => rand(1, 4), 'capital' => 0, 'pop' => 163,
|
||||||
'name' => self::NATARS_ARTIFACTS[$artifactArray['desc']][$artifactArray['size'] - 1]['vname'],
|
'name' => $artifactArrays[$artifactArray['desc']][$artifactArray['size'] - 1]['vname'],
|
||||||
'natar' => $artifactArray['type'] != 11 ? 0 : 1]];
|
'natar' => 0]];
|
||||||
|
|
||||||
//Set the unit arrays
|
//Set the unit arrays
|
||||||
$multiplier = $artifactArray['size'] == 3 ? 4 : $artifactArray['size'];
|
$multiplier = $artifactArray['size'] == 3 ? 4 : $artifactArray['size'];
|
||||||
|
|||||||
Reference in New Issue
Block a user