diff -r 98cf15b23985 -r 3aa7d21baca1 netserver/HWProto.hs --- a/netserver/HWProto.hs Sun Jan 25 18:54:30 2009 +0000 +++ b/netserver/HWProto.hs Sun Jan 25 18:54:39 2009 +0000 @@ -302,6 +302,15 @@ handleCmd_noRoom client _ _ ["CHAT_STRING", msg] = (noChangeClients, noChangeRooms, answerChatString (nick client) msg) +handleCmd_noRoom client _ _ ["GLOBALMSG", password, msg] = + (noChangeClients, noChangeRooms, [answer]) + where + answer = \serverInfo -> + if (not $ null password) && (adminPassword serverInfo == password) then + (allClients, ["CHAT_STRING", nick client, msg]) + else + (clientOnly, ["ERROR", "Wrong password"]) + handleCmd_noRoom _ _ _ _ = (noChangeClients, noChangeRooms, answerBadCmd)