--- a/gameServer/HWProtoChecker.hs Tue Aug 27 17:22:07 2013 +0400
+++ b/gameServer/HWProtoChecker.hs Wed Aug 28 23:11:05 2013 +0400
@@ -11,14 +11,14 @@
handleCmd_checker :: CmdHandler
-handleCmd_checker ["READY"] = return [CheckRecord]
+handleCmd_checker ["READY"] = return [ModifyClient $ \c -> c{isReady = True}, CheckRecord]
handleCmd_checker ["CHECKED", "FAIL", msg] = do
isChecking <- liftM (isJust . checkInfo) thisClient
if not isChecking then
return []
else
- return [CheckFailed msg, ModifyClient $ \c -> c{checkInfo = Nothing}]
+ return [CheckFailed msg, ModifyClient $ \c -> c{isReady = False, checkInfo = Nothing}]
handleCmd_checker ("CHECKED" : "OK" : info) = do
@@ -26,6 +26,6 @@
if not isChecking then
return []
else
- return [CheckSuccess info, ModifyClient $ \c -> c{checkInfo = Nothing}]
+ return [CheckSuccess info, ModifyClient $ \c -> c{isReady = False, checkInfo = Nothing}]
handleCmd_checker _ = return [ProtocolError "Unknown command"]