Documentation ¶
Index ¶
- Variables
- func C2S_Login_MessageID() protocol.MessageID
- func C2S_Ping_MessageID() protocol.MessageID
- func C2S_Register_MessageID() protocol.MessageID
- func C2S_TestRepeated_MessageID() protocol.MessageID
- func Check_E_Test(value E_Test) bool
- func Check_E_Test_I(value int32) bool
- func Check_S2C_Login_E_Error(value S2C_Login_E_Error) bool
- func Check_S2C_Login_E_Error_I(value int32) bool
- func Check_S2C_Register_E_Error(value S2C_Register_E_Error) bool
- func Check_S2C_Register_E_Error_I(value int32) bool
- func Check_S2C_Register_E_State(value S2C_Register_E_State) bool
- func Check_S2C_Register_E_State_I(value int32) bool
- func Check_Version(value Version) bool
- func Check_Version_I(value int32) bool
- func E_Test_Len() int
- func Each_E_Test(f func(E_Test) bool)
- func Each_E_Test_I(f func(int32) bool)
- func Each_S2C_Login_E_Error(f func(S2C_Login_E_Error) bool)
- func Each_S2C_Login_E_Error_I(f func(int32) bool)
- func Each_S2C_Register_E_Error(f func(S2C_Register_E_Error) bool)
- func Each_S2C_Register_E_Error_I(f func(int32) bool)
- func Each_S2C_Register_E_State(f func(S2C_Register_E_State) bool)
- func Each_S2C_Register_E_State_I(f func(int32) bool)
- func Each_Version(f func(Version) bool)
- func Each_Version_I(f func(int32) bool)
- func Put_C2S_Login(i interface{})
- func Put_C2S_Ping(i interface{})
- func Put_C2S_Register(i interface{})
- func Put_C2S_TestRepeated(i interface{})
- func Put_Item(i interface{})
- func Put_S2C_Close(i interface{})
- func Put_S2C_Items(i interface{})
- func Put_S2C_Login(i interface{})
- func Put_S2C_Login_ServerInfo(i interface{})
- func Put_S2C_Pong(i interface{})
- func Put_S2C_Register(i interface{})
- func Put_VersionInfo(i interface{})
- func S2C_Close_MessageID() protocol.MessageID
- func S2C_Items_MessageID() protocol.MessageID
- func S2C_Login_E_Error_Len() int
- func S2C_Login_MessageID() protocol.MessageID
- func S2C_Pong_MessageID() protocol.MessageID
- func S2C_Register_E_Error_Len() int
- func S2C_Register_E_State_Len() int
- func S2C_Register_MessageID() protocol.MessageID
- func Version_Len() int
- type C2S_Login
- type C2S_Ping
- type C2S_Register
- type C2S_TestRepeated
- func (m C2S_TestRepeated) Clone() *C2S_TestRepeated
- func (C2S_TestRepeated) Json()
- func (m C2S_TestRepeated) Marshal() (dAtA []byte, err error)
- func (C2S_TestRepeated) MessageID() protocol.MessageID
- func (m *C2S_TestRepeated) Reset()
- func (m C2S_TestRepeated) String() string
- func (m *C2S_TestRepeated) Unmarshal(dAtA []byte) error
- type E_Test
- type Item
- type S2C_Close
- type S2C_Items
- type S2C_Login
- type S2C_Login_E_Error
- type S2C_Login_ServerInfo
- type S2C_Pong
- type S2C_Register
- type S2C_Register_E_Error
- type S2C_Register_E_State
- type Version
- type VersionInfo
Constants ¶
This section is empty.
Variables ¶
View Source
var E_Test_Slice = []int32{
0,
1,
}
View Source
var E_Test_name = map[int32]string{
0: "E_Test_",
1: "E_Test_OK",
}
View Source
var E_Test_value = map[string]int32{
"E_Test_": 0,
"E_Test_OK": 1,
}
View Source
var S2C_Login_E_Error_Slice = []int32{
0,
1,
2,
3,
4,
5,
}
View Source
var S2C_Login_E_Error_name = map[int32]string{
0: "S2C_Login_E_Error_",
1: "S2C_Login_E_Error_OK",
2: "S2C_Login_E_Error_InvalidAccount",
3: "S2C_Login_E_Error_NotExist",
4: "S2C_Login_E_Error_InvalidPassword",
5: "S2C_Login_E_Error_Ban",
}
View Source
var S2C_Login_E_Error_value = map[string]int32{
"S2C_Login_E_Error_": 0,
"S2C_Login_E_Error_OK": 1,
"S2C_Login_E_Error_InvalidAccount": 2,
"S2C_Login_E_Error_NotExist": 3,
"S2C_Login_E_Error_InvalidPassword": 4,
"S2C_Login_E_Error_Ban": 5,
}
View Source
var S2C_Register_E_Error_Slice = []int32{
0,
1,
2,
3,
4,
}
View Source
var S2C_Register_E_Error_name = map[int32]string{
0: "Error_",
1: "OK",
2: "InvalidAccountName",
3: "InvalidPassword",
4: "Exist",
}
View Source
var S2C_Register_E_Error_value = map[string]int32{
"Error_": 0,
"OK": 1,
"InvalidAccountName": 2,
"InvalidPassword": 3,
"Exist": 4,
}
View Source
var S2C_Register_E_State_Slice = []int32{
0,
1,
2,
3,
}
View Source
var S2C_Register_E_State_name = map[int32]string{
0: "State_",
1: "Visitor",
2: "Register",
3: "Bind",
}
View Source
var S2C_Register_E_State_value = map[string]int32{
"State_": 0,
"Visitor": 1,
"Register": 2,
"Bind": 3,
}
View Source
var Version_Slice = []int32{
0,
1,
}
View Source
var Version_name = map[int32]string{
0: "Version_",
1: "Num",
}
View Source
var Version_value = map[string]int32{
"Version_": 0,
"Num": 1,
}
Functions ¶
func C2S_Login_MessageID ¶
func C2S_Ping_MessageID ¶
func C2S_Register_MessageID ¶
func Check_E_Test ¶
func Check_E_Test_I ¶
func Check_S2C_Login_E_Error ¶
func Check_S2C_Login_E_Error(value S2C_Login_E_Error) bool
func Check_S2C_Register_E_Error ¶
func Check_S2C_Register_E_Error(value S2C_Register_E_Error) bool
func Check_S2C_Register_E_State ¶
func Check_S2C_Register_E_State(value S2C_Register_E_State) bool
func Check_Version ¶
func Check_Version_I ¶
func E_Test_Len ¶
func E_Test_Len() int
func Each_E_Test ¶
func Each_E_Test_I ¶
func Each_S2C_Login_E_Error ¶
func Each_S2C_Login_E_Error(f func(S2C_Login_E_Error) bool)
func Each_S2C_Register_E_Error ¶
func Each_S2C_Register_E_Error(f func(S2C_Register_E_Error) bool)
func Each_S2C_Register_E_State ¶
func Each_S2C_Register_E_State(f func(S2C_Register_E_State) bool)
func Each_Version ¶
func Each_Version_I ¶
func Put_C2S_Login ¶
func Put_C2S_Login(i interface{})
func Put_C2S_Ping ¶
func Put_C2S_Ping(i interface{})
func Put_C2S_Register ¶
func Put_C2S_Register(i interface{})
func Put_C2S_TestRepeated ¶
func Put_C2S_TestRepeated(i interface{})
func Put_S2C_Close ¶
func Put_S2C_Close(i interface{})
func Put_S2C_Items ¶
func Put_S2C_Items(i interface{})
func Put_S2C_Login ¶
func Put_S2C_Login(i interface{})
func Put_S2C_Login_ServerInfo ¶
func Put_S2C_Login_ServerInfo(i interface{})
func Put_S2C_Pong ¶
func Put_S2C_Pong(i interface{})
func Put_S2C_Register ¶
func Put_S2C_Register(i interface{})
func Put_VersionInfo ¶
func Put_VersionInfo(i interface{})
func S2C_Close_MessageID ¶
func S2C_Items_MessageID ¶
func S2C_Login_E_Error_Len ¶
func S2C_Login_E_Error_Len() int
func S2C_Login_MessageID ¶
func S2C_Pong_MessageID ¶
func S2C_Register_E_Error_Len ¶
func S2C_Register_E_Error_Len() int
func S2C_Register_E_State_Len ¶
func S2C_Register_E_State_Len() int
func S2C_Register_MessageID ¶
func Version_Len ¶
func Version_Len() int
Types ¶
type C2S_Login ¶
/ 登录请求 @msg
func Clone_C2S_Login_Slice ¶
func Get_C2S_Login ¶
func Get_C2S_Login() *C2S_Login
func New_C2S_Login ¶
func New_C2S_Login() *C2S_Login
type C2S_Ping ¶
type C2S_Ping struct { /// 测试协议1字段1 Content string /// 测试协议1字段2 D float64 /// 测试协议1字段3 F float32 /// 测试协议1字段4 I32 int32 /// 测试协议1字段5 I64 int64 /// 测试协议1字段6 Ui32 uint32 /// 测试协议1字段7 Ui64 uint64 /// 测试协议1字段8 B bool /// 测试协议1字段9 Bytes []byte /// 测试协议1字段10 Info *VersionInfo /// 测试协议1字段11 V Version /// 测试协议1字段12 Infos []*VersionInfo }
/ 测试协议1 @msg
func Clone_C2S_Ping_Slice ¶
func Get_C2S_Ping ¶
func Get_C2S_Ping() *C2S_Ping
func New_C2S_Ping ¶
func New_C2S_Ping() *C2S_Ping
type C2S_Register ¶
/ 注册帐号请求 @msg
func Clone_C2S_Register_Slice ¶
func Clone_C2S_Register_Slice(dst []*C2S_Register, src []*C2S_Register) []*C2S_Register
func Get_C2S_Register ¶
func Get_C2S_Register() *C2S_Register
func New_C2S_Register ¶
func New_C2S_Register() *C2S_Register
func (C2S_Register) Clone ¶
func (m C2S_Register) Clone() *C2S_Register
func (C2S_Register) Json ¶
func (C2S_Register) Json()
func (C2S_Register) Marshal ¶
func (m C2S_Register) Marshal() (dAtA []byte, err error)
func (C2S_Register) MessageID ¶
func (C2S_Register) MessageID() protocol.MessageID
func (*C2S_Register) Reset ¶
func (m *C2S_Register) Reset()
func (C2S_Register) String ¶
func (m C2S_Register) String() string
func (*C2S_Register) Unmarshal ¶
func (m *C2S_Register) Unmarshal(dAtA []byte) error
type C2S_TestRepeated ¶
type C2S_TestRepeated struct { /// 测试协议3字段1 Content []string /// 测试协议3字段2 D []float64 /// 测试协议3字段3 F []float32 /// 测试协议3字段4 I32 []int32 /// 测试协议3字段5 I64 []int64 /// 测试协议3字段6 Ui32 []uint32 /// 测试协议3字段7 Ui64 []uint64 /// 测试协议3字段8 B []bool /// 测试协议3字段9 Bytes [][]byte /// 测试协议3字段10 Infos []*VersionInfo /// 测试协议3字段11 Vs []Version }
/ 测试协议3 @msg
func Clone_C2S_TestRepeated_Slice ¶
func Clone_C2S_TestRepeated_Slice(dst []*C2S_TestRepeated, src []*C2S_TestRepeated) []*C2S_TestRepeated
func Get_C2S_TestRepeated ¶
func Get_C2S_TestRepeated() *C2S_TestRepeated
func New_C2S_TestRepeated ¶
func New_C2S_TestRepeated() *C2S_TestRepeated
func (C2S_TestRepeated) Clone ¶
func (m C2S_TestRepeated) Clone() *C2S_TestRepeated
func (C2S_TestRepeated) Json ¶
func (C2S_TestRepeated) Json()
func (C2S_TestRepeated) Marshal ¶
func (m C2S_TestRepeated) Marshal() (dAtA []byte, err error)
func (C2S_TestRepeated) MessageID ¶
func (C2S_TestRepeated) MessageID() protocol.MessageID
func (*C2S_TestRepeated) Reset ¶
func (m *C2S_TestRepeated) Reset()
func (C2S_TestRepeated) String ¶
func (m C2S_TestRepeated) String() string
func (*C2S_TestRepeated) Unmarshal ¶
func (m *C2S_TestRepeated) Unmarshal(dAtA []byte) error
type S2C_Close ¶
type S2C_Close struct { /// 关闭代码 Err int32 }
/ 连接关闭 @msg
func Clone_S2C_Close_Slice ¶
func Get_S2C_Close ¶
func Get_S2C_Close() *S2C_Close
func New_S2C_Close ¶
func New_S2C_Close() *S2C_Close
type S2C_Items ¶
/ 下发物品信息 @msg
func Clone_S2C_Items_Slice ¶
func Get_S2C_Items ¶
func Get_S2C_Items() *S2C_Items
func New_S2C_Items ¶
func New_S2C_Items() *S2C_Items
type S2C_Login ¶
type S2C_Login struct { /// 错误码 Err S2C_Login_E_Error /// 密钥 Key string /// 服务器列表 Server []*S2C_Login_ServerInfo /// 上次登录服务器ID LastLoginServerID int32 }
/ 登录回复 @msg
func Clone_S2C_Login_Slice ¶
func Get_S2C_Login ¶
func Get_S2C_Login() *S2C_Login
func New_S2C_Login ¶
func New_S2C_Login() *S2C_Login
type S2C_Login_E_Error ¶
type S2C_Login_E_Error int32
/ 登录错误码枚举
const ( S2C_Login_E_Error_ S2C_Login_E_Error = 0 /// 成功 S2C_Login_E_Error_OK S2C_Login_E_Error = 1 /// 非法帐号 S2C_Login_E_Error_InvalidAccount S2C_Login_E_Error = 2 /// 帐号不存在 S2C_Login_E_Error_NotExist S2C_Login_E_Error = 3 /// 非法密码 S2C_Login_E_Error_InvalidPassword S2C_Login_E_Error = 4 /// 已封号 S2C_Login_E_Error_Ban S2C_Login_E_Error = 5 )
func (S2C_Login_E_Error) String ¶
func (x S2C_Login_E_Error) String() string
type S2C_Login_ServerInfo ¶
type S2C_Login_ServerInfo struct { /// 服务器ID ID int32 /// 服务器地址 = ip+端口+path, 例如: ws://127.0.0.1:8080/region1 Addr string /// 服务器名 Name string }
/ 服务器信息
func Clone_S2C_Login_ServerInfo_Slice ¶
func Clone_S2C_Login_ServerInfo_Slice(dst []*S2C_Login_ServerInfo, src []*S2C_Login_ServerInfo) []*S2C_Login_ServerInfo
func Get_S2C_Login_ServerInfo ¶
func Get_S2C_Login_ServerInfo() *S2C_Login_ServerInfo
func New_S2C_Login_ServerInfo ¶
func New_S2C_Login_ServerInfo() *S2C_Login_ServerInfo
func (S2C_Login_ServerInfo) Clone ¶
func (m S2C_Login_ServerInfo) Clone() *S2C_Login_ServerInfo
func (S2C_Login_ServerInfo) Marshal ¶
func (m S2C_Login_ServerInfo) Marshal() (dAtA []byte, err error)
func (*S2C_Login_ServerInfo) Reset ¶
func (m *S2C_Login_ServerInfo) Reset()
func (S2C_Login_ServerInfo) String ¶
func (m S2C_Login_ServerInfo) String() string
func (*S2C_Login_ServerInfo) Unmarshal ¶
func (m *S2C_Login_ServerInfo) Unmarshal(dAtA []byte) error
type S2C_Pong ¶
type S2C_Pong struct { /// 测试协议2字段1 Content string /// 测试协议2字段2 D float64 /// 测试协议2字段3 F float32 /// 测试协议2字段4 I32 int32 /// 测试协议2字段5 I64 int64 /// 测试协议2字段6 Ui32 uint32 /// 测试协议2字段7 Ui64 uint64 /// 测试协议2字段8 B bool /// 测试协议2字段9 Bytes []byte /// 测试协议2字段10 Info *VersionInfo /// 测试协议1字段11 V Version /// 测试协议1字段12 Infos []*VersionInfo }
/ 测试协议2 @msg
func Clone_S2C_Pong_Slice ¶
func Get_S2C_Pong ¶
func Get_S2C_Pong() *S2C_Pong
func New_S2C_Pong ¶
func New_S2C_Pong() *S2C_Pong
type S2C_Register ¶
type S2C_Register struct { /// 错误码 Err S2C_Register_E_Error /// 帐号名 AccountName string /// 密码 Password string /// 状态 State S2C_Register_E_State }
/ 注册帐号结果 @msg
func Clone_S2C_Register_Slice ¶
func Clone_S2C_Register_Slice(dst []*S2C_Register, src []*S2C_Register) []*S2C_Register
func Get_S2C_Register ¶
func Get_S2C_Register() *S2C_Register
func New_S2C_Register ¶
func New_S2C_Register() *S2C_Register
func (S2C_Register) Clone ¶
func (m S2C_Register) Clone() *S2C_Register
func (S2C_Register) Json ¶
func (S2C_Register) Json()
func (S2C_Register) Marshal ¶
func (m S2C_Register) Marshal() (dAtA []byte, err error)
func (S2C_Register) MessageID ¶
func (S2C_Register) MessageID() protocol.MessageID
func (*S2C_Register) Reset ¶
func (m *S2C_Register) Reset()
func (S2C_Register) String ¶
func (m S2C_Register) String() string
func (*S2C_Register) Unmarshal ¶
func (m *S2C_Register) Unmarshal(dAtA []byte) error
type S2C_Register_E_Error ¶
type S2C_Register_E_Error int32
/ 错误码
const ( Error_ S2C_Register_E_Error = 0 /// 成功 OK S2C_Register_E_Error = 1 /// 无效帐号名 InvalidAccountName S2C_Register_E_Error = 2 /// 无效密码 InvalidPassword S2C_Register_E_Error = 3 /// 已存在 Exist S2C_Register_E_Error = 4 )
func (S2C_Register_E_Error) String ¶
func (x S2C_Register_E_Error) String() string
type S2C_Register_E_State ¶
type S2C_Register_E_State int32
/ 注册返回的帐号状态
const ( State_ S2C_Register_E_State = 0 /// 游客 Visitor S2C_Register_E_State = 1 /// 注册 Register S2C_Register_E_State = 2 /// 绑定 Bind S2C_Register_E_State = 3 )
func (S2C_Register_E_State) String ¶
func (x S2C_Register_E_State) String() string
type VersionInfo ¶
type VersionInfo struct { /// 测试协议5字段1 Content string /// 测试协议5字段2 D float64 /// 测试协议5字段3 F float32 /// 测试协议5字段4 I32 int32 /// 测试协议5字段5 I64 int64 /// 测试协议5字段6 Ui32 uint32 /// 测试协议5字段7 Ui64 uint64 /// 测试协议5字段8 B bool /// 测试协议5字段9 Bytes []byte }
/ 版本信息
func Clone_VersionInfo_Slice ¶
func Clone_VersionInfo_Slice(dst []*VersionInfo, src []*VersionInfo) []*VersionInfo
func Get_VersionInfo ¶
func Get_VersionInfo() *VersionInfo
func New_VersionInfo ¶
func New_VersionInfo() *VersionInfo
func (VersionInfo) Clone ¶
func (m VersionInfo) Clone() *VersionInfo
func (VersionInfo) Marshal ¶
func (m VersionInfo) Marshal() (dAtA []byte, err error)
func (*VersionInfo) Reset ¶
func (m *VersionInfo) Reset()
func (VersionInfo) String ¶
func (m VersionInfo) String() string
func (*VersionInfo) Unmarshal ¶
func (m *VersionInfo) Unmarshal(dAtA []byte) error
Click to show internal directories.
Click to hide internal directories.