Example #1
0
 public override void Action(CommandCaller caller, string input, string[] args)
 {
     try
     {
         int          uuid   = int.Parse(args[0]);
         ServerPlayer player = ServerPlayer.FindPlayer(uuid);
         player.HasPassword = false;
         player.IsLogin     = false;
         player.SavePlayer();
         if (player.PrototypePlayer != null)
         {
             player.SendSuccessInfo("Your password has been reseted! Please register with another password");
         }
     }
     catch (Exception ex)
     {
         Console.WriteLine(ex);
     }
 }
        public ServerPlayer GetFriendP(ServerPlayer player)
        {
            int uuid = _friendPendings.ContainsKey(player.UUID) ? _friendPendings[player.UUID] : -1;

            return(ServerPlayer.FindPlayer(uuid));
        }