示例#1
0
文件: user.go 项目: chogaths/robin
// 只创建了用户对象的原始用户
func RawUserHandler(ses *netdef.Session, c netdef.IPacketContext) {

	u := GetUser(ses)

	if u == nil {
		c.CancelRoute()
		return
	}

	c.Map(u)
}
示例#2
0
文件: user.go 项目: chogaths/robin
// 进入游戏前的用户
func AccountHandler(ses *netdef.Session, c netdef.IPacketContext) {

	u := GetUser(ses)

	if u == nil || !u.VerifyOK || u.EnterGameOK {
		c.CancelRoute()
		return
	}

	c.Map(u)
}