--- a/gameServer/Opts.hs Mon Feb 28 22:28:43 2011 +0300
+++ b/gameServer/Opts.hs Thu Mar 03 22:15:13 2011 +0300
@@ -11,7 +11,7 @@
import CoreTypes
import Utils
-options :: [OptDescr (ServerInfo -> ServerInfo)]
+options :: [OptDescr (ServerInfo c -> ServerInfo c)]
options = [
Option "p" ["port"] (ReqArg readListenPort "PORT") "listen on PORT",
Option "d" ["dedicated"] (ReqArg readDedicated "BOOL") "start as dedicated (True or False)"
@@ -19,7 +19,7 @@
readListenPort
, readDedicated
- :: String -> ServerInfo -> ServerInfo
+ :: String -> ServerInfo c -> ServerInfo c
readListenPort str opts = opts{listenPort = readPort}
@@ -30,7 +30,7 @@
where
readDed = fromMaybe True (maybeRead str :: Maybe Bool)
-getOpts :: ServerInfo -> IO ServerInfo
+getOpts :: ServerInfo c -> IO (ServerInfo c)
getOpts opts = do
args <- getArgs
case getOpt Permute options args of