|
@@ -74,14 +74,13 @@ class Info_Store extends Object_ext {
|
|
|
/**
|
|
|
* @var int current UID
|
|
|
*/
|
|
|
- public $cuid = 10000;
|
|
|
-
|
|
|
-
|
|
|
+ public $cuid = 10000;
|
|
|
+
|
|
|
/**
|
|
|
* @var int $petUid
|
|
|
*/
|
|
|
- public $petUid = 1;
|
|
|
-
|
|
|
+ public $petUid = 1;
|
|
|
+
|
|
|
/**
|
|
|
* 宠物背包数据
|
|
|
*/
|
|
@@ -104,13 +103,13 @@ class Info_Store extends Object_ext {
|
|
|
* @var type
|
|
|
*/
|
|
|
public $petUids_supportFight_position;
|
|
|
-
|
|
|
+
|
|
|
/**
|
|
|
* 孵蛋坑位信息
|
|
|
* @var type
|
|
|
*/
|
|
|
public $breedEggLocation;
|
|
|
-
|
|
|
+
|
|
|
/**
|
|
|
* 宠物探索区域
|
|
|
* @var type
|
|
@@ -123,9 +122,8 @@ class Info_Store extends Object_ext {
|
|
|
|
|
|
public function __construct($arg = null) {
|
|
|
if ($arg == null) {
|
|
|
- $this->exploreArea = new \stdClass();
|
|
|
$this->petUids_supportFight_position = new \stdClass();
|
|
|
-
|
|
|
+
|
|
|
$this->items = new \stdClass();
|
|
|
$this->gemStore = new \stdClass();
|
|
|
$this->equip = new \stdClass();
|
|
@@ -146,24 +144,26 @@ class Info_Store extends Object_ext {
|
|
|
}
|
|
|
$this->gemEquip->$k = $item;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
$str = GameConfig::glc2()->Pet_BreedLocationUnlockInfo;
|
|
|
$this->breedEggLocation = new \stdClass();
|
|
|
- if($str != null){
|
|
|
+ if ($str != null) {
|
|
|
$list = explode(';', $str);
|
|
|
foreach ($list as $value) {
|
|
|
$s = explode(',', $value);
|
|
|
- $k = $s[0];
|
|
|
+ $k = $s[0];
|
|
|
$ins_breed = new Ins_BreedEggSlot();
|
|
|
$ins_breed->uid = $k;
|
|
|
- $ins_breed->unlock = 0;
|
|
|
- if($s[1] == 0){
|
|
|
- $ins_breed->unlock = 1;
|
|
|
+ $ins_breed->unlock = 0;
|
|
|
+ if ($s[1] == 0) {
|
|
|
+ $ins_breed->unlock = 1;
|
|
|
}
|
|
|
$this->breedEggLocation->$k = $ins_breed;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ $this->initExploreArea();
|
|
|
+
|
|
|
} else {
|
|
|
parent::__construct($arg);
|
|
|
}
|
|
@@ -184,4 +184,18 @@ class Info_Store extends Object_ext {
|
|
|
public function nextUID() {
|
|
|
return $this->cuid++;
|
|
|
}
|
|
|
+
|
|
|
+ public function initExploreArea() {
|
|
|
+ if($this->exploreArea = null){
|
|
|
+ $this->exploreArea = new \stdClass();
|
|
|
+ }
|
|
|
+
|
|
|
+ $exploreAreas = GameConfig::pet_area();
|
|
|
+ foreach ($exploreAreas as $areaId => $areaArr) {
|
|
|
+ if(!StlUtil::dictHasProperty($this->exploreArea, $areaId)){
|
|
|
+ $Ins_ExploreArea = new Ins_ExploreArea($areaArr[0]);
|
|
|
+ $this->exploreArea->$areaId = $Ins_ExploreArea;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|