# HG changeset patch
# User unc0rr
# Date 1313425891 -14400
# Node ID cc409ee3ad2e86463df7970fc74e60f88a445419
# Parent  47cc28299baa91e2dd76388f14c68aabeb862f6f
Don't allow to join other protocol room using FOLLOW command (not tested)

diff -r 47cc28299baa -r cc409ee3ad2e gameServer/HWProtoLobbyState.hs
--- a/gameServer/HWProtoLobbyState.hs	Mon Aug 15 20:18:18 2011 +0400
+++ b/gameServer/HWProtoLobbyState.hs	Mon Aug 15 20:31:31 2011 +0400
@@ -132,9 +132,10 @@
 handleCmd_lobby ["FOLLOW", asknick] = do
     (_, rnc) <- ask
     ci <- clientByNick asknick
+    cl <- thisClient
     let ri = clientRoom rnc $ fromJust ci
     let clRoom = room rnc ri
-    if isNothing ci || ri == lobbyId then
+    if isNothing ci || ri == lobbyId || clientProto cl /= roomProto clRoom then
         return []
         else
         handleCmd_lobby ["JOIN_ROOM", name clRoom]