StoreModel.php 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <?php
  2. namespace loyalsoft;
  3. /**
  4. * Description of StoreModel
  5. * 玩家背包/仓库数据模型
  6. * @author gwang
  7. */
  8. class StoreModel extends Object_ext
  9. {
  10. /**
  11. * 其他道具
  12. * @var array
  13. */
  14. public $items;
  15. /**
  16. * 已获得英雄卡牌道具,不叠加
  17. * @var array
  18. */
  19. public $cards;
  20. /**
  21. * 装备, 待定
  22. * @var type
  23. */
  24. public $equipment;
  25. /**
  26. * 宝箱
  27. * @var array
  28. */
  29. public $boxes;
  30. /**
  31. * 英雄碎片,叠加
  32. * @var object
  33. */
  34. public $segement;
  35. /**
  36. * 七宗罪元素(炼金元素)
  37. * @var object
  38. */
  39. public $element;
  40. /**
  41. * 石头,叠加
  42. * @var object
  43. */
  44. public $stones;
  45. /**
  46. * 玩家注册时初始化
  47. */
  48. public function initialize()
  49. {
  50. $this->boxes = GameConfig::primordial_data()->User_Store_boxes;
  51. //array('701001' => 0, '702002' => 0, '703003' => 0, '704004' => 0);
  52. $this->cards = ArrayInit();
  53. $this->items = GameConfig::primordial_data()->User_Store_items; # 初始含有一张黄金通知书
  54. $this->equipment = ObjectInit();
  55. $this->segement = GameConfig::primordial_data()->User_Store_segment; # 碎片
  56. $this->stones = ObjectInit();
  57. $this->element = GameConfig::primordial_data()->User_Store_element;
  58. //array('388001' => 0, '388002' => 0, '388003' => 0, '388004' => 0, '388005' => 0, '388006' => 0, '388007' => 0);
  59. }
  60. }