//------------------------------------------------------------------------------ // // 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 GameBuzkashiOpenData struct { Num int32 Shtime int32 Smtime int32 Ehtime int32 Emtime int32 } const TypeId_GameBuzkashiOpenData = 778618407 func (*GameBuzkashiOpenData) GetTypeId() int32 { return 778618407 } func (_v *GameBuzkashiOpenData)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 _tempNum_ float64; if _tempNum_, _ok_ = _buf["shtime"].(float64); !_ok_ { err = errors.New("shtime error"); return }; _v.Shtime = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["smtime"].(float64); !_ok_ { err = errors.New("smtime error"); return }; _v.Smtime = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["ehtime"].(float64); !_ok_ { err = errors.New("ehtime error"); return }; _v.Ehtime = int32(_tempNum_) } { var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["emtime"].(float64); !_ok_ { err = errors.New("emtime error"); return }; _v.Emtime = int32(_tempNum_) } return } func DeserializeGameBuzkashiOpenData(_buf map[string]interface{}) (*GameBuzkashiOpenData, error) { v := &GameBuzkashiOpenData{} if err := v.Deserialize(_buf); err == nil { return v, nil } else { return nil, err } }