X-Git-Url: https://git.r.bdr.sh/rbdr/mobius/blobdiff_plain/c789e2f35ea97fe2b390cf06dc1c914b913b7535..623eecee59af710eaae93033b9ff4c419d9d4cba:/hotline/server.go?ds=sidebyside diff --git a/hotline/server.go b/hotline/server.go index 9cf93d0..8d6803b 100644 --- a/hotline/server.go +++ b/hotline/server.go @@ -33,13 +33,8 @@ type requestCtx struct { name string } -const ( - userIdleSeconds = 300 // time in seconds before an inactive user is marked idle - idleCheckInterval = 10 // time in seconds to check for idle users - trackerUpdateFrequency = 300 // time in seconds between tracker re-registration -) - var nostalgiaVersion = []byte{0, 0, 2, 0x2c} // version ID used by the Nostalgia client +var frogblastVersion = []byte{0, 0, 0, 0xb9} // version ID used by the Frogblast 1.2.4 client type Server struct { Port int @@ -673,7 +668,7 @@ func (s *Server) handleNewConnection(ctx context.Context, rwc io.ReadWriteCloser } // Used simplified hotline v1.2.3 login flow for clients that do not send login info in tranAgreed - if c.Version == nil || bytes.Equal(c.Version, nostalgiaVersion) { + if c.Version == nil || bytes.Equal(c.Version, nostalgiaVersion) || bytes.Equal(c.Version, frogblastVersion) { c.Agreed = true c.logger = c.logger.With("name", string(c.UserName)) c.logger.Infow("Login successful", "clientVersion", fmt.Sprintf("%v", func() int { i, _ := byteToInt(c.Version); return i }()))