import java.awt.Color;
import java.awt.Font;
import java.awt.Graphics;
import java.awt.image.ImageObserver;

public class Class246 implements Interface47 {

   String aString2940;
   Class253 aClass253_2941;
   static String aString2942;
   public static Class253 aClass253_2943;


   public Class451 method270() {
      return Class451.aClass451_5646;
   }

   public int method99(int var1) {
      return this.aClass253_2941.method4530(this.aString2940, (byte)14)?100:this.aClass253_2941.method4527(this.aString2940, (byte)0);
   }

   public Class451 method268(byte var1) {
      return Class451.aClass451_5646;
   }

   public int method269() {
      return this.aClass253_2941.method4530(this.aString2940, (byte)14)?100:this.aClass253_2941.method4527(this.aString2940, (byte)0);
   }

   public int method31() {
      return this.aClass253_2941.method4530(this.aString2940, (byte)14)?100:this.aClass253_2941.method4527(this.aString2940, (byte)0);
   }

   Class246(Class253 var1, String var2) {
      this.aClass253_2941 = var1;
      this.aString2940 = var2;
   }

   static final void method4386(Class124 var0, Class121 var1, Class508 var2, int var3) {
      var0.aString1455 = (String)var2.anObjectArray6004[(var2.anInt6005 -= -46848683) * 639741949];
   }

   public static final void method4387(int var0, String var1, Color var2, Color var3, Color var4, short var5) {
      try {
         Graphics var6 = Class572.aCanvas7591.getGraphics();
         if(null == Class299.aFont3669) {
            Class299.aFont3669 = new Font("Helvetica", 1, 13);
         }

         if(var2 == null) {
            var2 = new Color(140, 17, 17);
         }

         if(var3 == null) {
            var3 = new Color(140, 17, 17);
         }

         if(null == var4) {
            var4 = new Color(255, 255, 255);
         }

         int var8;
         int var9;
         try {
            if(Class117.anImage1191 == null) {
               Class117.anImage1191 = Class572.aCanvas7591.createImage(759890095 * Class563.anInt7495, Class440.anInt5458 * 1404657485);
            }

            Graphics var7 = Class117.anImage1191.getGraphics();
            var7.setColor(Color.black);
            var7.fillRect(0, 0, Class563.anInt7495 * 759890095, Class440.anInt5458 * 1404657485);
            var8 = 759890095 * Class563.anInt7495 / 2 - 152;
            var9 = 1404657485 * Class440.anInt5458 / 2 - 18;
            var7.setColor(var3);
            var7.drawRect(var8, var9, 303, 33);
            var7.setColor(var2);
            var7.fillRect(var8 + 2, var9 + 2, var0 * 3, 30);
            var7.setColor(Color.black);
            var7.drawRect(var8 + 1, 1 + var9, 301, 31);
            var7.fillRect(2 + var8 + 3 * var0, 2 + var9, 300 - var0 * 3, 30);
            var7.setFont(Class299.aFont3669);
            var7.setColor(var4);
            var7.drawString(var1, var8 + (304 - var1.length() * 6) / 2, var9 + 22);
            if(GameEngine.aString3301 != null) {
               var7.setFont(Class299.aFont3669);
               var7.setColor(var4);
               var7.drawString(GameEngine.aString3301, 759890095 * Class563.anInt7495 / 2 - GameEngine.aString3301.length() * 6 / 2, Class440.anInt5458 * 1404657485 / 2 - 26);
            }

            var6.drawImage(Class117.anImage1191, 0, 0, (ImageObserver)null);
         } catch (Exception var10) {
            var6.setColor(Color.black);
            var6.fillRect(0, 0, Class563.anInt7495 * 759890095, Class440.anInt5458 * 1404657485);
            var8 = 759890095 * Class563.anInt7495 / 2 - 152;
            var9 = Class440.anInt5458 * 1404657485 / 2 - 18;
            var6.setColor(var3);
            var6.drawRect(var8, var9, 303, 33);
            var6.setColor(var2);
            var6.fillRect(2 + var8, 2 + var9, var0 * 3, 30);
            var6.setColor(Color.black);
            var6.drawRect(var8 + 1, var9 + 1, 301, 31);
            var6.fillRect(2 + var8 + var0 * 3, 2 + var9, 300 - var0 * 3, 30);
            var6.setFont(Class299.aFont3669);
            var6.setColor(var4);
            if(null != GameEngine.aString3301) {
               var6.setFont(Class299.aFont3669);
               var6.setColor(var4);
               var6.drawString(GameEngine.aString3301, 759890095 * Class563.anInt7495 / 2 - GameEngine.aString3301.length() * 6 / 2, 1404657485 * Class440.anInt5458 / 2 - 26);
            }

            var6.drawString(var1, var8 + (304 - var1.length() * 6) / 2, var9 + 22);
         }
      } catch (Exception var11) {
         Class572.aCanvas7591.repaint();
      }

   }

   public static boolean method4388(int var0, int var1, int var2) {
      if(!Class2.aBool20) {
         return false;
      } else {
         int var3 = var0 >> 16;
         int var4 = var0 & '\uffff';
         if(Class18.aClass121Array188[var3] != null && null != Class18.aClass121Array188[var3].aClass124Array1207[var4]) {
            Class124 var5 = Class18.aClass121Array188[var3].aClass124Array1207[var4];
            Class225_Sub14_Sub3 var6;
            if(var1 == -1 && 258921611 * var5.anInt1370 == 0) {
               for(var6 = (Class225_Sub14_Sub3)Class2.aClass456_29.method7682((byte)92); null != var6; var6 = (Class225_Sub14_Sub3)Class2.aClass456_29.method7666(-1817626535)) {
                  if(var6.anInt10024 * 1158601069 == 58 || 1007 == 1158601069 * var6.anInt10024 || var6.anInt10024 * 1158601069 == 25 || 57 == var6.anInt10024 * 1158601069 || 30 == 1158601069 * var6.anInt10024) {
                     for(Class124 var7 = Class97.method1903(var6.anInt10022 * 687573979, -510649277); null != var7; var7 = Class500.method8362(Class18.aClass121Array188[var7.anInt1406 * 34646887 >> 16], var7, (byte)103)) {
                        if(34646887 * var7.anInt1406 == var5.anInt1406 * 34646887) {
                           return true;
                        }
                     }
                  }
               }
            } else {
               for(var6 = (Class225_Sub14_Sub3)Class2.aClass456_29.method7682((byte)94); var6 != null; var6 = (Class225_Sub14_Sub3)Class2.aClass456_29.method7666(-1384507381)) {
                  if(var1 == var6.anInt10013 * 1129789703 && var6.anInt10022 * 687573979 == var5.anInt1406 * 34646887 && (58 == var6.anInt10024 * 1158601069 || 1007 == var6.anInt10024 * 1158601069 || 25 == var6.anInt10024 * 1158601069 || var6.anInt10024 * 1158601069 == 57 || 1158601069 * var6.anInt10024 == 30)) {
                     return true;
                  }
               }
            }

            return false;
         } else {
            return false;
         }
      }
   }

   static int method4389(int var0) {
      int var1 = Class441.aClass327_5463.anInt4057 * -2017705825;
      if(var1 < Class313.aClass327Array3958.length - 1) {
         if(var0 >= 1384505301) {
            ;
         }

         Class441.aClass327_5463 = Class313.aClass327Array3958[var1 + 1];
      }

      return 100;
   }

   static void method4390(int var0) {
      Class104.anInt1025 = 0;
      Class500.aClass225_Sub43_5952 = null;
      Class225_Sub14_Sub14_Sub1.aClass197_10666 = null;
      Class555.aClass253_7447 = null;
      Class371.aClass225_Sub12_Sub2_4642 = null;
   }

   public static int method4391(int var0) {
      return Class46.anInt486 * -1795614009;
   }

   static void method4392(int var0, byte var1) {
      Class383.anInt4773 = var0 * -1861668749;
      Class215_Sub1.anInt8336 = -471411789;
      Class215_Sub1.anInt8336 = -471411789;
      Class10.method684(-930730332);
   }
}
