Esempio n. 1
0
func (svc *UpdateService) NewClient(conn *server.Connection, service int) server.Client {
	conn.Log().Info("new update client")
	conn.Write <- new(protocol.OutboundUpdateHandshake)
	return NewUpdateClient(conn, svc)
}
Esempio n. 2
0
func (svc *GameService) NewClient(conn *server.Connection, service int) server.Client {
	conn.Log().Info("new game client")
	client := playerimpl.NewPlayer(conn, svc.world)
	client.SetDecodeFunc(svc.handshake)
	return client
}