import java.io.BufferedReader;
import java.io.DataInputStream;
import java.io.IOException;
import java.io.InputStreamReader;
import java.net.URL;
import java.util.ArrayList;

public class Class65 implements Runnable {

   Thread aThread624;
   Class33[] aClass33Array625;
   volatile boolean aBool626;
   static Class253 aClass253_627;
   public static String aString628;


   Class33 method1394(int var1, byte var2) {
      return null != this.aClass33Array625 && var1 >= 0 && var1 < this.aClass33Array625.length?this.aClass33Array625[var1]:null;
   }

   public void method1395() {
      try {
         int var1 = Class502.aClass487_5957 == Class487.aClass487_5903?80:7000 + Class419.aClass422_5325.anInt5346 * -72158445;
         BufferedReader var2 = new BufferedReader(new InputStreamReader(new DataInputStream((new URL("http://" + Class419.aClass422_5325.aString5344 + ":" + var1 + "/news.ws?game=" + -179465313 * client.aClass481_7742.anInt5859)).openStream())));
         String var3 = var2.readLine();

         ArrayList var4;
         for(var4 = new ArrayList(); var3 != null; var3 = var2.readLine()) {
            var4.add(var3);
         }

         String[] var5 = new String[var4.size()];
         var4.toArray(var5);
         if(0 != var5.length % 3) {
            return;
         }

         this.aClass33Array625 = new Class33[var5.length / 3];

         for(int var6 = 0; var6 < var5.length; var6 += 3) {
            this.aClass33Array625[var6 / 3] = new Class33(var5[var6], var5[var6 + 1], var5[var6 + 2]);
         }
      } catch (IOException var7) {
         ;
      }

      this.aBool626 = true;
   }

   boolean method1396(int var1) {
      if(this.aBool626) {
         return true;
      } else {
         if(null == this.aThread624) {
            this.aThread624 = new Thread(this);
            this.aThread624.start();
         }

         return this.aBool626;
      }
   }

   public void run() {
      try {
         int var1 = Class502.aClass487_5957 == Class487.aClass487_5903?80:7000 + Class419.aClass422_5325.anInt5346 * -72158445;
         BufferedReader var2 = new BufferedReader(new InputStreamReader(new DataInputStream((new URL("http://" + Class419.aClass422_5325.aString5344 + ":" + var1 + "/news.ws?game=" + -179465313 * client.aClass481_7742.anInt5859)).openStream())));
         String var3 = var2.readLine();

         ArrayList var4;
         for(var4 = new ArrayList(); var3 != null; var3 = var2.readLine()) {
            var4.add(var3);
         }

         String[] var5 = new String[var4.size()];
         var4.toArray(var5);
         if(0 != var5.length % 3) {
            return;
         }

         this.aClass33Array625 = new Class33[var5.length / 3];

         for(int var6 = 0; var6 < var5.length; var6 += 3) {
            this.aClass33Array625[var6 / 3] = new Class33(var5[var6], var5[var6 + 1], var5[var6 + 2]);
         }
      } catch (IOException var7) {
         ;
      }

      this.aBool626 = true;
   }

   public void method1397() {
      try {
         int var1 = Class502.aClass487_5957 == Class487.aClass487_5903?80:7000 + Class419.aClass422_5325.anInt5346 * -72158445;
         BufferedReader var2 = new BufferedReader(new InputStreamReader(new DataInputStream((new URL("http://" + Class419.aClass422_5325.aString5344 + ":" + var1 + "/news.ws?game=" + -179465313 * client.aClass481_7742.anInt5859)).openStream())));
         String var3 = var2.readLine();

         ArrayList var4;
         for(var4 = new ArrayList(); var3 != null; var3 = var2.readLine()) {
            var4.add(var3);
         }

         String[] var5 = new String[var4.size()];
         var4.toArray(var5);
         if(0 != var5.length % 3) {
            return;
         }

         this.aClass33Array625 = new Class33[var5.length / 3];

         for(int var6 = 0; var6 < var5.length; var6 += 3) {
            this.aClass33Array625[var6 / 3] = new Class33(var5[var6], var5[var6 + 1], var5[var6 + 2]);
         }
      } catch (IOException var7) {
         ;
      }

      this.aBool626 = true;
   }

   public void method1398() {
      try {
         int var1 = Class502.aClass487_5957 == Class487.aClass487_5903?80:7000 + Class419.aClass422_5325.anInt5346 * -72158445;
         BufferedReader var2 = new BufferedReader(new InputStreamReader(new DataInputStream((new URL("http://" + Class419.aClass422_5325.aString5344 + ":" + var1 + "/news.ws?game=" + -179465313 * client.aClass481_7742.anInt5859)).openStream())));
         String var3 = var2.readLine();

         ArrayList var4;
         for(var4 = new ArrayList(); var3 != null; var3 = var2.readLine()) {
            var4.add(var3);
         }

         String[] var5 = new String[var4.size()];
         var4.toArray(var5);
         if(0 != var5.length % 3) {
            return;
         }

         this.aClass33Array625 = new Class33[var5.length / 3];

         for(int var6 = 0; var6 < var5.length; var6 += 3) {
            this.aClass33Array625[var6 / 3] = new Class33(var5[var6], var5[var6 + 1], var5[var6 + 2]);
         }
      } catch (IOException var7) {
         ;
      }

      this.aBool626 = true;
   }

   static final void method1399(Class508 var0, int var1) {
      String var2 = (String)var0.anObjectArray6004[(var0.anInt6005 -= -46848683) * 639741949];
      Class225_Sub15 var3 = Class543.method11415(OutgoingOpcode.aClass302_3850, client.aClass180_7704.aClass433_2184, (byte)1);
      var3.buffer.writeByte(var2.length() + 1, -765864773);
      var3.buffer.writeString(var2, (byte)84);
      client.aClass180_7704.method3191(var3, (byte)93);
   }

   static final void method1400(Class508 var0, int var1) {
      var0.anIntArray6027[(var0.anInt6003 += 98312473) * -937710807 - 1] = var0.aClass64_5997.anInt610 * -1085486947;
   }

   static final void method1401(Class508 var0, int var1) {
      PacketContext var2 = Class35_Sub1.method13169(883808512);
      Class225_Sub15 var3 = Class543.method11415(OutgoingOpcode.aClass302_3795, var2.aClass433_2184, (byte)1);
      var3.buffer.writeByte(0, -765864773);
      int var4 = -543666943 * var3.buffer.position;
      var3.buffer.writeByte(3, -765864773);
      var3.buffer.writeShort(var0.aClass369_6012.anInt4624 * -670625691, 878089672);
      var0.aClass369_6012.aClass225_Sub14_Sub5_4623.method15607(var3.buffer, var0.aClass369_6012.anIntArray4622, 2092509611);
      var3.buffer.method13717(-543666943 * var3.buffer.position - var4, -1281278168);
      var2.method3191(var3, (byte)8);
   }

   static final void method1402(Class508 var0, byte var1) {
      Class505 var10000;
      if(var0.aBool6014) {
         if(var1 != 14) {
            ;
         }

         var10000 = var0.aClass505_6011;
      } else {
         var10000 = var0.aClass505_6010;
      }

      Class505 var2 = var10000;
      Class124 var3 = var2.aClass124_5977;
      Class509.method10808(var3, var0, (byte)-54);
   }
}
