예제 #1
0
func (this *SServerUser) NetConnecterWithMsgHeaderImpProcMsg() error {
	GSLog.Debugln("NetConnecterWithMsgHeaderImpProcMsg")
	GSLog.Debugln(this.M_SMsgHeader)
	GSLog.Debugln(this.M_by2MsgBody)

	msgType := this.MsgType()

	if bsn_msg.IsMsgSys(msgType) {
		return this.procSysMsg(bsn_define.ECmd(msgType))
	}

	return this.procServerMsg(bsn_msg_gate_server.ECmdServe2Gate(msgType))
}
예제 #2
0
func (this *SClientUser) procMsg() error {
	GSLog.Debugln(this.M_SMsgHeader)
	GSLog.Debugln(this.M_by2MsgBody)

	msgType := this.MsgType()

	if bsn_msg.IsMsgSys(msgType) {
		return this.procSysMsg(bsn_define.ECmd(msgType))
	}

	if IsMsgGate(msgType) {
		return this.procGateMsg(bsn_msg_gate_server.ECmdGate2Server(msgType))
	}

	return errors.New(fmt.Sprintf("unknown msg type = %v", msgType))
}
예제 #3
0
func (this *SClientUser) procMsg() error {
	GSLog.Debugln(this.M_SMsgHeader)
	GSLog.Debugln(this.M_by2MsgBody)

	msgType := this.MsgType()

	if bsn_msg.IsMsgSys(msgType) {
		return this.procSysMsg(bsn_define.ECmd(msgType))
	}

	if IsMsgClient(msgType) {
		return this.procClientMsg(bsn_msg_client_gate.ECmdClient2Gate(msgType))
	}

	return this.UserMgr().UserMgr().ServerUserMgr().OnClientMsg(this)
}
예제 #4
0
func (this *SServerUserGateConfig) NetConnecterWithMsgHeaderImpProcMsg() error {
	GSLog.Debugln("NetConnecterWithMsgHeaderImpProcMsg")
	GSLog.Debugln(this.M_SMsgHeader)
	GSLog.Debugln(this.M_by2MsgBody)

	msgType := this.MsgType()

	if bsn_msg.IsMsgSys(msgType) {
		return this.procSysMsg(bsn_define.ECmd(msgType))
	}

	if IsMsgGateConfig(msgType) {
		return this.procGateConfigMsg(bsn_msg_gate_gateconfig.ECmdGateConfig2Gate(msgType))
	}

	return errors.New(fmt.Sprintf("unknown msg type = %v", msgType))
}
예제 #5
0
func (this *SServerUserGate) NetConnecterWithMsgHeaderImpProcMsg() error {
	GSLog.Debugln("NetConnecterWithMsgHeaderImpProcMsg")
	GSLog.Debugln(this.M_SMsgHeader)
	GSLog.Debugln(this.M_by2MsgBody)

	msgType := this.MsgType()

	if bsn_msg.IsMsgSys(msgType) {
		return this.procSysMsg(bsn_define.ECmd(msgType))
	}

	if IsMsgGate(msgType) {
		return this.procGateMsg(bsn_msg_client_gate.ECmdGate2Client(msgType))
	}

	if IsMsgEchoServer(msgType) {
		return this.procEchoServerMsg(bsn_msg_client_echo_server.ECmdEchoServe2Client(msgType))
	}

	return errors.New(fmt.Sprintf("unknown msg type = %v", msgType))
}