Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import com.nokia.mid.ui.FullCanvas;
- import java.io.ByteArrayInputStream;
- import java.io.ByteArrayOutputStream;
- import java.io.DataInputStream;
- import java.io.DataOutputStream;
- import java.io.InputStream;
- import java.util.Random;
- import javax.microedition.lcdui.Alert;
- import javax.microedition.lcdui.AlertType;
- import javax.microedition.lcdui.Canvas;
- import javax.microedition.lcdui.Display;
- import javax.microedition.lcdui.Graphics;
- import javax.microedition.lcdui.Image;
- import javax.microedition.media.Controllable;
- import javax.microedition.media.Manager;
- import javax.microedition.media.Player;
- import javax.microedition.media.control.VolumeControl;
- import javax.microedition.midlet.MIDlet;
- import javax.microedition.rms.RecordStore;
- public final class a
- extends FullCanvas
- implements Runnable
- {
- private int g = 20;
- private int h = 48;
- private int i = 48;
- private int j = 24;
- private int k = 24;
- private int l = 12;
- private int m = 12;
- private int n = 6;
- private int o = 6;
- private int p = 5;
- private int q = 5;
- private int r = 4;
- public String[] a = null;
- public String b = null;
- private Player s = null;
- public byte c;
- private Bobby t;
- private int u;
- private int v;
- private int w;
- private int x;
- private String y = "EN";
- private Random z;
- public boolean d = false;
- public boolean e = false;
- public boolean f;
- private byte[] A = new byte[4];
- private boolean[] B = new boolean[4];
- private boolean C;
- private byte[] D = new byte[7];
- private boolean E;
- private boolean F;
- private boolean G;
- private byte H;
- private short I;
- private short J;
- private long K;
- private int L;
- private String[] M = new String[5];
- private boolean N;
- private boolean O;
- private boolean P;
- private boolean Q;
- private boolean R;
- private boolean S;
- private boolean T;
- private boolean U;
- private int[] V = { 49, 49, 51, 51, 55, 55, 57, 57 };
- private int W = 0;
- private boolean X = false;
- private boolean Y = false;
- private short[] Z = new short[5];
- private short[] aa = new short[5];
- private byte[] ab = new byte[5];
- private int ac;
- private byte ad;
- private String ae;
- private char[] af;
- private int ag;
- private int ah;
- private String ai;
- private String aj;
- private int ak;
- private int al;
- private int am;
- private int an;
- private int ao;
- private int ap;
- private int aq;
- private int ar;
- private int as;
- private int at;
- private int au;
- private int av;
- private int aw;
- private int ax;
- private int ay;
- private int az;
- private int aA;
- private int aB;
- private int aC;
- private int aD;
- private int aE;
- private int aF;
- private int aG;
- private int aH;
- private int aI;
- private int aJ;
- private int aK;
- private int aL;
- private int aM;
- private int aN;
- private int aO;
- private int aP;
- private int aQ;
- private int aR;
- private int aS;
- private int aT;
- private byte aU;
- private byte aV;
- private byte aW;
- private byte aX;
- private byte aY;
- private byte aZ;
- private boolean ba;
- private boolean bb;
- private boolean bc;
- private boolean bd;
- private boolean be;
- private boolean bf;
- private boolean bg;
- private boolean bh;
- private boolean bi;
- private boolean bj;
- private boolean bk;
- private boolean bl;
- private int bm;
- private int bn;
- private int bo;
- private static final byte[] bp = { 94, 95, -112, -111 };
- private byte bq = 3;
- private final byte[] br = { 5, 10, 30, 20, 10, 25, 10 };
- private byte bs;
- private int bt;
- private int bu;
- private int bv;
- private int bw;
- private byte bx;
- private boolean by;
- private int bz;
- private int bA;
- private int bB;
- private int bC;
- private int bD;
- private boolean bE;
- private int bF;
- private int bG;
- private int bH;
- private int bI;
- private int bJ;
- private int bK;
- private int bL;
- private int bM;
- private int bN;
- private int bO;
- private int bP;
- private int bQ;
- private int bR;
- private int bS;
- private int bT;
- private int bU;
- private int bV;
- private long bW;
- private long bX;
- private boolean bY;
- private int bZ;
- private int ca;
- private byte cb;
- private int cc;
- private int[] cd = new int[5];
- private int[] ce = new int[5];
- private Image cf;
- private Image cg;
- private Image ch;
- private Image ci;
- private Image cj;
- private Image ck;
- private Image cl;
- private Image cm;
- private Image cn;
- private Image[] co = new Image[10];
- private Image cp;
- private byte[][] cq;
- private byte[][] cr;
- private String cs;
- private String ct;
- private byte cu;
- private String[] cv = new String[4];
- private byte[] cw = new byte[4];
- private int cx;
- private int cy;
- private int cz;
- private byte[] cA;
- private byte[] cB;
- private byte[] cC;
- private boolean[] cD;
- private short[] cE;
- private short[] cF;
- private short cG;
- private short cH;
- private short cI;
- private short cJ;
- private short cK;
- private short cL;
- private short cM;
- private short cN;
- private short cO;
- private short cP;
- private boolean cQ;
- private boolean cR;
- private boolean cS;
- private boolean cT;
- private boolean cU;
- private boolean cV;
- private boolean cW;
- private boolean cX;
- private boolean cY;
- private boolean cZ;
- private boolean da;
- private boolean db;
- private boolean dc;
- private byte[] dd;
- private byte[] de;
- private byte[] df;
- private byte[] dg;
- private byte[] dh = new byte[5];
- private byte[] di = new byte[5];
- private byte[] dj = new byte[5];
- private int dk;
- private int dl;
- private int dm;
- private int dn;
- private byte jdField_do;
- private byte dp;
- private byte dq;
- private byte dr;
- private int ds;
- private int dt;
- private int du;
- private int dv;
- private int dw;
- private int dx;
- private int dy;
- private int dz;
- private int dA;
- private int dB;
- private boolean dC;
- private byte[][] dD;
- private byte[][] dE;
- private Image dF;
- private Graphics dG;
- private Image dH;
- private Image dI = null;
- private int dJ;
- private boolean dK;
- private int dL;
- private byte dM;
- private byte dN;
- private final short[] dO = { 0, 0, 1, 3, 5, 8, 12, 17, 23, 31, 41, 53, 70, 91, 118, 153, 198, 256, 256 };
- private boolean dP = false;
- private boolean dQ = false;
- private boolean dR = false;
- private boolean dS = false;
- private boolean dT = false;
- private String[] dU;
- private short[] dV;
- private byte dW;
- private byte dX;
- private byte dY;
- private byte dZ;
- private byte ea;
- private byte eb;
- private byte ec;
- private byte ed;
- private String ee;
- private int ef;
- private int eg;
- private int eh;
- private int ei;
- private String ej;
- private int ek;
- private int el;
- private int em;
- private int en;
- private int eo;
- private int ep;
- private int eq;
- private int er;
- private int es;
- private int et;
- private boolean eu;
- private byte ev;
- private String ew;
- private byte ex = 0;
- private short[] ey = { 59, 58, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80 };
- private byte[][] ez = { new byte[0], new byte[0], { -54, -52 }, { -57, -56 }, { -106 }, { -36, -96, -35 }, { -72, -74, -94 }, { -19 }, { -61, -58, -65, -62 }, { -80, -81 }, { -71, -69, -66, -67, -92 }, { 89, 87, -90 }, { -20 }, { -13 }, { -12, -11 }, { -29, -24, -40, -39 }, { -79, -78, -76, -77 }, { -44, -43, -42 }, { -32, -30, -14, -15 }, { -48, -45, -87, -86 }, { -49, -33 }, { -97, 124 }, { -10 } };
- private byte eA;
- public final void a(String paramString)
- {
- int i1 = 0;
- DataInputStream localDataInputStream = null;
- this.a = null;
- try
- {
- localDataInputStream = new DataInputStream(getClass().getResourceAsStream(paramString));
- i1 = localDataInputStream.readShort();
- this.a = new String[i1];
- for (int i2 = 0; i2 < i1; i2++) {
- this.a[i2] = localDataInputStream.readUTF();
- }
- }
- catch (Exception localException1)
- {
- c();
- }
- finally
- {
- if (localDataInputStream != null) {
- try
- {
- localDataInputStream.close();
- }
- catch (Exception localException4) {}
- }
- }
- }
- public final void a(String paramString, int paramInt, boolean paramBoolean)
- {
- if (paramBoolean)
- {
- if ((this.b == null) || (this.b.compareTo(paramString) != 0)) {}
- }
- else {
- this.b = null;
- }
- a();
- try
- {
- InputStream localInputStream = getClass().getResourceAsStream(paramString);
- this.s = Manager.createPlayer(localInputStream, "audio/midi");
- this.s.setLoopCount(paramBoolean ? -1 : 1);
- this.s.realize();
- try
- {
- VolumeControl localVolumeControl = (VolumeControl)this.s.getControl("VolumeControl");
- if (localVolumeControl != null) {
- localVolumeControl.setLevel(paramInt > 0 ? paramInt * 25 - (5 - paramInt) * 5 : 0);
- }
- }
- catch (Exception localException2) {}
- this.s.prefetch();
- this.s.start();
- this.b = paramString;
- try
- {
- Thread.sleep(250L);
- }
- catch (Exception localException3) {}
- }
- catch (Exception localException1) {}
- }
- public final void a()
- {
- if (this.s != null)
- {
- try
- {
- this.s.stop();
- this.s.deallocate();
- this.s.close();
- try
- {
- Thread.sleep(250L);
- }
- catch (Throwable localThrowable1) {}
- }
- catch (Throwable localThrowable2) {}
- this.s = null;
- }
- this.b = null;
- }
- public a(Bobby paramBobby)
- {
- this.t = paramBobby;
- a(this.y + ".dat");
- this.z = new Random(System.currentTimeMillis());
- this.c = 1;
- this.u = getWidth();
- this.v = getHeight();
- this.w = (this.v - 2 - 16 - 6);
- b(this.u, this.v, true);
- this.cf = a(this.cf, "/font.png");
- this.dH = a(this.dH, "/logo.png");
- this.bZ = 0;
- this.cb = -1;
- a(true, 0);
- this.x = 10;
- }
- private final void c()
- {
- Alert localAlert = new Alert("Error", this.a[51], null, AlertType.ERROR);
- localAlert.setTimeout(-2);
- this.t.a.setCurrent(localAlert, this);
- while (!this.R) {
- try
- {
- Thread.sleep(50L);
- }
- catch (Exception localException) {}
- }
- this.t.destroyApp(true);
- }
- public void hideNotify()
- {
- if (this.d)
- {
- this.d = false;
- if ((this.c == 1) && (this.x != 16))
- {
- a();
- this.c = 0;
- }
- }
- if (!this.dQ)
- {
- this.U = false;
- this.dQ = true;
- k();
- }
- }
- public void showNotify()
- {
- if ((!this.d) && (this.dU != null)) {
- for (int i1 = 0; i1 < this.dY; i1++) {
- if (this.dV[i1] == 11) {
- this.dU[i1] = (this.a[4] + this.a[3]);
- }
- }
- }
- this.d = true;
- }
- public void run()
- {
- boolean bool = true;
- while (!this.e)
- {
- long l1 = System.currentTimeMillis();
- bool |= b();
- if ((this.d) && (bool))
- {
- bool = false;
- repaint();
- serviceRepaints();
- }
- bool |= b();
- long l2 = System.currentTimeMillis() - l1 + 10L;
- if (l2 < 62L) {
- try
- {
- Thread.sleep(62L - l2);
- }
- catch (Exception localException) {}
- }
- }
- if (this.c == 1) {
- a();
- }
- this.t.notifyDestroyed();
- }
- private final void d()
- {
- this.dZ = ((byte)((this.w - 26) / 31));
- this.C = false;
- e();
- String str = this.y;
- f();
- if (str.compareTo(this.y) != 0) {
- a(this.y + ".dat");
- }
- aa();
- i();
- this.cg = a(this.cg, "/numbers.png");
- this.ch = a(this.ch, "/arrows.png");
- this.cj = a(this.cj, "/misc.png");
- this.ck = a(this.ck, "/ts.png");
- this.cl = a(this.cl, "/mow.png");
- ac();
- if (!this.f)
- {
- d((byte)2);
- }
- else
- {
- this.S = (this.T = this.R = 0);
- this.x = 11;
- c((byte)2, (byte)-1);
- }
- }
- private final void e()
- {
- this.f = false;
- try
- {
- RecordStore localRecordStore = null;
- int i1 = -1;
- try
- {
- localRecordStore = RecordStore.openRecordStore("BC5Data", true);
- i1 = localRecordStore.getNumRecords();
- }
- catch (Exception localException2) {}
- if (i1 != 1)
- {
- this.f = true;
- if (i1 != 0)
- {
- if (localRecordStore != null) {
- localRecordStore.closeRecordStore();
- }
- RecordStore.deleteRecordStore("BC5Data");
- localRecordStore = RecordStore.openRecordStore("BC5Data", true);
- }
- for (int i2 = 0; i2 < 4; i2++)
- {
- this.A[i2] = 0;
- this.B[i2] = false;
- }
- for (i2 = 0; i2 < this.D.length; i2++) {
- this.D[i2] = 0;
- }
- this.E = false;
- this.F = false;
- this.H = 0;
- this.I = 0;
- this.J = 0;
- this.K = 0L;
- this.L = this.z.nextInt();
- for (i2 = 0; i2 < this.M.length; i2++) {
- this.M[i2] = "";
- }
- this.G = false;
- byte[] arrayOfByte = h();
- localRecordStore.addRecord(arrayOfByte, 0, arrayOfByte.length);
- }
- localRecordStore.closeRecordStore();
- }
- catch (Exception localException1)
- {
- c();
- }
- }
- private final void f()
- {
- ByteArrayInputStream localByteArrayInputStream = null;
- DataInputStream localDataInputStream = null;
- try
- {
- localByteArrayInputStream = new ByteArrayInputStream(a("BC5Data", 1));
- localDataInputStream = new DataInputStream(localByteArrayInputStream);
- this.y = localDataInputStream.readUTF();
- this.bq = localDataInputStream.readByte();
- for (int i1 = 0; i1 < 4; i1++)
- {
- this.A[i1] = localDataInputStream.readByte();
- this.B[i1] = localDataInputStream.readBoolean();
- }
- for (i1 = 0; i1 < this.D.length; i1++) {
- this.D[i1] = localDataInputStream.readByte();
- }
- this.E = localDataInputStream.readBoolean();
- this.F = localDataInputStream.readBoolean();
- this.H = localDataInputStream.readByte();
- this.I = localDataInputStream.readShort();
- this.J = localDataInputStream.readShort();
- this.K = localDataInputStream.readLong();
- this.L = localDataInputStream.readInt();
- for (i1 = 0; i1 < this.M.length; i1++) {
- this.M[i1] = localDataInputStream.readUTF();
- }
- this.G = localDataInputStream.readBoolean();
- }
- catch (Exception localException1)
- {
- c();
- }
- finally
- {
- if (localDataInputStream != null)
- {
- try
- {
- localDataInputStream.close();
- }
- catch (Exception localException6) {}
- localDataInputStream = null;
- }
- if (localByteArrayInputStream != null)
- {
- try
- {
- localByteArrayInputStream.close();
- }
- catch (Exception localException7) {}
- localByteArrayInputStream = null;
- }
- }
- }
- private final void g()
- {
- a("BC5Data", 1, h());
- }
- private final byte[] h()
- {
- byte[] arrayOfByte = null;
- ByteArrayOutputStream localByteArrayOutputStream = null;
- DataOutputStream localDataOutputStream = null;
- try
- {
- localByteArrayOutputStream = new ByteArrayOutputStream();
- localDataOutputStream = new DataOutputStream(localByteArrayOutputStream);
- localDataOutputStream.writeUTF(this.y);
- localDataOutputStream.writeByte(this.bq);
- for (int i1 = 0; i1 < 4; i1++)
- {
- localDataOutputStream.writeByte(this.A[i1]);
- localDataOutputStream.writeBoolean(this.B[i1]);
- }
- for (i1 = 0; i1 < this.D.length; i1++) {
- localDataOutputStream.writeByte(this.D[i1]);
- }
- localDataOutputStream.writeBoolean(this.E);
- localDataOutputStream.writeBoolean(this.F);
- localDataOutputStream.writeByte(this.H);
- localDataOutputStream.writeShort(this.I);
- localDataOutputStream.writeShort(this.J);
- localDataOutputStream.writeLong(this.K);
- localDataOutputStream.writeInt(this.L);
- for (i1 = 0; i1 < this.M.length; i1++) {
- localDataOutputStream.writeUTF(this.M[i1]);
- }
- localDataOutputStream.writeBoolean(this.G);
- arrayOfByte = localByteArrayOutputStream.toByteArray();
- }
- catch (Exception localException1)
- {
- c();
- }
- finally
- {
- if (localDataOutputStream != null)
- {
- try
- {
- localDataOutputStream.close();
- }
- catch (Exception localException6) {}
- localDataOutputStream = null;
- }
- if (localByteArrayOutputStream != null)
- {
- try
- {
- localByteArrayOutputStream.close();
- }
- catch (Exception localException7) {}
- localByteArrayOutputStream = null;
- }
- }
- return arrayOfByte;
- }
- private final byte[] a(String paramString, int paramInt)
- {
- byte[] arrayOfByte = null;
- try
- {
- RecordStore localRecordStore = RecordStore.openRecordStore(paramString, false);
- arrayOfByte = localRecordStore.getRecord(paramInt);
- localRecordStore.closeRecordStore();
- }
- catch (Exception localException1)
- {
- try
- {
- RecordStore.deleteRecordStore(paramString);
- }
- catch (Exception localException2) {}
- c();
- }
- return arrayOfByte;
- }
- private final void a(String paramString, int paramInt, byte[] paramArrayOfByte)
- {
- try
- {
- RecordStore localRecordStore = RecordStore.openRecordStore(paramString, false);
- localRecordStore.setRecord(paramInt, paramArrayOfByte, 0, paramArrayOfByte.length);
- localRecordStore.closeRecordStore();
- }
- catch (Exception localException1)
- {
- try
- {
- RecordStore.deleteRecordStore(paramString);
- }
- catch (Exception localException2) {}
- c();
- }
- }
- private final void i()
- {
- this.x = 6;
- repaint();
- serviceRepaints();
- }
- public final void keyPressed(int paramInt)
- {
- if (paramInt == 0) {
- return;
- }
- if (!this.X) {
- if (paramInt == this.V[this.W])
- {
- this.W += 1;
- if (this.W >= this.V.length)
- {
- this.W = 0;
- this.X = true;
- }
- }
- else
- {
- this.W = 0;
- }
- }
- if ((this.x == 1) && (this.C)) {
- if (paramInt == 42) {
- this.Y = true;
- } else if (paramInt == 35)
- {
- if (this.Y)
- {
- this.Y = false;
- this.I = ((short)(this.I + 5));
- }
- }
- else {
- this.Y = false;
- }
- }
- this.U = true;
- if (paramInt == -6)
- {
- this.S = true;
- return;
- }
- if (paramInt == -7)
- {
- this.T = true;
- return;
- }
- if (paramInt == 50) {
- this.N = true;
- } else if (paramInt == 56) {
- this.O = true;
- } else if (paramInt == 52) {
- this.P = true;
- } else if (paramInt == 54) {
- this.Q = true;
- } else if (paramInt == 53) {
- this.R = true;
- } else if (paramInt == -1) {
- this.N = true;
- } else if (paramInt == -2) {
- this.O = true;
- } else if (paramInt == -3) {
- this.P = true;
- } else if (paramInt == -4) {
- this.Q = true;
- } else if (paramInt == -5) {
- this.R = true;
- }
- }
- public final void keyReleased(int paramInt)
- {
- if (paramInt == 0) {
- return;
- }
- if (paramInt == -6)
- {
- this.S = false;
- return;
- }
- if (paramInt == -7)
- {
- this.T = false;
- return;
- }
- if (paramInt == 50) {
- this.N = false;
- } else if (paramInt == 56) {
- this.O = false;
- } else if (paramInt == 52) {
- this.P = false;
- } else if (paramInt == 54) {
- this.Q = false;
- } else if (paramInt == 53) {
- this.R = false;
- } else if (paramInt == -1) {
- this.N = false;
- } else if (paramInt == -2) {
- this.O = false;
- } else if (paramInt == -3) {
- this.P = false;
- } else if (paramInt == -4) {
- this.Q = false;
- } else if (paramInt == -5) {
- this.R = false;
- }
- }
- private final void a(Graphics paramGraphics)
- {
- d(paramGraphics, this.bF, this.bG);
- c(paramGraphics, this.bF, this.bG);
- if ((this.bn != -1) && (this.bm % 8 >= 4)) {
- a(paramGraphics, true, (byte)-8, this.bn - this.bF, this.bo - this.bG);
- }
- b(paramGraphics, this.bF, this.bG);
- int i1;
- if (this.cW) {
- for (i1 = 0; i1 < 3; i1++) {
- a(paramGraphics, false, (byte)(52 + this.bC), this.cG * this.h - this.bF, this.cH * this.i - this.k - this.i * i1 - this.bG);
- }
- }
- if (this.cX) {
- for (i1 = 0; i1 < 3; i1++) {
- a(paramGraphics, false, (byte)(52 + this.bC), this.cI * this.h - this.bF, this.cJ * this.i + this.k + this.i * i1 - this.bG);
- }
- }
- if (this.cY) {
- for (i1 = 0; i1 < 3; i1++) {
- a(paramGraphics, false, (byte)(55 + this.bC), this.cK * this.h - this.j - this.h * i1 - this.bF, this.cL * this.i - this.bG);
- }
- }
- if (this.cZ) {
- for (i1 = 0; i1 < 3; i1++) {
- a(paramGraphics, false, (byte)(55 + this.bC), this.cM * this.h + this.j + this.h * i1 - this.bF, this.cN * this.i - this.bG);
- }
- }
- a(paramGraphics, this.bF, this.bG);
- if (this.jdField_do > 0) {
- b(paramGraphics, this.ci, this.bs < 4 ? 282 : 310, 0, 28, 28, this.dl - 14 - this.bF, this.dm - 14 - this.bG);
- }
- if ((this.ax > 0) && (this.ay >= 4))
- {
- int i3;
- int i4;
- int i5;
- switch (this.aV)
- {
- case 0:
- i3 = 82;
- i4 = 39;
- i5 = 37;
- break;
- case 1:
- i3 = 121;
- i4 = 22;
- i5 = 35;
- break;
- case 2:
- i3 = 143;
- i4 = 36;
- i5 = 36;
- break;
- case 3:
- i3 = 179;
- i4 = 37;
- i5 = 38;
- break;
- default:
- i3 = 247;
- i4 = 35;
- i5 = 36;
- }
- i1 = this.am + (this.h - i4 >> 1);
- int i2 = this.an - 1 + -36 - i5;
- if (i2 - this.bG < 0) {
- i2 += i5 + 72 + 2;
- }
- b(paramGraphics, this.ci, i3, 0, i4, i5, i1 - this.bF, i2 - this.bG);
- }
- if (this.cS) {
- for (i1 = 0; i1 < 5; i1++) {
- b(paramGraphics, this.ci, 338, 0, 12, 8, this.cd[i1] >> this.r, this.ce[i1] >> this.r);
- }
- }
- b(paramGraphics, this.cm, 0, this.bx / 3 * 24, 24, 24, (this.bt >> this.r) - this.bF, (this.bu >> this.r) - this.bG);
- b(paramGraphics);
- if (this.aX != -1) {
- b(paramGraphics, this.cn, this.aX * 48, 0, 48, 48, this.u - 48 >> 1, this.v - 48 >> 1);
- }
- if (this.cb > 0) {
- c(paramGraphics);
- }
- if (!this.dS) {
- if (this.dQ) {
- a(paramGraphics, this.a[37], (byte)1, 0);
- } else if (this.ec > 0) {
- a(paramGraphics, this.ee, this.ed, 0);
- } else if (this.at == 5) {
- a(paramGraphics, this.a[54], (byte)(this.aX == -1 ? 0 : 1), 0);
- }
- }
- }
- private final void b(Graphics paramGraphics)
- {
- int i1 = 2;
- int i2 = 2;
- if (this.bS != 0)
- {
- long l1;
- if (!this.bY) {
- l1 = System.currentTimeMillis() - this.bX + this.bW;
- } else {
- l1 = this.bW;
- }
- if (this.cR) {
- if (this.db)
- {
- l1 = 60000L - l1;
- if (l1 < 0L) {
- l1 = 0L;
- }
- }
- else
- {
- l1 = 60000L;
- }
- }
- int i3 = (int)l1 / 60000;
- long l2 = l1 % 60000L;
- a(paramGraphics, i1, i2, i3, 2);
- i1 += 32;
- int i4 = (int)l2 / 1000;
- a(paramGraphics, i1, i2, i4, 2);
- if ((this.bY) || (i4 % 2 == 0))
- {
- i1 -= 6;
- paramGraphics.setClip(i1, i2, 5, 13);
- paramGraphics.drawImage(this.cg, i1 - 120, i2, 20);
- }
- i1 = this.u - (this.cQ ? 40 : 31) - 2;
- paramGraphics.setClip(i1, i2, this.cQ ? 40 : 31, this.cQ ? 38 : 38);
- paramGraphics.drawImage(this.ci, i1 - (this.cQ ? 42 : 216), i2, 20);
- i1 -= 28;
- a(paramGraphics, i1, i2 + ((this.cQ ? 40 : 31) - 13 >> 1), this.cy, 2);
- }
- if (this.dR)
- {
- i1 = this.u - 42 >> 1;
- paramGraphics.setClip(i1, i2, 42, 38);
- paramGraphics.drawImage(this.ci, i1 - 0, i2, 20);
- }
- if (this.bS != 0)
- {
- i1 = this.u;
- i2 += (this.cQ ? 38 : 38) + 2;
- if (this.cT)
- {
- i1 -= 41;
- paramGraphics.setClip(i1, i2, 39, 37);
- paramGraphics.drawImage(this.ci, i1 - 82, i2, 20);
- }
- if (this.cU)
- {
- i1 -= 38;
- paramGraphics.setClip(i1, i2, 36, 36);
- paramGraphics.drawImage(this.ci, i1 - 143, i2, 20);
- }
- if (this.cV)
- {
- i1 -= 39;
- paramGraphics.setClip(i1, i2, 37, 38);
- paramGraphics.drawImage(this.ci, i1 - 179, i2, 20);
- }
- if (this.cz > 0)
- {
- i1 -= 37;
- paramGraphics.setClip(i1, i2, 35, 36);
- paramGraphics.drawImage(this.ci, i1 - 247, i2, 20);
- }
- if ((this.da) || (this.D[2] > 0))
- {
- i1 -= 24;
- paramGraphics.setClip(i1, i2, 22, 35);
- paramGraphics.drawImage(this.ci, i1 - 121, i2, 20);
- }
- }
- }
- private final void a(Graphics paramGraphics, Image paramImage, int paramInt1, int paramInt2, int paramInt3, int paramInt4, int paramInt5, int paramInt6)
- {
- b(paramGraphics, paramImage, paramInt1, paramInt2, paramInt3, paramInt4, paramInt5, paramInt6);
- if (paramInt3 + paramInt5 < this.u) {
- b(paramGraphics, paramImage, paramInt1, paramInt2, paramInt3, paramInt4, 384 + paramInt5, paramInt6);
- }
- }
- public final void paint(Graphics paramGraphics)
- {
- try
- {
- switch (this.x)
- {
- case 1:
- a(paramGraphics);
- break;
- case 2:
- a(paramGraphics);
- a(paramGraphics, 22935, 10370, true, false, true, true);
- a(paramGraphics, this.ai, this.aj, true);
- return;
- case 4:
- d(paramGraphics, this.bF, this.bG);
- c(paramGraphics, 0, 0);
- a(paramGraphics, 0, 0);
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.drawImage(this.dH, this.u >> 1, this.w - this.dH.getHeight() - this.i - 72 >> 1, 17);
- if ((!this.dS) && (this.dK)) {
- a(paramGraphics, this.a[81], (byte)3, this.v - (this.g + 10) - 5);
- }
- if (this.cb > 0) {
- c(paramGraphics);
- }
- break;
- case 5:
- a(paramGraphics, 22935, 10370, true, true, true, true);
- a(paramGraphics, this.ev == 0 ? this.a[31] : null, this.ev != 0 ? this.a[29] : null, true);
- break;
- case 6:
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.setColor(0);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- a(paramGraphics, this.a[38], (byte)0, 0);
- return;
- case 7:
- if (this.cb > 0)
- {
- a(paramGraphics);
- }
- else
- {
- paramGraphics.setColor(0);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- }
- if (this.ej != null)
- {
- d(paramGraphics);
- a(paramGraphics, this.a[31], null, true);
- }
- break;
- case 8:
- e(paramGraphics);
- break;
- case 9:
- a(paramGraphics, 22935, 10370, true, true, true, true);
- switch (this.eA)
- {
- case 0:
- case 1:
- case 2:
- a(paramGraphics, this.a[32], this.a[33], true);
- break;
- default:
- a(paramGraphics, this.a[30], null, true);
- }
- break;
- case 10:
- paramGraphics.setColor(16777215);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- b(paramGraphics, this.dH, 0, this.bZ * 100, 176, 100, (this.u - 176 >> 1) + (this.dM == 1 ? -e(this.u) : e(this.u)), this.v - 100 >> 1);
- break;
- case 11:
- paramGraphics.setColor(0);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- break;
- case 12:
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.setColor(1259130);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- b(paramGraphics, this.dI, 0, 0, 384, 96, 0, 0);
- a(paramGraphics, this.dI, 0, 96, 384, 37, -(this.ag >> 4), 59);
- b(paramGraphics, this.dI, 0, 153, 384, 54, 0, 34);
- a(paramGraphics, this.dI, 0, 133, 384, 20, -(this.ah >> 4), 76);
- if (this.cb > 0) {
- c(paramGraphics);
- }
- if (this.dY > 0)
- {
- a(paramGraphics, true);
- }
- else
- {
- a(paramGraphics, 22935, 10370, false, false, true, true);
- a(paramGraphics, null, this.a[29], false);
- }
- return;
- case 13:
- d(paramGraphics, this.bF, this.bG);
- c(paramGraphics, 0, 0);
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.drawImage(this.dH, this.u >> 1, this.v, 33);
- int i1 = this.u - this.h - ((this.ae.length() - 1) * 12 + 10) >> 1;
- int i2 = this.i >> 1;
- a(paramGraphics, true, (byte)-10, i1, i2);
- a(this.ae, paramGraphics, i1 + this.h, i2 + (this.i - 16 >> 1), false);
- a(paramGraphics, 22935, 10370, false, false, false, false);
- if (this.cb > 0) {
- c(paramGraphics);
- }
- return;
- case 14:
- d(paramGraphics, this.bF, this.bG);
- c(paramGraphics, 0, 0);
- if (this.ao == -1)
- {
- a(paramGraphics, 0, 0);
- a(paramGraphics, 22935, 10370, false, false, false, true);
- }
- else
- {
- a(paramGraphics, true, (byte)-10, this.ao, this.ap);
- a(paramGraphics, 0, 0);
- }
- if (this.cb > 0) {
- c(paramGraphics);
- }
- return;
- case 15:
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.setColor(1259130);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- a(paramGraphics, 22935, 10370, false, false, true, true);
- a(paramGraphics, true, (byte)-10, this.u - this.h >> 1, this.i >> 1);
- if (this.cb > 0) {
- c(paramGraphics);
- }
- a(paramGraphics, this.a[31], null, false);
- return;
- case 16:
- a(paramGraphics, 22935, 10370, true, true, true, true);
- a(paramGraphics, this.ai, this.aj, true);
- return;
- }
- if (this.dS) {
- a(paramGraphics, true);
- }
- if ((this.dT) && (this.cb == 0)) {
- b(paramGraphics, this.ch, 0, 9, 17, 9, 2, this.v - 9 - 2);
- }
- }
- catch (Throwable localThrowable) {}
- }
- private final void a(Graphics paramGraphics, boolean paramBoolean, byte paramByte, int paramInt1, int paramInt2)
- {
- int i4 = paramBoolean ? 4 : 2;
- int i1 = (paramByte & 0xFF) >> i4;
- int i3 = i1 * this.i;
- int i2 = ((paramByte & 0xFF) - (i1 << i4)) * this.h;
- b(paramGraphics, paramBoolean ? this.ck : this.cp, i2, i3, this.h, this.i, paramInt1, paramInt2);
- }
- private final void c(Graphics paramGraphics)
- {
- int i2 = this.bZ;
- int i3 = this.bZ;
- int i5 = (this.v + this.i - 1) / this.i;
- int i7 = (this.u + this.h - 1) / this.h;
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.setColor(0);
- int i4;
- int i6;
- int i1;
- switch (this.cb)
- {
- case 1:
- i4 = (i5 - 1) * this.i;
- i6 = 0;
- for (i1 = 0; i1 < i7; i1++)
- {
- paramGraphics.fillRect(i6, 0, this.h - i3, this.v);
- i3 -= 3;
- if (i3 < 0) {
- i3 = 0;
- }
- i6 += this.h;
- }
- for (i1 = 0; i1 < i5; i1++)
- {
- paramGraphics.fillRect(0, i4, this.u, this.i - i2);
- i2 -= 3;
- if (i2 < 0) {
- i2 = 0;
- }
- i4 -= this.i;
- }
- if ((i2 >= this.i) && (i3 >= this.h)) {
- this.cb = 0;
- }
- break;
- case 2:
- i4 = 0;
- i6 = (i7 - 1) * this.h;
- for (i1 = 0; i1 < i7; i1++)
- {
- paramGraphics.fillRect(i6, 0, i3, this.v);
- i3 -= 3;
- if (i3 < 0) {
- i3 = 0;
- }
- i6 -= this.h;
- }
- for (i1 = 0; i1 < i5; i1++)
- {
- paramGraphics.fillRect(0, i4, this.u, i2);
- i2 -= 3;
- if (i2 < 0) {
- i2 = 0;
- }
- i4 += this.i;
- }
- if ((i2 >= this.i) && (i3 >= this.h)) {
- this.cb = 0;
- }
- break;
- }
- }
- private final void j()
- {
- this.bZ += 3;
- }
- private final void a(Graphics paramGraphics, int paramInt1, int paramInt2)
- {
- int i7;
- int i8;
- int i3;
- int i5;
- int i1;
- int i4;
- int i6;
- if (this.bf)
- {
- i7 = 1;
- i8 = 0;
- switch (this.at)
- {
- case 0:
- i3 = 60;
- i5 = -6;
- i1 = 0;
- i8 = this.h;
- break;
- case 1:
- i3 = 60;
- i5 = -6;
- i1 = i3;
- i8 = -this.h;
- break;
- case 2:
- i3 = 48;
- i5 = 0;
- i1 = 120;
- i7 = 0;
- break;
- default:
- i3 = 48;
- i5 = 0;
- i1 = 120 + i3;
- }
- i4 = 83;
- i6 = -48;
- if (((this.aK > 0) || (this.bh)) && (i7 != 0)) {
- a(paramGraphics, i8, paramInt1, paramInt2);
- }
- b(paramGraphics, this.co[7], i1, this.as * i4, i3, i4, this.am + i5 - paramInt1, this.an + i6 - paramInt2);
- if (((this.aK > 0) || (this.bh)) && (i7 == 0)) {
- a(paramGraphics, i8, paramInt1, paramInt2);
- }
- }
- else if (this.bj)
- {
- switch (this.at)
- {
- case 0:
- i1 = 0;
- break;
- case 1:
- i1 = 120;
- break;
- case 2:
- i1 = 240;
- break;
- default:
- i1 = 360;
- }
- b(paramGraphics, this.co[9], i1, 0, 120, 72, this.am + -36 - paramInt1, this.an + -36 - this.aT - paramInt2);
- }
- else if (this.aZ > 0)
- {
- switch (this.at)
- {
- case 0:
- i1 = 0;
- break;
- case 1:
- i1 = 72;
- break;
- case 2:
- i1 = 144;
- break;
- default:
- i1 = 216;
- }
- b(paramGraphics, this.co[8], i1, this.as / 3 * 72, 72, 72, this.am + -12 - paramInt1, this.an + -36 - this.aT - paramInt2);
- }
- else
- {
- i7 = 0;
- i8 = 0;
- if (this.at == 5)
- {
- i3 = 48;
- i4 = 72;
- i5 = 0;
- i6 = -36;
- }
- else
- {
- i3 = 48;
- i4 = 72;
- i5 = 0;
- i6 = -36;
- if (this.aK > 0) {
- switch (!this.bg ? this.at : 2)
- {
- case 0:
- i8 = this.h - this.l;
- break;
- case 1:
- i8 = -this.h + this.l;
- break;
- case 3:
- i7 = 1;
- }
- }
- }
- i1 = this.am + i5;
- int i2 = this.an + i6 - this.aT;
- if ((this.aK > 0) && (i7 != 0)) {
- a(paramGraphics, i8, paramInt1, paramInt2);
- }
- b(paramGraphics, this.co[2], this.as * i3, 0, i3, i4, i1 - paramInt1, i2 - paramInt2);
- if ((this.aK > 0) && (i7 == 0)) {
- a(paramGraphics, i8, paramInt1, paramInt2);
- }
- }
- }
- private final void a(Graphics paramGraphics, int paramInt1, int paramInt2, int paramInt3)
- {
- b(paramGraphics, this.cl, this.aA / 3 * this.h, this.bh ? 0 : this.i, this.h, this.i, this.am + paramInt1 - paramInt2, this.an - this.m - paramInt3);
- }
- private final void b(Graphics paramGraphics, int paramInt1, int paramInt2)
- {
- for (int i7 = 0; i7 < this.cx; i7++)
- {
- int i6 = this.cA[i7] & 0xFF;
- int i5 = i6 >> 4;
- int i4 = i5 * this.i;
- int i3 = (i6 - (i5 << 4)) * this.h;
- int i1 = this.cE[i7] - paramInt1;
- int i2 = this.cF[i7] - paramInt2;
- b(paramGraphics, this.ck, i3, i4, this.h, this.i, i1, i2);
- }
- }
- private final void b(Graphics paramGraphics, Image paramImage, int paramInt1, int paramInt2, int paramInt3, int paramInt4, int paramInt5, int paramInt6)
- {
- paramGraphics.setClip(paramInt5, paramInt6, paramInt3, paramInt4);
- paramGraphics.drawImage(paramImage, paramInt5 - paramInt1, paramInt6 - paramInt2, 20);
- }
- private final void a(byte paramByte1, byte paramByte2, int paramInt1, int paramInt2)
- {
- this.dG.setClip(paramInt1, paramInt2, this.h, this.i);
- a(paramByte1, paramInt1, paramInt2);
- if ((paramByte1 == -1) || (paramByte1 == -57)) {
- return;
- }
- a(paramByte2, paramInt1, paramInt2);
- }
- private final void a(byte paramByte, int paramInt1, int paramInt2)
- {
- int i6 = 0;
- int i1;
- if ((this.bB != 0) && (paramByte == -106) && (this.cy == 0))
- {
- i1 = 0 + this.bB - 1;
- }
- else if ((this.bB != 0) && (paramByte == -8) && (this.bE))
- {
- i1 = 15 + this.bB - 1;
- }
- else if ((this.bA != 0) && (paramByte == -12))
- {
- i1 = 26 + this.bA - 1;
- }
- else if ((this.bz != 0) && (paramByte == 86))
- {
- i1 = 39 + this.bz - 1;
- }
- else if ((this.bC != 0) && ((paramByte == 88) || (paramByte == 87) || (paramByte == 90) || (paramByte == 89) || (paramByte == 91) || (paramByte == 92) || (paramByte == 93)))
- {
- switch (paramByte)
- {
- case 88:
- i1 = 31;
- break;
- case 87:
- i1 = 33;
- break;
- case 90:
- i1 = 35;
- break;
- case 89:
- i1 = 37;
- break;
- case 91:
- i1 = 46;
- break;
- case 92:
- i1 = 48;
- break;
- default:
- i1 = 50;
- }
- i1 += this.bC - 1;
- }
- else if ((this.bB != 0) && ((paramByte == -75) || (paramByte == -74) || (paramByte == -73) || (paramByte == -72)))
- {
- switch (paramByte)
- {
- case -75:
- i1 = 3;
- break;
- case -74:
- i1 = 6;
- break;
- case -73:
- i1 = 9;
- break;
- default:
- i1 = 12;
- }
- i1 += this.bB - 1;
- }
- else if ((this.cW) && (this.bC != 0) && (paramByte == -48))
- {
- i1 = 18 + this.bC - 1;
- }
- else if ((this.cX) && (this.bC != 0) && (paramByte == -47))
- {
- i1 = 20 + this.bC - 1;
- }
- else if ((this.cY) && (this.bC != 0) && (paramByte == -46))
- {
- i1 = 22 + this.bC - 1;
- }
- else if ((this.cZ) && (this.bC != 0) && (paramByte == -45))
- {
- i1 = 24 + this.bC - 1;
- }
- else
- {
- i6 = 1;
- i1 = paramByte & 0xFF;
- }
- int i5 = i6 != 0 ? 4 : 2;
- int i2 = i1 >> i5;
- int i4 = i2 * this.i;
- int i3 = (i1 - (i2 << i5)) * this.h;
- this.dG.drawImage(i6 != 0 ? this.ck : this.cp, paramInt1 - i3, paramInt2 - i4, 20);
- }
- private final void k()
- {
- this.bW += System.currentTimeMillis() - this.bX;
- this.bY = true;
- }
- private final void l()
- {
- this.bX = System.currentTimeMillis();
- this.bY = false;
- }
- public final boolean b()
- {
- try
- {
- if (this.cb > 0) {
- j();
- }
- if (this.dS) {
- return (ag()) || (this.cb > 0);
- }
- switch (this.x)
- {
- case 0:
- d();
- return true;
- case 1:
- if ((this.dT) && (this.S) && (this.cb == 0))
- {
- this.S = false;
- c((byte)1, (byte)-1);
- return true;
- }
- if (this.dQ)
- {
- if (this.U)
- {
- this.S = false;
- this.T = false;
- this.R = false;
- this.P = false;
- this.Q = false;
- this.N = false;
- this.O = false;
- this.dQ = false;
- l();
- return true;
- }
- return this.cb > 0;
- }
- if (this.ec > 0) {
- this.ec = ((byte)(this.ec - 1));
- }
- if ((!this.ba) && (this.aQ == 0) && (this.at != 5) && (this.R))
- {
- this.R = false;
- this.dR = (!this.dR);
- if (!this.dR) {
- T();
- }
- }
- if (this.ax > 0)
- {
- this.ay = ((this.ay + 1) % 8);
- if (this.ay == 0) {
- this.ax -= 1;
- }
- }
- if (E())
- {
- if (this.x != 1) {
- return true;
- }
- if (this.jdField_do > 0) {
- N();
- }
- M();
- P();
- S();
- if (this.cS) {
- Q();
- } else {
- R();
- }
- D();
- if (this.E) {
- C();
- } else {
- this.bn = -1;
- }
- if (this.dR)
- {
- if (this.P) {
- this.bL -= 24;
- } else if (this.Q) {
- this.bL += 24;
- } else if (this.N) {
- this.bM -= 24;
- } else if (this.O) {
- this.bM += 24;
- }
- U();
- }
- if ((this.bL != this.bF) || ((this.bM != this.bG) && (this.aL == 0))) {
- V();
- }
- }
- return true;
- case 2:
- return z();
- case 3:
- this.t.destroyApp(true);
- return false;
- case 4:
- return (af()) || (this.cb > 0);
- case 5:
- return ak();
- case 7:
- return (an()) || (this.cb > 0);
- case 8:
- return ap();
- case 9:
- return aq();
- case 10:
- if (this.cb == -1)
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dM = 0;
- this.dL = 0;
- this.cb = -2;
- }
- }
- else if (this.cb == -2)
- {
- this.az += 1;
- if (this.az >= 3)
- {
- this.az = 0;
- this.bZ += 1;
- if (this.bZ >= 3) {
- this.cb = -3;
- }
- }
- }
- else if (this.cb == -3)
- {
- this.az += 1;
- if (this.az >= 40)
- {
- a(false, 0);
- this.cb = -4;
- }
- }
- else
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dM = 0;
- this.dL = 0;
- this.cb = 0;
- this.bZ = 0;
- this.dH = null;
- this.x = 0;
- }
- }
- return true;
- case 12:
- return y();
- case 13:
- return v();
- case 14:
- return q();
- case 15:
- return s();
- case 16:
- return B();
- }
- }
- catch (Throwable localThrowable)
- {
- c();
- }
- return false;
- }
- private final void c(Graphics paramGraphics, int paramInt1, int paramInt2)
- {
- for (int i5 = 0; i5 < 5; i5++)
- {
- int i4 = this.ab[i5];
- if (i4 >= 0)
- {
- int i1 = i4 / 6;
- int i3 = i1 * 16;
- int i2 = (i4 - i1 * 6) * 16;
- b(paramGraphics, this.cp, 96 + i2, 672 + i3, 16, 16, this.Z[i5] - paramInt1 - 8, this.aa[i5] - paramInt2 - 8);
- }
- }
- }
- private final void m()
- {
- this.cq = ((byte[][])null);
- this.cr = ((byte[][])null);
- int i4 = this.u / this.h + 1;
- this.ds = (i4 * 3);
- this.dt = (this.v / this.i + 1);
- this.cq = new byte[this.dt][this.ds];
- this.cr = new byte[this.dt][this.ds];
- this.bF = (this.bG = 0);
- int i1;
- for (int i2 = 0; i2 < this.dt; i2++) {
- for (i1 = 0; i1 < i4 * 2; i1++)
- {
- int i3 = b(10);
- int i5;
- if (i3 == 9) {
- i5 = 71;
- } else if (i3 >= 7) {
- i5 = 72;
- } else {
- i5 = 73;
- }
- this.cq[i2][i1] = i5;
- this.cr[i2][i1] = -1;
- this.cq[i2][(i1 + i4)] = i5;
- this.cr[i2][(i1 + i4)] = -1;
- }
- }
- for (i2 = 0; i2 < this.dt; i2++) {
- for (i1 = 0; i1 < i4; i1++)
- {
- this.cq[i2][(i1 + i4 * 2)] = this.cq[i2][i1];
- this.cr[i2][(i1 + i4 * 2)] = this.cr[i2][i1];
- }
- }
- ad();
- f(this.bF, this.bG);
- this.aq = (this.ds * this.h - 1);
- this.ar = (this.dt * this.i - 1);
- this.bH = ((i4 << 1) * this.h - 1);
- this.bI = (this.ar - this.dv);
- if (this.bH < 0) {
- this.bH = 0;
- }
- if (this.bI < 0) {
- this.bI = 0;
- }
- for (int i6 = 0; i6 < 5; i6++)
- {
- this.ab[i6] = ((byte)b(8));
- this.Z[i6] = ((short)(this.h + b(this.u)));
- this.aa[i6] = -16;
- }
- }
- private final void n()
- {
- int i1 = 3;
- this.bF += i1;
- if (this.bF > this.bH)
- {
- this.bF -= this.bF / this.h * this.h;
- f(this.bF, this.bG);
- }
- g(this.bF, this.bG);
- for (int i2 = 0; i2 < 5; i2++)
- {
- int i4 = this.ab[i2];
- if (this.bD == 0) {
- i4 = (byte)(i4 + 1);
- }
- int i3 = (short)(this.Z[i2] - i1);
- if ((i4 >= 8) || (i3 <= -16))
- {
- i4 = 0;
- i3 = (short)(this.h + b(this.u));
- this.aa[i2] = ((short)b(this.v));
- }
- this.ab[i2] = i4;
- this.Z[i2] = i3;
- }
- this.bD += 1;
- if (this.bD >= 4) {
- this.bD = 0;
- }
- }
- private final void o()
- {
- d(false);
- this.bf = false;
- this.bg = false;
- this.aT = 0;
- this.aK = 0;
- this.bj = true;
- this.as = 0;
- this.av = 1;
- this.at = 1;
- this.am = ((this.u >> 1) - (this.h >> 1));
- this.an = (this.v / 3);
- this.ao = -1;
- this.ap = this.an;
- d(this.bT);
- this.ac = 0;
- p();
- m();
- b(true, -1);
- this.x = 14;
- b("/fly.mid");
- }
- private final void p()
- {
- int i1 = this.ct.indexOf('#', this.ac);
- if (i1 == -1) {
- i1 = this.ct.length();
- }
- String str = this.ct.substring(this.ac, i1);
- this.ac = (i1 + 1);
- this.ew = str;
- this.ep = 0;
- this.en = (this.an + this.i);
- this.eo = 0;
- this.er = this.u;
- a(null, 0, 0, false, false, false, true);
- this.aN = 192;
- }
- private final boolean q()
- {
- if (this.cb == 0)
- {
- if (this.ca == 0)
- {
- r();
- return true;
- }
- if (this.ao == -1)
- {
- this.aN -= 1;
- if (this.aN < 0) {
- if (this.ac < this.ct.length()) {
- p();
- } else {
- this.ao = this.u;
- }
- }
- }
- else if (this.ao > this.am)
- {
- this.ao -= 3;
- }
- else
- {
- this.J = ((short)(this.J + 1));
- a(true, this.bT, 10);
- g();
- b(false, 0);
- }
- }
- if (this.cb != 2)
- {
- L();
- n();
- }
- return true;
- }
- private final void r()
- {
- this.ew = (this.a[120] + this.J + this.a[121]);
- this.ep = 0;
- this.en = (this.i << 1);
- this.eo = 0;
- this.er = this.u;
- a(null, 0, 0, false, false, true, true);
- if (this.c == 1) {
- a("/cleared.mid", this.bq, false);
- }
- b(true, -1);
- this.x = 15;
- }
- private final boolean s()
- {
- if (this.cb == 0)
- {
- if (this.ca == 0)
- {
- if (this.bS == 0) {
- ae();
- } else {
- f(true);
- }
- }
- else
- {
- if ((this.S) || (this.R))
- {
- this.S = (this.R = 0);
- b(false, 0);
- return true;
- }
- if (this.N)
- {
- this.N = false;
- if (this.ep > 0)
- {
- this.ep -= 2;
- if (this.ep < 0) {
- this.ep = 0;
- }
- return true;
- }
- }
- else if (this.O)
- {
- this.O = false;
- if (this.ep < this.eq)
- {
- this.ep += 2;
- if (this.ep > this.eq) {
- this.ep = this.eq;
- }
- return true;
- }
- }
- }
- return false;
- }
- return true;
- }
- private final void t()
- {
- d(false);
- this.ad = ((byte)(this.J > 100 ? 100 : this.J));
- this.ae = (" X " + this.ad);
- this.aN = 256;
- this.ew = ("0000 0000 0000 0000##" + this.a[105]);
- this.af = this.ew.toCharArray();
- this.ep = 0;
- this.en = (this.i << 1);
- this.eo = 0;
- this.er = this.u;
- u();
- a(null, 0, 0, false, false, false, false);
- m();
- b(true, -1);
- this.dH = a(null, "/sleep.png");
- this.x = 13;
- b("/universe.mid");
- }
- private final void u()
- {
- int i3 = 0;
- for (int i1 = 1; i1 <= 16; i1++)
- {
- int i2 = b(32);
- this.af[i3] = ((char)(i2 < 10 ? i2 + 48 : i2 - 10 + 65));
- i3++;
- if (i1 % 4 == 0) {
- i3++;
- }
- }
- this.ew = new String(this.af);
- }
- private final boolean v()
- {
- if (this.cb == 0) {
- if (this.ca == 0)
- {
- this.dH = null;
- if (this.M[1].length() > 0) {
- ae();
- } else {
- a(this.a[107] + this.ad + this.a[108], 0, (byte)0);
- }
- }
- else if (this.aN > 0)
- {
- this.aN -= 1;
- if (this.aN == 0)
- {
- String str = w();
- for (int i1 = this.M.length - 1; i1 > 0; i1--) {
- this.M[i1] = this.M[(i1 - 1)];
- }
- this.M[0] = str;
- this.ew = (str + "##" + this.a[106]);
- this.af = null;
- this.ep = 0;
- this.en = (this.i << 1);
- this.eo = 0;
- this.er = this.u;
- a(null, 0, 0, false, false, false, false);
- this.J = ((short)(this.J - this.ad));
- g();
- }
- else
- {
- u();
- }
- }
- else if ((this.R) || (this.S))
- {
- this.R = (this.S = 0);
- b(false, 0);
- }
- }
- n();
- return true;
- }
- private final String w()
- {
- byte[] arrayOfByte = new byte[10];
- a(arrayOfByte, 0, this.L);
- arrayOfByte[5] = this.ad;
- a(arrayOfByte, 6, (int)System.currentTimeMillis());
- int i2 = 76;
- for (int i1 = 0; i1 < 10; i1++) {
- if (i1 != 4) {
- i2 = (byte)(i2 + ((byte)(arrayOfByte[i1] + i1) ^ 0xFFFFFFFF));
- }
- }
- arrayOfByte[4] = i2;
- String str = a(arrayOfByte, arrayOfByte.length << 3);
- str = str.substring(0, 4) + ' ' + str.substring(4, 8) + ' ' + str.substring(8, 12) + ' ' + str.substring(12);
- return str;
- }
- private final void a(byte[] paramArrayOfByte, int paramInt1, int paramInt2)
- {
- int i2 = 24;
- for (int i1 = 0; i1 < 4; i1++)
- {
- paramArrayOfByte[(paramInt1 + i1)] = ((byte)(0xFF & paramInt2 >>> i2));
- i2 -= 8;
- }
- }
- private final String a(byte[] paramArrayOfByte, int paramInt)
- {
- StringBuffer localStringBuffer = new StringBuffer(19);
- String str = "";
- int i3 = 0;
- int i4 = 0;
- int i5 = 0;
- for (int i1 = 0; i1 < paramInt; i1++)
- {
- int i2 = paramArrayOfByte[(i1 >> 3)] >> 7 - i1 % 8 & 0x1;
- i3 |= i2 << 4 - i5;
- i5++;
- if (i5 > 4)
- {
- localStringBuffer.append(a(i3));
- i5 = 0;
- i3 = 0;
- }
- }
- if (i5 > 0) {
- localStringBuffer.append(a(i3));
- }
- return localStringBuffer.toString();
- }
- private final char a(int paramInt)
- {
- if (paramInt < 10) {
- return (char)(paramInt + 48);
- }
- return (char)(paramInt - 10 + 65);
- }
- private final void x()
- {
- c((byte)4, (byte)-1);
- this.dS = false;
- if (this.dY == 0)
- {
- this.ew = this.a[119];
- this.ep = 0;
- this.en = 96;
- this.eo = 0;
- this.er = this.u;
- a(null, 0, 0, false, false, true, true);
- }
- this.ag = (this.ah = 0);
- this.dI = a(this.dI, "/train.png");
- b(true, -1);
- a(true, 0);
- this.x = 12;
- b("/train.mid");
- }
- private final boolean y()
- {
- if (this.dM == 0)
- {
- if (this.dY > 0)
- {
- if (this.N)
- {
- this.N = false;
- if (this.dX > 0) {
- this.dX = ((byte)(this.dX - 1));
- } else {
- this.dX = ((byte)(this.dY - 1));
- }
- if (this.dX < this.ea) {
- this.ea = this.dX;
- } else if (this.dX >= this.ea + this.dZ) {
- this.ea = ((byte)(this.dX - this.dZ + 1));
- }
- }
- else if (this.O)
- {
- this.Q = (this.O = 0);
- if (this.dX < this.dY - 1) {
- this.dX = ((byte)(this.dX + 1));
- } else {
- this.dX = 0;
- }
- if (this.dX < this.ea) {
- this.ea = this.dX;
- } else if (this.dX >= this.ea + this.dZ) {
- this.ea = ((byte)(this.dX - this.dZ + 1));
- }
- }
- else if ((this.R) || (this.S))
- {
- this.R = (this.S = 0);
- b(false, -1);
- a(false, 2);
- }
- }
- else if (this.N)
- {
- this.N = false;
- if (this.ep > 0)
- {
- this.ep -= 2;
- if (this.ep < 0) {
- this.ep = 0;
- }
- }
- }
- else if (this.O)
- {
- this.O = false;
- if (this.ep < this.eq)
- {
- this.ep += 2;
- if (this.ep > this.eq) {
- this.ep = this.eq;
- }
- }
- }
- if (this.T)
- {
- this.T = false;
- b(false, -1);
- a(false, 1);
- }
- }
- else
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dL = 0;
- if (this.dM == 2)
- {
- this.dM = 0;
- switch (this.dN)
- {
- case 0:
- break;
- case 1:
- ae();
- this.dI = null;
- return true;
- case 2:
- i();
- if (this.c == 1) {
- a();
- }
- this.bS = 0;
- this.bR = (this.dV[this.dX] == 1 ? 3 : 2);
- X();
- this.x = 1;
- d(true);
- this.dI = null;
- }
- }
- else
- {
- this.dM = 0;
- }
- }
- }
- this.ag += 24;
- if (this.ag >> 4 >= 384) {
- this.ag -= 6144;
- }
- this.ah += 64;
- if (this.ah >> 4 >= 384) {
- this.ah -= 6144;
- }
- return true;
- }
- private final void a(int paramInt, String paramString1, String paramString2, String paramString3)
- {
- this.ak = paramInt;
- this.ai = paramString2;
- this.aj = paramString3;
- this.ew = paramString1;
- this.ep = 0;
- this.en = this.k;
- this.eo = this.k;
- this.er = (this.u - this.h);
- a(null, 0, 0, true, false, true, true);
- if (this.et > this.es)
- {
- int i1 = (this.et - this.es) * this.g;
- this.en += (i1 >> 1);
- this.eo += (i1 >> 1);
- this.eq = 0;
- }
- this.x = 2;
- a(true, -1);
- }
- private final boolean z()
- {
- boolean bool = false;
- if (this.dM == 0)
- {
- if (this.N)
- {
- this.N = false;
- if (this.ep > 0)
- {
- this.ep -= 2;
- if (this.ep < 0) {
- this.ep = 0;
- }
- bool = true;
- }
- }
- else if (this.O)
- {
- this.O = false;
- if (this.ep < this.eq)
- {
- this.ep += 2;
- if (this.ep > this.eq) {
- this.ep = this.eq;
- }
- bool = true;
- }
- }
- else if ((this.ai != null) && (this.S))
- {
- this.S = false;
- a(false, 0);
- }
- else if ((this.aj != null) && (this.T))
- {
- this.T = false;
- a(false, 1);
- }
- }
- else
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dL = 0;
- if (this.dM == 2)
- {
- this.dM = 0;
- switch (this.dN)
- {
- case 0:
- bool = a(true);
- break;
- case 1:
- bool = a(false);
- }
- }
- else
- {
- this.dM = 0;
- }
- }
- bool = true;
- }
- return bool;
- }
- private final boolean a(boolean paramBoolean)
- {
- this.x = 1;
- if (this.ak == -1) {
- return true;
- }
- if (!paramBoolean)
- {
- if (this.ak == 10) {
- ae();
- }
- return true;
- }
- if (this.ak == 8)
- {
- this.C = true;
- }
- else if (this.ak == 7)
- {
- if (this.I < 3) {
- this.dc = true;
- } else {
- this.I = ((short)(this.I - 3));
- }
- this.da = true;
- }
- else if (this.ak == 9)
- {
- t();
- }
- else if (this.ak == 10)
- {
- o();
- }
- else
- {
- this.I = ((short)(this.I - this.br[this.ak]));
- this.cq[this.ap][this.ao] = -98;
- f(this.bF, this.bG);
- int tmp182_179 = this.ak;
- byte[] tmp182_175 = this.D;
- tmp182_175[tmp182_179] = ((byte)(tmp182_175[tmp182_179] + 1));
- if (this.ak == 4) {
- this.H = this.D[4];
- }
- g();
- }
- return true;
- }
- private final void A()
- {
- d(false);
- this.dH = null;
- c(false);
- b(0, this.a[111], this.a[30], null);
- this.x = 16;
- }
- private final void b(int paramInt, String paramString1, String paramString2, String paramString3)
- {
- b("/universe.mid");
- this.ai = paramString2;
- this.aj = paramString3;
- this.al = paramInt;
- this.ew = paramString1;
- this.ep = 0;
- this.eo = 0;
- this.er = this.u;
- this.en = 0;
- a(null, 0, 0, true, true, true, true);
- a(true, -1);
- }
- private final boolean B()
- {
- boolean bool = false;
- if (this.dM == 0)
- {
- if (this.N)
- {
- this.N = false;
- if ((this.al != 5) && (this.ep > 0))
- {
- this.ep -= 2;
- if (this.ep < 0) {
- this.ep = 0;
- }
- bool = true;
- }
- }
- else if (this.O)
- {
- this.O = false;
- if ((this.al != 5) && (this.ep < this.eq))
- {
- this.ep += 2;
- if (this.ep > this.eq) {
- this.ep = this.eq;
- }
- bool = true;
- }
- }
- else if ((this.ai != null) && (this.S))
- {
- this.S = false;
- a(false, 0);
- }
- else if ((this.aj != null) && (this.T))
- {
- this.T = false;
- a(false, 1);
- }
- }
- else
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dL = 0;
- this.dP = false;
- if (this.dM == 2)
- {
- this.dM = 0;
- switch (this.dN)
- {
- case 0:
- bool = b(true);
- break;
- case 1:
- bool = b(false);
- }
- }
- else
- {
- this.dM = 0;
- }
- }
- bool = true;
- }
- return bool;
- }
- private final boolean b(boolean paramBoolean)
- {
- this.ai = null;
- this.aj = null;
- int i1 = 0;
- switch (this.al)
- {
- case 0:
- i1 = 1;
- }
- if (i1 != 0)
- {
- this.dH = null;
- ae();
- }
- return true;
- }
- private final int b(int paramInt)
- {
- int i1 = this.z.nextInt();
- if (i1 < 0) {
- i1 = -i1;
- }
- return i1 % paramInt;
- }
- private final void C()
- {
- if (this.bn != -1)
- {
- this.bm -= 1;
- if (this.bm <= 0) {
- this.bn = -1;
- }
- }
- else
- {
- int i1 = (this.bF + b(this.du)) / this.h;
- int i2 = (this.bG + b(this.dv)) / this.i;
- if ((i1 < this.ds) && (i2 < this.dt) && (this.cr[i2][i1] == -8) && ((this.cq[i2][i1] == -57) || (this.cq[i2][i1] == -56)))
- {
- this.bn = (i1 * this.h);
- this.bo = (i2 * this.i);
- this.bm = 32;
- }
- }
- }
- private final void D()
- {
- if (this.aL > 0)
- {
- this.aL -= 1;
- int i1 = this.h * this.aL / 8;
- int i2 = b(i1 + 1) - (i1 >> 1);
- int i3 = b(i1 + 1) - (i1 >> 1);
- this.bF += i2;
- this.bG += i3;
- if (this.bF < 0) {
- this.bF = 0;
- } else if (this.bF > this.bH) {
- this.bF = this.bH;
- }
- if (this.bG < 0) {
- this.bG = 0;
- } else if (this.bG > this.bI) {
- this.bG = this.bI;
- }
- g(this.bF, this.bG);
- }
- }
- private final boolean E()
- {
- if ((this.cR) && (this.db) && (this.at != 5))
- {
- long l1;
- if (!this.bY) {
- l1 = 60000L - (System.currentTimeMillis() - this.bX + this.bW);
- } else {
- l1 = 60000L - this.bW;
- }
- if (l1 <= 0L)
- {
- this.aX = 0;
- H();
- }
- }
- if ((this.aQ > 0) && (this.bL == this.bF) && (this.bM == this.bG))
- {
- this.aQ -= 1;
- if (this.aQ == 0)
- {
- this.aW = -1;
- this.aB = -1;
- T();
- }
- }
- if ((this.bS == 0) && (this.bR == 1) && (!this.C) && (this.X))
- {
- this.X = false;
- a(8, "DO YOU WANT TO ENABLE THE CHEAT?", this.a[32], this.a[33]);
- return false;
- }
- int i1 = this.bF;
- int i2 = this.bG;
- int i3;
- int i4;
- if ((this.at <= 4) && (this.av == 0) && (this.aZ == 0))
- {
- this.bk = false;
- if (this.be)
- {
- this.be = false;
- this.aK = 0;
- i3 = 0;
- i4 = 1;
- byte b1 = this.cA[this.aw];
- int i6 = this.cE[this.aw];
- int i7 = this.cF[this.aw];
- if (b1 == -20)
- {
- int i9 = i7 / this.i;
- int i8 = i6 / this.h;
- int i5 = this.cq[i9][i8];
- if (((i5 == 87) || (i5 == 91) || (i5 == 92) || (i5 == 93)) && (this.at == 2)) {
- i4 = 0;
- } else if ((i5 == 88) && (this.at == 3)) {
- i4 = 0;
- } else if ((i5 == 89) && (this.at == 0)) {
- i4 = 0;
- } else if ((i5 == 90) && (this.at == 1)) {
- i4 = 0;
- }
- if (i4 != 0) {
- switch (this.at)
- {
- case 0:
- if ((a(i8 - 1, i9, this.at, b1)) && (!a(i6 - this.h, i7, this.aw, 0))) {
- i3 = 1;
- }
- break;
- case 1:
- if ((a(i8 + 1, i9, this.at, b1)) && (!a(i6 + this.h, i7, this.aw, 1))) {
- i3 = 1;
- }
- break;
- case 2:
- if ((a(i8, i9 - 1, this.at, b1)) && (!a(i6, i7 - this.i, this.aw, 2))) {
- i3 = 1;
- }
- break;
- case 3:
- if ((a(i8, i9 + 1, this.at, b1)) && (!a(i6, i7 + this.i, this.aw, 3))) {
- i3 = 1;
- }
- break;
- }
- }
- if (i3 != 0)
- {
- this.cC[this.aw] = ((byte)this.h);
- this.cB[this.aw] = ((byte)this.at);
- this.cD[this.aw] = false;
- }
- }
- }
- if ((this.aw == -1) || (this.cB[this.aw] == 4)) {
- if (J())
- {
- if (!this.be) {
- this.aw = -1;
- }
- this.bd = true;
- if ((!this.bf) && (!this.bj)) {
- this.as = 3;
- }
- }
- else if ((this.az == 0) && (!this.bf) && (!this.bj) && (this.aZ == 0))
- {
- this.as = 3;
- }
- }
- }
- else if (this.aZ > 0)
- {
- this.aZ = ((byte)(this.aZ - 1));
- if (this.aZ <= 0)
- {
- this.aZ = 0;
- i3 = this.ao;
- i4 = this.ap;
- switch (this.at)
- {
- case 0:
- i3--;
- break;
- case 1:
- i3++;
- break;
- case 2:
- i4--;
- break;
- case 3:
- i4++;
- }
- this.cq[i4][i3] = 124;
- f(this.bF, this.bG);
- this.as = 3;
- this.az = 0;
- this.bl = true;
- }
- }
- if (L()) {
- return false;
- }
- if ((this.at == 5) && ((this.R) || (this.S) || (this.T)))
- {
- this.R = (this.S = this.T = 0);
- if (!this.dc)
- {
- Y();
- d(true);
- }
- else
- {
- f(false);
- }
- return true;
- }
- if (this.av != 0)
- {
- if ((this.bd) && (this.av <= this.j))
- {
- this.bd = false;
- G();
- if ((this.aY == 0) && (!this.bj)) {
- this.aT = (this.aw != -1 ? this.m : 0);
- }
- }
- switch (this.aY)
- {
- case 1:
- this.aT += 6;
- break;
- case 2:
- this.aT -= 6;
- }
- this.az = 0;
- K();
- if (this.av == 0)
- {
- switch (this.aY)
- {
- case 1:
- this.aY = 0;
- this.bj = true;
- this.aT = this.k;
- this.as = 0;
- this.aK = 1;
- break;
- case 2:
- this.aY = 0;
- this.bj = false;
- this.aT = 0;
- this.as = 0;
- }
- this.az = 0;
- this.bi = false;
- if (this.bh)
- {
- this.bh = false;
- if (this.cq[this.ap][this.ao] == -56) {
- this.cr[this.ap][this.ao] = ((byte)(this.cQ ? 'Ê' : 'Ë'));
- }
- this.cq[this.ap][this.ao] = bp[b(4)];
- f(this.bF, this.bG);
- }
- switch (this.aU)
- {
- case 1:
- this.aU = 0;
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- this.aK = 0;
- this.bf = true;
- this.as = 0;
- b(F());
- break;
- case 2:
- this.aU = 0;
- this.bf = false;
- this.aK = 0;
- this.cr[this.ap][this.ao] = -36;
- f(this.bF, this.bG);
- this.ao += 1;
- this.am += this.h;
- b(F());
- this.P = (this.Q = this.N = this.O = 0);
- }
- }
- }
- else if ((!this.bf) && (!this.bg) && (!this.bj) && (this.aZ == 0) && (this.at < 4) && (++this.az >= 160))
- {
- this.at = 4;
- this.as = 0;
- this.bb = true;
- }
- if (this.aI != -1)
- {
- this.aM -= 1;
- if (this.aM <= 0)
- {
- if (this.cr[this.aJ][this.aI] == -43)
- {
- this.cr[this.aJ][this.aI] = -42;
- this.aM = 6;
- }
- else
- {
- this.cr[this.aJ][this.aI] = -1;
- this.aI = -1;
- }
- f(this.bF, this.bG);
- }
- }
- if (this.dn > 0) {
- O();
- }
- if (this.jdField_do == 0)
- {
- this.aN -= 1;
- if (this.aN <= 0)
- {
- i3 = this.cr[this.cP][this.cO];
- switch (i3)
- {
- case -41:
- i3 = -24;
- break;
- case -24:
- i3 = -23;
- break;
- default:
- i3 = -41;
- this.dl = (this.cO * this.h);
- this.dm = (this.cP * this.i + (this.i >> 1));
- this.dp = 0;
- this.dq = -1;
- this.dr = 4;
- this.jdField_do = 1;
- }
- this.cr[this.cP][this.cO] = i3;
- this.aN = 6;
- f(this.bF, this.bG);
- }
- }
- if ((!this.dR) && (this.aQ == 0)) {
- d(this.am, this.an);
- }
- if ((this.bF != i1) || (this.bG != i2)) {
- g(this.bF, this.bG);
- }
- return true;
- }
- private final String F()
- {
- if (this.bf) {
- return "/mow.mid";
- }
- if (this.bS != 0)
- {
- if (!this.cR)
- {
- if (this.H != -1) {
- return "/ingame" + this.H + ".mid";
- }
- return "/ingame" + b(this.D[4] + 1) + ".mid";
- }
- if (!this.db) {
- return "/shop.mid";
- }
- return "/bonus.mid";
- }
- if (this.bR == 1) {
- return "/shop.mid";
- }
- if ((this.bR == 2) || (this.bR == 4) || (this.bR == 5)) {
- return "/sandman.mid";
- }
- return "/shop.mid";
- }
- private final void b(String paramString)
- {
- if (this.c == 1) {
- a(paramString, this.bq, true);
- }
- }
- private final void G()
- {
- int i1 = this.cq[this.ap][this.ao];
- int i2 = this.cr[this.ap][this.ao];
- if (this.aC != -1)
- {
- this.cq[this.aD][this.aC] = -81;
- f(this.bF, this.bG);
- this.aC = -1;
- }
- else if (this.aE != -1)
- {
- this.cq[this.aF][this.aE] = b(this.cq[this.aF][this.aE]);
- f(this.bF, this.bG);
- this.aE = -1;
- }
- else if (this.aR != -1)
- {
- this.cq[this.aS][this.aR] = c(this.cq[this.aS][this.aR]);
- f(this.bF, this.bG);
- this.aR = -1;
- }
- else if (this.aG != -1)
- {
- if (this.aI != -1)
- {
- this.cr[this.aJ][this.aI] = -1;
- f(this.bF, this.bG);
- }
- this.cr[this.aH][this.aG] = -43;
- f(this.bF, this.bG);
- this.aI = this.aG;
- this.aJ = this.aH;
- this.aM = 6;
- this.aG = -1;
- }
- else if (this.aO != -1)
- {
- this.cy -= 1;
- this.cr[this.aP][this.aO] = -52;
- f(this.bF, this.bG);
- this.aO = -1;
- }
- if (this.bj)
- {
- if (i2 == -11) {
- this.aY = 2;
- }
- }
- else if (i2 == -12)
- {
- this.aY = 1;
- this.aT = 0;
- return;
- }
- if (i2 == -44)
- {
- this.aG = this.ao;
- this.aH = this.ap;
- return;
- }
- if ((i2 == -39) && (this.cO != -1) && (this.jdField_do == -1))
- {
- this.jdField_do = 0;
- this.aN = 6;
- }
- this.bg = false;
- if (!this.bf) {
- if (i2 == -51)
- {
- this.da = false;
- if ((this.cR) && (!this.db))
- {
- this.db = true;
- b(F());
- l();
- this.bW = 0L;
- }
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- }
- else if (i2 == -8)
- {
- this.bU += 1;
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- }
- else if (i2 == -35)
- {
- this.ax = 0;
- this.cT = true;
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- }
- else if (i2 == -13)
- {
- this.ax = 0;
- this.cU = true;
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- }
- else if (i2 == -49)
- {
- this.cz += 1;
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- }
- else if (i2 == -54)
- {
- this.cy -= 1;
- this.cr[this.ap][this.ao] = -55;
- f(this.bF, this.bG);
- }
- else if (i2 == -53)
- {
- this.aO = this.ao;
- this.aP = this.ap;
- }
- else if (i2 == -33)
- {
- if (this.cz > 0)
- {
- this.cz -= 1;
- this.dd[this.dk] = ((byte)this.ao);
- this.de[this.dk] = ((byte)this.ap);
- this.df[this.dk] = 1;
- this.dg[this.dk] = 16;
- this.dk += 1;
- this.cr[this.ap][this.ao] = -17;
- f(this.bF, this.bG);
- }
- else
- {
- this.aV = 4;
- this.ax = 4;
- }
- }
- else if ((i2 == -18) || (i2 == -34) || (i2 == -50))
- {
- this.bg = true;
- }
- else if (i2 == -36)
- {
- this.aU = 1;
- }
- else if (i2 == -10)
- {
- this.J = ((short)(this.J + 1));
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- a(true, this.bS, this.bR);
- this.I = ((short)(this.I + this.bU));
- this.ec = 0;
- g();
- d(false);
- k();
- r();
- return;
- }
- }
- if (i1 == -92)
- {
- I();
- }
- else if (i1 == -94)
- {
- c(0);
- }
- else if (i1 == -108)
- {
- this.bk = true;
- this.as = 1;
- }
- else if (((i1 & 0xFF) >= 191) && ((i1 & 0xFF) <= 194))
- {
- a(i1);
- }
- else if (i1 == -90)
- {
- c(1);
- }
- else if (i1 == -80)
- {
- this.aC = this.ao;
- this.aD = this.ap;
- }
- else if ((!this.bf) && ((i1 & 0xFF) >= 185) && ((i1 & 0xFF) <= 190))
- {
- this.aE = this.ao;
- this.aF = this.ap;
- }
- else if ((!this.bf) && ((i1 & 0xFF) >= 177) && ((i1 & 0xFF) <= 180))
- {
- this.aR = this.ao;
- this.aS = this.ap;
- }
- else if ((!this.bf) && (i1 == -97))
- {
- this.cV = true;
- this.cq[this.ap][this.ao] = 124;
- f(this.bF, this.bG);
- }
- else if (i1 == -89)
- {
- this.cW = false;
- a((byte)-89, (byte)-88);
- }
- else if (i1 == -87)
- {
- this.cX = false;
- a((byte)-87, (byte)-86);
- }
- else if (i1 == -85)
- {
- this.cY = false;
- a((byte)-85, (byte)-84);
- }
- else if (i1 == -83)
- {
- this.cZ = false;
- a((byte)-83, (byte)-82);
- }
- else if (i1 == -88)
- {
- this.cW = true;
- this.aW = 2;
- a((byte)-88, (byte)-89);
- this.aQ = 64;
- d(this.cG * this.h, this.cH * this.i);
- }
- else if (i1 == -86)
- {
- this.cX = true;
- this.aW = 3;
- a((byte)-86, (byte)-87);
- this.aQ = 64;
- d(this.cI * this.h, this.cJ * this.i);
- }
- else if (i1 == -84)
- {
- this.cY = true;
- this.aW = 0;
- a((byte)-84, (byte)-85);
- this.aQ = 64;
- d(this.cK * this.h, this.cL * this.i);
- }
- else if (i1 == -82)
- {
- this.cZ = true;
- this.aW = 1;
- a((byte)-82, (byte)-83);
- this.aQ = 64;
- d(this.cM * this.h, this.cN * this.i);
- }
- else if ((!this.bf) && (i1 == -81))
- {
- H();
- }
- else if ((!this.bf) && (this.cy == 0) && (i1 == -106))
- {
- d(false);
- k();
- this.au = this.at;
- this.at = 6;
- this.as = 0;
- this.bb = true;
- }
- else if ((this.bf) && (i1 == -96))
- {
- this.aU = 2;
- }
- else if (((i1 & 0xFF) >= 151) && ((i1 & 0xFF) <= 157))
- {
- int i3 = (i1 & 0xFF) - 151;
- int i4 = this.I >= this.br[i3] ? 1 : 0;
- a(i4 != 0 ? i3 : -1, this.a[(82 + i3)] + this.a[(91 + i3)] + (i4 != 0 ? this.a[99] : this.a[98]), i4 != 0 ? this.a[32] : this.a[30], i4 != 0 ? this.a[33] : null);
- }
- }
- private final void H()
- {
- d(false);
- k();
- this.av = 0;
- this.at = 5;
- this.bg = (this.bj = 0);
- this.as = 0;
- if (this.dR)
- {
- this.dR = false;
- T();
- }
- if (this.c == 1) {
- a(this.aX == -1 ? "/death.mid" : "/alarm.mid", this.bq, false);
- }
- this.U = false;
- }
- private final void I()
- {
- for (int i1 = 0; i1 < this.dt; i1++) {
- for (int i2 = 0; i2 < this.ds; i2++) {
- this.cq[i1][i2] = b(this.cq[i1][i2]);
- }
- }
- f(this.bF, this.bG);
- }
- private final void c(int paramInt)
- {
- byte b1;
- byte b2;
- byte b3;
- byte b4;
- byte b5;
- byte b6;
- switch (paramInt)
- {
- case 0:
- b1 = -73;
- b2 = -72;
- b3 = -75;
- b4 = -74;
- b5 = -95;
- b6 = -94;
- break;
- default:
- b1 = 90;
- b2 = 89;
- b3 = 88;
- b4 = 87;
- b5 = -91;
- b6 = -90;
- }
- for (int i1 = 0; i1 < this.dt; i1++) {
- for (int i2 = 0; i2 < this.ds; i2++) {
- this.cq[i1][i2] = a(this.cq[i1][i2], b1, b3, b2, b4, b5, b6);
- }
- }
- f(this.bF, this.bG);
- }
- private final void a(byte paramByte)
- {
- byte b1;
- byte b2;
- byte b3;
- byte b4;
- switch (paramByte)
- {
- case -65:
- case -64:
- b1 = -65;
- b2 = -64;
- b3 = -61;
- b4 = -60;
- break;
- case -63:
- case -62:
- b1 = -63;
- b2 = -62;
- b3 = -59;
- b4 = -58;
- break;
- default:
- return;
- }
- for (int i1 = 0; i1 < this.dt; i1++) {
- for (int i2 = 0; i2 < this.ds; i2++)
- {
- paramByte = this.cq[i1][i2];
- if (paramByte == b1) {
- this.cq[i1][i2] = b2;
- } else if (paramByte == b2) {
- this.cq[i1][i2] = b1;
- } else if (paramByte == b3) {
- this.cq[i1][i2] = b4;
- } else if (paramByte == b4) {
- this.cq[i1][i2] = b3;
- }
- }
- }
- f(this.bF, this.bG);
- }
- private final void a(byte paramByte1, byte paramByte2)
- {
- for (int i1 = 0; i1 < this.dt; i1++) {
- for (int i2 = 0; i2 < this.ds; i2++) {
- if (this.cq[i1][i2] == paramByte1) {
- this.cq[i1][i2] = paramByte2;
- }
- }
- }
- f(this.bF, this.bG);
- }
- private final byte a(byte paramByte1, byte paramByte2, byte paramByte3, byte paramByte4, byte paramByte5, byte paramByte6, byte paramByte7)
- {
- if (paramByte1 == paramByte6) {
- return paramByte7;
- }
- if (paramByte1 == paramByte7) {
- return paramByte6;
- }
- if (paramByte1 == paramByte5) {
- return paramByte3;
- }
- if (paramByte1 == paramByte3) {
- return paramByte5;
- }
- if (paramByte1 == paramByte4) {
- return paramByte2;
- }
- if (paramByte1 == paramByte2) {
- return paramByte4;
- }
- return paramByte1;
- }
- private final byte b(byte paramByte)
- {
- switch (paramByte)
- {
- case -93:
- return -92;
- case -92:
- return -93;
- case -71:
- return -68;
- case -70:
- return -71;
- case -69:
- return -70;
- case -68:
- return -69;
- case -67:
- return -66;
- case -66:
- return -67;
- }
- return paramByte;
- }
- private final byte c(byte paramByte)
- {
- switch (paramByte)
- {
- case -79:
- return -78;
- case -78:
- return -76;
- case -77:
- return -79;
- case -76:
- return -77;
- }
- return paramByte;
- }
- private final boolean a(int paramInt1, int paramInt2)
- {
- paramInt1 *= this.h;
- paramInt2 *= this.i;
- for (int i1 = 0; i1 < this.cx; i1++) {
- if ((this.cB[i1] == 4) && (this.cE[i1] == paramInt1) && (this.cF[i1] == paramInt2))
- {
- this.be = true;
- this.aw = ((byte)i1);
- return true;
- }
- }
- return false;
- }
- private final boolean J()
- {
- int i1 = this.cq[this.ap][this.ao];
- int i2 = this.cr[this.ap][this.ao];
- if (this.bl)
- {
- this.bl = false;
- switch (this.at)
- {
- case 0:
- if (a(-1, 0, false))
- {
- this.ao -= 1;
- this.av = this.h;
- if (this.F) {
- this.bi = true;
- }
- return true;
- }
- break;
- case 1:
- if (a(1, 0, false))
- {
- this.ao += 1;
- this.av = this.h;
- if (this.F) {
- this.bi = true;
- }
- return true;
- }
- break;
- case 2:
- if (a(0, -1, false))
- {
- this.ap -= 1;
- this.av = this.i;
- if (this.F) {
- this.bi = true;
- }
- return true;
- }
- break;
- case 3:
- if (a(0, 1, false))
- {
- this.ap += 1;
- this.av = this.i;
- if (this.F) {
- this.bi = true;
- }
- return true;
- }
- break;
- }
- }
- if (this.bj)
- {
- switch (this.at)
- {
- case 0:
- this.ao -= 1;
- this.av = this.h;
- break;
- case 1:
- this.ao += 1;
- this.av = this.h;
- break;
- case 2:
- this.ap -= 1;
- this.av = this.i;
- break;
- case 3:
- this.ap += 1;
- this.av = this.i;
- }
- return true;
- }
- if (i2 != -44) {
- if ((i1 == -73) && (a(-1, 0, true)))
- {
- this.at = 0;
- this.aK = 3;
- }
- else if ((i1 == -72) && (a(1, 0, true)))
- {
- this.at = 1;
- this.aK = 3;
- }
- else if ((i1 == -75) && (a(0, -1, true)))
- {
- this.at = 2;
- this.aK = 3;
- }
- else if ((i1 == -74) && (a(0, 1, true)))
- {
- this.at = 3;
- this.aK = 3;
- }
- }
- int i3;
- if (this.aK > 0)
- {
- i3 = 1;
- int i4 = 0;
- switch (this.at)
- {
- case 0:
- if (a(-1, 0, false))
- {
- this.ao -= 1;
- if ((!this.dR) && (this.P)) {
- i3 = 0;
- }
- }
- else
- {
- i4 = 1;
- }
- break;
- case 1:
- if (a(1, 0, false))
- {
- this.ao += 1;
- if ((!this.dR) && (this.Q)) {
- i3 = 0;
- }
- }
- else
- {
- i4 = 1;
- }
- break;
- case 2:
- if (a(0, -1, false))
- {
- this.ap -= 1;
- if ((!this.dR) && (this.N)) {
- i3 = 0;
- }
- }
- else
- {
- i4 = 1;
- }
- break;
- case 3:
- if (a(0, 1, false))
- {
- this.ap += 1;
- if ((!this.dR) && (this.O)) {
- i3 = 0;
- }
- }
- else
- {
- i4 = 1;
- }
- break;
- }
- if (i4 == 0)
- {
- if ((this.bf) && (c(this.ao, this.ap) == -19))
- {
- this.cr[this.ap][this.ao] = -1;
- f(this.bF, this.bG);
- this.aL = 8;
- }
- if ((i3 == 0) || (i1 == -108)) {
- this.aK = 3;
- } else {
- this.aK -= 1;
- }
- if (i1 == -108)
- {
- this.bk = true;
- this.aK = 3;
- }
- this.av = this.h;
- return true;
- }
- this.aK = 0;
- this.aL = 8;
- this.bc = false;
- }
- if ((this.av == 0) && (i1 == -108))
- {
- i3 = 0;
- switch (this.at)
- {
- case 0:
- if (a(-1, 0, false)) {
- this.ao -= 1;
- } else {
- i3 = 1;
- }
- break;
- case 1:
- if (a(1, 0, false)) {
- this.ao += 1;
- } else {
- i3 = 1;
- }
- break;
- case 2:
- if (a(0, -1, false)) {
- this.ap -= 1;
- } else {
- i3 = 1;
- }
- break;
- case 3:
- if (a(0, 1, false)) {
- this.ap += 1;
- } else {
- i3 = 1;
- }
- break;
- default:
- i3 = 1;
- }
- if (i3 == 0)
- {
- this.av = this.h;
- this.bk = true;
- this.as = 1;
- if ((!this.bf) && (this.F)) {
- this.bi = true;
- }
- return true;
- }
- }
- if ((!this.dR) && (this.aQ == 0)) {
- if (this.P)
- {
- if (a(-1, 0, false))
- {
- this.ao -= 1;
- this.at = 0;
- this.av = this.h;
- if ((!this.bf) && (this.F)) {
- this.bi = true;
- }
- return true;
- }
- }
- else if (this.Q)
- {
- if (a(1, 0, false))
- {
- this.ao += 1;
- this.at = 1;
- this.av = this.h;
- if ((!this.bf) && (this.F)) {
- this.bi = true;
- }
- return true;
- }
- }
- else if (this.N)
- {
- if (a(0, -1, false))
- {
- this.ap -= 1;
- this.at = 2;
- this.av = this.h;
- if ((!this.bf) && (this.F)) {
- this.bi = true;
- }
- return true;
- }
- }
- else if ((this.O) && (a(0, 1, false)))
- {
- this.ap += 1;
- this.at = 3;
- this.av = this.h;
- if ((!this.bf) && (this.F)) {
- this.bi = true;
- }
- return true;
- }
- }
- return false;
- }
- private final byte b(int paramInt1, int paramInt2)
- {
- if ((paramInt1 < 0) || (paramInt2 < 0) || (paramInt1 >= this.ds) || (paramInt2 >= this.dt)) {
- return -1;
- }
- return this.cq[paramInt2][paramInt1];
- }
- private final byte c(int paramInt1, int paramInt2)
- {
- if ((paramInt1 < 0) || (paramInt2 < 0) || (paramInt1 >= this.ds) || (paramInt2 >= this.dt)) {
- return -1;
- }
- return this.cr[paramInt2][paramInt1];
- }
- private final boolean a(int paramInt1, int paramInt2, boolean paramBoolean)
- {
- int i1 = this.ao + paramInt1;
- int i2 = this.ap + paramInt2;
- this.aZ = 0;
- if ((i1 < 0) || (i2 < 0) || (i1 >= this.ds) || (i2 >= this.dt)) {
- return false;
- }
- if (this.bj) {
- return true;
- }
- int i3 = this.cq[this.ap][this.ao];
- int i4 = this.cq[i2][i1];
- int i5 = this.cr[i2][i1];
- int i6 = 1;
- if (i3 == -66) {
- i6 = paramInt1 != 0 ? 1 : 0;
- } else if (i3 == -67) {
- i6 = paramInt2 != 0 ? 1 : 0;
- } else if (i3 == -68) {
- i6 = (paramInt1 == 1) || (paramInt2 == 1) ? 1 : 0;
- } else if (i3 == -69) {
- i6 = (paramInt1 == -1) || (paramInt2 == 1) ? 1 : 0;
- } else if (i3 == -70) {
- i6 = (paramInt1 == -1) || (paramInt2 == -1) ? 1 : 0;
- } else if (i3 == -71) {
- i6 = (paramInt1 == 1) || (paramInt2 == -1) ? 1 : 0;
- }
- if (i6 == 0) {
- return false;
- }
- if ((!this.bf) && (a(this.ao + paramInt1, this.ap + paramInt2))) {
- return true;
- }
- i6 = ((i4 & 0xFF) >= 94) && ((i4 & 0xFF) <= 200) ? 1 : 0;
- if (i6 != 0)
- {
- if (((i4 & 0xFF) >= 185) && ((i4 & 0xFF) <= 190))
- {
- if (!this.bf) {
- switch (i4)
- {
- case -71:
- i6 = (paramInt1 == -1) || (paramInt2 == 1) ? 1 : 0;
- break;
- case -70:
- i6 = (paramInt1 == 1) || (paramInt2 == 1) ? 1 : 0;
- break;
- case -69:
- i6 = (paramInt1 == 1) || (paramInt2 == -1) ? 1 : 0;
- break;
- case -68:
- i6 = (paramInt1 == -1) || (paramInt2 == -1) ? 1 : 0;
- break;
- case -67:
- i6 = paramInt2 != 0 ? 1 : 0;
- break;
- case -66:
- i6 = paramInt1 != 0 ? 1 : 0;
- }
- } else {
- i6 = 0;
- }
- }
- else if (((i4 & 0xFF) >= 177) && ((i4 & 0xFF) <= 180)) {
- i6 = !this.bf ? 1 : 0;
- } else if ((i4 == -57) || (i4 == -56))
- {
- if (this.bf) {
- this.bh = true;
- } else {
- i6 = 0;
- }
- }
- else if ((i4 == -61) || (i4 == -59)) {
- i6 = 0;
- }
- }
- else if ((i4 == 77) && (!this.bf)) {
- if (this.cV)
- {
- this.aZ = 32;
- this.as = 0;
- if (paramInt1 != 0) {
- this.at = (paramInt1 < 0 ? 0 : 1);
- } else {
- this.at = (paramInt2 < 0 ? 2 : 3);
- }
- this.bi = false;
- this.aK = 0;
- this.az = 0;
- }
- else
- {
- this.aV = 3;
- this.ax = 4;
- }
- }
- if (i6 == 0)
- {
- switch (i5)
- {
- case -50:
- case -44:
- case -34:
- i6 = !this.bf ? 1 : 0;
- break;
- default:
- i6 = 0;
- }
- if (i6 == 0) {
- return false;
- }
- }
- else
- {
- switch (i5)
- {
- case -54:
- i6 = !this.bf ? 1 : 0;
- break;
- case -52:
- case -48:
- case -47:
- case -46:
- case -45:
- case -41:
- case -40:
- case -38:
- case -37:
- case -29:
- case -25:
- case -7:
- case -6:
- case -5:
- case -4:
- case -3:
- case -2:
- i6 = 0;
- break;
- case -51:
- if (!this.bf)
- {
- if ((!this.da) && (this.D[2] == 0))
- {
- this.aV = 1;
- this.ax = 4;
- i6 = 0;
- }
- else
- {
- i6 = 1;
- }
- }
- else {
- i6 = 0;
- }
- break;
- case -36:
- if (!this.cT)
- {
- this.aV = 0;
- this.ax = 4;
- i6 = 0;
- }
- else
- {
- i6 = 1;
- }
- break;
- case -22:
- case -9:
- if (this.cR)
- {
- int i8 = 0;
- int i7;
- String str;
- if (!this.db)
- {
- if (this.D[2] > 0)
- {
- i7 = -1;
- str = this.a[113] + this.a[114];
- }
- else if (!this.da)
- {
- i7 = 7;
- if (this.I >= 3)
- {
- str = this.a[113] + this.a[115] + this.I + this.a[116];
- }
- else
- {
- str = this.a[113] + this.a[117];
- i8 = 1;
- }
- }
- else
- {
- i7 = -1;
- str = this.a[118];
- }
- }
- else
- {
- i7 = -1;
- str = this.a[118];
- }
- a(i7, str, this.a[30], i7 != -1 ? this.a[33] : null);
- }
- else if (this.bS == 0)
- {
- if (this.bR == 1) {
- a(-1, this.a[100] + this.I + this.a[101], this.a[30], null);
- } else if (this.bR == 2)
- {
- if (this.J > 0) {
- a(9, this.a[102] + this.J + this.a[103], this.a[32], this.a[33]);
- } else {
- a(-1, this.a[102] + this.a[104], this.a[30], null);
- }
- }
- else if (this.bR == 3) {
- a(-1, this.a[109], this.a[30], null);
- } else if (this.bR == 4) {
- a(10, this.a[112], this.a[32], this.a[33]);
- } else if (this.bR == 5) {
- a(-1, this.a[110], this.a[30], null);
- }
- }
- i6 = 0;
- break;
- case -21:
- A();
- i6 = 0;
- break;
- case -19:
- i6 = (this.bf) && ((this.aK > 0) || (paramBoolean)) ? 1 : 0;
- break;
- case -12:
- if (!this.bf)
- {
- if (this.cU)
- {
- i6 = 1;
- }
- else
- {
- this.aV = 2;
- this.ax = 4;
- i6 = 0;
- }
- }
- else {
- i6 = 0;
- }
- break;
- case -53:
- case -50:
- case -49:
- case -44:
- case -43:
- case -42:
- case -39:
- case -35:
- case -34:
- case -33:
- case -32:
- case -31:
- case -30:
- case -28:
- case -27:
- case -26:
- case -24:
- case -23:
- case -20:
- case -18:
- case -17:
- case -16:
- case -15:
- case -14:
- case -13:
- case -11:
- case -10:
- case -8:
- default:
- i6 = 1;
- }
- if (i6 == 0) {
- return false;
- }
- }
- return true;
- }
- private final void K()
- {
- int i1 = this.at;
- int i2 = (this.aK > 0) || (this.bi) ? 6 : 3;
- this.av -= i2;
- if (this.at == 6) {
- i1 = this.au;
- }
- switch (i1)
- {
- case 0:
- this.am -= i2;
- break;
- case 1:
- this.am += i2;
- break;
- case 2:
- this.an -= i2;
- break;
- case 3:
- this.an += i2;
- }
- }
- private final boolean L()
- {
- if ((!this.bc) || ((this.at <= 3) && (!this.bj) && ((this.aK > 0) || ((this.F) && (!this.bf) && (this.aZ <= 0)))))
- {
- this.aA = ((this.aA + 1) % 12);
- if (this.bf) {
- this.as = ((this.as + 1) % 2);
- } else if (this.bj) {
- this.as = 0;
- } else if (this.aZ > 0) {
- this.as = ((this.as + 1) % 9);
- } else {
- switch (this.at)
- {
- case 0:
- case 1:
- case 2:
- case 3:
- if (this.av != 0) {
- if (!this.bk) {
- this.as = ((this.as + 1) % 8);
- } else {
- this.as = 1;
- }
- }
- break;
- case 4:
- if (this.bb)
- {
- this.as += 1;
- if (this.as >= 3)
- {
- this.as = 1;
- this.bb = false;
- }
- }
- else
- {
- this.as -= 1;
- if (this.as < 0)
- {
- this.as = 1;
- this.bb = true;
- }
- }
- break;
- case 5:
- if (this.as < 7) {
- this.as += 1;
- }
- break;
- case 6:
- if (this.bb)
- {
- this.as += 1;
- if (this.as >= 10)
- {
- if (this.bS != 0)
- {
- am();
- }
- else if (this.bR == 1)
- {
- ae();
- this.aL = 0;
- this.bL = this.bF;
- this.bM = this.bG;
- }
- else if (this.bR == 5)
- {
- this.G = true;
- g();
- this.bS = this.bT;
- this.bR = 1;
- X();
- d(true);
- }
- else
- {
- x();
- }
- return true;
- }
- }
- else
- {
- this.as -= 1;
- if (this.as < 0)
- {
- this.at = 3;
- this.as = 3;
- l();
- }
- }
- break;
- }
- }
- if (this.aX != -1) {
- this.aX = ((byte)((this.aX + 1) % 2));
- }
- this.bc = true;
- }
- else
- {
- this.bc = false;
- }
- if ((this.at <= 3) && (this.bk)) {
- this.as = 1;
- }
- return false;
- }
- private final void M()
- {
- int i6 = 3;
- for (int i12 = 0; i12 < this.cx; i12++)
- {
- byte b1 = this.cA[i12];
- int i5 = this.cB[i12];
- int i1 = this.cE[i12];
- int i2 = this.cF[i12];
- int i7 = this.cC[i12];
- int i11 = this.cD[i12];
- int i10 = 0;
- int i4;
- int i3;
- if (i7 > 0)
- {
- i3 = i4 = 0;
- switch (i5)
- {
- case 0:
- i3 = i11 != 0 ? -6 : -i6;
- break;
- case 1:
- i3 = i11 != 0 ? 6 : i6;
- break;
- case 2:
- i4 = i11 != 0 ? -6 : -i6;
- break;
- case 3:
- i4 = i11 != 0 ? 6 : i6;
- }
- if ((i11 == 0) || (!a(i1 + i3, i2 + i4, i12, 4)))
- {
- i1 += i3;
- i2 += i4;
- this.cE[i12] = ((short)i1);
- this.cF[i12] = ((short)i2);
- if (this.aw == i12)
- {
- this.am += i3;
- this.an += i4;
- this.ao = (this.am / this.h);
- this.ap = (this.an / this.i);
- }
- i7 -= (i11 != 0 ? 6 : i6);
- }
- }
- if ((i12 == this.aB) && (this.aQ > 1))
- {
- d(i1, i2);
- this.aQ -= 1;
- }
- if (i7 <= 0)
- {
- i4 = i2 / this.i;
- i3 = i1 / this.h;
- int i8 = this.cq[i4][i3];
- int i9 = this.cr[i4][i3];
- i7 = 0;
- i11 = 0;
- if (b1 == -20)
- {
- if (i8 == 90)
- {
- if ((a(i3 - 1, i4, 0, b1)) && (!a(i1 - this.h, i2, i12, 0)))
- {
- i5 = 0;
- i7 = this.h;
- }
- }
- else if (i8 == 89)
- {
- if ((a(i3 + 1, i4, 1, b1)) && (!a(i1 + this.h, i2, i12, 1)))
- {
- i5 = 1;
- i7 = this.h;
- }
- }
- else if (i8 == 88)
- {
- if ((a(i3, i4 - 1, 2, b1)) && (!a(i1, i2 - this.i, i12, 2)))
- {
- i5 = 2;
- i7 = this.i;
- }
- }
- else if (i8 == 87)
- {
- if ((a(i3, i4 + 1, 3, b1)) && (!a(i1, i2 + this.i, i12, 3)))
- {
- i5 = 3;
- i7 = this.i;
- }
- }
- else if (((i8 == 91) || (i8 == 92) || (i8 == 93)) && (a(i3, i4 + 1, 3, b1)) && (!a(i1, i2 + this.i, i12, 3)))
- {
- i5 = 3;
- i7 = this.i;
- i11 = 1;
- }
- }
- else if (((b1 == -32) && (i9 == -16)) || ((b1 == -31) && (i9 == -15)) || ((b1 == -30) && (i9 == -14)))
- {
- i10 = 1;
- }
- else if ((this.aQ == 0) || ((this.bL == this.bF) && (this.bM == this.bG)) || (this.aB != -1))
- {
- if ((this.cW) && (i5 != 2) && (i3 == this.cG) && (i4 >= this.cH - 3) && (i4 <= this.cH - 1) && (a(i3, i4 - 1, 2, b1)) && (!a(i1, i2 - this.i, i12, 2)))
- {
- i5 = 2;
- i7 = this.i;
- }
- else if ((this.cX) && (i5 != 3) && (i3 == this.cI) && (i4 >= this.cJ + 1) && (i4 <= this.cJ + 3) && (a(i3, i4 + 1, 3, b1)) && (!a(i1, i2 + this.i, i12, 3)))
- {
- i5 = 3;
- i7 = this.i;
- }
- else if ((this.cY) && (i5 != 0) && (i4 == this.cL) && (i3 >= this.cK - 3) && (i3 <= this.cK - 1) && (a(i3 - 1, i4, 0, b1)) && (!a(i1 - this.h, i2, i12, 0)))
- {
- i5 = 0;
- i7 = this.h;
- }
- else if ((this.cZ) && (i5 != 1) && (i4 == this.cN) && (i3 >= this.cM + 1) && (i3 <= this.cM + 3) && (a(i3 + 1, i4, 1, b1)) && (!a(i1 + this.h, i2, i12, 1)))
- {
- i5 = 1;
- i7 = this.h;
- }
- if ((i7 != 0) && (this.aW == i5))
- {
- this.aW = -1;
- this.aB = i12;
- this.aQ = 64;
- d(i3 * this.h, i4 * this.i);
- }
- }
- if ((i10 == 0) && (i7 == 0)) {
- switch (i5)
- {
- case 0:
- if ((a(i3 - 1, i4, 0, b1)) && (!a(i1 - this.h, i2, i12, 0))) {
- i7 = this.h;
- }
- break;
- case 1:
- if ((a(i3 + 1, i4, 1, b1)) && (!a(i1 + this.h, i2, i12, 1))) {
- i7 = this.h;
- }
- break;
- case 2:
- if ((a(i3, i4 - 1, 2, b1)) && (!a(i1, i2 - this.i, i12, 2))) {
- i7 = this.i;
- }
- break;
- case 3:
- if ((a(i3, i4 + 1, 3, b1)) && (!a(i1, i2 + this.i, i12, 3))) {
- i7 = this.i;
- }
- break;
- }
- }
- if (i7 == 0) {
- i5 = 4;
- }
- }
- this.cC[i12] = ((byte)i7);
- this.cB[i12] = ((byte)i5);
- this.cD[i12] = i11;
- }
- }
- private final boolean a(int paramInt1, int paramInt2, int paramInt3, int paramInt4)
- {
- for (int i4 = 0; i4 < this.cx; i4++) {
- if (i4 != paramInt3) {
- if (paramInt3 != -1)
- {
- if ((this.cB[i4] != paramInt4) && (b(paramInt1, paramInt2, this.cE[i4], this.cF[i4]))) {
- return true;
- }
- }
- else
- {
- int i1 = this.cC[i4];
- int i2 = this.cE[i4];
- int i3 = this.cF[i4];
- switch (this.cB[i4])
- {
- case 0:
- i2 = (short)(i2 - i1);
- break;
- case 1:
- i2 = (short)(i2 + i1);
- break;
- case 2:
- i3 = (short)(i3 - i1);
- break;
- case 3:
- i3 = (short)(i3 + i1);
- }
- if (b(paramInt1, paramInt2, i2, i3)) {
- return true;
- }
- }
- }
- }
- return false;
- }
- private final boolean b(int paramInt1, int paramInt2, int paramInt3, int paramInt4)
- {
- int i1 = paramInt1 + this.h - 1;
- int i2 = paramInt3 + this.h - 1;
- int i3 = paramInt2 + this.i - 1;
- int i4 = paramInt4 + this.i - 1;
- if (i3 < paramInt4) {
- return false;
- }
- if (paramInt2 > i4) {
- return false;
- }
- if (i1 < paramInt3) {
- return false;
- }
- return paramInt1 <= i2;
- }
- private final boolean a(int paramInt1, int paramInt2, int paramInt3, byte paramByte)
- {
- if ((paramInt1 < 0) || (paramInt2 < 0) || (paramInt1 >= this.ds) || (paramInt2 >= this.dt)) {
- return false;
- }
- int i1 = this.cr[paramInt2][paramInt1];
- switch (i1)
- {
- case -44:
- case -43:
- case -42:
- case -29:
- case -28:
- case -27:
- case -26:
- case -19:
- case -7:
- case -6:
- case -5:
- case -4:
- case -3:
- case -2:
- return false;
- }
- i1 = this.cq[paramInt2][paramInt1];
- if (paramByte == -20)
- {
- switch (i1)
- {
- case 88:
- return paramInt3 != 3;
- case 87:
- return paramInt3 != 2;
- case 90:
- return paramInt3 != 1;
- case 89:
- return paramInt3 != 0;
- case 85:
- case 86:
- return true;
- case 91:
- case 92:
- case 93:
- return paramInt3 != 2;
- }
- }
- else
- {
- switch (paramInt3)
- {
- case 0:
- if ((this.cZ) && (paramInt2 == this.cN) && (paramInt1 >= this.cM + 1) && (paramInt1 <= this.cM + 3)) {
- return false;
- }
- break;
- case 1:
- if ((this.cY) && (paramInt2 == this.cL) && (paramInt1 >= this.cK - 3) && (paramInt1 <= this.cK - 1)) {
- return false;
- }
- break;
- case 2:
- if ((this.cX) && (paramInt1 == this.cI) && (paramInt2 >= this.cJ + 1) && (paramInt2 <= this.cJ + 3)) {
- return false;
- }
- break;
- case 3:
- if ((this.cW) && (paramInt1 == this.cG) && (paramInt2 >= this.cH - 3) && (paramInt2 <= this.cH - 1)) {
- return false;
- }
- break;
- }
- if (((i1 & 0xFF) >= 71) && ((i1 & 0xFF) <= 76)) {
- return true;
- }
- }
- return false;
- }
- private final void N()
- {
- this.bs = ((byte)((this.bs + 1) % 8));
- this.aQ = 16;
- d(this.dl, this.dm);
- if (this.dr == 3)
- {
- i1 = this.dl / this.h;
- int i2 = this.dm / this.i;
- if ((i1 < 0) || (i2 < 0) || (i1 >= this.ds) || (i2 >= this.dt))
- {
- this.jdField_do = -1;
- return;
- }
- int i3 = this.cq[i2][i1];
- int i4 = this.cr[i2][i1];
- int i5 = (((i3 & 0xFF) >= 94) && ((i3 & 0xFF) <= 200)) || (((i3 & 0xFF) >= 85) && ((i3 & 0xFF) <= 93)) || (((i3 & 0xFF) >= 71) && ((i3 & 0xFF) <= 76)) ? 1 : 0;
- if (i5 != 0) {
- switch (i3)
- {
- case -61:
- case -59:
- i5 = 0;
- }
- }
- if (i5 != 0) {
- switch (i4)
- {
- case -41:
- case -40:
- i5 = 0;
- break;
- case -29:
- b((byte)i1, (byte)i2);
- break;
- case -19:
- i5 = 0;
- }
- }
- if (i5 != 0) {
- switch (i3)
- {
- case -79:
- if (this.dp == 0) {
- this.dq = 3;
- } else if (this.dp == 2) {
- this.dq = 1;
- } else {
- i5 = 0;
- }
- break;
- case -78:
- if (this.dp == 1) {
- this.dq = 3;
- } else if (this.dp == 2) {
- this.dq = 0;
- } else {
- i5 = 0;
- }
- break;
- case -77:
- if (this.dp == 0) {
- this.dq = 2;
- } else if (this.dp == 3) {
- this.dq = 1;
- } else {
- i5 = 0;
- }
- break;
- case -76:
- if (this.dp == 1) {
- this.dq = 2;
- } else if (this.dp == 3) {
- this.dq = 0;
- } else {
- i5 = 0;
- }
- break;
- }
- }
- if (i5 == 0) {
- this.jdField_do = -1;
- }
- }
- else if (this.dr == 0)
- {
- this.dr = 8;
- if (this.dq != -1)
- {
- this.dp = this.dq;
- this.dq = -1;
- }
- }
- this.dr = ((byte)(this.dr - 1));
- int i1 = 6;
- switch (this.dp)
- {
- case 0:
- this.dl -= i1;
- break;
- case 1:
- this.dl += i1;
- break;
- case 2:
- this.dm -= i1;
- break;
- default:
- this.dm += i1;
- }
- }
- private final void b(byte paramByte1, byte paramByte2)
- {
- if (this.dn >= 5)
- {
- this.cr[this.di[0]][this.dh[0]] = -1;
- for (int i1 = 0; i1 < this.dn - 1; i1++)
- {
- this.dh[i1] = this.dh[(i1 + 1)];
- this.di[i1] = this.di[(i1 + 1)];
- this.dj[i1] = this.dj[(i1 + 1)];
- }
- this.dn -= 1;
- }
- this.dh[this.dn] = paramByte1;
- this.di[this.dn] = paramByte2;
- this.dj[this.dn] = 6;
- this.dn += 1;
- this.cr[paramByte2][paramByte1] = -28;
- f(this.bF, this.bG);
- }
- private final void O()
- {
- int i1 = 0;
- int i6 = 0;
- while (i1 < this.dn)
- {
- int i5 = this.dj[i1];
- if (i5 <= 0)
- {
- int i2 = this.dh[i1];
- int i3 = this.di[i1];
- int i4 = this.cr[i3][i2];
- int i7 = 0;
- i6 = 1;
- switch (i4)
- {
- case -28:
- i4 = -27;
- break;
- case -27:
- i4 = -26;
- break;
- case -26:
- i4 = -1;
- i7 = 1;
- }
- this.dj[i1] = 6;
- this.cr[i3][i2] = i4;
- if (i7 != 0)
- {
- for (int i8 = i1; i8 < this.dn - 1; i8++)
- {
- this.dh[i8] = this.dh[(i8 + 1)];
- this.di[i8] = this.di[(i8 + 1)];
- this.dj[i8] = this.dj[(i8 + 1)];
- }
- this.dn -= 1;
- i1--;
- }
- }
- else
- {
- this.dj[i1] = ((byte)(i5 - 1));
- }
- i1++;
- }
- if (i6 != 0) {
- f(this.bF, this.bG);
- }
- }
- private final void P()
- {
- int i1 = 0;
- int i7 = 0;
- while (i1 < this.dk)
- {
- int i6 = this.dg[i1];
- if (i6 <= 0)
- {
- int i2 = this.dd[i1];
- int i3 = this.de[i1];
- int i4 = this.df[i1];
- int i8 = 1;
- if ((i3 - i4 >= 0) && (this.cr[(i3 - i4)][i2] == -1))
- {
- int i5 = this.cq[(i3 - i4)][i2];
- if (((i5 & 0xFF) >= 0) && ((i5 & 0xFF) <= 93))
- {
- this.cr[(i3 - i4 + 1)][i2] = -34;
- if (i4 <= 1) {
- this.cr[i3][i2] = -18;
- }
- this.cr[(i3 - i4)][i2] = -50;
- this.df[i1] = ((byte)(i4 + 1));
- this.dg[i1] = 16;
- i8 = 0;
- i7 = 1;
- }
- }
- if (i8 != 0)
- {
- for (int i9 = i1; i9 < this.dk - 1; i9++)
- {
- this.dd[i9] = this.dd[(i9 + 1)];
- this.de[i9] = this.de[(i9 + 1)];
- this.dg[i9] = this.dg[(i9 + 1)];
- }
- this.dk -= 1;
- i1--;
- }
- }
- else
- {
- this.dg[i1] = ((byte)(i6 - 1));
- }
- i1++;
- }
- if (i7 != 0) {
- f(this.bF, this.bG);
- }
- }
- private final void Q()
- {
- int i1 = 48;
- if (this.cc < this.bG) {
- i1 -= 24;
- } else if (this.cc > this.bG) {
- i1 += 24;
- }
- for (int i2 = 0; i2 < 5; i2++)
- {
- if (this.ce[i2] >> this.r > this.v)
- {
- this.cd[i2] = (b(this.u) << this.r);
- this.ce[i2] = (-(b(10) << this.r));
- }
- this.cd[i2] += (b(3) - 1 << this.r);
- this.ce[i2] += i1;
- }
- this.cc = this.bG;
- }
- private final void R()
- {
- if (this.by)
- {
- this.bx = ((byte)(this.bx + 1));
- if (this.bx >= 8)
- {
- this.by = false;
- this.bx = 8;
- }
- }
- else
- {
- this.bx = ((byte)(this.bx - 1));
- if (this.bx <= 0)
- {
- this.by = true;
- this.bx = 0;
- }
- }
- int i1 = this.bt >> this.r;
- int i2 = this.bu >> this.r;
- if (i1 == this.bv) {
- this.bv = b(this.aq + 1 - 24);
- }
- if (i2 == this.bw) {
- this.bw = b(this.ar + 1 - 24);
- }
- int i3 = b(48);
- this.bt += (i1 < this.bv ? i3 : -i3);
- i3 = b(24);
- this.bu += (i2 < this.bw ? i3 : -i3);
- }
- private final void S()
- {
- if (this.bD == 0)
- {
- this.bz = ((this.bz + 1) % 8);
- this.bA = ((this.bA + 1) % 6);
- this.bB = ((this.bB + 1) % 4);
- this.bC = ((this.bC + 1) % 3);
- int i1;
- for (int i3 = 0; i3 < 3; i3++)
- {
- int i5 = (byte)(this.ab[i3] + 1);
- if ((i5 == 0) || (i5 >= 8))
- {
- i1 = b(this.u) + this.bF;
- i2 = b(this.v) + this.bG;
- if (c(i1 / this.h, i2 / this.i) == -1)
- {
- int i4 = b(i1 / this.h, i2 / this.i) & 0xFF;
- if ((i4 < 71) || (i4 > 76)) {
- i5 = -1;
- }
- }
- else
- {
- i5 = -1;
- }
- this.Z[i3] = ((short)i1);
- this.aa[i3] = ((short)i2);
- }
- this.ab[i3] = i5;
- }
- for (int i2 = 0; i2 < this.dB; i2++) {
- for (i1 = 0; i1 < this.dA; i1++)
- {
- boolean bool = false;
- byte b1 = this.dD[i2][i1];
- byte b2 = this.dE[i2][i1];
- switch (b1)
- {
- case -75:
- case -74:
- case -73:
- case -72:
- case 86:
- case 87:
- case 88:
- case 89:
- case 90:
- case 91:
- case 92:
- case 93:
- bool = true;
- break;
- case -106:
- if (this.cy == 0) {
- bool = true;
- }
- break;
- }
- if (!bool) {
- switch (b2)
- {
- case -48:
- bool = this.cW;
- break;
- case -47:
- bool = this.cX;
- break;
- case -46:
- bool = this.cY;
- break;
- case -45:
- bool = this.cZ;
- break;
- case -12:
- bool = true;
- break;
- case -8:
- bool = this.bE;
- }
- }
- if (bool) {
- a(b1, b2, i1 * this.h, i2 * this.i);
- }
- }
- }
- }
- if (this.bB == 0) {
- if (this.bE) {
- this.bE = false;
- } else if (b(7) == 0) {
- this.bE = true;
- }
- }
- this.bD += 1;
- if (this.bD >= 4) {
- this.bD = 0;
- }
- }
- private final void T()
- {
- this.bJ = 0;
- this.bK = 0;
- d(this.am, this.an);
- this.bN = (this.bO = 0);
- this.bP = (this.bQ = 0);
- this.ba = true;
- V();
- }
- private final void d(int paramInt1, int paramInt2)
- {
- this.bL = (paramInt1 + this.j - (this.du >> 1) + this.bJ);
- this.bM = (paramInt2 + this.k - (this.dv >> 1) + this.bK);
- U();
- }
- private final void U()
- {
- if (this.bL < 0) {
- this.bL = 0;
- } else if (this.bL > this.bH) {
- this.bL = this.bH;
- }
- if (this.bM < 0) {
- this.bM = 0;
- } else if (this.bM > this.bI) {
- this.bM = this.bI;
- }
- }
- private final void V()
- {
- int i1 = this.bL - this.bF;
- int i2 = this.bM - this.bG;
- int i3 = 1;
- int i4 = 1;
- if (i1 < 0)
- {
- i1 = -i1;
- i3 = 0;
- }
- if (i2 < 0)
- {
- i2 = -i2;
- i4 = 0;
- }
- if (i1 != 0)
- {
- if (i1 > this.bP + this.bN)
- {
- if (this.bN < ((this.ba) || (this.dR) || (this.aQ > 0) ? 24 : 6))
- {
- this.bN += 1;
- this.bP += this.bN;
- }
- }
- else if ((i1 < this.bP + this.bN) && (this.bN > 1))
- {
- this.bP -= this.bN;
- this.bN -= 1;
- }
- }
- else {
- this.bN = (this.bP = 0);
- }
- if (i2 != 0)
- {
- if (i2 > this.bQ + this.bO)
- {
- if (this.bO < ((this.ba) || (this.dR) || (this.aQ > 0) ? 24 : 6))
- {
- this.bO += 1;
- this.bQ += this.bO;
- }
- }
- else if ((i2 < this.bQ + this.bO) && (this.bO > 1))
- {
- this.bQ -= this.bO;
- this.bO -= 1;
- }
- }
- else {
- this.bO = (this.bQ = 0);
- }
- if (i1 - this.bN < 0) {
- this.bN = i1;
- }
- if (i2 - this.bO < 0) {
- this.bO = i2;
- }
- this.bF += (i3 != 0 ? this.bN : -this.bN);
- this.bG += (i4 != 0 ? this.bO : -this.bO);
- g(this.bF, this.bG);
- if ((this.ba) && (this.bL == this.bF) && (this.bM == this.bG)) {
- this.ba = false;
- }
- }
- private final void W()
- {
- for (int i1 = 0; i1 < this.co.length; i1++) {
- this.co[i1] = a(this.co[i1], "/b" + i1 + ".png");
- }
- this.cp = a(this.cp, "/ta.png");
- this.ci = a(this.ci, "/hud.png");
- this.cm = a(this.cm, "/bf.png");
- this.cn = a(this.cn, "/alarm.png");
- }
- private final void c(boolean paramBoolean)
- {
- for (int i1 = 0; i1 < (paramBoolean ? 9 : 10); i1++) {
- this.co[i1] = null;
- }
- if (!paramBoolean) {
- this.cp = null;
- }
- this.cm = null;
- this.cn = null;
- }
- private final void X()
- {
- W();
- Y();
- }
- private final void Y()
- {
- this.X = false;
- b(true, -1);
- this.cG = (this.cI = this.cK = this.cM = -1);
- this.cW = (this.cX = this.cY = this.cZ = 0);
- this.cO = -1;
- this.dl = -1;
- this.jdField_do = -1;
- this.cS = false;
- if (this.bS == 0) {
- this.F = (this.E = 0);
- }
- e(this.bS, this.bR);
- ab();
- if (this.cS) {
- for (i1 = 0; i1 < 5; i1++)
- {
- this.cd[i1] = (b(this.u) << this.r);
- this.ce[i1] = (b(this.v) << this.r);
- }
- }
- this.bv = (b(2) == 0 ? -24 : this.aq + 1);
- this.bw = b(this.ar + 1 - 24);
- this.bt = (this.bv << this.r);
- this.bu = (this.bw << this.r);
- this.bn = -1;
- this.bU = 0;
- this.da = (this.dc = 0);
- this.db = false;
- this.cz = 0;
- this.bY = true;
- this.bW = 0L;
- this.bz = 0;
- this.bA = 0;
- this.bB = 0;
- this.bC = 0;
- this.dQ = false;
- this.av = 0;
- this.at = 6;
- this.bb = false;
- this.bc = false;
- this.as = 9;
- this.bd = false;
- this.cT = (this.cU = this.cV = this.be = 0);
- this.aK = 0;
- this.aL = 0;
- this.aw = -1;
- this.bf = false;
- this.bg = false;
- this.bj = false;
- this.aY = 0;
- this.bk = (this.bl = 0);
- this.aU = 0;
- this.bh = false;
- this.aZ = 0;
- this.bi = false;
- this.ax = 0;
- this.az = 0;
- this.aT = 0;
- this.aX = -1;
- this.aQ = 0;
- this.aX = -1;
- this.aW = -1;
- this.aB = -1;
- this.aC = -1;
- this.aO = -1;
- this.aE = -1;
- this.aR = -1;
- this.aG = (this.aI = -1);
- for (int i1 = 0; i1 < 5; i1++) {
- this.ab[i1] = ((byte)(-b(8) - 1));
- }
- this.aq = (this.ds * this.h - 1);
- this.ar = (this.dt * this.i - 1);
- this.bH = (this.aq - this.du);
- this.bI = (this.ar - this.dv);
- if (this.bH < 0) {
- this.bH = 0;
- }
- if (this.bI < 0) {
- this.bI = 0;
- }
- this.dR = false;
- this.ba = false;
- this.bJ = 0;
- this.bK = 0;
- d(this.am, this.an);
- this.bF = this.bL;
- this.bG = this.bM;
- ad();
- f(this.bF, this.bG);
- String str;
- if (this.bS != 0)
- {
- if ((this.bR == 11) || (this.bR == 12)) {
- str = this.a[42];
- } else {
- str = this.a[39] + this.bS + '-' + this.bR;
- }
- }
- else {
- switch (this.bR)
- {
- case 1:
- str = this.a[22];
- break;
- case 2:
- str = this.a[40];
- break;
- case 3:
- str = this.a[41];
- break;
- case 4:
- str = this.a[42];
- break;
- default:
- str = this.a[43];
- }
- }
- a((byte)75, str, (byte)1);
- b(F());
- }
- private final void a(byte paramByte1, String paramString, byte paramByte2)
- {
- this.ec = paramByte1;
- this.ee = paramString;
- this.ed = paramByte2;
- }
- private final Image a(Image paramImage, String paramString)
- {
- if (paramImage != null) {
- return paramImage;
- }
- try
- {
- return Image.createImage(paramString);
- }
- catch (Throwable localThrowable)
- {
- c();
- }
- return null;
- }
- private final void Z()
- {
- this.cq = ((byte[][])null);
- this.cr = ((byte[][])null);
- this.cA = null;
- this.cB = null;
- this.cC = null;
- this.cE = null;
- this.cF = null;
- this.cD = null;
- this.dd = null;
- this.de = null;
- this.df = null;
- this.dg = null;
- }
- private final void aa()
- {
- int i2 = 0;
- for (int i1 = 1; i1 <= 4; i1++)
- {
- d(i1);
- this.cv[i2] = this.cs;
- this.cw[i2] = this.cu;
- i2++;
- }
- }
- private final void d(int paramInt)
- {
- int i1 = 1;
- if (this.y.compareTo("DE") == 0) {
- i1 = 0;
- } else if (this.y.compareTo("EN") == 0) {
- i1 = 1;
- } else if (this.y.compareTo("FR") == 0) {
- i1 = 2;
- } else if (this.y.compareTo("IT") == 0) {
- i1 = 3;
- } else if (this.y.compareTo("SP") == 0) {
- i1 = 4;
- } else if (this.y.compareTo("PG") == 0) {
- i1 = 5;
- }
- try
- {
- InputStream localInputStream = getClass().getResourceAsStream((paramInt < 10 ? "0" : "") + paramInt + ".dat");
- DataInputStream localDataInputStream = new DataInputStream(localInputStream);
- localDataInputStream.readShort();
- this.cu = localDataInputStream.readByte();
- for (int i2 = 0; i2 <= i1; i2++)
- {
- this.cs = localDataInputStream.readUTF();
- this.ct = localDataInputStream.readUTF();
- }
- localDataInputStream.close();
- localDataInputStream = null;
- }
- catch (Exception localException)
- {
- c();
- }
- }
- private final void e(int paramInt1, int paramInt2)
- {
- Z();
- this.bV = 0;
- try
- {
- InputStream localInputStream = getClass().getResourceAsStream((paramInt1 < 10 ? "0" : "") + paramInt1 + ".dat");
- DataInputStream localDataInputStream = new DataInputStream(localInputStream);
- for (int i1 = 0; i1 < paramInt2; i1++)
- {
- i4 = localDataInputStream.readShort();
- for (;;)
- {
- int i8 = localDataInputStream.skipBytes(i4);
- if (i8 >= i4) {
- break;
- }
- i4 -= i8;
- }
- }
- localDataInputStream.readShort();
- this.ds = localDataInputStream.readByte();
- this.dt = localDataInputStream.readByte();
- this.cq = new byte[this.dt][this.ds];
- for (i1 = 0; i1 < this.dt; i1++) {
- localDataInputStream.readFully(this.cq[i1]);
- }
- this.cr = new byte[this.dt][this.ds];
- int i2;
- for (int i3 = 0; i3 < this.dt; i3++) {
- for (i2 = 0; i2 < this.ds; i2++) {
- this.cr[i3][i2] = -1;
- }
- }
- this.cx = localDataInputStream.readByte();
- this.cA = new byte[this.cx];
- this.cB = new byte[this.cx];
- this.cC = new byte[this.cx];
- this.cE = new short[this.cx];
- this.cF = new short[this.cx];
- this.cD = new boolean[this.cx];
- int i4 = localDataInputStream.readShort();
- int i5 = 0;
- for (i1 = 0; i1 < i4; i1++)
- {
- int i6 = localDataInputStream.readByte();
- i2 = localDataInputStream.readByte();
- i3 = localDataInputStream.readByte();
- int i7 = 0;
- switch (i6)
- {
- case -32:
- case -31:
- case -30:
- case -20:
- this.cE[i5] = ((short)(i2 * this.h));
- this.cF[i5] = ((short)(i3 * this.i));
- this.cB[i5] = 4;
- this.cC[i5] = 0;
- this.cA[i5] = i6;
- i5++;
- i7 = 1;
- break;
- case -41:
- this.cr[i3][(i2 + 1)] = -40;
- this.cr[i3][(i2 + 2)] = -39;
- break;
- case -38:
- this.cr[(i3 + 1)][i2] = -22;
- break;
- case -37:
- this.cr[(i3 + 1)][i2] = -21;
- break;
- case -25:
- this.cr[(i3 + 1)][i2] = -9;
- break;
- case -8:
- this.bV += 1;
- }
- if (i7 == 0) {
- this.cr[i3][i2] = i6;
- }
- }
- localDataInputStream.close();
- localDataInputStream = null;
- }
- catch (Exception localException)
- {
- c();
- }
- }
- private final void ab()
- {
- byte[] arrayOfByte = { 0, 0, 0, 0, 0, 0, 0 };
- if ((this.bS == 0) && (this.bR == 1))
- {
- arrayOfByte[6] = ((byte)(1 - this.D[6]));
- arrayOfByte[4] = ((byte)(2 - this.D[4]));
- arrayOfByte[5] = ((byte)(1 - this.D[5]));
- arrayOfByte[2] = ((byte)(1 - this.D[2]));
- arrayOfByte[3] = ((byte)(1 - this.D[3]));
- arrayOfByte[0] = ((byte)(1 - this.D[0]));
- arrayOfByte[1] = ((byte)(1 - this.D[1]));
- }
- this.cy = 0;
- int i4 = 0;
- this.cR = ((this.bS != 0) && ((this.bR == 11) || (this.bR == 12)));
- for (int i2 = 0; i2 < this.dt; i2++) {
- for (int i1 = 0; i1 < this.ds; i1++)
- {
- int i5 = this.cq[i2][i1];
- int i6 = this.cr[i2][i1];
- if (i5 == -107)
- {
- this.ao = i1;
- this.ap = i2;
- this.am = (i1 * this.h);
- this.an = (i2 * this.i);
- }
- else if (i5 == -56)
- {
- this.cy += 1;
- }
- else if (i5 == 77)
- {
- this.cS = true;
- }
- else if ((this.bS == 0) && (this.bR == 1) && ((i5 & 0xFF) >= 151) && ((i5 & 0xFF) <= 157))
- {
- int i3 = (i5 & 0xFF) - 151;
- if (arrayOfByte[i3] > 0)
- {
- int tmp360_359 = i3;
- byte[] tmp360_357 = arrayOfByte;
- tmp360_357[tmp360_359] = ((byte)(tmp360_357[tmp360_359] - 1));
- }
- else
- {
- this.cq[i2][i1] = -98;
- }
- }
- if (i6 == -54)
- {
- this.cQ = true;
- this.cy += 1;
- }
- else if (i6 == -53)
- {
- this.cQ = false;
- this.cy += 1;
- }
- else if (i6 == -33)
- {
- i4++;
- }
- else if (i6 == -48)
- {
- this.cG = ((short)i1);
- this.cH = ((short)i2);
- }
- else if (i6 == -47)
- {
- this.cI = ((short)i1);
- this.cJ = ((short)i2);
- }
- else if (i6 == -46)
- {
- this.cK = ((short)i1);
- this.cL = ((short)i2);
- }
- else if (i6 == -45)
- {
- this.cM = ((short)i1);
- this.cN = ((short)i2);
- }
- else if (i6 == -41)
- {
- this.cO = ((short)i1);
- this.cP = ((short)i2);
- }
- }
- }
- this.dk = 0;
- this.dd = new byte[i4];
- this.de = new byte[i4];
- this.df = new byte[i4];
- this.dg = new byte[i4];
- this.dn = 0;
- }
- private final void b(int paramInt1, int paramInt2, boolean paramBoolean)
- {
- this.du = paramInt1;
- this.dv = paramInt2;
- this.dC = paramBoolean;
- this.dw = ((paramInt1 + this.h - 1) / this.h);
- this.dx = ((paramInt2 + this.i - 1) / this.i);
- int i1;
- if (!this.dC) {
- i1 = 3;
- } else {
- i1 = 1;
- }
- this.dA = (this.dw + i1);
- this.dB = (this.dx + i1);
- this.dy = (this.dA * this.h);
- this.dz = (this.dB * this.i);
- }
- private final void ac()
- {
- this.dG = null;
- this.dF = null;
- this.dF = Image.createImage(this.dy, this.dz);
- this.dG = this.dF.getGraphics();
- this.dD = (this.dE = (byte[][])null);
- this.dD = new byte[this.dB][this.dA];
- this.dE = new byte[this.dB][this.dA];
- for (int i1 = 0; i1 < this.dB; i1++) {
- for (int i2 = 0; i2 < this.dA; i2++)
- {
- this.dD[i1][i2] = -1;
- this.dE[i1][i2] = 0;
- }
- }
- }
- private final void ad()
- {
- this.dG.setColor(0);
- this.dG.setClip(0, 0, this.dy, this.dz);
- this.dG.fillRect(0, 0, this.dy, this.dz);
- for (int i1 = 0; i1 < this.dB; i1++) {
- for (int i2 = 0; i2 < this.dA; i2++)
- {
- this.dD[i1][i2] = -1;
- this.dE[i1][i2] = 0;
- }
- }
- }
- private final void f(int paramInt1, int paramInt2)
- {
- int i1;
- if (!this.dC) {
- i1 = 1;
- } else {
- i1 = 0;
- }
- int i2 = paramInt1 / this.h - i1;
- int i3 = paramInt2 / this.i - i1;
- int i4 = i2 + this.dw + i1;
- int i5 = i3 + this.dx + i1;
- if (i2 < 0) {
- i2 = 0;
- }
- if (i4 >= this.ds) {
- i4 = this.ds - 1;
- }
- if (i3 < 0) {
- i3 = 0;
- }
- if (i5 >= this.dt) {
- i5 = this.dt - 1;
- }
- int i10 = i2 % this.dA;
- int i9 = i3 % this.dB;
- for (int i7 = i3; i7 <= i5; i7++)
- {
- int i8 = i10;
- for (int i6 = i2; i6 <= i4; i6++)
- {
- c(i6, i7, i8, i9);
- i8++;
- if (i8 >= this.dA) {
- i8 = 0;
- }
- }
- i9++;
- if (i9 >= this.dB) {
- i9 = 0;
- }
- }
- }
- private final void g(int paramInt1, int paramInt2)
- {
- int i1;
- if (!this.dC) {
- i1 = 1;
- } else {
- i1 = 0;
- }
- int i2 = paramInt1 / this.h - i1;
- int i3 = paramInt2 / this.i - i1;
- int i4 = i2 + this.dw + i1;
- int i5 = i3 + this.dx + i1;
- int i7 = i2 >= 0 ? i2 : 0;
- int i8 = i4 < this.ds ? i4 : this.ds - 1;
- int i11 = i3 % this.dB;
- int i12 = i5 % this.dB;
- int i9 = i7 % this.dA;
- for (int i6 = i7; i6 <= i8; i6++)
- {
- if (i3 >= 0) {
- c(i6, i3, i9, i11);
- }
- if (i5 < this.dt) {
- c(i6, i5, i9, i12);
- }
- i9++;
- if (i9 >= this.dA) {
- i9 = 0;
- }
- }
- i7 = i3 >= 0 ? i3 : 0;
- i8 = i5 < this.dt ? i5 : this.dt - 1;
- i11 = i2 % this.dA;
- i12 = i4 % this.dA;
- int i10 = i7 % this.dB;
- for (i6 = i7; i6 <= i8; i6++)
- {
- if (i2 >= 0) {
- c(i2, i6, i11, i10);
- }
- if (i4 < this.ds) {
- c(i4, i6, i12, i10);
- }
- i10++;
- if (i10 >= this.dB) {
- i10 = 0;
- }
- }
- }
- private final void c(int paramInt1, int paramInt2, int paramInt3, int paramInt4)
- {
- byte b1 = this.cq[paramInt2][paramInt1];
- byte b2 = this.cr[paramInt2][paramInt1];
- if ((this.dD[paramInt4][paramInt3] == b1) && (this.dE[paramInt4][paramInt3] == b2)) {
- return;
- }
- this.dD[paramInt4][paramInt3] = b1;
- this.dE[paramInt4][paramInt3] = b2;
- a(b1, b2, paramInt3 * this.h, paramInt4 * this.i);
- }
- private final void d(Graphics paramGraphics, int paramInt1, int paramInt2)
- {
- if (this.dF != null)
- {
- int i3 = 0;
- int i4 = 0;
- int i1 = paramInt1 % this.dy;
- int i2 = paramInt2 % this.dz;
- if (i1 + this.du > this.dy) {
- i3 = 1;
- }
- if (i2 + this.dv > this.dz) {
- i4 = 1;
- }
- paramGraphics.drawImage(this.dF, -i1, -i2, 20);
- if (i3 != 0) {
- paramGraphics.drawImage(this.dF, this.dy - i1, -i2, 20);
- }
- if (i4 != 0) {
- paramGraphics.drawImage(this.dF, -i1, this.dz - i2, 20);
- }
- if ((i3 != 0) && (i4 != 0)) {
- paramGraphics.drawImage(this.dF, this.dy - i1, this.dz - i2, 20);
- }
- }
- }
- private final void d(boolean paramBoolean)
- {
- this.dT = paramBoolean;
- }
- private final void ae()
- {
- i();
- c(true);
- this.co[9] = a(this.co[9], "/b9.png");
- this.cp = a(this.cp, "/ta.png");
- this.dH = a(this.dH, "/title.png");
- this.bf = false;
- this.bg = false;
- this.aT = 0;
- this.aK = 0;
- this.bj = true;
- this.as = 0;
- this.av = 1;
- this.az = 0;
- this.at = 1;
- this.au = 0;
- this.aC = 0;
- this.aD = 0;
- this.aF = ((this.w - this.dH.getHeight() - this.i - 72 >> 1) + this.dH.getHeight() + this.i + (this.i >> 1));
- this.am = -120;
- this.an = this.w;
- this.ao = (this.am << this.r);
- this.ap = (this.an << this.r);
- m();
- b(true, -1);
- this.x = 4;
- b("/title.mid");
- this.dJ = 0;
- this.dK = true;
- d(false);
- this.U = false;
- }
- private final boolean af()
- {
- if ((this.cb == 0) && (this.U))
- {
- this.R = (this.S = this.T = 0);
- c((byte)0, (byte)-1);
- return true;
- }
- this.dJ += 1;
- if (this.dJ >= 20)
- {
- this.dJ = 0;
- this.dK = (!this.dK);
- }
- this.ao += this.aC;
- this.am = (this.ao >> this.r);
- this.ap += this.aD;
- this.an = (this.ap >> this.r);
- if (this.an <= this.aF) {
- this.aD = 0;
- }
- switch (this.au)
- {
- case 0:
- this.az += 1;
- if (this.az >= 64)
- {
- this.aC = (3 << this.r + 1);
- this.aD = (-(1 << this.r));
- this.au += 1;
- }
- break;
- case 1:
- if (this.am > this.u - this.h >> 1) {
- this.au += 1;
- }
- break;
- case 2:
- if (this.aC > 0) {
- this.aC -= 4;
- } else {
- this.au += 1;
- }
- break;
- case 3:
- if (this.aC > -(2 << this.r)) {
- this.aC -= 4;
- }
- if (this.am <= (this.u - this.h >> 1) + this.j) {
- this.au += 1;
- }
- break;
- case 4:
- if (this.aC < 0)
- {
- this.aC += 4;
- }
- else
- {
- this.aC = 0;
- this.au += 1;
- }
- break;
- }
- L();
- n();
- return true;
- }
- private final int e(int paramInt)
- {
- switch (this.dM)
- {
- case 0:
- return 0;
- case 1:
- return this.dO[this.dL] * paramInt >> 8;
- }
- return this.dO[(18 - this.dL)] * paramInt >> 8;
- }
- private final void a(boolean paramBoolean, int paramInt)
- {
- this.dM = ((byte)(paramBoolean ? 1 : 2));
- this.dN = ((byte)paramInt);
- this.dL = 18;
- }
- private final void c(byte paramByte1, byte paramByte2)
- {
- int i2 = 0;
- int i4 = -1;
- this.dW = paramByte1;
- this.eb = paramByte2;
- if (!this.dS)
- {
- if (!this.dQ) {
- k();
- }
- d(false);
- this.dS = true;
- }
- this.dU = new String[20];
- this.dV = new short[20];
- this.ea = 0;
- this.dX = 0;
- int i5;
- int i6;
- int i3;
- switch (paramByte1)
- {
- case 0:
- for (i1 = 0; i1 < 4; i1++) {
- if (this.A[i1] > 0)
- {
- this.dU[i2] = this.a[1];
- this.dV[(i2++)] = 1;
- break;
- }
- }
- this.dU[i2] = this.a[0];
- this.dV[(i2++)] = 0;
- this.dU[i2] = this.a[22];
- this.dV[(i2++)] = 20;
- this.dU[i2] = this.a[23];
- this.dV[(i2++)] = 14;
- if (this.M[0].length() > 0)
- {
- this.dU[i2] = this.a[24];
- this.dV[(i2++)] = 15;
- }
- this.dU[i2] = this.a[18];
- this.dV[(i2++)] = 10;
- this.dU[i2] = (this.a[4] + this.a[3]);
- this.dV[(i2++)] = 11;
- this.dU[i2] = (this.a[5] + this.bq);
- this.dV[(i2++)] = 13;
- if (this.D[3] > 0)
- {
- this.dU[i2] = this.a[6];
- this.dV[(i2++)] = 16;
- }
- this.dU[i2] = this.a[17];
- this.dV[(i2++)] = 12;
- this.dU[i2] = this.a[19];
- this.dV[(i2++)] = 3;
- this.dU[i2] = this.a[21];
- this.dV[(i2++)] = 4;
- break;
- case 1:
- if (this.bS != 0)
- {
- if (this.C)
- {
- this.dU[i2] = "CHEAT!";
- this.dV[(i2++)] = 99;
- }
- if (this.D[5] > 0)
- {
- this.dU[i2] = (this.a[87] + this.a[3]);
- this.dV[(i2++)] = 30;
- }
- if (this.D[6] > 0)
- {
- this.dU[i2] = (this.a[88] + this.a[3]);
- this.dV[(i2++)] = 31;
- }
- if (!this.dc)
- {
- this.dU[i2] = this.a[27];
- this.dV[(i2++)] = 6;
- }
- this.dU[i2] = this.a[18];
- this.dV[(i2++)] = 10;
- }
- this.dU[i2] = (this.a[4] + this.a[3]);
- this.dV[(i2++)] = 11;
- if ((this.bS != 0) && (this.D[4] > 0))
- {
- this.dU[i2] = (this.a[89] + (this.H != -1 ? Integer.toString(this.H + 1) : this.a[90]));
- this.dV[(i2++)] = 32;
- i4 = this.a[89].length() + this.a[90].length();
- }
- this.dU[i2] = this.a[20];
- this.dV[(i2++)] = 8;
- break;
- case 2:
- i5 = 0;
- for (i6 = 0; (i3 = "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".indexOf(';', i6)) != -1; i6 = i3 + 1) {
- i5++;
- }
- i6 = 0;
- i1 = 0;
- case 3:
- case 4:
- case 5:
- while (i1 < i5)
- {
- i3 = "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".indexOf('=', i6);
- this.dU[i2] = "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".substring(i6, i3);
- i6 = i3 + 1;
- this.dV[(i2++)] = ((short)i6);
- i3 = "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".indexOf(';', i6);
- if (this.y.compareTo("DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".substring(i6, i3)) == 0) {
- this.dX = ((byte)i1);
- }
- i6 = i3 + 1;
- i1++;
- continue;
- i3 = 0;
- i1 = 1;
- while (i1 <= 4)
- {
- if ((paramByte2 == 0) || ((paramByte2 == 1) && (this.A[i3] > 0)))
- {
- this.dU[i2] = this.cv[i3];
- this.dV[(i2++)] = ((short)i1);
- }
- i3++;
- i1++;
- continue;
- if (this.D[0] > 0)
- {
- this.dU[i2] = this.a[25];
- this.dV[(i2++)] = 1;
- }
- if (this.D[1] > 0)
- {
- this.dU[i2] = this.a[26];
- this.dV[(i2++)] = 2;
- break;
- this.dU[i2] = this.a[7];
- this.dV[(i2++)] = 0;
- this.dU[i2] = this.a[8];
- this.dV[(i2++)] = 1;
- this.dU[i2] = this.a[9];
- this.dV[(i2++)] = 2;
- this.dU[i2] = this.a[12];
- this.dV[(i2++)] = 3;
- this.dU[i2] = this.a[13];
- this.dV[(i2++)] = 4;
- this.dU[i2] = this.a[14];
- this.dV[(i2++)] = 5;
- this.dU[i2] = this.a[15];
- this.dV[(i2++)] = 6;
- this.dU[i2] = this.a[16];
- this.dV[(i2++)] = 7;
- this.dU[i2] = this.a[10];
- this.dV[(i2++)] = 8;
- this.dU[i2] = this.a[11];
- this.dV[(i2++)] = 9;
- }
- }
- }
- }
- this.dY = ((byte)i2);
- this.ef = (this.w - Math.min(this.dZ, i2) * 31 >> 1);
- if (this.dX >= i2) {
- this.dX = ((byte)(i2 - 1));
- }
- if (this.ea > this.dX) {
- this.ea = this.dX;
- }
- if (this.dX >= this.ea + this.dZ) {
- this.ea = ((byte)(this.dX - this.dZ + 1));
- }
- this.eg = (i4 == -1 ? 0 : i4);
- for (int i1 = 0; i1 < i2; i1++)
- {
- i5 = this.dU[i1].length();
- if (i5 > this.eg) {
- this.eg = i5;
- }
- }
- this.eg = ((this.eg + 1) * 12 + 10);
- if (this.dW == 2)
- {
- this.eh = ((this.u - this.eg >> 1) - 27);
- this.eg += 78;
- }
- else if (this.dW == 3)
- {
- this.eh = ((this.u - this.eg >> 1) - 31);
- this.ei = (this.u - this.eh - 31);
- this.eg += 86;
- }
- this.eg = Math.max((this.u << 1) / 3, this.eg);
- a(true, -1);
- }
- private final boolean ag()
- {
- boolean bool = false;
- if (this.dM == 0)
- {
- if (this.N)
- {
- this.N = false;
- if (this.dX > 0) {
- this.dX = ((byte)(this.dX - 1));
- } else {
- this.dX = ((byte)(this.dY - 1));
- }
- if (this.dX < this.ea) {
- this.ea = this.dX;
- } else if (this.dX >= this.ea + this.dZ) {
- this.ea = ((byte)(this.dX - this.dZ + 1));
- }
- bool = true;
- }
- else if (this.O)
- {
- this.Q = (this.O = 0);
- if (this.dX < this.dY - 1) {
- this.dX = ((byte)(this.dX + 1));
- } else {
- this.dX = 0;
- }
- if (this.dX < this.ea) {
- this.ea = this.dX;
- } else if (this.dX >= this.ea + this.dZ) {
- this.ea = ((byte)(this.dX - this.dZ + 1));
- }
- bool = true;
- }
- else if ((this.Q) || (this.P))
- {
- bool = e(this.P);
- this.Q = (this.P = 0);
- }
- else if ((this.S) || (this.R))
- {
- this.S = (this.R = this.U = 0);
- int i1 = this.dV[this.dX];
- if ((this.dW == 5) || ((this.dW != 2) && ((i1 == 11) || (i1 == 13) || (i1 == 30) || (i1 == 31) || (i1 == 32) || (i1 == 101))))
- {
- bool = ah();
- }
- else
- {
- if (((this.dW == 0) && (i1 != 0) && (i1 != 1) && (i1 != 16) && (i1 != 12)) || ((this.dW == 1) && (i1 != 99) && (i1 != 100)) || (this.dW == 3)) {
- b(false, -1);
- }
- a(false, 0);
- }
- }
- else if (this.T)
- {
- this.T = (this.U = 0);
- if (this.x != 11) {
- a(false, 1);
- }
- }
- }
- else
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dL = 0;
- if (this.cb <= 0) {
- if (this.dM == 2)
- {
- this.dM = 0;
- switch (this.dN)
- {
- case 0:
- ah();
- break;
- case 1:
- ai();
- }
- }
- else
- {
- this.dM = 0;
- }
- }
- }
- bool = true;
- }
- return bool;
- }
- private final boolean e(boolean paramBoolean)
- {
- boolean bool = false;
- if ((this.dW == 0) && (this.dV[this.dX] == 13))
- {
- if ((paramBoolean) && (this.bq > 1))
- {
- bool = true;
- this.bq = ((byte)(this.bq - 1));
- }
- else if ((!paramBoolean) && (this.bq < 5))
- {
- bool = true;
- this.bq = ((byte)(this.bq + 1));
- }
- if (bool)
- {
- if (this.c == 1)
- {
- a();
- b("/title.mid");
- }
- g();
- this.dU[this.dX] = (this.a[5] + this.bq);
- }
- }
- return bool;
- }
- private final boolean ah()
- {
- boolean bool = false;
- int i1 = 0;
- int i2 = this.dV[this.dX];
- String str1;
- switch (this.dW)
- {
- case 0:
- case 1:
- switch (i2)
- {
- case 0:
- case 1:
- c((byte)3, (byte)i2);
- bool = true;
- break;
- case 3:
- a(this.a[52], 0, (byte)-1);
- this.dS = false;
- bool = true;
- break;
- case 4:
- d((byte)1);
- return true;
- case 6:
- i();
- Y();
- this.x = 1;
- d(true);
- i1 = 1;
- break;
- case 8:
- if ((this.bS != 0) || (this.bR == 4))
- {
- d((byte)0);
- }
- else
- {
- aj();
- if ((this.bR == 1) || (this.bR == 5)) {
- ae();
- } else if ((this.bR == 2) || (this.bR == 3)) {
- x();
- }
- }
- return true;
- case 10:
- ao();
- this.dS = false;
- bool = true;
- break;
- case 11:
- if (this.c == 1) {
- this.c = 0;
- } else {
- this.c = 1;
- }
- if (this.x == 4)
- {
- if (this.c == 0) {
- a();
- } else {
- b("/title.mid");
- }
- }
- else if (this.c == 0) {
- a();
- } else {
- b(F());
- }
- g();
- this.dU[this.dX] = (this.a[4] + this.a[3]);
- bool = true;
- break;
- case 12:
- c((byte)2, (byte)-1);
- bool = true;
- break;
- case 13:
- this.bq = ((byte)(this.bq + 1));
- if (this.bq > 5) {
- this.bq = 1;
- }
- if (this.c == 1)
- {
- a();
- b("/title.mid");
- }
- g();
- this.dU[this.dX] = (this.a[5] + this.bq);
- bool = true;
- break;
- case 14:
- x();
- this.dH = null;
- break;
- case 15:
- str1 = this.a[122];
- for (int i3 = 0; (i3 < this.M.length) && (this.M[i3].length() > 0); i3++)
- {
- str1 = str1 + this.M[i3] + '#';
- if (i3 == 0) {
- str1 = str1 + '#';
- }
- }
- a(str1, 0, (byte)-1);
- this.dS = false;
- bool = true;
- break;
- case 16:
- c((byte)5, (byte)0);
- bool = true;
- break;
- case 20:
- i();
- this.dH = null;
- if (this.c == 1) {
- a();
- }
- this.bS = 0;
- this.bR = 1;
- X();
- this.x = 1;
- i1 = 1;
- break;
- case 30:
- this.F = (!this.F);
- g();
- this.dU[this.dX] = (this.a[87] + this.a[3]);
- bool = true;
- break;
- case 31:
- this.E = (!this.E);
- g();
- this.dU[this.dX] = (this.a[88] + this.a[3]);
- bool = true;
- break;
- case 32:
- this.H = ((byte)(this.H + 1));
- if (this.H > this.D[4]) {
- this.H = -1;
- }
- b(F());
- g();
- this.dU[this.dX] = (this.a[89] + (this.H != -1 ? Integer.toString(this.H + 1) : this.a[90]));
- bool = true;
- break;
- case 99:
- aj();
- this.cy = 0;
- d(false);
- k();
- if (this.dR)
- {
- this.dR = false;
- T();
- }
- this.au = this.at;
- this.at = 6;
- this.as = 0;
- this.bb = true;
- am();
- bool = true;
- }
- break;
- case 2:
- str1 = "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".substring(i2, "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".indexOf(';', i2));
- if (str1.compareTo(this.y) != 0)
- {
- this.y = str1;
- a(this.y + ".dat");
- g();
- aa();
- }
- if (this.x != 11)
- {
- c((byte)0, (byte)-1);
- }
- else
- {
- aj();
- d((byte)2);
- }
- bool = true;
- break;
- case 3:
- i();
- this.dH = null;
- if (this.c == 1) {
- a();
- }
- if (this.G)
- {
- this.bS = i2;
- if (this.eb == 0)
- {
- this.bR = 1;
- }
- else
- {
- this.bR = this.A[(i2 - 1)];
- if ((this.bR == 11) && (i(this.bS, 11))) {
- this.bR = 3;
- } else if ((this.bR == 12) && (i(this.bS, 12))) {
- this.bR = 6;
- }
- }
- }
- else
- {
- this.bT = i2;
- this.bS = 0;
- this.bR = 5;
- }
- X();
- this.x = 1;
- i1 = 1;
- break;
- case 5:
- String str2;
- switch (i2)
- {
- case 0:
- case 1:
- case 2:
- str2 = "/ingame" + i2 + ".mid";
- break;
- case 3:
- str2 = "/mow.mid";
- break;
- case 4:
- str2 = "/sandman.mid";
- break;
- case 5:
- str2 = "/shop.mid";
- break;
- case 6:
- str2 = "/universe.mid";
- break;
- case 7:
- str2 = "/fly.mid";
- break;
- case 8:
- str2 = "/bonus.mid";
- break;
- default:
- str2 = "/cleared.mid";
- }
- a(str2, this.bq, false);
- }
- if (i1 != 0)
- {
- aj();
- bool = true;
- }
- return bool;
- }
- private final boolean ai()
- {
- boolean bool = false;
- int i1 = 0;
- switch (this.dW)
- {
- case 0:
- case 1:
- i1 = 1;
- break;
- case 2:
- case 5:
- a();
- b("/title.mid");
- case 3:
- c((byte)0, (byte)-1);
- bool = true;
- }
- if (i1 != 0)
- {
- aj();
- bool = true;
- }
- return bool;
- }
- private final void aj()
- {
- this.dS = false;
- if ((this.x != 4) && (this.x != 11)) {
- d(true);
- }
- this.dU = null;
- this.dV = null;
- if (!this.dQ) {
- l();
- }
- }
- private final void a(Graphics paramGraphics, boolean paramBoolean)
- {
- int i1 = 0;
- int i2 = this.ea;
- int i3 = this.ef;
- i3 -= e(this.v);
- int i4 = 31 - e(31);
- if (this.ea > 0) {
- b(paramGraphics, this.ch, 0, 0, 17, 9, this.u - 17 >> 1, i3 - 9 - 2);
- }
- while ((i1 < this.dZ) && (i2 < this.dY))
- {
- if (paramBoolean) {
- a(paramGraphics, this.u - this.eg >> 1, i3, this.eg, 26, i2 == this.dX ? 41658 : 22935, 10370);
- }
- a(this.dU[i2], paramGraphics, this.u - (this.dU[i2].length() - 1) * 12 - 10 >> 1, i3 + 3 + 2, false);
- int i5;
- if (this.dW == 2)
- {
- i5 = -1;
- String str = "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".substring(this.dV[i2], "DEUTSCH=DE;ENGLISH=EN;FRANÇAIS=FR;ITALIANO=IT;ESPAÑOL=SP;PORTUGUÊS=PG;".indexOf(';', this.dV[i2]));
- if (str.compareTo("DE") == 0) {
- i5 = 0;
- } else if (str.compareTo("EN") == 0) {
- i5 = 1;
- } else if (str.compareTo("FR") == 0) {
- i5 = 2;
- } else if (str.compareTo("IT") == 0) {
- i5 = 3;
- } else if (str.compareTo("SP") == 0) {
- i5 = 4;
- } else if (str.compareTo("PG") == 0) {
- i5 = 5;
- }
- if (i5 != -1) {
- b(paramGraphics, this.cj, 72 + i5 * 27, 0, 27, 18, this.eh, i3 + 3 + 2 + -1);
- }
- }
- else if (this.dW == 3)
- {
- i5 = this.dV[i2];
- int i6 = this.B[(i5 - 1)];
- if (i6 != 0) {
- b(paramGraphics, this.cj, 18, 0, 31, 18, this.eh, i3 + 3 + 2 + -1);
- } else {
- b(paramGraphics, this.cj, 0, 0, 18, 18, this.eh + 6, i3 + 3 + 2 + -1);
- }
- int i10 = this.cw[(i5 - 1)];
- int i7;
- int i8;
- int i9;
- switch (i10)
- {
- case 1:
- i7 = 9;
- i8 = 11;
- i9 = 9;
- break;
- case 2:
- i7 = 9;
- i8 = 23;
- i9 = 9;
- break;
- default:
- i7 = 0;
- i8 = 23;
- i9 = 18;
- }
- b(paramGraphics, this.cj, 49, i7, i8, i8, this.ei + (31 - i8 >> 1), i3 + 3 + 2 + (16 - i9 >> 1));
- }
- i3 += i4;
- i2++;
- i1++;
- }
- if (this.ea + this.dZ < this.dY) {
- b(paramGraphics, this.ch, 0, 9, 17, 9, this.u - 17 >> 1, i3 + 2);
- }
- a(paramGraphics, this.a[30], this.x != 11 ? this.a[29] : null, paramBoolean);
- }
- private final void d(Graphics paramGraphics)
- {
- int i1 = 0;
- int i2 = 0;
- int i4 = 0;
- int i5 = 0;
- int i6 = this.ej.length();
- int i8 = 0;
- int i9 = 0;
- if (paramGraphics != null)
- {
- i1 = this.u - this.ek >> 1;
- i2 = this.w - this.el >> 1;
- a(paramGraphics, i1, i2, this.ek, this.el, 22935, 10370);
- i2 += 6;
- }
- while (i4 < i6)
- {
- int i10 = this.ej.charAt(i4);
- if ((i10 == 35) || (i4 == i6 - 1))
- {
- if (i10 != 35) {
- i4++;
- }
- int i7 = i4 - i5;
- if (i7 > i8) {
- i8 = i7;
- }
- if (paramGraphics != null)
- {
- i1 = this.u - i7 * 12 >> 1;
- for (int i3 = i5; i3 < i4; i3++)
- {
- a(paramGraphics, i1, i2, this.ej.charAt(i3));
- i1 += 12;
- }
- i2 += this.g;
- }
- i5 = i4 + 1;
- i9++;
- }
- i4++;
- }
- if (paramGraphics == null)
- {
- this.ek = (i8 * 12 + 16);
- this.el = (i9 * this.g + 10);
- }
- }
- private final void a(Graphics paramGraphics, int paramInt1, int paramInt2, int paramInt3, int paramInt4, int paramInt5, int paramInt6)
- {
- paramGraphics.setClip(paramInt1, paramInt2, paramInt3, paramInt4);
- paramGraphics.setColor(paramInt6);
- paramGraphics.fillRect(paramInt1, paramInt2 + 1, paramInt3, paramInt4 - 2);
- paramGraphics.fillRect(paramInt1 + 1, paramInt2, paramInt3 - 2, paramInt4);
- paramGraphics.setColor(paramInt5);
- paramGraphics.fillRect(paramInt1 + 3, paramInt2 + 2, paramInt3 - 6, paramInt4 - 4);
- paramGraphics.drawLine(paramInt1 + 2, paramInt2 + 3, paramInt1 + 2, paramInt2 + paramInt4 - 4);
- paramGraphics.drawLine(paramInt1 + paramInt3 - 3, paramInt2 + 3, paramInt1 + paramInt3 - 3, paramInt2 + paramInt4 - 4);
- }
- private final void a(Graphics paramGraphics, String paramString, byte paramByte, int paramInt)
- {
- int i1 = paramString.length() * 12 + 16;
- int i2 = this.g + 10;
- int i3 = this.u - i1 >> 1;
- if (paramByte != 3) {
- if (paramByte == 0) {
- paramInt = this.w - i2 >> 1;
- } else if (paramByte == 1) {
- paramInt = 45;
- } else {
- paramInt = this.w - i2 - 5;
- }
- }
- a(paramGraphics, i3, paramInt, i1, i2, 22935, 10370);
- a(paramString, paramGraphics, this.u >> 1, paramInt + 6, true);
- }
- private final int a(String paramString, Graphics paramGraphics, int paramInt1, int paramInt2, boolean paramBoolean)
- {
- int i2 = paramString.length();
- int i3 = (i2 - 1) * 12 + 10;
- if (paramBoolean) {
- paramInt1 -= (i3 >> 1);
- }
- int i1 = paramInt1;
- for (int i4 = 0; i4 < i2; i4++)
- {
- a(paramGraphics, paramInt1, paramInt2, paramString.charAt(i4));
- paramInt1 += 12;
- }
- return i1;
- }
- private final void a(Graphics paramGraphics, int paramInt1, int paramInt2, int paramInt3, int paramInt4)
- {
- int i1 = 10;
- int i2 = 1;
- paramInt1 += 13 * (paramInt4 - 1);
- for (int i3 = 0; i3 < paramInt4; i3++)
- {
- paramGraphics.setClip(paramInt1, paramInt2, 12, 13);
- paramGraphics.drawImage(this.cg, paramInt1 - paramInt3 % i1 / i2 * 12, paramInt2, 20);
- paramInt1 -= 13;
- i2 = i1;
- i1 *= 10;
- }
- }
- private final void a(Graphics paramGraphics, int paramInt1, int paramInt2, char paramChar)
- {
- int i4 = -1;
- if (paramGraphics != null) {
- paramGraphics.setClip(paramInt1, paramInt2, 10, 16);
- }
- int i1;
- if ((paramChar >= '0') && (paramChar <= '9')) {
- i1 = paramChar - '0';
- } else if ((paramChar >= 'A') && (paramChar <= 'Z')) {
- i1 = '\n' + paramChar - 65;
- } else {
- switch (paramChar)
- {
- case '.':
- i1 = 36;
- break;
- case ',':
- i1 = 37;
- break;
- case '-':
- i1 = 38;
- break;
- case ':':
- i1 = 39;
- break;
- case '!':
- i1 = 40;
- break;
- case '?':
- i1 = 41;
- break;
- case '*':
- i1 = 42;
- break;
- case '\'':
- i1 = 43;
- break;
- case '©':
- i1 = 44;
- break;
- case '@':
- i1 = 45;
- break;
- case 'À':
- i1 = 46;
- i4 = 0;
- break;
- case 'È':
- i1 = 47;
- i4 = 0;
- break;
- case 'Ì':
- i1 = 48;
- i4 = 0;
- break;
- case 'Ò':
- i1 = 49;
- i4 = 0;
- break;
- case 'Ù':
- i1 = 50;
- i4 = 0;
- break;
- case 'Â':
- i1 = 46;
- i4 = 2;
- break;
- case 'Ê':
- i1 = 47;
- i4 = 2;
- break;
- case 'Î':
- i1 = 48;
- i4 = 2;
- break;
- case 'Ô':
- i1 = 49;
- i4 = 2;
- break;
- case 'Û':
- i1 = 50;
- i4 = 2;
- break;
- case 'Á':
- i1 = 46;
- i4 = 4;
- break;
- case 'É':
- i1 = 47;
- i4 = 4;
- break;
- case 'Í':
- i1 = 48;
- i4 = 4;
- break;
- case 'Ó':
- i1 = 49;
- i4 = 4;
- break;
- case 'Ú':
- i1 = 50;
- i4 = 4;
- break;
- case 'Ä':
- i1 = 46;
- i4 = 1;
- break;
- case 'Ë':
- i1 = 47;
- i4 = 1;
- break;
- case 'Ï':
- i1 = 48;
- i4 = 1;
- break;
- case 'Ö':
- i1 = 49;
- i4 = 1;
- break;
- case 'Ü':
- i1 = 50;
- i4 = 1;
- break;
- case 'Ã':
- i1 = 46;
- i4 = 3;
- break;
- case 'Ñ':
- i1 = 51;
- i4 = 3;
- break;
- case 'Õ':
- i1 = 49;
- i4 = 3;
- break;
- case 'Ç':
- i1 = 12;
- i4 = 5;
- break;
- default:
- return;
- }
- }
- if (paramGraphics != null)
- {
- int i3 = i1 / 18;
- int i2 = i1 % 18;
- paramGraphics.drawImage(this.cf, paramInt1 - i2 * 10, paramInt2 - i3 * 16, 20);
- if (i4 != -1)
- {
- paramGraphics.setClip(paramInt1, paramInt2 + (i4 != 5 ? -3 : 16), 10, 3);
- i3 = i4 / 2;
- i2 = i4 % 2;
- paramGraphics.drawImage(this.cf, paramInt1 - (160 + i2 * 10), paramInt2 + (i4 != 5 ? -3 : 16) - (32 + i3 * 3), 20);
- }
- }
- }
- private final void a(String paramString, int paramInt, byte paramByte)
- {
- this.eu = this.dS;
- this.ew = paramString;
- this.ep = 0;
- this.en = paramInt;
- this.eo = 0;
- this.er = this.u;
- this.ev = paramByte;
- a(null, 0, 0, true, true, true, true);
- this.em = this.x;
- this.x = 5;
- a(true, -1);
- }
- private final boolean ak()
- {
- boolean bool = false;
- if (this.dM == 0)
- {
- if (this.N)
- {
- this.N = false;
- if (this.ep > 0)
- {
- this.ep -= 2;
- if (this.ep < 0) {
- this.ep = 0;
- }
- bool = true;
- }
- }
- else if (this.O)
- {
- this.O = false;
- if (this.ep < this.eq)
- {
- this.ep += 2;
- if (this.ep > this.eq) {
- this.ep = this.eq;
- }
- bool = true;
- }
- }
- else if ((this.S) || (this.T) || (this.R))
- {
- this.S = (this.T = this.R = 0);
- a(false, 0);
- }
- }
- else
- {
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dL = 0;
- if (this.dM == 2)
- {
- this.dM = 0;
- switch (this.dN)
- {
- case 0:
- al();
- }
- }
- else
- {
- this.dM = 0;
- }
- }
- bool = true;
- }
- return bool;
- }
- private final void al()
- {
- if (this.ev == -1)
- {
- this.x = this.em;
- this.dS = this.eu;
- b(true, -1);
- a(true, -1);
- }
- else if (this.ev == 0)
- {
- ae();
- }
- }
- private final void a(Graphics paramGraphics, int paramInt1, int paramInt2, boolean paramBoolean1, boolean paramBoolean2, boolean paramBoolean3, boolean paramBoolean4)
- {
- int i3 = 0;
- int i5 = 0;
- int i4 = this.w - this.en - this.eo;
- if ((paramGraphics != null) && (paramBoolean1))
- {
- if (paramBoolean2)
- {
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.setColor(0);
- paramGraphics.fillRect(0, 0, this.u, this.v);
- }
- int i13 = this.er - e(this.er);
- int i14 = i4 - e(i4);
- a(paramGraphics, this.u - i13 >> 1, this.en + (i4 - i14 >> 1), i13, i14, paramInt1, paramInt2);
- }
- int i7 = (this.er - 7) / 12;
- this.et = ((i4 - 19) / this.g);
- int i8 = this.ep + this.et;
- int i11 = this.ew.length();
- int i9 = 0;
- this.es = 0;
- int i10 = 0;
- int i12 = -1;
- i5 = e(this.u);
- if (paramGraphics != null)
- {
- i3 = 5 + this.en + (i4 - (paramBoolean1 ? 19 : 7) - this.et * this.g >> 1);
- if ((this.eq < 0) && (paramBoolean4)) {
- i3 -= (this.eq * this.g >> 1);
- }
- }
- while (i10 < i11)
- {
- int i6 = this.ew.charAt(i10);
- i9++;
- if ((i6 == 32) || (i6 == 46) || (i6 == 44) || (i6 == 45) || (i6 == 58) || (i6 == 58) || (i6 == 35)) {
- i12 = i10;
- }
- if ((i9 >= i7) || (i6 == 35) || (i10 >= i11 - 1))
- {
- if ((i12 == -1) || (i10 >= i11 - 1)) {
- i12 = i10;
- }
- if ((paramGraphics != null) && (this.es >= this.ep))
- {
- if ((this.dM == 0) || (!paramBoolean1))
- {
- i6 = this.ew.charAt(i12);
- int i2;
- if ((i6 != 32) && (i6 != 35)) {
- i2 = this.u - (i12 - (i10 - i9 + 1) + 1) * 12 >> 1;
- } else {
- i2 = this.u - (i12 - (i10 - i9 + 1)) * 12 >> 1;
- }
- for (int i1 = i10 - i9 + 1; i1 <= i12; i1++)
- {
- a(paramGraphics, i2 - i5, i3, this.ew.charAt(i1));
- i2 += 12;
- }
- }
- i3 += this.g;
- }
- i9 = i10 - i12;
- if ((i12 + 1 < i11) && (this.ew.charAt(i12 + 1) == ' ')) {
- i10++;
- }
- i12 = -1;
- this.es += 1;
- if ((paramGraphics != null) && (this.es >= i8)) {
- break;
- }
- }
- i10++;
- }
- if (paramGraphics != null)
- {
- if ((paramBoolean3) && (this.dM == 0))
- {
- if (this.ep > 0) {
- b(paramGraphics, this.ch, 0, 0, 17, 9, (this.u >> 1) - 17 + 1, this.en + i4 - 9 - 4);
- }
- if (this.ep < this.eq) {
- b(paramGraphics, this.ch, 0, 9, 17, 9, (this.u >> 1) - 1, this.en + i4 - 9 - 4);
- }
- }
- }
- else
- {
- if (i9 > 0) {
- this.es += 1;
- }
- this.eq = (this.es - this.et);
- }
- }
- private final void b(boolean paramBoolean, int paramInt)
- {
- this.bZ = 0;
- this.cb = ((byte)(paramBoolean ? 1 : 2));
- this.ca = paramInt;
- }
- private final void am()
- {
- this.I = ((short)(this.I + this.bU));
- this.ec = 0;
- d(false);
- if (this.c == 1) {
- a("/cleared.mid", this.bq, false);
- }
- b(false, -1);
- if ((this.bR != 11) && (this.bR != 12))
- {
- int i5 = 2 + this.a[48].length();
- int i1 = (int)this.bW / 1000;
- int i2 = i1 / 60;
- int i3 = i1 - i2 * 60;
- StringBuffer localStringBuffer = new StringBuffer(100);
- localStringBuffer.append(this.a[44]);
- localStringBuffer.append("##");
- localStringBuffer.append(this.a[45]);
- int i4 = localStringBuffer.length();
- if (i2 <= 9) {
- localStringBuffer.append('0');
- }
- localStringBuffer.append(i2);
- localStringBuffer.append(':');
- if (i3 <= 9) {
- localStringBuffer.append('0');
- }
- localStringBuffer.append(i3);
- a(localStringBuffer, "", i5 - (localStringBuffer.length() - i4), ' ', false);
- localStringBuffer.append("#");
- localStringBuffer.append(this.a[46]);
- i4 = localStringBuffer.length();
- localStringBuffer.append(this.bU);
- localStringBuffer.append(this.a[48]);
- localStringBuffer.append(this.bV);
- a(localStringBuffer, "", i5 - (localStringBuffer.length() - i4), ' ', false);
- localStringBuffer.append("#");
- localStringBuffer.append(this.a[47]);
- a(localStringBuffer, String.valueOf(this.I), i5, ' ', false);
- this.ej = localStringBuffer.toString();
- d(null);
- }
- else
- {
- this.ej = null;
- }
- this.x = 7;
- }
- private final void a(StringBuffer paramStringBuffer, String paramString, int paramInt, char paramChar, boolean paramBoolean)
- {
- int i2 = paramString.length();
- if (!paramBoolean) {
- paramStringBuffer.append(paramString);
- }
- for (int i1 = i2; i1 < paramInt; i1++) {
- paramStringBuffer.append(paramChar);
- }
- if (paramBoolean) {
- paramStringBuffer.append(paramString);
- }
- }
- private final boolean an()
- {
- if (this.cb <= 0)
- {
- if ((this.ej != null) && ((this.S) || (this.R)))
- {
- this.S = (this.T = this.R = 0);
- f(true);
- return true;
- }
- if (this.ej == null)
- {
- f(true);
- return true;
- }
- return false;
- }
- return true;
- }
- private final void f(boolean paramBoolean)
- {
- this.bT = this.bS;
- int i1 = this.bR + 1;
- int i2 = this.bS;
- int i3 = 1;
- int i4 = 0;
- switch (this.bR)
- {
- case 3:
- if (!i(this.bS, 11)) {
- i1 = 11;
- }
- break;
- case 6:
- if (!i(this.bS, 12)) {
- i1 = 12;
- }
- break;
- case 11:
- i1 = 4;
- break;
- case 12:
- i1 = 7;
- break;
- case 10:
- this.B[(this.bS - 1)] = true;
- i4 = 1;
- if (!i(this.bS, 10))
- {
- i2 = 0;
- i1 = 4;
- }
- else
- {
- i3 = 0;
- }
- break;
- }
- this.A[(this.bS - 1)] = ((byte)(i4 == 0 ? i1 : 0));
- g();
- if (i3 != 0)
- {
- this.bS = i2;
- this.bR = i1;
- if (paramBoolean) {
- i();
- }
- Y();
- this.x = 1;
- d(true);
- }
- else
- {
- ae();
- }
- }
- private final int h(int paramInt1, int paramInt2)
- {
- int i1 = (paramInt1 - 1) * 3;
- if (paramInt2 == 12) {
- i1++;
- } else if (paramInt2 == 10) {
- i1 += 2;
- } else if (paramInt2 != 11) {
- return -1;
- }
- return i1;
- }
- private final boolean i(int paramInt1, int paramInt2)
- {
- int i1 = h(paramInt1, paramInt2);
- if (i1 == -1) {
- return true;
- }
- return (this.K & 1L << i1) != 0L;
- }
- private final void a(boolean paramBoolean, int paramInt1, int paramInt2)
- {
- int i1 = h(paramInt1, paramInt2);
- if (i1 == -1) {
- return;
- }
- if (paramBoolean) {
- this.K |= 1L << i1;
- } else {
- this.K &= (1L << i1 ^ 0xFFFFFFFFFFFFFFFF);
- }
- }
- private final void ao()
- {
- a(this.a[this.ey[this.ex]], this.i + 12, (byte)-1);
- this.x = 8;
- }
- private final boolean ap()
- {
- boolean bool = false;
- if (this.Q)
- {
- this.Q = false;
- this.ex = ((byte)(this.ex + 1));
- if (this.ex >= this.ey.length) {
- this.ex = 0;
- }
- this.ep = 0;
- this.ew = this.a[this.ey[this.ex]];
- this.er = this.u;
- a(null, 0, 0, true, true, true, true);
- bool = true;
- }
- else if (this.P)
- {
- this.P = false;
- this.ex = ((byte)(this.ex - 1));
- if (this.ex < 0) {
- this.ex = ((byte)(this.ey.length - 1));
- }
- this.ep = 0;
- this.ew = this.a[this.ey[this.ex]];
- this.er = this.u;
- a(null, 0, 0, true, true, true, true);
- bool = true;
- }
- bool |= ak();
- return bool;
- }
- private final void e(Graphics paramGraphics)
- {
- a(paramGraphics, 22935, 10370, true, true, true, true);
- int i1 = this.i + 10;
- int i2 = this.u - e(this.u);
- int i3 = i1 - e(i1);
- a(paramGraphics, this.u - i2 >> 1, i1 - i3 >> 1, i2, i3, 22935, 10370);
- if (this.dM == 0)
- {
- if (this.ez[this.ex].length == 0)
- {
- String str;
- if (this.ex == 0) {
- str = this.a[49];
- } else {
- str = this.a[50];
- }
- a(str, paramGraphics, this.u >> 1, 6 + (this.i - this.g >> 1), true);
- }
- else
- {
- int i5 = this.ez[this.ex].length;
- int i6 = this.u - i5 * (this.h + this.l) + this.l >> 1;
- int i7 = i1 - this.i >> 1;
- for (int i4 = 0; i4 < i5; i4++)
- {
- byte b1 = this.ez[this.ex][i4];
- a(paramGraphics, true, b1, i6, i7);
- i6 += this.h + ((b1 != -24) && (b1 != -40) && (b1 != -39) ? this.l : 0);
- }
- }
- b(paramGraphics, this.ch, 17, 0, 9, 17, 5, i1 - 17 >> 1);
- b(paramGraphics, this.ch, 26, 0, 9, 17, this.u - 9 - 5, i1 - 17 >> 1);
- }
- a(paramGraphics, null, this.a[29], true);
- }
- private final void a(Graphics paramGraphics, String paramString1, String paramString2, boolean paramBoolean)
- {
- int i1;
- if (!this.dP) {
- i1 = e(22);
- } else {
- i1 = 0;
- }
- if (paramBoolean)
- {
- paramGraphics.setClip(0, 0, this.u, this.v);
- paramGraphics.setColor(22935);
- paramGraphics.fillRect(0, this.w + 2 + i1, this.u, 22);
- }
- if (paramString1 != null) {
- a(paramString1, paramGraphics, 3, this.w + 2 + 3 + i1, false);
- }
- if (paramString2 != null) {
- a(paramString2, paramGraphics, this.u - ((paramString2.length() - 1) * 12 + 10) - 3, this.w + 2 + 3 + i1, false);
- }
- }
- private final void d(byte paramByte)
- {
- this.eA = paramByte;
- this.ep = 0;
- this.en = 0;
- this.eo = 0;
- this.er = this.u;
- this.dS = false;
- switch (this.eA)
- {
- case 0:
- this.ew = this.a[55];
- break;
- case 1:
- this.ew = this.a[56];
- break;
- case 2:
- this.ew = this.a[57];
- }
- this.x = 9;
- a(null, 0, 0, true, true, true, true);
- a(true, -1);
- }
- private final boolean aq()
- {
- if (this.dM == 0)
- {
- if (this.S)
- {
- this.S = false;
- a(false, 0);
- return true;
- }
- if (this.T)
- {
- this.T = false;
- a(false, 1);
- return true;
- }
- if (this.N)
- {
- this.N = false;
- if (this.ep > 0)
- {
- this.ep -= 2;
- if (this.ep < 0) {
- this.ep = 0;
- }
- return true;
- }
- }
- else if (this.O)
- {
- this.O = false;
- if (this.ep < this.eq)
- {
- this.ep += 2;
- if (this.ep > this.eq) {
- this.ep = this.eq;
- }
- return true;
- }
- }
- return false;
- }
- this.dL -= 1;
- if (this.dL < 0)
- {
- this.dL = 0;
- if (this.dM == 2)
- {
- this.dM = 0;
- switch (this.dN)
- {
- case 0:
- g(true);
- break;
- case 1:
- g(false);
- }
- }
- else
- {
- this.dM = 0;
- }
- }
- return true;
- }
- private final void g(boolean paramBoolean)
- {
- switch (this.eA)
- {
- case 0:
- if (paramBoolean)
- {
- ae();
- }
- else
- {
- this.x = 1;
- this.dS = true;
- b(true, -1);
- a(true, -1);
- }
- break;
- case 1:
- if (paramBoolean)
- {
- this.x = 3;
- this.dS = false;
- }
- else
- {
- this.x = 4;
- this.dS = true;
- b(true, -1);
- a(true, -1);
- }
- break;
- case 2:
- this.c = ((byte)(paramBoolean ? 1 : 0));
- ae();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement