diff --git a/bin/json/game_tdreward.json b/bin/json/game_tdreward.json new file mode 100644 index 000000000..e9ce873ed --- /dev/null +++ b/bin/json/game_tdreward.json @@ -0,0 +1,62 @@ +[ + { + "id": 1, + "reward": [ + { + "a": "attr", + "t": "gold", + "n": 1000 + } + ] + }, + { + "id": 2, + "reward": [ + { + "a": "attr", + "t": "gold", + "n": 1200 + } + ] + }, + { + "id": 3, + "reward": [ + { + "a": "attr", + "t": "gold", + "n": 1400 + } + ] + }, + { + "id": 4, + "reward": [ + { + "a": "attr", + "t": "gold", + "n": 1600 + } + ] + }, + { + "id": 5, + "reward": [ + { + "a": "attr", + "t": "gold", + "n": 1800 + } + ] + }, + { + "id": 6, + "reward": [ + { + "a": "attr", + "t": "gold", + "n": 2000 + } + ] + } +] \ No newline at end of file diff --git a/modules/whackamole/api_award.go b/modules/whackamole/api_award.go index 0c22f64f0..1d21eb122 100644 --- a/modules/whackamole/api_award.go +++ b/modules/whackamole/api_award.go @@ -3,21 +3,37 @@ package whackamole import ( "go_dreamfactory/comm" "go_dreamfactory/pb" + cfg "go_dreamfactory/sys/configure/structs" ) // 参数校验 -func (this *apiComp) AwardCheck(session comm.IUserSession, req *pb.TreasuremapAwardReq) (errdata *pb.ErrorData) { +func (this *apiComp) AwardCheck(session comm.IUserSession, req *pb.WhackamoleAwardReq) (errdata *pb.ErrorData) { return } // /获取系统公告 -func (this *apiComp) Award(session comm.IUserSession, req *pb.TreasuremapAwardReq) (errdata *pb.ErrorData) { - var () +func (this *apiComp) Award(session comm.IUserSession, req *pb.WhackamoleAwardReq) (errdata *pb.ErrorData) { + var ( + conf *cfg.GameTDRewardData + award []*pb.UserAtno + err error + ) if errdata = this.AwardCheck(session, req); errdata != nil { return } - session.SendMsg(string(this.module.GetType()), "award", &pb.TreasuremapAwardResp{Id: req.Id}) + if conf, err = this.module.configure.getGameTDRewardData(req.Id); err != nil { + errdata = &pb.ErrorData{ + Code: pb.ErrorCode_ConfigNoFound, + Message: err.Error(), + } + return + } + if errdata, award = this.module.DispenseAtno(session, conf.Reward, true); errdata != nil { + return + } + + session.SendMsg(string(this.module.GetType()), "award", &pb.WhackamoleAwardResp{Id: req.Id, Award: award}) return } diff --git a/modules/whackamole/configure.go b/modules/whackamole/configure.go index 147c4f0f3..14b3bdcde 100644 --- a/modules/whackamole/configure.go +++ b/modules/whackamole/configure.go @@ -9,9 +9,7 @@ import ( ) const ( - game_gcolorgetfraction = "game_gcolorgetfraction.json" - game_gcolorreward = "game_gcolorreward.json" - game_gcolorttmedecay = "game_gcolorttmedecay.json" + game_tdreward = "game_tdreward.json" ) type configureComp struct { @@ -23,21 +21,21 @@ type configureComp struct { func (this *configureComp) Init(service core.IService, module core.IModule, comp core.IModuleComp, options core.IModuleOptions) (err error) { err = this.MCompConfigure.Init(service, module, comp, options) this.module = module.(*Whackamole) - + err = this.LoadConfigure(game_tdreward, cfg.NewGameTDReward) return } // 获取奖励列表 -func (this *configureComp) getGameGColorRewardData(id int32) (conf *cfg.GameGColorRewardData, err error) { +func (this *configureComp) getGameTDRewardData(id int32) (conf *cfg.GameTDRewardData, err error) { var ( v interface{} ok bool ) - if v, err = this.GetConfigure(game_gcolorreward); err != nil { + if v, err = this.GetConfigure(game_tdreward); err != nil { return } - if conf, ok = v.(*cfg.GameGColorReward).GetDataMap()[id]; !ok { - err = comm.NewNotFoundConfErr(string(this.module.GetType()), game_gcolorreward, id) + if conf, ok = v.(*cfg.GameTDReward).GetDataMap()[id]; !ok { + err = comm.NewNotFoundConfErr(string(this.module.GetType()), game_tdreward, id) this.module.Errorln(err) return } diff --git a/sys/configure/structs/Game.BlockData.go b/sys/configure/structs/Game.BlockData.go index dae61ae12..f0a77356c 100644 --- a/sys/configure/structs/Game.BlockData.go +++ b/sys/configure/structs/Game.BlockData.go @@ -18,6 +18,7 @@ type GameBlockData struct { Belongto int32 Open int32 Icon string + Icon2 string Weight int32 Score int32 Type int32 @@ -51,6 +52,7 @@ func (_v *GameBlockData)Deserialize(_buf map[string]interface{}) (err error) { { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["belongto"].(float64); !_ok_ { err = errors.New("belongto error"); return }; _v.Belongto = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["open"].(float64); !_ok_ { err = errors.New("open error"); return }; _v.Open = int32(_tempNum_) } { var _ok_ bool; if _v.Icon, _ok_ = _buf["icon"].(string); !_ok_ { err = errors.New("icon error"); return } } + { var _ok_ bool; if _v.Icon2, _ok_ = _buf["icon2"].(string); !_ok_ { err = errors.New("icon2 error"); return } } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["weight"].(float64); !_ok_ { err = errors.New("weight error"); return }; _v.Weight = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["score"].(float64); !_ok_ { err = errors.New("score error"); return }; _v.Score = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["type"].(float64); !_ok_ { err = errors.New("type error"); return }; _v.Type = int32(_tempNum_) } diff --git a/sys/configure/structs/Game.ConsumeHeroData.go b/sys/configure/structs/Game.ConsumeHeroData.go index 58698bd4c..b4b1f11f6 100644 --- a/sys/configure/structs/Game.ConsumeHeroData.go +++ b/sys/configure/structs/Game.ConsumeHeroData.go @@ -13,6 +13,8 @@ import "errors" type GameConsumeHeroData struct { Key string Type int32 + Skillname string + Skilltxt string Hero int32 Consume []*Gameatn Skilltype int32 @@ -30,6 +32,8 @@ func (*GameConsumeHeroData) GetTypeId() int32 { func (_v *GameConsumeHeroData)Deserialize(_buf map[string]interface{}) (err error) { { var _ok_ bool; if _v.Key, _ok_ = _buf["key"].(string); !_ok_ { err = errors.New("key error"); return } } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["type"].(float64); !_ok_ { err = errors.New("type error"); return }; _v.Type = int32(_tempNum_) } + {var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["skillname"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Skillname error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Skillname, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } } + {var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["skilltxt"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Skilltxt error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Skilltxt, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["hero"].(float64); !_ok_ { err = errors.New("hero error"); return }; _v.Hero = int32(_tempNum_) } { var _arr_ []interface{} diff --git a/sys/configure/structs/Game.ConsumeIntegral.go b/sys/configure/structs/Game.ConsumeIntegral.go new file mode 100644 index 000000000..116d1a148 --- /dev/null +++ b/sys/configure/structs/Game.ConsumeIntegral.go @@ -0,0 +1,42 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +package cfg + +type GameConsumeIntegral struct { + _dataMap map[int32]*GameConsumeIntegralData + _dataList []*GameConsumeIntegralData +} + +func NewGameConsumeIntegral(_buf []map[string]interface{}) (*GameConsumeIntegral, error) { + _dataList := make([]*GameConsumeIntegralData, 0, len(_buf)) + dataMap := make(map[int32]*GameConsumeIntegralData) + for _, _ele_ := range _buf { + if _v, err2 := DeserializeGameConsumeIntegralData(_ele_); err2 != nil { + return nil, err2 + } else { + _dataList = append(_dataList, _v) + dataMap[_v.Key] = _v + } + } + return &GameConsumeIntegral{_dataList:_dataList, _dataMap:dataMap}, nil +} + +func (table *GameConsumeIntegral) GetDataMap() map[int32]*GameConsumeIntegralData { + return table._dataMap +} + +func (table *GameConsumeIntegral) GetDataList() []*GameConsumeIntegralData { + return table._dataList +} + +func (table *GameConsumeIntegral) Get(key int32) *GameConsumeIntegralData { + return table._dataMap[key] +} + + diff --git a/sys/configure/structs/Game.ConsumeIntegralData.go b/sys/configure/structs/Game.ConsumeIntegralData.go new file mode 100644 index 000000000..323f53c8d --- /dev/null +++ b/sys/configure/structs/Game.ConsumeIntegralData.go @@ -0,0 +1,86 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +package cfg + +import "errors" + +type GameConsumeIntegralData struct { + Key int32 + Type int32 + Onereward []*Gameatn + Rewards []*Gameatn + Boxid int32 + Deductrewards []*Gameatn + Name string +} + +const TypeId_GameConsumeIntegralData = -1538782826 + +func (*GameConsumeIntegralData) GetTypeId() int32 { + return -1538782826 +} + +func (_v *GameConsumeIntegralData)Deserialize(_buf map[string]interface{}) (err error) { + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["key"].(float64); !_ok_ { err = errors.New("key error"); return }; _v.Key = int32(_tempNum_) } + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["type"].(float64); !_ok_ { err = errors.New("type error"); return }; _v.Type = int32(_tempNum_) } + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["onereward"].([]interface{}); !_ok_ { err = errors.New("onereward error"); return } + + _v.Onereward = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Onereward = append(_v.Onereward, _list_v_) + } + } + + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["rewards"].([]interface{}); !_ok_ { err = errors.New("rewards error"); return } + + _v.Rewards = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Rewards = append(_v.Rewards, _list_v_) + } + } + + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["boxid"].(float64); !_ok_ { err = errors.New("boxid error"); return }; _v.Boxid = int32(_tempNum_) } + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["deductrewards"].([]interface{}); !_ok_ { err = errors.New("deductrewards error"); return } + + _v.Deductrewards = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Deductrewards = append(_v.Deductrewards, _list_v_) + } + } + + {var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["name"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Name error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Name, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } } + return +} + +func DeserializeGameConsumeIntegralData(_buf map[string]interface{}) (*GameConsumeIntegralData, error) { + v := &GameConsumeIntegralData{} + if err := v.Deserialize(_buf); err == nil { + return v, nil + } else { + return nil, err + } +} diff --git a/sys/configure/structs/Game.MainStageData.go b/sys/configure/structs/Game.MainStageData.go index e65a04dd3..692f53287 100644 --- a/sys/configure/structs/Game.MainStageData.go +++ b/sys/configure/structs/Game.MainStageData.go @@ -16,6 +16,8 @@ type GameMainStageData struct { GroupId int32 PreviousGroupId []int32 Previoustage int32 + BuriedType int32 + Buried int32 Grouptype []int32 Episodetype int32 StageParam int32 @@ -89,6 +91,8 @@ func (_v *GameMainStageData)Deserialize(_buf map[string]interface{}) (err error) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["previoustage"].(float64); !_ok_ { err = errors.New("previoustage error"); return }; _v.Previoustage = int32(_tempNum_) } + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["buried_type"].(float64); !_ok_ { err = errors.New("buried_type error"); return }; _v.BuriedType = int32(_tempNum_) } + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["buried"].(float64); !_ok_ { err = errors.New("buried error"); return }; _v.Buried = int32(_tempNum_) } { var _arr_ []interface{} var _ok_ bool diff --git a/sys/configure/structs/Game.TDReward.go b/sys/configure/structs/Game.TDReward.go new file mode 100644 index 000000000..f31f28192 --- /dev/null +++ b/sys/configure/structs/Game.TDReward.go @@ -0,0 +1,42 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +package cfg + +type GameTDReward struct { + _dataMap map[int32]*GameTDRewardData + _dataList []*GameTDRewardData +} + +func NewGameTDReward(_buf []map[string]interface{}) (*GameTDReward, error) { + _dataList := make([]*GameTDRewardData, 0, len(_buf)) + dataMap := make(map[int32]*GameTDRewardData) + for _, _ele_ := range _buf { + if _v, err2 := DeserializeGameTDRewardData(_ele_); err2 != nil { + return nil, err2 + } else { + _dataList = append(_dataList, _v) + dataMap[_v.Id] = _v + } + } + return &GameTDReward{_dataList:_dataList, _dataMap:dataMap}, nil +} + +func (table *GameTDReward) GetDataMap() map[int32]*GameTDRewardData { + return table._dataMap +} + +func (table *GameTDReward) GetDataList() []*GameTDRewardData { + return table._dataList +} + +func (table *GameTDReward) Get(key int32) *GameTDRewardData { + return table._dataMap[key] +} + + diff --git a/sys/configure/structs/Game.TDRewardData.go b/sys/configure/structs/Game.TDRewardData.go new file mode 100644 index 000000000..4ec0d8474 --- /dev/null +++ b/sys/configure/structs/Game.TDRewardData.go @@ -0,0 +1,50 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +package cfg + +import "errors" + +type GameTDRewardData struct { + Id int32 + Reward []*Gameatn +} + +const TypeId_GameTDRewardData = 8107621 + +func (*GameTDRewardData) GetTypeId() int32 { + return 8107621 +} + +func (_v *GameTDRewardData)Deserialize(_buf map[string]interface{}) (err error) { + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["id"].(float64); !_ok_ { err = errors.New("id error"); return }; _v.Id = int32(_tempNum_) } + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["reward"].([]interface{}); !_ok_ { err = errors.New("reward error"); return } + + _v.Reward = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Reward = append(_v.Reward, _list_v_) + } + } + + return +} + +func DeserializeGameTDRewardData(_buf map[string]interface{}) (*GameTDRewardData, error) { + v := &GameTDRewardData{} + if err := v.Deserialize(_buf); err == nil { + return v, nil + } else { + return nil, err + } +} diff --git a/sys/configure/structs/Game.TreasureMap.go b/sys/configure/structs/Game.TreasureMap.go new file mode 100644 index 000000000..19b63e5af --- /dev/null +++ b/sys/configure/structs/Game.TreasureMap.go @@ -0,0 +1,42 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +package cfg + +type GameTreasureMap struct { + _dataMap map[int32]*GameTreasureMapData + _dataList []*GameTreasureMapData +} + +func NewGameTreasureMap(_buf []map[string]interface{}) (*GameTreasureMap, error) { + _dataList := make([]*GameTreasureMapData, 0, len(_buf)) + dataMap := make(map[int32]*GameTreasureMapData) + for _, _ele_ := range _buf { + if _v, err2 := DeserializeGameTreasureMapData(_ele_); err2 != nil { + return nil, err2 + } else { + _dataList = append(_dataList, _v) + dataMap[_v.Id] = _v + } + } + return &GameTreasureMap{_dataList:_dataList, _dataMap:dataMap}, nil +} + +func (table *GameTreasureMap) GetDataMap() map[int32]*GameTreasureMapData { + return table._dataMap +} + +func (table *GameTreasureMap) GetDataList() []*GameTreasureMapData { + return table._dataList +} + +func (table *GameTreasureMap) Get(key int32) *GameTreasureMapData { + return table._dataMap[key] +} + + diff --git a/sys/configure/structs/Game.TreasureMapData.go b/sys/configure/structs/Game.TreasureMapData.go new file mode 100644 index 000000000..346028408 --- /dev/null +++ b/sys/configure/structs/Game.TreasureMapData.go @@ -0,0 +1,58 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +package cfg + +import "errors" + +type GameTreasureMapData struct { + Id int32 + Pic string + Unlock []*Gameatn + Name string + Explain string + Describe string +} + +const TypeId_GameTreasureMapData = 1832570747 + +func (*GameTreasureMapData) GetTypeId() int32 { + return 1832570747 +} + +func (_v *GameTreasureMapData)Deserialize(_buf map[string]interface{}) (err error) { + { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["id"].(float64); !_ok_ { err = errors.New("id error"); return }; _v.Id = int32(_tempNum_) } + { var _ok_ bool; if _v.Pic, _ok_ = _buf["pic"].(string); !_ok_ { err = errors.New("pic error"); return } } + { + var _arr_ []interface{} + var _ok_ bool + if _arr_, _ok_ = _buf["unlock"].([]interface{}); !_ok_ { err = errors.New("unlock error"); return } + + _v.Unlock = make([]*Gameatn, 0, len(_arr_)) + + for _, _e_ := range _arr_ { + var _list_v_ *Gameatn + { var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _e_.(map[string]interface{}); !_ok_ { err = errors.New("_list_v_ error"); return }; if _list_v_, err = DeserializeGameatn(_x_); err != nil { return } } + _v.Unlock = append(_v.Unlock, _list_v_) + } + } + + {var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["name"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Name error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Name, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } } + {var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["explain"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Explain error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Explain, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } } + {var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["describe"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Describe error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Describe, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } } + return +} + +func DeserializeGameTreasureMapData(_buf map[string]interface{}) (*GameTreasureMapData, error) { + v := &GameTreasureMapData{} + if err := v.Deserialize(_buf); err == nil { + return v, nil + } else { + return nil, err + } +} diff --git a/sys/configure/structs/Tables.go b/sys/configure/structs/Tables.go index 5940a9567..83c7e7698 100644 --- a/sys/configure/structs/Tables.go +++ b/sys/configure/structs/Tables.go @@ -277,6 +277,9 @@ type Tables struct { GColorGetfraction *GameGColorGetfraction GColorReward *GameGColorReward GColortTmedecay *GameGColortTmedecay + TreasureMap *GameTreasureMap + ConsumeIntegral *GameConsumeIntegral + TDReward *GameTDReward } func NewTables(loader JsonLoader) (*Tables, error) { @@ -1880,5 +1883,23 @@ func NewTables(loader JsonLoader) (*Tables, error) { if tables.GColortTmedecay, err = NewGameGColortTmedecay(buf) ; err != nil { return nil, err } + if buf, err = loader("game_treasuremap") ; err != nil { + return nil, err + } + if tables.TreasureMap, err = NewGameTreasureMap(buf) ; err != nil { + return nil, err + } + if buf, err = loader("game_consumeintegral") ; err != nil { + return nil, err + } + if tables.ConsumeIntegral, err = NewGameConsumeIntegral(buf) ; err != nil { + return nil, err + } + if buf, err = loader("game_tdreward") ; err != nil { + return nil, err + } + if tables.TDReward, err = NewGameTDReward(buf) ; err != nil { + return nil, err + } return tables, nil }