equal
deleted
inserted
replaced
31 client's :: (ClientInfo -> a) -> StateT ServerState IO a |
31 client's :: (ClientInfo -> a) -> StateT ServerState IO a |
32 client's f = do |
32 client's f = do |
33 (Just ci) <- gets clientIndex |
33 (Just ci) <- gets clientIndex |
34 rnc <- gets roomsClients |
34 rnc <- gets roomsClients |
35 liftIO $ client'sM rnc f ci |
35 liftIO $ client'sM rnc f ci |
36 |
36 |
37 allClientsS :: StateT ServerState IO [ClientInfo] |
37 allClientsS :: StateT ServerState IO [ClientInfo] |
38 allClientsS = gets roomsClients >>= liftIO . clientsM |
38 allClientsS = gets roomsClients >>= liftIO . clientsM |
39 |
39 |
40 roomClientsS :: RoomIndex -> StateT ServerState IO [ClientInfo] |
40 roomClientsS :: RoomIndex -> StateT ServerState IO [ClientInfo] |
41 roomClientsS ri = do |
41 roomClientsS ri = do |
42 rnc <- gets roomsClients |
42 rnc <- gets roomsClients |
43 liftIO $ roomClientsM rnc ri |
43 liftIO $ roomClientsM rnc ri |
44 |
|