<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -38,6 +38,7 @@ Featuers:
 		-Changed the way ips are outputted by the &quot;players&quot; command - they are now put on the next line, so that people with rediculously long names don't obscure their ip address for kicking/banning
 		-Made the server tell all players that it's changing map so when they disconnect they don't think it crashed
 		-Made server console output whether the level file to load was found or not
+		-Ability to assign admins who can then prefix commands with \ for full server console access!
 	-Other
 		-Help menu updated to reflect new key layout
 		-Server browser dims servers that are full</diff>
      <filename>changelog.txt</filename>
    </modified>
    <modified>
      <diff>@@ -490,6 +490,8 @@ namespace Infiniminer
         {
             if (authority == 0)
                 return false;
+            if (sender != null)
+                sender.admin = GetAdmin(sender.IP);
             string[] args = input.Split(' '.ToString().ToCharArray(),2);
             if (args[0].StartsWith(&quot;\\&quot;) &amp;&amp; args[0].Length &gt; 1)
                 args[0] = args[0].Substring(1);
@@ -924,6 +926,13 @@ namespace Infiniminer
             }
         }
 
+        public short GetAdmin(string ip)
+        {
+            if (admins.ContainsKey(ip.Trim()))
+                return admins[ip.Trim()];
+            return (short)0;
+        }
+
         public void AdminPlayer(string ip)
         {
             AdminPlayer(ip, false,(short)2);
@@ -948,7 +957,7 @@ namespace Infiniminer
                     }
                 }
             }
-            if (admins.ContainsKey(realIp))
+            if (!admins.ContainsKey(realIp))
             {
                 admins.Add(realIp,authority);
                 SaveAdminList();
@@ -1581,7 +1590,7 @@ namespace Infiniminer
                                                 // Read the data from the packet.
                                                 ChatMessageType chatType = (ChatMessageType)msgBuffer.ReadByte();
                                                 string chatString = Defines.Sanitize(msgBuffer.ReadString());
-                                                if (!ProcessCommand(chatString,playerList[msgSender].admin,playerList[msgSender]))
+                                                if (!ProcessCommand(chatString,GetAdmin(playerList[msgSender].IP),playerList[msgSender]))
                                                 {
                                                     ConsoleWrite(&quot;CHAT: (&quot; + player.Handle + &quot;) &quot; + chatString);
 </diff>
      <filename>code/InfiniminerServer/InfiniminerServer.cs</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>64432b0506025ccdf5b358e5358b7a6ac4603b3b</id>
    </parent>
  </parents>
  <author>
    <name>Metroid48</name>
    <email>metroid48@gmail.com</email>
  </author>
  <url>http://github.com/krispykrem/Infiniminer/commit/e4a580319789c3477d09025df62bf4410c6f720a</url>
  <id>e4a580319789c3477d09025df62bf4410c6f720a</id>
  <committed-date>2009-06-15T17:21:25-07:00</committed-date>
  <authored-date>2009-06-07T08:14:48-07:00</authored-date>
  <message>Fixed a problem with admins - for an unkown reason their admin status would drop after time. Also fixed the &quot;add admin&quot; commands - they were missing a ! that made them never work.

Signed-off-by: Zach Barth &lt;zachbarth@gmail.com&gt;</message>
  <tree>08609b75cc2a019b892b767a4ab1726d634e2ac5</tree>
  <committer>
    <name>Zach Barth</name>
    <email>zachbarth@gmail.com</email>
  </committer>
</commit>
