📄 b.java
字号:
package src;
import java.io.InputStream;
import java.io.PrintStream;
import javax.microedition.lcdui.*;
import javax.microedition.media.Manager;
import javax.microedition.media.Player;
import javax.microedition.midlet.MIDlet;
class b extends Canvas implements Runnable {
public b(FIFA2005 fifa2005) {
aa = fifa2005;
at = cf = false;
setFullScreenMode(true);
N = 4;
ah = 0;
bo = false;
cu = 1;
ac = 0;
bt = new int[4];
for (int i1 = 0; i1 < 4; i1++)
bt[i1] = 1800;
r = new int[6];
aN = new int[3][31];
am = new int[2][11][42];
F = true;
aY = Font.getFont(32, 0, 8);
n();
cs = aY.getHeight();
Q = new byte[30];
aE = new byte[256];
for (int j1 = 0; j1 < 256; j1++)
aE[j1] = 0;
bF = new a(this);
try {
f();
be = new Image[3];
be[0] = Image.createImage("/res/img/ea.png");
be[1] = Image.createImage("/res/img/fifa.png");
be[2] = Image.createImage("/res/img/globes.png");
} catch (Exception exception) {
}
System.gc();
aE[49] = 5;
aE[51] = 6;
aE[55] = 9;
aE[57] = 10;
aE[50] = 4;
aE[56] = 8;
aE[52] = 1;
aE[54] = 2;
aE[53] = 16;
aE[35] = 16;
aE[42] = 32;
aE[48] = 64;
aE[21] = 64;
aE[22] = 32;
aE[2] = 1;
aE[5] = 2;
aE[1] = 4;
aE[6] = 8;
aE[20] = 16;
System.gc();
cj = 0;
for (int k1 = (int) System.currentTimeMillis() & 0xff; k1 > 0; k1--)
e();
c(0);
}
public synchronized void a() {
if (ba == null) {
ba = new Thread(this);
ba.start();
}
}
public synchronized void m() {
ba = null;
}
public static int e() {
M = 0x41c64e6dL * M + 12345L;
return (int) (M >> 16);
}
public static void b(boolean flag) {
i();
bn = null;
cn = null;
aW = null;
cq = null;
U = null;
aS = null;
bw = null;
ad = null;
ax = null;
cD = null;
aD = null;
ab = null;
bd = null;
cL = null;
bI = null;
d = null;
aK = null;
J = null;
if (flag) {
cp = null;
av = null;
bY = (int[][]) null;
t = null;
W = (byte[][]) null;
Z = (byte[][]) null;
cv = (byte[][]) null;
aJ = (int[][]) null;
a = null;
by = null;
bv = bH = null;
D = null;
if (aC != null)
aC[0] = aC[1] = null;
aC = (int[][]) null;
H = null;
S = null;
br = null;
bL = null;
}
System.gc();
}
private static void a(byte abyte0[], int i1, int j1, int k1) {
int i2 = i1;
int l1 = 0;
int j2 = 16;
int k2 = 7;
for (; l1 < 64; l1++) {
aK[l1 + j1] = (byte) i2;
if ((abyte0[j2] & 1 << k2) != 0)
i2 += k1;
if (--k2 < 0) {
k2 = 7;
j2++;
}
}
}
public static int a(byte abyte0[], int i1, int j1) {
int k1 = 0;
int l1 = 0;
for (; k1 < j1; k1++) {
int i2 = aS[abyte0[k1 + i1] & 0xff] & 0xff;
if (i2 == 255)
i2 = 0;
l1 += aS[(i2 << 2) + 0 + 256] - 1;
}
return l1;
}
public static void a(Graphics g1, byte abyte0[], int i1, int j1, int k1,
int l1, int i2) {
if (i2 != 20) {
int k2 = a(abyte0, i1, j1);
if (i2 == 17)
k1 -= k2 >> 1;
else
k1 -= k2;
}
l1 += aS[305];
for (int j2 = 0; j2 < j1; j2++) {
int i3 = aS[abyte0[j2 + i1] & 0xff] & 0xff;
if (i3 != 255) {
i3 = (i3 << 2) + 256;
int l2 = l1 - aS[i3 + 1];
g1.setClip(k1, l2, aS[i3 + 0], aS[i3 + 1]);
g1.drawImage(bw, k1 - (aS[i3 + 2] & 0xff), l2
- (aS[i3 + 3] & 0xff), 20);
k1 += aS[i3 + 0] - 1;
} else {
k1 += aS[256] - 1;
}
}
}
private static void j() {
d = new int[256];
byte abyte0[] = b("/res/bin/sin.bin", 128);
int i2 = 0;
for (int k1 = 0; k1 < 2; k1++) {
int j2 = 2;
int i1 = 0;
for (int j1 = 0; i1 < 128; j1 += j2) {
int l1;
if (i1 == 64) {
l1 = 0x10000;
j2 = -j2;
} else {
l1 = abyte0[j1 + 0] & 0xff | (abyte0[j1 + 1] & 0xff) << 8;
}
if (k1 == 1)
l1 = -l1;
d[i2] = l1;
i2++;
i1++;
}
}
abyte0 = null;
System.gc();
}
private static void f() {
try {
cx = new Player[4];
cx[0] = Manager.createPlayer(aa.getClass().getResourceAsStream(
"/res/wav/crowdgol8.wav"), "audio/x-wav");
cx[1] = null;
cx[2] = Manager.createPlayer(aa.getClass().getResourceAsStream(
"/res/wav/whistle18.wav"), "audio/x-wav");
cx[3] = Manager.createPlayer(aa.getClass().getResourceAsStream(
"/res/wav/whistle28.wav"), "audio/x-wav");
cC = -1;
} catch (Exception exception) {
}
}
public static void a(boolean flag) {
try {
System.gc();
at = true;
cf = flag;
bn = Image.createImage("/res/img/pitch.png");
System.gc();
byte abyte1[] = b("/res/bin/playpal.bin", 12360);
byte abyte2[] = b("/res/img/players.png", 11055);
byte abyte0[] = b("/res/bin/teampals.bin", 32);
System.gc();
aW = a(abyte2, abyte1, 11055, abyte0[m]);
cq = a(abyte2, abyte1, 11055, abyte0[L]);
abyte1 = null;
abyte2 = null;
abyte0 = null;
System.gc();
U = a("/res/bin/playoff.bin", 1200);
cn = b("/res/pitch.map", 2916);
a(bn, cn, 108, 27);
System.gc();
aS = b("/res/bin/font.bin", 472);
bw = Image.createImage("/res/img/font.png");
ad = b("/res/bin/goalbits.bin", 16);
ax = Image.createImage("/res/img/goalbits.png");
cD = Image.createImage("/res/img/marker.png");
aD = Image.createImage("/res/img/ball.png");
ab = Image.createImage("/res/img/shadows.png");
bd = b("/res/bin/shadows.bin", 96);
cL = b("/res/bin/markoff.bin", 60);
bI = b("/res/bin/pstate.bin", 172);
j();
aK = new byte[520];
abyte0 = b("/res/bin/atan.bin", 32);
System.arraycopy(abyte0, 24, aK, 512, 8);
int j1 = 0;
for (int i1 = 0; j1 < 16; i1 += 64) {
a(abyte0, abyte0[j1], i1, abyte0[j1 + 1]);
j1 += 2;
}
abyte0 = null;
System.gc();
J = new byte[68];
for (int k1 = 0; k1 < 59; k1++)
J[k1] = -1;
if (flag)
if (aV) {
cp = Image.createImage("/res/img/arw.png");
av = b("/res/bin/arrows.bin", 20);
bY = new int[4][2];
} else {
t = Image.createImage("/res/img/mcb.png");
}
if (flag) {
W = new byte[24][44];
Z = new byte[32][44];
cv = new byte[2][384];
aJ = new int[2][11];
a = new short[8000];
by = new int[17];
bv = new byte[24];
bH = new byte[32];
D = new int[2];
aC = new int[2][];
H = new int[11];
S = new byte[8];
br = new int[11];
bL = new byte[32];
for (int l1 = 0; l1 < 24; l1++) {
if (l1 < 2) {
bv[l1] = -32;
continue;
}
if (l1 > 21)
bv[l1] = 14;
else
bv[l1] = 0;
}
for (int i2 = 0; i2 < 32; i2++) {
if (i2 < 4) {
bH[i2] = 56;
continue;
}
if (i2 > 27)
bH[i2] = -125;
else
bH[i2] = 0;
}
}
bu = 5;
bq = false;
f = false;
ag = false;
ap = 5;
bi = false;
at = false;
} catch (Exception exception) {
}
System.gc();
}
public static short[] a(String s1, int i1) {
short aword0[] = null;
try {
InputStream inputstream = aa.getClass().getResourceAsStream(s1);
aword0 = new short[i1 >> 1];
for (int i2 = 0; i2 < i1 >> 1; i2++) {
int k1 = 0;
int j1 = 2;
int l1;
do {
l1 = inputstream.read(Q, k1, j1);
if (l1 > 0) {
j1 -= l1;
k1 += l1;
}
} while (j1 > 0 && l1 != -1);
aword0[i2] = (short) (Q[0] & 0xff | (Q[1] & 0xff) << 8);
}
inputstream.close();
} catch (Exception exception) {
aword0 = null;
}
return aword0;
}
public static byte[] b(String s1, int i1) {
byte abyte0[];
try {
InputStream inputstream = aa.a(s1);
abyte0 = new byte[i1];
int k1 = 0;
int j1;
for (int l1 = i1; l1 > 0
&& (j1 = inputstream.read(abyte0, k1, l1)) >= 0; l1 -= j1)
k1 += j1;
inputstream.close();
} catch (Exception exception) {
abyte0 = null;
}
return abyte0;
}
private static void b(int i1, byte abyte0[]) {
int k1 = i1 / 6000;
i1 %= 6000;
abyte0[0] = (byte) ((k1 & 0xf) + 48);
abyte0[7] = 0;
for (int j1 = 6; j1 >= 1; j1--) {
if (j1 == 4) {
abyte0[j1] = 46;
continue;
}
if (j1 == 1) {
abyte0[j1] = 58;
} else {
abyte0[j1] = (byte) (i1 % 10 + 48);
i1 /= 10;
}
}
}
private static void a(Image image, byte abyte0[], int i1, int j1) {
bP = image;
ce = abyte0;
T = i1;
bK = j1;
aO = 0x7fffffff;
bN = 0x7fffffff;
aL = Image.createImage(192, 224);
bD = aL.getGraphics();
}
private static void i() {
bP = null;
ce = null;
bD = null;
aL = null;
}
private static void a(int i1, int j1, Graphics g1) {
if (i1 >= (T << 4) - 176)
i1 = (T << 4) - 176 - 1;
if (i1 < 0)
i1 = 0;
if (j1 >= (bK << 4) - 208)
j1 = (bK << 4) - 208 - 1;
if (j1 < 0)
j1 = 0;
int k6 = i1;
int l6 = j1;
Graphics g2 = bD;
int i6 = k6 % 192;
int j6 = l6 % 224;
int k5 = k6 - aO;
int l5 = l6 - bN;
if (k5 < 0)
k5 = -k5;
if (l5 < 0)
l5 = -l5;
int k2 = (i6 >> 4) << 4;
int j3 = j6 & 0xfffffff0;
if (k5 > 16 || l5 > 16) {
for (int j2 = 0; j2 < 12; j2++) {
int i4 = ((l6 >> 4) * T + (k6 >> 4) + j2) - T;
for (int k1 = 14; k1 > 0; k1--) {
int l4 = (ce[i4 += T] & 0xff) << 4;
g2.setClip(k2, j3, 16, 16);
g2.drawImage(bP, k2 - ((l4 >> 8) << 4), j3 - (l4 & 0xff),
20);
if ((j3 += 16) >= 224)
j3 = 0;
}
if ((k2 += 16) >= 192)
k2 = 0;
}
} else {
if (k6 >> 4 != aO >> 4) {
int l2 = (i6 >> 4) << 4;
int k3 = j6 & 0xfffffff0;
int j4 = (l6 >> 4) * T + (k6 >> 4);
if (k6 > aO) {
l2 += 176;
if (l2 >= 192)
l2 -= 192;
j4 += 11;
}
j4 -= T;
for (int l1 = 14; l1 > 0; l1--) {
int i5 = (ce[j4 += T] & 0xff) << 4;
g2.setClip(l2, k3, 16, 16);
g2.drawImage(bP, l2 - ((i5 >> 8) << 4), k3 - (i5 & 0xff),
20);
if ((k3 += 16) >= 224)
k3 = 0;
}
}
if (l6 >> 4 != bN >> 4) {
int i3 = (i6 >> 4) << 4;
int l3 = j6 & 0xfffffff0;
int k4 = (l6 >> 4) * T + (k6 >> 4);
if (l6 > bN) {
l3 += 208;
if (l3 >= 224)
l3 -= 224;
k4 += 13 * T;
}
k4--;
for (int i2 = 12; i2 > 0; i2--) {
int j5 = (ce[++k4] & 0xff) << 4;
g2.setClip(i3, l3, 16, 16);
g2.drawImage(bP, i3 - ((j5 >> 8) << 4), l3 - (j5 & 0xff),
20);
if ((i3 += 16) >= 192)
i3 = 0;
}
}
}
g1.drawImage(aL, -i6, -j6, 20);
g1.drawImage(aL, -i6 + 192, -j6, 20);
g1.drawImage(aL, -i6, -j6 + 224, 20);
g1.drawImage(aL, -i6 + 192, -j6 + 224, 20);
aO = k6;
bN = l6;
}
private static void a(Graphics g1, int i1, int j1, int k1) {
byte abyte0[] = ad;
if (k1 == 0) {
g1.setClip(i1 - 1, j1 + 1, abyte0[10] + 1, abyte0[11]);
g1.drawImage(ax, i1 - abyte0[8], (j1 - abyte0[9]) + 1, 20);
g1.setClip(i1 + 23, j1 - 1, abyte0[6], abyte0[7]);
g1.drawImage(ax, (i1 - abyte0[4]) + 23, j1 - abyte0[5] - 1, 20);
g1.setClip(i1 + 24, j1 - 2, abyte0[6], abyte0[7]);
g1.drawImage(ax, (i1 - abyte0[4]) + 24, j1 - abyte0[5] - 2, 20);
} else if (k1 == 1) {
for (int l1 = 0; l1 < 4; l1++) {
g1.setClip(i1 + l1 * 24 + 1, j1 + l1 * 6 + 5, abyte0[2],
abyte0[3]);
g1.drawImage(ax, (i1 - abyte0[0]) + l1 * 24 + 1,
(j1 - abyte0[1]) + l1 * 6 + 5, 20);
}
for (int i2 = 0; i2 < 4; i2++) {
g1.setClip(i1 + i2 * 24, (j1 + i2 * 6) - 4, abyte0[14],
abyte0[15]);
g1.drawImage(ax, (i1 - abyte0[12]) + i2 * 24,
((j1 - abyte0[13]) + i2 * 6) - 4, 20);
}
g1.setClip(i1 + 96, j1 + 23, abyte0[10] + 1, abyte0[11]);
g1.drawImage(ax, (i1 - abyte0[8]) + 1 + 95, (j1 - abyte0[9]) + 23,
20);
g1.setClip(i1 + 18 + 100, (j1 - 1) + 23, abyte0[6], abyte0[7]);
g1.drawImage(ax, (i1 - abyte0[4]) + 18 + 100,
(j1 - abyte0[5] - 1) + 23, 20);
g1.setClip(i1 + 17 + 100, (j1 - 1) + 23, abyte0[6], abyte0[7]);
g1.drawImage(ax, (i1 - abyte0[4]) + 17 + 100,
(j1 - abyte0[5] - 1) + 23, 20);
} else if (k1 == 2) {
g1.setClip(i1, j1, abyte0[10] + 1, abyte0[11]);
g1.drawImage(ax, (i1 - abyte0[8]) + 1, j1 - abyte0[9], 20);
g1.setClip(i1 + 24, j1 - 1, abyte0[6], abyte0[7]);
g1.drawImage(ax, (i1 - abyte0[4]) + 24, j1 - abyte0[5] - 1, 20);
for (int j2 = 0; j2 < 4; j2++) {
g1.setClip(i1 + j2 * 24 + 26, j1 + j2 * 6 + 1, abyte0[2],
abyte0[3]);
g1.drawImage(ax, (i1 - abyte0[0]) + j2 * 24 + 26,
(j1 - abyte0[1]) + j2 * 6 + 1, 20);
}
} else if (k1 == 3) {
g1.setClip(i1 + 95, j1 + 23, abyte0[10] + 1, abyte0[11]);
g1.drawImage(ax, (i1 - abyte0[8]) + 1 + 95, (j1 - abyte0[9]) + 23,
20);
g1.setClip(i1 + 19 + 100, (j1 - 2) + 22, abyte0[6], abyte0[7]);
g1.drawImage(ax, (i1 - abyte0[4]) + 19 + 100,
(j1 - abyte0[5] - 2) + 22, 20);
for (int k2 = 0; k2 < 4; k2++) {
g1.setClip(i1 + k2 * 24, (j1 + k2 * 6) - 5, abyte0[14],
abyte0[15]);
g1.drawImage(ax, (i1 - abyte0[12]) + k2 * 24,
((j1 - abyte0[13]) + k2 * 6) - 5, 20);
}
}
}
private static int a(int i1, int j1) {
int k1 = 0;
if (i1 < 0) {
k1 |= 0x100;
i1 = -i1;
}
if (j1 < 0) {
k1 |= 0x80;
j1 = -j1;
}
int l1;
if (i1 == j1) {
l1 = aK[512 + (k1 >> 6)] & 0xff;
} else {
if (j1 < i1) {
k1 |= 0x40;
int i2 = i1;
i1 = j1;
j1 = i2;
}
if (j1 == 0)
l1 = aK[k1] & 0xff;
else
l1 = aK[(i1 << 6) / j1 + k1] & 0xff;
}
return l1;
}
private static int a(int i1) {
if (i1 <= 0)
return 1;
int j1 = i1;
int k1;
do {
k1 = j1;
j1 = k1 + i1 / k1 >> 1;
} while (j1 < k1 && j1 > 0);
return j1;
}
private static void b(Graphics g1, int i1, int j1) {
int i2;
int j2;
if (cw || Y == 8) {
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -