gameServer/HWProtoLobbyState.hs
changeset 4984 20da3c5c7dee
parent 4983 1c9381181e85
child 4989 4771fed9272e
equal deleted inserted replaced
4983:1c9381181e85 4984:20da3c5c7dee
   106 
   106 
   107         toAnswer cl (paramName, paramStrs) = AnswerClients [sendChan cl] $ "CFG" : paramName : paramStrs
   107         toAnswer cl (paramName, paramStrs) = AnswerClients [sendChan cl] $ "CFG" : paramName : paramStrs
   108 
   108 
   109         answerFullConfig cl mpr pr
   109         answerFullConfig cl mpr pr
   110             | clientProto cl < 38 = map (toAnswer cl) $
   110             | clientProto cl < 38 = map (toAnswer cl) $
   111                  (map (\(a, b) -> (a, [b])) $ Map.toList mpr)
   111                  (reverse . map (\(a, b) -> (a, [b])) $ Map.toList mpr)
   112                  ++ (("SCHEME", pr Map.! "SCHEME")
   112                  ++ (("SCHEME", pr Map.! "SCHEME")
   113                  ++ (("SEED", pr Map.! "SEED")
   113                  : (filter (\(p, _) -> p /= "SCHEME") $ Map.toList pr))
   114                  : (filter (\(p, _) -> p /= "SCHEME" && p /= "SEED") $ Map.toList pr))
       
   115 
   114 
   116             | otherwise = map (toAnswer cl) $
   115             | otherwise = map (toAnswer cl) $
   117                  ("FULLMAPCONFIG", Map.elems mpr)
   116                  ("FULLMAPCONFIG", Map.elems mpr)
   118                  : ("SCHEME", pr Map.! "SCHEME")
   117                  : ("SCHEME", pr Map.! "SCHEME")
   119                  : (filter (\(p, _) -> p /= "SCHEME") $ Map.toList pr)
   118                  : (filter (\(p, _) -> p /= "SCHEME") $ Map.toList pr)