gameServer/HWProtoLobbyState.hs
changeset 9702 27006953d901
parent 9448 04e0acfa7c2c
child 9729 6a3640c4f4b7
equal deleted inserted replaced
9700:3034605a4604 9702:27006953d901
    19 
    19 
    20 handleCmd_lobby ["LIST"] = do
    20 handleCmd_lobby ["LIST"] = do
    21     (ci, irnc) <- ask
    21     (ci, irnc) <- ask
    22     let cl = irnc `client` ci
    22     let cl = irnc `client` ci
    23     rooms <- allRoomInfos
    23     rooms <- allRoomInfos
    24     let roomsInfoList = concatMap (\r -> roomInfo (nick $ irnc `client` masterID r) r) . filter (\r -> (roomProto r == clientProto cl))
    24     let roomsInfoList = concatMap (\r -> roomInfo (clientProto cl) (nick $ irnc `client` masterID r) r) . filter (\r -> (roomProto r == clientProto cl))
    25     return [AnswerClients [sendChan cl] ("ROOMS" : roomsInfoList rooms)]
    25     return [AnswerClients [sendChan cl] ("ROOMS" : roomsInfoList rooms)]
    26 
    26 
    27 
    27 
    28 handleCmd_lobby ["CHAT", msg] = do
    28 handleCmd_lobby ["CHAT", msg] = do
    29     n <- clientNick
    29     n <- clientNick