上传配置

This commit is contained in:
liwei 2023-07-12 16:07:26 +08:00
parent 17df04439d
commit 164067f12e
16 changed files with 1331 additions and 1411 deletions

View File

@ -406,7 +406,7 @@
"battleScenes": [
"bossfight_naturetitan_01"
],
"disableAiCamera": 1,
"disableAiCamera": 0,
"ChoseCamp": [],
"DisableCamp": [],
"DefaultHero": 0,
@ -444,7 +444,7 @@
"battleScenes": [
"bossfight_chef_01"
],
"disableAiCamera": 1,
"disableAiCamera": 0,
"ChoseCamp": [],
"DisableCamp": [],
"DefaultHero": 0,

File diff suppressed because it is too large Load Diff

View File

@ -23,12 +23,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
},
{
@ -55,7 +69,7 @@
"n5pool": "base_pool20005",
"baodi4": 10,
"baidi5": 100,
"etime": -1,
"etime": 15,
"permission": 1,
"consumeA": [
{
@ -64,12 +78,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
},
{
@ -96,12 +124,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000021",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
},
{
@ -128,12 +170,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000022",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
},
{
@ -160,12 +216,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000023",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
},
{
@ -192,12 +262,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000024",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
},
{
@ -224,12 +308,26 @@
"n": 1
}
],
"consumeB": [
"consumeA10": [
{
"a": "item",
"t": "10000024",
"t": "10000001",
"n": 10
}
],
"consumeB": [
{
"a": "attr",
"t": "gold",
"n": 10
}
],
"consumeB10": [
{
"a": "attr",
"t": "gold",
"n": 100
}
]
}
]

View File

@ -0,0 +1,50 @@
[
{
"id": 1,
"pool": 1,
"hero_initial": "25001",
"hero_replace": "25001",
"replace_cd": 0,
"replace_num": 0
},
{
"id": 2,
"pool": 1,
"hero_initial": "25001",
"hero_replace": "24002",
"replace_cd": 0,
"replace_num": 0
},
{
"id": 3,
"pool": 1,
"hero_initial": "25001",
"hero_replace": "13003",
"replace_cd": 0,
"replace_num": 0
},
{
"id": 4,
"pool": 2,
"hero_initial": "35001",
"hero_replace": "35001",
"replace_cd": 5184000,
"replace_num": 60
},
{
"id": 5,
"pool": 2,
"hero_initial": "35001",
"hero_replace": "43006",
"replace_cd": 5184000,
"replace_num": 120
},
{
"id": 6,
"pool": 2,
"hero_initial": "35001",
"hero_replace": "43001",
"replace_cd": 5184000,
"replace_num": 200
}
]

View File

@ -0,0 +1,98 @@
[
{
"num": 20,
"text": {
"key": "drawcard_drawcard_reward_text20",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 1
}
},
{
"num": 40,
"text": {
"key": "drawcard_drawcard_reward_text40",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 1
}
},
{
"num": 60,
"text": {
"key": "drawcard_drawcard_reward_text60",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 1
}
},
{
"num": 80,
"text": {
"key": "drawcard_drawcard_reward_text80",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 1
}
},
{
"num": 100,
"text": {
"key": "drawcard_drawcard_reward_text100",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 10
}
},
{
"num": 120,
"text": {
"key": "drawcard_drawcard_reward_text120",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 5
}
},
{
"num": 150,
"text": {
"key": "drawcard_drawcard_reward_text150",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 5
}
},
{
"num": 200,
"text": {
"key": "drawcard_drawcard_reward_text200",
"text": "{0}抽"
},
"reward": {
"a": "item",
"t": "10000001",
"n": 10
}
}
]

View File

@ -218,43 +218,5 @@
15008,
15009
]
},
{
"shopid": 7,
"tab": 7,
"shopname": {
"key": "shop_shop_shopname_7",
"text": "铁匠商店"
},
"upper_shop": {
"key": "shop_shop_upper_shop_7",
"text": "玩法商店"
},
"needshow": [
{
"a": "attr",
"t": "diamond",
"n": 1
}
],
"rtype": 2,
"rtime": 7,
"rnum": -1,
"rneed": [],
"shopitem": [
16001,
16002,
16003,
16004,
16005,
16006,
16007,
16008,
16009,
16010,
16011,
16012,
16013
]
}
]

View File

@ -71,474 +71,6 @@
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 6,
"id": 16001,
"iteminfo": [
{
"a": "item",
"t": "13001001",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 7,
"id": 16002,
"iteminfo": [
{
"a": "item",
"t": "13001002",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 8,
"id": 16003,
"iteminfo": [
{
"a": "item",
"t": "13001003",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 9,
"id": 16004,
"iteminfo": [
{
"a": "item",
"t": "13002001",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 10,
"id": 16005,
"iteminfo": [
{
"a": "item",
"t": "13002002",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 11,
"id": 16006,
"iteminfo": [
{
"a": "item",
"t": "13002003",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 12,
"id": 16007,
"iteminfo": [
{
"a": "item",
"t": "13003001",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 13,
"id": 16008,
"iteminfo": [
{
"a": "item",
"t": "13003002",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 14,
"id": 16009,
"iteminfo": [
{
"a": "item",
"t": "13003003",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 15,
"id": 16010,
"iteminfo": [
{
"a": "item",
"t": "13000001",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 16,
"id": 16011,
"iteminfo": [
{
"a": "item",
"t": "13000002",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 17,
"id": 16012,
"iteminfo": [
{
"a": "item",
"t": "13000003",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 18,
"id": 16013,
"iteminfo": [
{
"a": "item",
"t": "13000004",
"n": 100
}
],
"preview": false,
"probability": 1000,
"need": [
{
"a": "attr",
"t": "diamond",
"n": 20
}
],
"sale": 1000,
"salelist": [
1000,
1000,
1000,
1000,
1000,
1000
],
"buyminnum": 999,
"buymaxnum": 999,
"vip": 0,
"lvmin": 1,
"lvmax": 60,
"mapidmin": 101,
"mapidmax": 9999
},
{
"key": 19,
"id": 10001,

View File

@ -535,7 +535,7 @@ type (
//练功房
IPasson interface {
//英雄升级
HeroUpLv(uid string, heroid string, lv int32)
HeroUpLv(session IUserSession, heroid string, lv int32)
}
// 世界任务
IWtask interface {

View File

@ -598,7 +598,7 @@ func (this *ModelHero) AddCardExp(session comm.IUserSession, hero *pb.DBHero, ex
szTask = append(szTask, comm.GetBuriedParam(comm.Rtype113, hero.Lv))
szTask = append(szTask, comm.GetBuriedParam(comm.Rtype33, 1, 1, hero.Lv))
szTask = append(szTask, comm.GetBuriedParam(comm.Rtype118, hero.Lv, hero.JuexingLv))
go this.module.passon.HeroUpLv(session.GetUserId(), hero.HeroID, curLv)
go this.module.passon.HeroUpLv(session.Clone(), hero.HeroID, curLv)
go this.module.ModuleBuried.TriggerBuried(session.Clone(), szTask...)
}

View File

@ -53,7 +53,7 @@ func (this *Passon) Start() (err error) {
}
// 英雄升级
func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
func (this *Passon) HeroUpLv(session comm.IUserSession, heroid string, lv int32) {
var (
passon *pb.DBPasson
heros []*pb.DBHero
@ -61,7 +61,7 @@ func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
errdata *pb.ErrorData
err error
)
if passon, err = this.modelPasson.getUserPasson(uid); err != nil {
if passon, err = this.modelPasson.getUserPasson(session.GetUserId()); err != nil {
this.Error("getUserPasson err", log.Field{Key: "err", Value: err.Error()})
return
}
@ -75,7 +75,7 @@ func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
}
}
heros = this.ModuleHero.GetHeroList(uid)
heros = this.ModuleHero.GetHeroList(session.GetUserId())
// 使用sort.Slice进行排序
sort.Slice(heros, func(i, j int) bool {
return heros[i].Lv > heros[j].Lv
@ -85,7 +85,7 @@ func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
for i, v := range heros {
passon.Teacher[i] = v.Id
}
if err = this.modelPasson.updateUserPasson(uid, passon); err != nil {
if err = this.modelPasson.updateUserPasson(session.GetUserId(), passon); err != nil {
this.Errorln(err)
return
}
@ -106,7 +106,6 @@ func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
passon.Teacher[i] = heros[i].Id
}
session, _ := this.GetUserSession(uid)
defer func() {
session.Push()
this.PutUserSession(session)
@ -114,6 +113,7 @@ func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
if len(change) > 0 {
if errdata = this.ModuleHero.PassonHero(session, change); errdata != nil {
this.Errorln(errdata)
return
}
}
@ -126,7 +126,7 @@ func (this *Passon) HeroUpLv(uid string, heroid string, lv int32) {
session.SendMsg(string(this.GetType()), "lvchange", &pb.PassonLvChangePush{Lv: passon.Passonlv})
}
if err = this.modelPasson.updateUserPasson(uid, passon); err != nil {
if err = this.modelPasson.updateUserPasson(session.GetUserId(), passon); err != nil {
this.Errorln(err)
return
}

View File

@ -1152,7 +1152,7 @@ var File_errorcode_proto protoreflect.FileDescriptor
var file_errorcode_proto_rawDesc = []byte{
0x0a, 0x0f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74,
0x6f, 0x2a, 0xa1, 0x40, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12,
0x6f, 0x2a, 0x8c, 0x40, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12,
0x0b, 0x0a, 0x07, 0x53, 0x75, 0x63, 0x63, 0x65, 0x73, 0x73, 0x10, 0x00, 0x12, 0x14, 0x0a, 0x10,
0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x45, 0x78, 0x63, 0x65, 0x70, 0x74, 0x69, 0x6f, 0x6e,
0x10, 0x01, 0x12, 0x11, 0x0a, 0x0d, 0x4e, 0x6f, 0x46, 0x69, 0x6e, 0x64, 0x53, 0x65, 0x72, 0x76,
@ -1665,9 +1665,7 @@ var file_errorcode_proto_rawDesc = []byte{
0x61, 0x73, 0x73, 0x6f, 0x6e, 0x48, 0x65, 0x72, 0x6f, 0x55, 0x6e, 0x61, 0x76, 0x61, 0x69, 0x6c,
0x61, 0x62, 0x6c, 0x65, 0x10, 0xde, 0x24, 0x12, 0x17, 0x0a, 0x12, 0x50, 0x61, 0x73, 0x73, 0x6f,
0x6e, 0x53, 0x65, 0x61, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x45, 0x72, 0x72, 0x10, 0xdf, 0x24,
0x12, 0x13, 0x0a, 0x0e, 0x57, 0x61, 0x72, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x4e, 0x6f, 0x4f, 0x70,
0x65, 0x6e, 0x10, 0xc1, 0x25, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x33,
0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (

View File

@ -0,0 +1,42 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
package cfg
type GamedrawReplace struct {
_dataMap map[int32]*GamedrawReplaceData
_dataList []*GamedrawReplaceData
}
func NewGamedrawReplace(_buf []map[string]interface{}) (*GamedrawReplace, error) {
_dataList := make([]*GamedrawReplaceData, 0, len(_buf))
dataMap := make(map[int32]*GamedrawReplaceData)
for _, _ele_ := range _buf {
if _v, err2 := DeserializeGamedrawReplaceData(_ele_); err2 != nil {
return nil, err2
} else {
_dataList = append(_dataList, _v)
dataMap[_v.Id] = _v
}
}
return &GamedrawReplace{_dataList:_dataList, _dataMap:dataMap}, nil
}
func (table *GamedrawReplace) GetDataMap() map[int32]*GamedrawReplaceData {
return table._dataMap
}
func (table *GamedrawReplace) GetDataList() []*GamedrawReplaceData {
return table._dataList
}
func (table *GamedrawReplace) Get(key int32) *GamedrawReplaceData {
return table._dataMap[key]
}

View File

@ -0,0 +1,45 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
package cfg
import "errors"
type GamedrawReplaceData struct {
Id int32
Pool int32
HeroInitial string
HeroReplace string
ReplaceCd int32
ReplaceNum int32
}
const TypeId_GamedrawReplaceData = 1468145342
func (*GamedrawReplaceData) GetTypeId() int32 {
return 1468145342
}
func (_v *GamedrawReplaceData)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; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["pool"].(float64); !_ok_ { err = errors.New("pool error"); return }; _v.Pool = int32(_tempNum_) }
{ var _ok_ bool; if _v.HeroInitial, _ok_ = _buf["hero_initial"].(string); !_ok_ { err = errors.New("hero_initial error"); return } }
{ var _ok_ bool; if _v.HeroReplace, _ok_ = _buf["hero_replace"].(string); !_ok_ { err = errors.New("hero_replace error"); return } }
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["replace_cd"].(float64); !_ok_ { err = errors.New("replace_cd error"); return }; _v.ReplaceCd = int32(_tempNum_) }
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["replace_num"].(float64); !_ok_ { err = errors.New("replace_num error"); return }; _v.ReplaceNum = int32(_tempNum_) }
return
}
func DeserializeGamedrawReplaceData(_buf map[string]interface{}) (*GamedrawReplaceData, error) {
v := &GamedrawReplaceData{}
if err := v.Deserialize(_buf); err == nil {
return v, nil
} else {
return nil, err
}
}

View File

@ -0,0 +1,42 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
package cfg
type GamedrawReward struct {
_dataMap map[int32]*GamedrawRewardData
_dataList []*GamedrawRewardData
}
func NewGamedrawReward(_buf []map[string]interface{}) (*GamedrawReward, error) {
_dataList := make([]*GamedrawRewardData, 0, len(_buf))
dataMap := make(map[int32]*GamedrawRewardData)
for _, _ele_ := range _buf {
if _v, err2 := DeserializeGamedrawRewardData(_ele_); err2 != nil {
return nil, err2
} else {
_dataList = append(_dataList, _v)
dataMap[_v.Num] = _v
}
}
return &GamedrawReward{_dataList:_dataList, _dataMap:dataMap}, nil
}
func (table *GamedrawReward) GetDataMap() map[int32]*GamedrawRewardData {
return table._dataMap
}
func (table *GamedrawReward) GetDataList() []*GamedrawRewardData {
return table._dataList
}
func (table *GamedrawReward) Get(key int32) *GamedrawRewardData {
return table._dataMap[key]
}

View File

@ -0,0 +1,39 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
package cfg
import "errors"
type GamedrawRewardData struct {
Num int32
Text string
Reward *Gameatn
}
const TypeId_GamedrawRewardData = 1862777145
func (*GamedrawRewardData) GetTypeId() int32 {
return 1862777145
}
func (_v *GamedrawRewardData)Deserialize(_buf map[string]interface{}) (err error) {
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["num"].(float64); !_ok_ { err = errors.New("num error"); return }; _v.Num = int32(_tempNum_) }
{var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["text"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Text error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Text, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } }
{ var _ok_ bool; var _x_ map[string]interface{}; if _x_, _ok_ = _buf["reward"].(map[string]interface{}); !_ok_ { err = errors.New("reward error"); return }; if _v.Reward, err = DeserializeGameatn(_x_); err != nil { return } }
return
}
func DeserializeGamedrawRewardData(_buf map[string]interface{}) (*GamedrawRewardData, error) {
v := &GamedrawRewardData{}
if err := v.Deserialize(_buf); err == nil {
return v, nil
} else {
return nil, err
}
}

View File

@ -186,6 +186,8 @@ type Tables struct {
Robot *GameRobot
Passon *GamePasson
Circulate *GameCirculate
drawReward *GamedrawReward
drawReplace *GamedrawReplace
}
func NewTables(loader JsonLoader) (*Tables, error) {
@ -1243,5 +1245,17 @@ func NewTables(loader JsonLoader) (*Tables, error) {
if tables.Circulate, err = NewGameCirculate(buf) ; err != nil {
return nil, err
}
if buf, err = loader("game_drawreward") ; err != nil {
return nil, err
}
if tables.drawReward, err = NewGamedrawReward(buf) ; err != nil {
return nil, err
}
if buf, err = loader("game_drawreplace") ; err != nil {
return nil, err
}
if tables.drawReplace, err = NewGamedrawReplace(buf) ; err != nil {
return nil, err
}
return tables, nil
}