コード例 #1
0
 public ServerConfigurationManager(MinecraftServer p_i3376_1_) {
   field_72414_i = new HashSet();
   field_72411_j = new HashSet();
   field_72408_o = 0;
   field_72400_f = p_i3376_1_;
   field_72401_g.func_73708_a(false);
   field_72413_h.func_73708_a(false);
   field_72405_c = 8;
 }
コード例 #2
0
 public String func_72399_a(SocketAddress p_72399_1_, String p_72399_2_) {
   if (field_72401_g.func_73704_a(p_72399_2_)) {
     BanEntry banentry = (BanEntry) field_72401_g.func_73712_c().get(p_72399_2_);
     String s1 =
         (new StringBuilder())
             .append("You are banned from this server!\nReason: ")
             .append(banentry.func_73686_f())
             .toString();
     if (banentry.func_73680_d() != null) {
       s1 =
           (new StringBuilder())
               .append(s1)
               .append("\nYour ban will be removed on ")
               .append(field_72403_e.format(banentry.func_73680_d()))
               .toString();
     }
     return s1;
   }
   if (!func_72370_d(p_72399_2_)) {
     return "You are not white-listed on this server!";
   }
   String s = p_72399_1_.toString();
   s = s.substring(s.indexOf("/") + 1);
   s = s.substring(0, s.indexOf(":"));
   if (field_72413_h.func_73704_a(s)) {
     BanEntry banentry1 = (BanEntry) field_72413_h.func_73712_c().get(s);
     String s2 =
         (new StringBuilder())
             .append("Your IP address is banned from this server!\nReason: ")
             .append(banentry1.func_73686_f())
             .toString();
     if (banentry1.func_73680_d() != null) {
       s2 =
           (new StringBuilder())
               .append(s2)
               .append("\nYour ban will be removed on ")
               .append(field_72403_e.format(banentry1.func_73680_d()))
               .toString();
     }
     return s2;
   }
   if (field_72404_b.size() >= field_72405_c) {
     return "The server is full!";
   } else {
     return null;
   }
 }