Ignore:
Timestamp:
Aug 26, 2014, 4:41:47 PM (10 years ago)
Author:
alloc
Message:

Fixes

Location:
binary-improvements/7dtd-server-fixes/src/CustomCommands
Files:
1 edited
1 moved

Legend:

Unmodified
Added
Removed
  • binary-improvements/7dtd-server-fixes/src/CustomCommands/PrivateMassageConnections.cs

    r112 r130  
    22using System.Collections.Generic;
    33
    4 public class PrivateMassageConnections
     4namespace AllocsFixes.CustomCommands
    55{
    6         private static Dictionary<ClientInfo, ClientInfo> senderOfLastPM = new Dictionary<ClientInfo, ClientInfo>();
     6        public class PrivateMassageConnections
     7        {
     8                private static Dictionary<ClientInfo, ClientInfo> senderOfLastPM = new Dictionary<ClientInfo, ClientInfo> ();
    79
    8         public static void SetLastPMSender(ClientInfo _sender, ClientInfo _receiver) {
    9                 if (senderOfLastPM.ContainsKey(_receiver))
    10                         senderOfLastPM[_receiver] = _sender;
    11                 else
    12                         senderOfLastPM.Add(_receiver, _sender);
    13         }
     10                public static void SetLastPMSender (ClientInfo _sender, ClientInfo _receiver)
     11                {
     12                        if (senderOfLastPM.ContainsKey (_receiver))
     13                                senderOfLastPM [_receiver] = _sender;
     14                        else
     15                                senderOfLastPM.Add (_receiver, _sender);
     16                }
    1417
    15         public static ClientInfo GetLastPMSenderForPlayer(ClientInfo _player) {
    16                 if (senderOfLastPM.ContainsKey(_player))
    17                         return senderOfLastPM[_player];
    18                 return null;
     18                public static ClientInfo GetLastPMSenderForPlayer (ClientInfo _player)
     19                {
     20                        if (senderOfLastPM.ContainsKey (_player))
     21                                return senderOfLastPM [_player];
     22                        return null;
     23                }
    1924        }
    2025}
    21 
Note: See TracChangeset for help on using the changeset viewer.