88 lines
4.2 KiB
Go
88 lines
4.2 KiB
Go
//------------------------------------------------------------------------------
|
|
// <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 GameWorldTaskData struct {
|
|
Key int32
|
|
Lock int32
|
|
Ontxe int32
|
|
IdAfter int32
|
|
Des int32
|
|
Icon string
|
|
TaskName string
|
|
TaskDisplay string
|
|
Npc string
|
|
GetafterEvent []string
|
|
Completetask int32
|
|
AutoAccept int32
|
|
Overtips int32
|
|
Reword []*Gameatn
|
|
}
|
|
|
|
const TypeId_GameWorldTaskData = -1059668091
|
|
|
|
func (*GameWorldTaskData) GetTypeId() int32 {
|
|
return -1059668091
|
|
}
|
|
|
|
func (_v *GameWorldTaskData)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["lock"].(float64); !_ok_ { err = errors.New("lock error"); return }; _v.Lock = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["ontxe"].(float64); !_ok_ { err = errors.New("ontxe error"); return }; _v.Ontxe = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["id_after"].(float64); !_ok_ { err = errors.New("id_after error"); return }; _v.IdAfter = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["des"].(float64); !_ok_ { err = errors.New("des error"); return }; _v.Des = int32(_tempNum_) }
|
|
{ var _ok_ bool; if _v.Icon, _ok_ = _buf["icon"].(string); !_ok_ { err = errors.New("icon error"); return } }
|
|
{ var _ok_ bool; if _v.TaskName, _ok_ = _buf["task_name"].(string); !_ok_ { err = errors.New("task_name error"); return } }
|
|
{ var _ok_ bool; if _v.TaskDisplay, _ok_ = _buf["task_display"].(string); !_ok_ { err = errors.New("task_display error"); return } }
|
|
{ var _ok_ bool; if _v.Npc, _ok_ = _buf["npc"].(string); !_ok_ { err = errors.New("npc error"); return } }
|
|
{
|
|
var _arr_ []interface{}
|
|
var _ok_ bool
|
|
if _arr_, _ok_ = _buf["getafter_event"].([]interface{}); !_ok_ { err = errors.New("getafter_event error"); return }
|
|
|
|
_v.GetafterEvent = make([]string, 0, len(_arr_))
|
|
|
|
for _, _e_ := range _arr_ {
|
|
var _list_v_ string
|
|
{ if _list_v_, _ok_ = _e_.(string); !_ok_ { err = errors.New("_list_v_ error"); return } }
|
|
_v.GetafterEvent = append(_v.GetafterEvent, _list_v_)
|
|
}
|
|
}
|
|
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["completetask"].(float64); !_ok_ { err = errors.New("completetask error"); return }; _v.Completetask = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["auto_accept"].(float64); !_ok_ { err = errors.New("auto_accept error"); return }; _v.AutoAccept = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["overtips"].(float64); !_ok_ { err = errors.New("overtips error"); return }; _v.Overtips = int32(_tempNum_) }
|
|
{
|
|
var _arr_ []interface{}
|
|
var _ok_ bool
|
|
if _arr_, _ok_ = _buf["reword"].([]interface{}); !_ok_ { err = errors.New("reword error"); return }
|
|
|
|
_v.Reword = 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.Reword = append(_v.Reword, _list_v_)
|
|
}
|
|
}
|
|
|
|
return
|
|
}
|
|
|
|
func DeserializeGameWorldTaskData(_buf map[string]interface{}) (*GameWorldTaskData, error) {
|
|
v := &GameWorldTaskData{}
|
|
if err := v.Deserialize(_buf); err == nil {
|
|
return v, nil
|
|
} else {
|
|
return nil, err
|
|
}
|
|
}
|