Updated patches for new JAD style names.

This commit is contained in:
LexManos 2013-01-11 13:16:40 -08:00
parent 04e4ce6266
commit 674a9e5e52
42 changed files with 527 additions and 526 deletions

View file

@ -122,6 +122,6 @@
+ public static void fmlReentry(ArgsWrapper wrapper)
+ {
+ String[] p_main_0_ = wrapper.args;
HashMap var1 = new HashMap();
boolean var2 = false;
boolean var3 = true;
HashMap hashmap = new HashMap();
boolean flag = false;
boolean flag1 = true;

View file

@ -18,7 +18,7 @@
+ public void fmlInitReentry()
{
this.field_71483_a = new CanvasMinecraftApplet(this);
boolean var1 = "true".equalsIgnoreCase(this.getParameter("fullscreen"));
boolean flag = "true".equalsIgnoreCase(this.getParameter("fullscreen"));
@@ -62,6 +68,11 @@
public void start()

View file

@ -6,6 +6,6 @@
+ WorldType.field_77139_a[this.field_73916_E].onGUICreateWorldPress();
+
EnumGameType var8 = EnumGameType.func_77142_a(this.field_73927_m);
WorldSettings var6 = new WorldSettings(var2, var8, this.field_73925_n, this.field_73933_r, WorldType.field_77139_a[this.field_73916_E]);
var6.func_82750_a(this.field_82290_a);
EnumGameType enumgametype = EnumGameType.func_77142_a(this.field_73927_m);
WorldSettings worldsettings = new WorldSettings(i, enumgametype, this.field_73925_n, this.field_73933_r, WorldType.field_77139_a[this.field_73916_E]);
worldsettings.func_82750_a(this.field_82290_a);

View file

@ -27,12 +27,12 @@
@SideOnly(Side.CLIENT)
public class GuiMainMenu extends GuiScreen
@@ -140,7 +146,8 @@
this.func_73969_a(var4, 24, var2);
this.func_73969_a(i, 24, stringtranslate);
}
- this.field_73887_h.add(new GuiButton(3, this.field_73880_f / 2 - 100, var4 + 48, var2.func_74805_b("menu.mods")));
+ this.field_73887_h.add(new GuiButton(3, this.field_73880_f / 2 - 100, var4 + 48, 98, 20, var2.func_74805_b("menu.mods")));
+ this.field_73887_h.add(new GuiButton(6, this.field_73880_f / 2 + 2, var4 + 48, 98, 20, "Mods"));
- this.field_73887_h.add(new GuiButton(3, this.field_73880_f / 2 - 100, i + 48, stringtranslate.func_74805_b("menu.mods")));
+ this.field_73887_h.add(new GuiButton(3, this.field_73880_f / 2 - 100, i + 48, 98, 20, stringtranslate.func_74805_b("menu.mods")));
+ this.field_73887_h.add(new GuiButton(6, this.field_73880_f / 2 + 2, i + 48, 98, 20, "Mods"));
if (this.field_73882_e.field_71448_m)
{
@ -49,10 +49,10 @@
if (p_73875_1_.field_73741_f == 11)
@@ -460,7 +472,16 @@
var9 = var9 + " Demo";
s = s + " Demo";
}
- this.func_73731_b(this.field_73886_k, var9, 2, this.field_73881_g - 10, 16777215);
- this.func_73731_b(this.field_73886_k, s, 2, this.field_73881_g - 10, 16777215);
+ List<String> brandings = Lists.reverse(FMLCommonHandler.instance().getBrandings());
+ for (int i = 0; i < brandings.size(); i++)
+ {
@ -63,6 +63,6 @@
+ }
+ }
+
String var10 = "Copyright Mojang AB. Do not distribute!";
this.func_73731_b(this.field_73886_k, var10, this.field_73880_f - this.field_73886_k.func_78256_a(var10) - 2, this.field_73881_g - 10, 16777215);
String s1 = "Copyright Mojang AB. Do not distribute!";
this.func_73731_b(this.field_73886_k, s1, this.field_73880_f - this.field_73886_k.func_78256_a(s1) - 2, this.field_73881_g - 10, 16777215);

View file

@ -16,8 +16,8 @@
public NetClientHandler(Minecraft p_i3103_1_, String p_i3103_2_, int p_i3103_3_) throws IOException
{
this.field_72563_h = p_i3103_1_;
Socket var4 = new Socket(InetAddress.getByName(p_i3103_2_), p_i3103_3_);
this.field_72555_g = new TcpConnection(var4, "Client", this);
Socket socket = new Socket(InetAddress.getByName(p_i3103_2_), p_i3103_3_);
this.field_72555_g = new TcpConnection(socket, "Client", this);
+ FMLNetworkHandler.onClientConnectionToRemoteServer(this, p_i3103_2_, p_i3103_3_, this.field_72555_g);
}
@ -85,7 +85,7 @@
+ {
if ("MC|TPack".equals(p_72501_1_.field_73630_a))
{
String[] var2 = (new String(p_72501_1_.field_73629_c)).split("\u0000");
String[] astring = (new String(p_72501_1_.field_73629_c)).split("\u0000");
@@ -1396,4 +1415,20 @@
{
return this.field_72555_g;

View file

@ -11,24 +11,24 @@
public void func_78443_a(EntityLiving p_78443_1_, ItemStack p_78443_2_, int p_78443_3_)
{
GL11.glPushMatrix();
- Block var4 = Block.field_71973_m[p_78443_2_.field_77993_c];
- Block block = Block.field_71973_m[p_78443_2_.field_77993_c];
+
+ Block var4 = null;
+ Block block = null;
+ if (p_78443_2_.field_77993_c < Block.field_71973_m.length)
+ {
+ var4 = Block.field_71973_m[p_78443_2_.field_77993_c];
+ block = Block.field_71973_m[p_78443_2_.field_77993_c];
+ }
if (var4 != null && RenderBlocks.func_78597_b(var4.func_71857_b()))
if (block != null && RenderBlocks.func_78597_b(block.func_71857_b()))
{
@@ -136,10 +142,17 @@
float var9;
float var10;
float f7;
float f8;
- for (var7 = 0; var7 < 16; ++var7)
- for (i = 0; i < 16; ++i)
- {
- var8 = (float)var7 / 16.0F;
- var9 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * var8 - 0.001953125F;
- f6 = (float)i / 16.0F;
- f7 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * f6 - 0.001953125F;
+ /* Gets the width/16 of the currently bound texture, used
+ * to fix the side rendering issues on textures != 16 */
+ int tileSize = TextureFXManager.instance().getTextureDimensions(GL11.glGetInteger(GL11.GL_TEXTURE_BINDING_2D)).width / 16;
@ -36,59 +36,59 @@
+ float tx = 1.0f / (32 * tileSize);
+ float tz = 1.0f / tileSize;
+
+ for (var7 = 0; var7 < tileSize; ++var7)
+ for (i = 0; i < tileSize; ++i)
+ {
+ var8 = (float)var7 / tileSize;
+ var9 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * var8 - tx;
var10 = var6 * var8;
p_78439_0_.func_78374_a((double)var10, 0.0D, (double)(0.0F - p_78439_5_), (double)var9, (double)p_78439_4_);
p_78439_0_.func_78374_a((double)var10, 0.0D, 0.0D, (double)var9, (double)p_78439_4_);
+ f6 = (float)i / tileSize;
+ f7 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * f6 - tx;
f8 = f5 * f6;
p_78439_0_.func_78374_a((double)f8, 0.0D, (double)(0.0F - p_78439_5_), (double)f7, (double)p_78439_4_);
p_78439_0_.func_78374_a((double)f8, 0.0D, 0.0D, (double)f7, (double)p_78439_4_);
@@ -151,11 +164,11 @@
p_78439_0_.func_78382_b();
p_78439_0_.func_78375_b(1.0F, 0.0F, 0.0F);
- for (var7 = 0; var7 < 16; ++var7)
- for (i = 0; i < 16; ++i)
- {
- var8 = (float)var7 / 16.0F;
- var9 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * var8 - 0.001953125F;
- var10 = var6 * var8 + 0.0625F;
+ for (var7 = 0; var7 < tileSize; ++var7)
- f6 = (float)i / 16.0F;
- f7 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * f6 - 0.001953125F;
- f8 = f5 * f6 + 0.0625F;
+ for (i = 0; i < tileSize; ++i)
+ {
+ var8 = (float)var7 / tileSize;
+ var9 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * var8 - tx;
+ var10 = var6 * var8 + tz;
p_78439_0_.func_78374_a((double)var10, 1.0D, (double)(0.0F - p_78439_5_), (double)var9, (double)p_78439_2_);
p_78439_0_.func_78374_a((double)var10, 1.0D, 0.0D, (double)var9, (double)p_78439_2_);
p_78439_0_.func_78374_a((double)var10, 0.0D, 0.0D, (double)var9, (double)p_78439_4_);
+ f6 = (float)i / tileSize;
+ f7 = p_78439_1_ + (p_78439_3_ - p_78439_1_) * f6 - tx;
+ f8 = f5 * f6 + tz;
p_78439_0_.func_78374_a((double)f8, 1.0D, (double)(0.0F - p_78439_5_), (double)f7, (double)p_78439_2_);
p_78439_0_.func_78374_a((double)f8, 1.0D, 0.0D, (double)f7, (double)p_78439_2_);
p_78439_0_.func_78374_a((double)f8, 0.0D, 0.0D, (double)f7, (double)p_78439_4_);
@@ -166,11 +179,11 @@
p_78439_0_.func_78382_b();
p_78439_0_.func_78375_b(0.0F, 1.0F, 0.0F);
- for (var7 = 0; var7 < 16; ++var7)
- for (i = 0; i < 16; ++i)
- {
- var8 = (float)var7 / 16.0F;
- var9 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * var8 - 0.001953125F;
- var10 = var6 * var8 + 0.0625F;
+ for (var7 = 0; var7 < tileSize; ++var7)
- f6 = (float)i / 16.0F;
- f7 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * f6 - 0.001953125F;
- f8 = f5 * f6 + 0.0625F;
+ for (i = 0; i < tileSize; ++i)
+ {
+ var8 = (float)var7 / tileSize;
+ var9 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * var8 - tx;
+ var10 = var6 * var8 + tz;
p_78439_0_.func_78374_a(0.0D, (double)var10, 0.0D, (double)p_78439_1_, (double)var9);
p_78439_0_.func_78374_a((double)var6, (double)var10, 0.0D, (double)p_78439_3_, (double)var9);
p_78439_0_.func_78374_a((double)var6, (double)var10, (double)(0.0F - p_78439_5_), (double)p_78439_3_, (double)var9);
+ f6 = (float)i / tileSize;
+ f7 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * f6 - tx;
+ f8 = f5 * f6 + tz;
p_78439_0_.func_78374_a(0.0D, (double)f8, 0.0D, (double)p_78439_1_, (double)f7);
p_78439_0_.func_78374_a((double)f5, (double)f8, 0.0D, (double)p_78439_3_, (double)f7);
p_78439_0_.func_78374_a((double)f5, (double)f8, (double)(0.0F - p_78439_5_), (double)p_78439_3_, (double)f7);
@@ -181,10 +194,10 @@
p_78439_0_.func_78382_b();
p_78439_0_.func_78375_b(0.0F, -1.0F, 0.0F);
- for (var7 = 0; var7 < 16; ++var7)
- for (i = 0; i < 16; ++i)
- {
- var8 = (float)var7 / 16.0F;
- var9 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * var8 - 0.001953125F;
+ for (var7 = 0; var7 < tileSize; ++var7)
- f6 = (float)i / 16.0F;
- f7 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * f6 - 0.001953125F;
+ for (i = 0; i < tileSize; ++i)
+ {
+ var8 = (float)var7 / tileSize;
+ var9 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * var8 - tx;
var10 = var6 * var8;
p_78439_0_.func_78374_a((double)var6, (double)var10, 0.0D, (double)p_78439_3_, (double)var9);
p_78439_0_.func_78374_a(0.0D, (double)var10, 0.0D, (double)p_78439_1_, (double)var9);
+ f6 = (float)i / tileSize;
+ f7 = p_78439_4_ + (p_78439_2_ - p_78439_4_) * f6 - tx;
f8 = f5 * f6;
p_78439_0_.func_78374_a((double)f5, (double)f8, 0.0D, (double)p_78439_3_, (double)f7);
p_78439_0_.func_78374_a(0.0D, (double)f8, 0.0D, (double)p_78439_1_, (double)f7);

View file

@ -9,12 +9,12 @@
import net.minecraft.util.MathHelper;
import net.minecraft.util.Vec3;
@@ -215,7 +216,82 @@
int var5 = p_78612_1_.func_71857_b();
int l = p_78612_1_.func_71857_b();
p_78612_1_.func_71902_a(this.field_78669_a, p_78612_2_, p_78612_3_, p_78612_4_);
this.func_83018_a(p_78612_1_);
- return var5 == 0 ? this.func_78570_q(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 31 ? this.func_78581_r(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 4 ? this.func_78621_p(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 13 ? this.func_78584_s(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 1 ? this.func_78620_l(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 19 ? this.func_78603_m(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 23 ? this.func_78566_o(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 6 ? this.func_78614_n(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 2 ? this.func_78572_c(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 3 ? this.func_78590_h(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 5 ? this.func_78589_i(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 8 ? this.func_78576_j(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 7 ? this.func_78601_u(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 9 ? this.func_78586_a((BlockRail)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 10 ? this.func_78565_t((BlockStairs)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 27 ? this.func_78618_a((BlockDragonEgg)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 11 ? this.func_78582_a((BlockFence)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 32 ? this.func_82779_a((BlockWall)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 12 ? this.func_78594_e(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 29 ? this.func_78577_f(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 30 ? this.func_78619_g(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 14 ? this.func_78574_w(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 15 ? this.func_78610_x(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 16 ? this.func_78593_b(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_, false) : (var5 == 17 ? this.func_78608_c(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_, true) : (var5 == 18 ? this.func_78592_a((BlockPane)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 20 ? this.func_78598_k(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 21 ? this.func_78580_a((BlockFenceGate)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 24 ? this.func_78615_a((BlockCauldron)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 33 ? this.func_82780_a((BlockFlowerPot)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 35 ? this.func_82775_a((BlockAnvil)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 25 ? this.func_78585_a((BlockBrewingStand)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 26 ? this.func_78567_v(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 28 ? this.func_78616_a((BlockCocoa)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (var5 == 34 ? this.func_82778_a((BlockBeacon)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : false))))))))))))))))))))))))))))))))));
- return l == 0 ? this.func_78570_q(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 31 ? this.func_78581_r(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 4 ? this.func_78621_p(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 13 ? this.func_78584_s(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 1 ? this.func_78620_l(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 19 ? this.func_78603_m(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 23 ? this.func_78566_o(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 6 ? this.func_78614_n(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 2 ? this.func_78572_c(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 3 ? this.func_78590_h(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 5 ? this.func_78589_i(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 8 ? this.func_78576_j(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 7 ? this.func_78601_u(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 9 ? this.func_78586_a((BlockRail)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 10 ? this.func_78565_t((BlockStairs)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 27 ? this.func_78618_a((BlockDragonEgg)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 11 ? this.func_78582_a((BlockFence)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 32 ? this.func_82779_a((BlockWall)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 12 ? this.func_78594_e(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 29 ? this.func_78577_f(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 30 ? this.func_78619_g(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 14 ? this.func_78574_w(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 15 ? this.func_78610_x(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 16 ? this.func_78593_b(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_, false) : (l == 17 ? this.func_78608_c(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_, true) : (l == 18 ? this.func_78592_a((BlockPane)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 20 ? this.func_78598_k(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 21 ? this.func_78580_a((BlockFenceGate)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 24 ? this.func_78615_a((BlockCauldron)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 33 ? this.func_82780_a((BlockFlowerPot)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 35 ? this.func_82775_a((BlockAnvil)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 25 ? this.func_78585_a((BlockBrewingStand)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 26 ? this.func_78567_v(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 28 ? this.func_78616_a((BlockCocoa)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : (l == 34 ? this.func_82778_a((BlockBeacon)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_) : false))))))))))))))))))))))))))))))))));
+
+ switch (var5)
+ switch (l)
+ {
+ case 0:
+ return this.func_78570_q(p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_);
@ -87,7 +87,7 @@
+ case 34:
+ return this.func_82778_a((BlockBeacon)p_78612_1_, p_78612_2_, p_78612_3_, p_78612_4_);
+ default:
+ return FMLRenderAccessLibrary.renderWorldBlock(this, field_78669_a, p_78612_2_, p_78612_3_, p_78612_4_, p_78612_1_, var5);
+ return FMLRenderAccessLibrary.renderWorldBlock(this, field_78669_a, p_78612_2_, p_78612_3_, p_78612_4_, p_78612_1_, l);
+ }
}
@ -98,7 +98,7 @@
}
+ else
+ {
+ FMLRenderAccessLibrary.renderInventoryBlock(this, p_78600_1_, p_78600_2_, var6);
+ FMLRenderAccessLibrary.renderInventoryBlock(this, p_78600_1_, p_78600_2_, j);
+ }
}
else

View file

@ -32,25 +32,25 @@
{
this.field_78366_k = p_i3192_1_;
@@ -102,8 +110,9 @@
this.field_78359_d.put(p_78346_1_, var7);
return var7;
this.field_78359_d.put(p_78346_1_, aint1);
return aint1;
}
- catch (IOException var6)
- catch (IOException ioexception)
- {
+ catch (Exception var6)
+ catch (Exception ioexception)
+ {
+ log.log(Level.INFO, String.format("An error occured reading texture file %s (getTexture)", p_78346_1_), var6);
var6.printStackTrace();
int[] var5 = this.func_78348_b(this.field_78364_l);
this.field_78359_d.put(p_78346_1_, var5);
+ log.log(Level.INFO, String.format("An error occured reading texture file %s (getTexture)", p_78346_1_), ioexception);
ioexception.printStackTrace();
int[] aint2 = this.func_78348_b(this.field_78364_l);
this.field_78359_d.put(p_78346_1_, aint2);
@@ -250,6 +259,7 @@
int var3 = p_78351_1_.getWidth();
int var4 = p_78351_1_.getHeight();
+ TextureFXManager.instance().setTextureDimensions(p_78351_2_, var3, var4, (List<TextureFX>)field_78367_h);
int[] var5 = new int[var3 * var4];
byte[] var6 = new byte[var3 * var4 * 4];
p_78351_1_.getRGB(0, 0, var3, var4, var5, 0, var3);
int j = p_78351_1_.getWidth();
int k = p_78351_1_.getHeight();
+ TextureFXManager.instance().setTextureDimensions(p_78351_2_, j, k, (List<TextureFX>)field_78367_h);
int[] aint = new int[j * k];
byte[] abyte = new byte[j * k * 4];
p_78351_1_.getRGB(0, 0, j, k, aint, 0, j);
@@ -410,6 +420,7 @@
public void func_78355_a(TextureFX p_78355_1_)
@ -61,13 +61,13 @@
}
@@ -422,28 +433,44 @@
{
TextureFX var3 = (TextureFX)this.field_78367_h.get(var2);
var3.field_76851_c = this.field_78365_j.field_74337_g;
- var3.func_76846_a();
- var1 = this.func_82772_a(var3, var1);
+ if (TextureFXManager.instance().onUpdateTextureEffect(var3))
TextureFX texturefx = (TextureFX)this.field_78367_h.get(j);
texturefx.field_76851_c = this.field_78365_j.field_74337_g;
- texturefx.func_76846_a();
- i = this.func_82772_a(texturefx, i);
+ if (TextureFXManager.instance().onUpdateTextureEffect(texturefx))
+ {
+ var1 = this.func_82772_a(var3, var1);
+ i = this.func_82772_a(texturefx, i);
+ }
}
}
@ -102,13 +102,13 @@
+ p_82772_2_ = p_82772_1_.field_76848_d;
}
for (int var3 = 0; var3 < p_82772_1_.field_76849_e; ++var3)
for (int j = 0; j < p_82772_1_.field_76849_e; ++j)
{
+ int xOffset = p_82772_1_.field_76850_b % 16 * tWidth + var3 * tWidth;
for (int var4 = 0; var4 < p_82772_1_.field_76849_e; ++var4)
+ int xOffset = p_82772_1_.field_76850_b % 16 * tWidth + j * tWidth;
for (int k = 0; k < p_82772_1_.field_76849_e; ++k)
{
- GL11.glTexSubImage2D(GL11.GL_TEXTURE_2D, 0, p_82772_1_.field_76850_b % 16 * 16 + var3 * 16, p_82772_1_.field_76850_b / 16 * 16 + var4 * 16, 16, 16, GL11.GL_RGBA, GL11.GL_UNSIGNED_BYTE, this.field_78358_g);
+ int yOffset = p_82772_1_.field_76850_b / 16 * tHeight + var4 * tHeight;
- GL11.glTexSubImage2D(GL11.GL_TEXTURE_2D, 0, p_82772_1_.field_76850_b % 16 * 16 + j * 16, p_82772_1_.field_76850_b / 16 * 16 + k * 16, 16, 16, GL11.GL_RGBA, GL11.GL_UNSIGNED_BYTE, this.field_78358_g);
+ int yOffset = p_82772_1_.field_76850_b / 16 * tHeight + k * tHeight;
+ GL11.glTexSubImage2D(GL11.GL_TEXTURE_2D, 0, xOffset, yOffset, tWidth, tHeight, GL11.GL_RGBA, GL11.GL_UNSIGNED_BYTE, this.field_78358_g);
}
}
@ -117,23 +117,23 @@
this.field_78361_b = false;
this.field_78363_a = false;
}
- catch (IOException var7)
- catch (IOException ioexception)
- {
+ catch (Exception var7)
+ catch (Exception ioexception)
+ {
+ log.log(Level.INFO,String.format("An error occured reading texture file %s (refreshTexture)", var9), var7);
var7.printStackTrace();
+ log.log(Level.INFO,String.format("An error occured reading texture file %s (refreshTexture)", s), ioexception);
ioexception.printStackTrace();
}
}
@@ -546,8 +574,9 @@
this.field_78361_b = false;
this.field_78363_a = false;
}
- catch (IOException var6)
- catch (IOException ioexception1)
- {
+ catch (Exception var6)
+ catch (Exception ioexception1)
+ {
+ log.log(Level.INFO,String.format("An error occured reading texture file data %s (refreshTexture)", var9), var6);
var6.printStackTrace();
+ log.log(Level.INFO,String.format("An error occured reading texture file data %s (refreshTexture)", s), ioexception1);
ioexception1.printStackTrace();
}
}

View file

@ -45,58 +45,58 @@
+
try
{
- BufferedImage var2 = ImageIO.read(Minecraft.class.getResource("/gui/items.png"));
- int var3 = this.field_76850_b % 16 * 16;
- int var4 = this.field_76850_b / 16 * 16;
- var2.getRGB(var3, var4, 16, 16, this.field_76867_h, 0, 16);
+ BufferedImage var2 = ImageIO.read(field_76865_g.field_71418_C.func_77292_e().func_77532_a("/gui/items.png"));
+ int var3 = this.field_76850_b % 16 * tileSizeBase;
+ int var4 = this.field_76850_b / 16 * tileSizeBase;
+ var2.getRGB(var3, var4, tileSizeBase, tileSizeBase, this.field_76867_h, 0, tileSizeBase);
- BufferedImage bufferedimage = ImageIO.read(Minecraft.class.getResource("/gui/items.png"));
- int i = this.field_76850_b % 16 * 16;
- int j = this.field_76850_b / 16 * 16;
- bufferedimage.getRGB(i, j, 16, 16, this.field_76867_h, 0, 16);
+ BufferedImage bufferedimage = ImageIO.read(field_76865_g.field_71418_C.func_77292_e().func_77532_a("/gui/items.png"));
+ int i = this.field_76850_b % 16 * tileSizeBase;
+ int j = this.field_76850_b / 16 * tileSizeBase;
+ bufferedimage.getRGB(i, j, tileSizeBase, tileSizeBase, this.field_76867_h, 0, tileSizeBase);
}
catch (IOException var5)
catch (IOException ioexception)
{
@@ -58,7 +76,7 @@
int var17;
int var16;
int i;
int j;
- for (int var10 = 0; var10 < 256; ++var10)
+ for (int var10 = 0; var10 < stileSizeSquare; ++var10)
- for (int k = 0; k < 256; ++k)
+ for (int k = 0; k < stileSizeSquare; ++k)
{
int var11 = var8[var10] >> 24 & 255;
int var12 = var8[var10] >> 16 & 255;
int l = aint[k] >> 24 & 255;
int i1 = aint[k] >> 16 & 255;
@@ -141,11 +159,11 @@
int var24;
int var26;
int k3;
int l3;
- for (var16 = -4; var16 <= 4; ++var16)
- for (j = -4; j <= 4; ++j)
- {
- var17 = (int)(8.5D + var31 * (double)var16 * 0.3D);
- var18 = (int)(7.5D - var30 * (double)var16 * 0.3D * 0.5D);
- var19 = var18 * 16 + var17;
+ for (var16 = -(stileSizeBase >> 2); var16 <= (stileSizeBase >> 2); ++var16)
- i = (int)(8.5D + d7 * (double)j * 0.3D);
- j2 = (int)(7.5D - d6 * (double)j * 0.3D * 0.5D);
- i2 = j2 * 16 + i;
+ for (j = -(stileSizeBase >> 2); j <= (stileSizeBase >> 2); ++j)
+ {
+ var17 = (int)((stileSizeBase >> 1) + 0.5D + var31 * (double)var16 * 0.3D);
+ var18 = (int)((stileSizeBase >> 1) - 0.5D - var30 * (double)var16 * 0.3D * 0.5D);
+ var19 = var18 * stileSizeBase + var17;
var20 = 100;
var21 = 100;
var22 = 100;
+ i = (int)((stileSizeBase >> 1) + 0.5D + d7 * (double)j * 0.3D);
+ j2 = (int)((stileSizeBase >> 1) - 0.5D - d6 * (double)j * 0.3D * 0.5D);
+ i2 = j2 * stileSizeBase + i;
l2 = 100;
k2 = 100;
i3 = 100;
@@ -167,11 +185,12 @@
var9[var19 * 4 + 3] = (byte)var23;
abyte[i2 * 4 + 3] = (byte)short1;
}
- for (var16 = -8; var16 <= 16; ++var16)
- for (j = -8; j <= 16; ++j)
- {
- var17 = (int)(8.5D + var30 * (double)var16 * 0.3D);
- var18 = (int)(7.5D + var31 * (double)var16 * 0.3D * 0.5D);
- var19 = var18 * 16 + var17;
- i = (int)(8.5D + d6 * (double)j * 0.3D);
- j2 = (int)(7.5D + d7 * (double)j * 0.3D * 0.5D);
- i2 = j2 * 16 + i;
+
+ for (var16 = -(stileSizeBase>>2); var16 <= stileSizeBase; ++var16)
+ for (j = -(stileSizeBase>>2); j <= stileSizeBase; ++j)
+ {
+ var17 = (int)((stileSizeBase >> 1) + 0.5D + var30 * (double)var16 * 0.3D);
+ var18 = (int)((stileSizeBase >> 1) - 0.5D + var31 * (double)var16 * 0.3D * 0.5D);
+ var19 = var18 * stileSizeBase + var17;
var20 = var16 >= 0 ? 255 : 100;
var21 = var16 >= 0 ? 20 : 100;
var22 = var16 >= 0 ? 20 : 100;
+ i = (int)((stileSizeBase >> 1) + 0.5D + d6 * (double)j * 0.3D);
+ j2 = (int)((stileSizeBase >> 1) - 0.5D + d7 * (double)j * 0.3D * 0.5D);
+ i2 = j2 * stileSizeBase + i;
l2 = j >= 0 ? 255 : 100;
k2 = j >= 0 ? 20 : 100;
i3 = j >= 0 ? 20 : 100;

View file

@ -35,55 +35,55 @@
public void func_76846_a()
@@ -20,32 +34,34 @@
int var3;
float var4;
int var6;
int i;
float f;
int j;
+ float fireFactor1 = 3.0F + (float)(tileSizeBase >> 4);
+ float fireFactor2 = 1.01F + (0.8F / tileSizeBase);
- for (int var1 = 0; var1 < 16; ++var1)
+ for (int var1 = 0; var1 < tileSizeBase; ++var1)
- for (int k = 0; k < 16; ++k)
+ for (int k = 0; k < tileSizeBase; ++k)
{
- for (int var2 = 0; var2 < 20; ++var2)
+ for (int var2 = 0; var2 < fireTileSize; ++var2)
- for (int l = 0; l < 20; ++l)
+ for (int l = 0; l < fireTileSize; ++l)
{
- var3 = 18;
- var4 = this.field_76869_g[var1 + (var2 + 1) % 20 * 16] * (float)var3;
+ var3 = fireTileSize - (tileSizeBase >> 3);
+ var4 = this.field_76869_g[var1 + (var2 + 1) % fireTileSize * tileSizeBase] * (float)var3;
- i = 18;
- f = this.field_76869_g[k + (l + 1) % 20 * 16] * (float)i;
+ i = fireTileSize - (tileSizeBase >> 3);
+ f = this.field_76869_g[k + (l + 1) % fireTileSize * tileSizeBase] * (float)i;
for (int var5 = var1 - 1; var5 <= var1 + 1; ++var5)
for (int i1 = k - 1; i1 <= k + 1; ++i1)
{
for (var6 = var2; var6 <= var2 + 1; ++var6)
for (j = l; j <= l + 1; ++j)
{
- if (var5 >= 0 && var6 >= 0 && var5 < 16 && var6 < 20)
+ if (var5 >= 0 && var6 >= 0 && var5 < tileSizeBase && var6 < fireTileSize)
- if (i1 >= 0 && j >= 0 && i1 < 16 && j < 20)
+ if (i1 >= 0 && j >= 0 && i1 < tileSizeBase && j < fireTileSize)
{
- var4 += this.field_76869_g[var5 + var6 * 16];
+ var4 += this.field_76869_g[var5 + var6 * tileSizeBase];
- f += this.field_76869_g[i1 + j * 16];
+ f += this.field_76869_g[i1 + j * tileSizeBase];
}
++var3;
++i;
}
}
- this.field_76870_h[var1 + var2 * 16] = var4 / ((float)var3 * 1.0600001F);
+ this.field_76870_h[var1 + var2 * tileSizeBase] = var4 / ((float)var3 * fireFactor2);
- this.field_76870_h[k + l * 16] = f / ((float)i * 1.0600001F);
+ this.field_76870_h[k + l * tileSizeBase] = f / ((float)i * fireFactor2);
- if (var2 >= 19)
+ if (var2 >= fireTileSize - (tileSizeBase >> 4))
- if (l >= 19)
+ if (l >= fireTileSize - (tileSizeBase >> 4))
{
- this.field_76870_h[var1 + var2 * 16] = (float)(Math.random() * Math.random() * Math.random() * 4.0D + Math.random() * 0.10000000149011612D + 0.20000000298023224D);
+ this.field_76870_h[var1 + var2 * tileSizeBase] = (float)(Math.random() * Math.random() * Math.random() * fireFactor1 + Math.random() * 0.1F + 0.2F);
- this.field_76870_h[k + l * 16] = (float)(Math.random() * Math.random() * Math.random() * 4.0D + Math.random() * 0.10000000149011612D + 0.20000000298023224D);
+ this.field_76870_h[k + l * tileSizeBase] = (float)(Math.random() * Math.random() * Math.random() * fireFactor1 + Math.random() * 0.1F + 0.2F);
}
}
}
@@ -54,7 +70,7 @@
this.field_76870_h = this.field_76869_g;
this.field_76869_g = var13;
this.field_76869_g = afloat;
- for (var3 = 0; var3 < 256; ++var3)
+ for (var3 = 0; var3 < tileSizeSquare; ++var3)
- for (i = 0; i < 256; ++i)
+ for (i = 0; i < tileSizeSquare; ++i)
{
var4 = this.field_76869_g[var3] * 1.8F;
f = this.field_76869_g[i] * 1.8F;

View file

@ -34,58 +34,58 @@
public void func_76846_a()
@@ -28,9 +40,9 @@
int var8;
int var9;
int i1;
int j1;
- for (int var1 = 0; var1 < 16; ++var1)
+ for (int var1 = 0; var1 < tileSizeBase; ++var1)
- for (int k1 = 0; k1 < 16; ++k1)
+ for (int k1 = 0; k1 < tileSizeBase; ++k1)
{
- for (var2 = 0; var2 < 16; ++var2)
+ for (var2 = 0; var2 < tileSizeBase; ++var2)
- for (i = 0; i < 16; ++i)
+ for (i = 0; i < tileSizeBase; ++i)
{
var3 = 0.0F;
int var4 = (int)(MathHelper.func_76126_a((float)var2 * (float)Math.PI * 2.0F / 16.0F) * 1.2F);
f = 0.0F;
int l1 = (int)(MathHelper.func_76126_a((float)i * (float)Math.PI * 2.0F / 16.0F) * 1.2F);
@@ -40,25 +52,25 @@
{
for (var7 = var2 - 1; var7 <= var2 + 1; ++var7)
for (l = i - 1; l <= i + 1; ++l)
{
- var8 = var6 + var4 & 15;
- var9 = var7 + var5 & 15;
- var3 += this.field_76876_g[var8 + var9 * 16];
+ var8 = var6 + var4 & tileSizeMask;
+ var9 = var7 + var5 & tileSizeMask;
+ var3 += this.field_76876_g[var8 + var9 * tileSizeBase];
- i1 = k + l1 & 15;
- j1 = l + j & 15;
- f += this.field_76876_g[i1 + j1 * 16];
+ i1 = k + l1 & tileSizeMask;
+ j1 = l + j & tileSizeMask;
+ f += this.field_76876_g[i1 + j1 * tileSizeBase];
}
}
- this.field_76878_h[var1 + var2 * 16] = var3 / 10.0F + (this.field_76879_i[(var1 + 0 & 15) + (var2 + 0 & 15) * 16] + this.field_76879_i[(var1 + 1 & 15) + (var2 + 0 & 15) * 16] + this.field_76879_i[(var1 + 1 & 15) + (var2 + 1 & 15) * 16] + this.field_76879_i[(var1 + 0 & 15) + (var2 + 1 & 15) * 16]) / 4.0F * 0.8F;
- this.field_76879_i[var1 + var2 * 16] += this.field_76877_j[var1 + var2 * 16] * 0.01F;
+ this.field_76878_h[var1 + var2 * tileSizeBase] = var3 / 10.0F + (this.field_76879_i[(var1 + 0 & tileSizeMask) + (var2 + 0 & tileSizeMask) * tileSizeBase] + this.field_76879_i[(var1 + 1 & tileSizeMask) + (var2 + 0 & tileSizeMask) * tileSizeBase] + this.field_76879_i[(var1 + 1 & tileSizeMask) + (var2 + 1 & tileSizeMask) * tileSizeBase] + this.field_76879_i[(var1 + 0 & tileSizeMask) + (var2 + 1 & tileSizeMask) * tileSizeBase]) / 4.0F * 0.8F;
+ this.field_76879_i[var1 + var2 * tileSizeBase] += this.field_76877_j[var1 + var2 * tileSizeBase] * 0.01F;
- this.field_76878_h[k1 + i * 16] = f / 10.0F + (this.field_76879_i[(k1 + 0 & 15) + (i + 0 & 15) * 16] + this.field_76879_i[(k1 + 1 & 15) + (i + 0 & 15) * 16] + this.field_76879_i[(k1 + 1 & 15) + (i + 1 & 15) * 16] + this.field_76879_i[(k1 + 0 & 15) + (i + 1 & 15) * 16]) / 4.0F * 0.8F;
- this.field_76879_i[k1 + i * 16] += this.field_76877_j[k1 + i * 16] * 0.01F;
+ this.field_76878_h[k1 + i * tileSizeBase] = f / 10.0F + (this.field_76879_i[(k1 + 0 & tileSizeMask) + (i + 0 & tileSizeMask) * tileSizeBase] + this.field_76879_i[(k1 + 1 & tileSizeMask) + (i + 0 & tileSizeMask) * tileSizeBase] + this.field_76879_i[(k1 + 1 & tileSizeMask) + (i + 1 & tileSizeMask) * tileSizeBase] + this.field_76879_i[(k1 + 0 & tileSizeMask) + (i + 1 & tileSizeMask) * tileSizeBase]) / 4.0F * 0.8F;
+ this.field_76879_i[k1 + i * tileSizeBase] += this.field_76877_j[k1 + i * tileSizeBase] * 0.01F;
- if (this.field_76879_i[var1 + var2 * 16] < 0.0F)
+ if (this.field_76879_i[var1 + var2 * tileSizeBase] < 0.0F)
- if (this.field_76879_i[k1 + i * 16] < 0.0F)
+ if (this.field_76879_i[k1 + i * tileSizeBase] < 0.0F)
{
- this.field_76879_i[var1 + var2 * 16] = 0.0F;
+ this.field_76879_i[var1 + var2 * tileSizeBase] = 0.0F;
- this.field_76879_i[k1 + i * 16] = 0.0F;
+ this.field_76879_i[k1 + i * tileSizeBase] = 0.0F;
}
- this.field_76877_j[var1 + var2 * 16] -= 0.06F;
+ this.field_76877_j[var1 + var2 * tileSizeBase] -= 0.06F;
- this.field_76877_j[k1 + i * 16] -= 0.06F;
+ this.field_76877_j[k1 + i * tileSizeBase] -= 0.06F;
if (Math.random() < 0.005D)
{
- this.field_76877_j[var1 + var2 * 16] = 1.5F;
+ this.field_76877_j[var1 + var2 * tileSizeBase] = 1.5F;
- this.field_76877_j[k1 + i * 16] = 1.5F;
+ this.field_76877_j[k1 + i * tileSizeBase] = 1.5F;
}
}
}
@@ -67,7 +79,7 @@
this.field_76878_h = this.field_76876_g;
this.field_76876_g = var11;
this.field_76876_g = afloat;
- for (var2 = 0; var2 < 256; ++var2)
+ for (var2 = 0; var2 < tileSizeSquare; ++var2)
- for (i = 0; i < 256; ++i)
+ for (i = 0; i < tileSizeSquare; ++i)
{
var3 = this.field_76876_g[var2] * 2.0F;
f = this.field_76876_g[i] * 2.0F;

View file

@ -35,61 +35,61 @@
public void func_76846_a()
@@ -31,9 +44,9 @@
int var8;
int var9;
int i1;
int j1;
- for (int var1 = 0; var1 < 16; ++var1)
+ for (int var1 = 0; var1 < tileSizeBase; ++var1)
- for (int k1 = 0; k1 < 16; ++k1)
+ for (int k1 = 0; k1 < tileSizeBase; ++k1)
{
- for (var2 = 0; var2 < 16; ++var2)
+ for (var2 = 0; var2 < tileSizeBase; ++var2)
- for (i = 0; i < 16; ++i)
+ for (i = 0; i < tileSizeBase; ++i)
{
var3 = 0.0F;
int var4 = (int)(MathHelper.func_76126_a((float)var2 * (float)Math.PI * 2.0F / 16.0F) * 1.2F);
f = 0.0F;
int l1 = (int)(MathHelper.func_76126_a((float)i * (float)Math.PI * 2.0F / 16.0F) * 1.2F);
@@ -43,25 +56,25 @@
{
for (var7 = var2 - 1; var7 <= var2 + 1; ++var7)
for (l = i - 1; l <= i + 1; ++l)
{
- var8 = var6 + var4 & 15;
- var9 = var7 + var5 & 15;
- var3 += this.field_76871_g[var8 + var9 * 16];
+ var8 = var6 + var4 & tileSizeMask;
+ var9 = var7 + var5 & tileSizeMask;
+ var3 += this.field_76871_g[var8 + var9 * tileSizeBase];
- i1 = k + l1 & 15;
- j1 = l + j & 15;
- f += this.field_76871_g[i1 + j1 * 16];
+ i1 = k + l1 & tileSizeMask;
+ j1 = l + j & tileSizeMask;
+ f += this.field_76871_g[i1 + j1 * tileSizeBase];
}
}
- this.field_76874_h[var1 + var2 * 16] = var3 / 10.0F + (this.field_76875_i[(var1 + 0 & 15) + (var2 + 0 & 15) * 16] + this.field_76875_i[(var1 + 1 & 15) + (var2 + 0 & 15) * 16] + this.field_76875_i[(var1 + 1 & 15) + (var2 + 1 & 15) * 16] + this.field_76875_i[(var1 + 0 & 15) + (var2 + 1 & 15) * 16]) / 4.0F * 0.8F;
- this.field_76875_i[var1 + var2 * 16] += this.field_76872_j[var1 + var2 * 16] * 0.01F;
+ this.field_76874_h[var1 + var2 * tileSizeBase] = var3 / 10.0F + (this.field_76875_i[(var1 + 0 & tileSizeMask) + (var2 + 0 & tileSizeMask) * tileSizeBase] + this.field_76875_i[(var1 + 1 & tileSizeMask) + (var2 + 0 & tileSizeMask) * tileSizeBase] + this.field_76875_i[(var1 + 1 & tileSizeMask) + (var2 + 1 & tileSizeMask) * tileSizeBase] + this.field_76875_i[(var1 + 0 & tileSizeMask) + (var2 + 1 & tileSizeMask) * tileSizeBase]) / 4.0F * 0.8F;
+ this.field_76875_i[var1 + var2 * tileSizeBase] += this.field_76872_j[var1 + var2 * tileSizeBase] * 0.01F;
- this.field_76874_h[k1 + i * 16] = f / 10.0F + (this.field_76875_i[(k1 + 0 & 15) + (i + 0 & 15) * 16] + this.field_76875_i[(k1 + 1 & 15) + (i + 0 & 15) * 16] + this.field_76875_i[(k1 + 1 & 15) + (i + 1 & 15) * 16] + this.field_76875_i[(k1 + 0 & 15) + (i + 1 & 15) * 16]) / 4.0F * 0.8F;
- this.field_76875_i[k1 + i * 16] += this.field_76872_j[k1 + i * 16] * 0.01F;
+ this.field_76874_h[k1 + i * tileSizeBase] = f / 10.0F + (this.field_76875_i[(k1 + 0 & tileSizeMask) + (i + 0 & tileSizeMask) * tileSizeBase] + this.field_76875_i[(k1 + 1 & tileSizeMask) + (i + 0 & tileSizeMask) * tileSizeBase] + this.field_76875_i[(k1 + 1 & tileSizeMask) + (i + 1 & tileSizeMask) * tileSizeBase] + this.field_76875_i[(k1 + 0 & tileSizeMask) + (i + 1 & tileSizeMask) * tileSizeBase]) / 4.0F * 0.8F;
+ this.field_76875_i[k1 + i * tileSizeBase] += this.field_76872_j[k1 + i * tileSizeBase] * 0.01F;
- if (this.field_76875_i[var1 + var2 * 16] < 0.0F)
+ if (this.field_76875_i[var1 + var2 * tileSizeBase] < 0.0F)
- if (this.field_76875_i[k1 + i * 16] < 0.0F)
+ if (this.field_76875_i[k1 + i * tileSizeBase] < 0.0F)
{
- this.field_76875_i[var1 + var2 * 16] = 0.0F;
+ this.field_76875_i[var1 + var2 * tileSizeBase] = 0.0F;
- this.field_76875_i[k1 + i * 16] = 0.0F;
+ this.field_76875_i[k1 + i * tileSizeBase] = 0.0F;
}
- this.field_76872_j[var1 + var2 * 16] -= 0.06F;
+ this.field_76872_j[var1 + var2 * tileSizeBase] -= 0.06F;
- this.field_76872_j[k1 + i * 16] -= 0.06F;
+ this.field_76872_j[k1 + i * tileSizeBase] -= 0.06F;
if (Math.random() < 0.005D)
{
- this.field_76872_j[var1 + var2 * 16] = 1.5F;
+ this.field_76872_j[var1 + var2 * tileSizeBase] = 1.5F;
- this.field_76872_j[k1 + i * 16] = 1.5F;
+ this.field_76872_j[k1 + i * tileSizeBase] = 1.5F;
}
}
}
@@ -70,9 +83,9 @@
this.field_76874_h = this.field_76871_g;
this.field_76871_g = var11;
this.field_76871_g = afloat;
- for (var2 = 0; var2 < 256; ++var2)
+ for (var2 = 0; var2 < tileSizeSquare; ++var2)
- for (i = 0; i < 256; ++i)
+ for (i = 0; i < tileSizeSquare; ++i)
{
- var3 = this.field_76871_g[var2 - this.field_76873_k / 3 * 16 & 255] * 2.0F;
+ var3 = this.field_76871_g[(var2 - this.field_76873_k / 3 * tileSizeBase) & tileSizeSquareMask] * 2.0F;
- f = this.field_76871_g[i - this.field_76873_k / 3 * 16 & 255] * 2.0F;
+ f = this.field_76871_g[(i - this.field_76873_k / 3 * tileSizeBase) & tileSizeSquareMask] * 2.0F;
if (var3 > 1.0F)
if (f > 1.0F)
{

View file

@ -29,47 +29,47 @@
+ {
+ super.setup();
+ field_76854_h = new byte[32][tileSizeSquare << 4];
Random var1 = new Random(100L);
Random random = new Random(100L);
for (int var2 = 0; var2 < 32; ++var2)
for (int i = 0; i < 32; ++i)
{
- for (int var3 = 0; var3 < 16; ++var3)
+ for (int var3 = 0; var3 < tileSizeBase; ++var3)
- for (int j = 0; j < 16; ++j)
+ for (int j = 0; j < tileSizeBase; ++j)
{
- for (int var4 = 0; var4 < 16; ++var4)
+ for (int var4 = 0; var4 < tileSizeBase; ++var4)
- for (int k = 0; k < 16; ++k)
+ for (int k = 0; k < tileSizeBase; ++k)
{
float var5 = 0.0F;
int var6;
float f = 0.0F;
int l;
for (var6 = 0; var6 < 2; ++var6)
for (l = 0; l < 2; ++l)
{
- float var7 = (float)(var6 * 16) * 0.5F;
- float var8 = (float)(var6 * 16) * 0.5F;
- float var9 = ((float)var3 - var7) / 16.0F * 2.0F;
- float var10 = ((float)var4 - var8) / 16.0F * 2.0F;
+ float var7 = (float)(var6 * tileSizeBase) * 0.5F;
+ float var8 = (float)(var6 * tileSizeBase) * 0.5F;
+ float var9 = ((float)var3 - var7) / (float)tileSizeBase * 2.0F;
+ float var10 = ((float)var4 - var8) / (float)tileSizeBase * 2.0F;
- float f1 = (float)(l * 16) * 0.5F;
- float f2 = (float)(l * 16) * 0.5F;
- float f3 = ((float)j - f1) / 16.0F * 2.0F;
- float f4 = ((float)k - f2) / 16.0F * 2.0F;
+ float f1 = (float)(l * tileSizeBase) * 0.5F;
+ float f2 = (float)(l * tileSizeBase) * 0.5F;
+ float f3 = ((float)j - f1) / (float)tileSizeBase * 2.0F;
+ float f4 = ((float)k - f2) / (float)tileSizeBase * 2.0F;
if (var9 < -1.0F)
if (f3 < -1.0F)
{
@@ -65,7 +74,7 @@
int var13 = (int)(var5 * var5 * 200.0F + 55.0F);
int var14 = (int)(var5 * var5 * var5 * var5 * 255.0F);
int var15 = (int)(var5 * 100.0F + 155.0F);
- int var16 = var4 * 16 + var3;
+ int var16 = var4 * tileSizeBase + var3;
this.field_76854_h[var2][var16 * 4 + 0] = (byte)var13;
this.field_76854_h[var2][var16 * 4 + 1] = (byte)var14;
this.field_76854_h[var2][var16 * 4 + 2] = (byte)var6;
int i1 = (int)(f * f * 200.0F + 55.0F);
int j1 = (int)(f * f * f * f * 255.0F);
int k1 = (int)(f * 100.0F + 155.0F);
- int l1 = k * 16 + j;
+ int l1 = k * tileSizeBase + j;
this.field_76854_h[i][l1 * 4 + 0] = (byte)i1;
this.field_76854_h[i][l1 * 4 + 1] = (byte)j1;
this.field_76854_h[i][l1 * 4 + 2] = (byte)l;
@@ -80,7 +89,7 @@
++this.field_76853_g;
byte[] var1 = this.field_76854_h[this.field_76853_g & 31];
byte[] abyte = this.field_76854_h[this.field_76853_g & 31];
- for (int var2 = 0; var2 < 256; ++var2)
+ for (int var2 = 0; var2 < tileSizeSquare; ++var2)
- for (int i = 0; i < 256; ++i)
+ for (int i = 0; i < tileSizeSquare; ++i)
{
int var3 = var1[var2 * 4 + 0] & 255;
int var4 = var1[var2 * 4 + 1] & 255;
int j = abyte[i * 4 + 0] & 255;
int k = abyte[i * 4 + 1] & 255;

View file

@ -39,61 +39,61 @@
try
{
- BufferedImage var2 = ImageIO.read(Minecraft.class.getResource("/gui/items.png"));
- int var3 = this.field_76850_b % 16 * 16;
- int var4 = this.field_76850_b / 16 * 16;
- var2.getRGB(var3, var4, 16, 16, this.field_76863_h, 0, 16);
- var2 = ImageIO.read(Minecraft.class.getResource("/misc/dial.png"));
- var2.getRGB(0, 0, 16, 16, this.field_76864_i, 0, 16);
+ BufferedImage var2 = ImageIO.read(field_76860_g.field_71418_C.func_77292_e().func_77532_a("/gui/items.png"));
+ int var3 = this.field_76850_b % 16 * tileSizeBase;
+ int var4 = this.field_76850_b / 16 * tileSizeBase;
+ var2.getRGB(var3, var4, tileSizeBase, tileSizeBase, this.field_76863_h, 0, tileSizeBase);
+ var2 = ImageIO.read(field_76860_g.field_71418_C.func_77292_e().func_77532_a("/misc/dial.png"));
+ if (var2.getWidth() != tileSizeBase)
- BufferedImage bufferedimage = ImageIO.read(Minecraft.class.getResource("/gui/items.png"));
- int i = this.field_76850_b % 16 * 16;
- int j = this.field_76850_b / 16 * 16;
- bufferedimage.getRGB(i, j, 16, 16, this.field_76863_h, 0, 16);
- bufferedimage = ImageIO.read(Minecraft.class.getResource("/misc/dial.png"));
- bufferedimage.getRGB(0, 0, 16, 16, this.field_76864_i, 0, 16);
+ BufferedImage bufferedimage = ImageIO.read(field_76860_g.field_71418_C.func_77292_e().func_77532_a("/gui/items.png"));
+ int i = this.field_76850_b % 16 * tileSizeBase;
+ int j = this.field_76850_b / 16 * tileSizeBase;
+ bufferedimage.getRGB(i, j, tileSizeBase, tileSizeBase, this.field_76863_h, 0, tileSizeBase);
+ bufferedimage = ImageIO.read(field_76860_g.field_71418_C.func_77292_e().func_77532_a("/misc/dial.png"));
+ if (bufferedimage.getWidth() != tileSizeBase)
+ {
+ BufferedImage tmp = new BufferedImage(tileSizeBase, tileSizeBase, 6);
+ Graphics2D gfx = tmp.createGraphics();
+ gfx.drawImage(var2, 0, 0, tileSizeBase, tileSizeBase, 0, 0, var2.getWidth(), var2.getHeight(), (ImageObserver)null);
+ gfx.drawImage(bufferedimage, 0, 0, tileSizeBase, tileSizeBase, 0, 0, bufferedimage.getWidth(), bufferedimage.getHeight(), (ImageObserver)null);
+ gfx.dispose();
+ var2 = tmp;
+ bufferedimage = tmp;
+ }
+
+ var2.getRGB(0, 0, tileSizeBase, tileSizeBase, this.field_76864_i, 0, tileSizeBase);
+ bufferedimage.getRGB(0, 0, tileSizeBase, tileSizeBase, this.field_76864_i, 0, tileSizeBase);
}
- catch (IOException var5)
+ catch (Exception var5)
- catch (IOException ioexception)
+ catch (Exception ioexception)
{
var5.printStackTrace();
+ log.log(Level.WARNING, String.format("A problem occurred with the watch texture: animation will be disabled"), var5);
ioexception.printStackTrace();
+ log.log(Level.WARNING, String.format("A problem occurred with the watch texture: animation will be disabled"), ioexception);
+ setErrored(true);
}
}
@@ -81,7 +107,7 @@
double var5 = Math.sin(this.field_76861_j);
double var7 = Math.cos(this.field_76861_j);
double d2 = Math.sin(this.field_76861_j);
double d3 = Math.cos(this.field_76861_j);
- for (int var9 = 0; var9 < 256; ++var9)
+ for (int var9 = 0; var9 < tileSizeSquare; ++var9)
- for (int i = 0; i < 256; ++i)
+ for (int i = 0; i < tileSizeSquare; ++i)
{
int var10 = this.field_76863_h[var9] >> 24 & 255;
int var11 = this.field_76863_h[var9] >> 16 & 255;
int j = this.field_76863_h[i] >> 24 & 255;
int k = this.field_76863_h[i] >> 16 & 255;
@@ -90,12 +116,12 @@
if (var11 == var13 && var12 == 0 && var13 > 0)
if (k == i1 && l == 0 && i1 > 0)
{
- double var14 = -((double)(var9 % 16) / 15.0D - 0.5D);
- double var16 = (double)(var9 / 16) / 15.0D - 0.5D;
+ double var14 = -((double)(var9 % tileSizeBase) / tileSizeMask - 0.5D);
+ double var16 = (double)(var9 / tileSizeBase) / tileSizeMask - 0.5D;
int var18 = var11;
- int var19 = (int)((var14 * var7 + var16 * var5 + 0.5D) * 16.0D);
- int var20 = (int)((var16 * var7 - var14 * var5 + 0.5D) * 16.0D);
- int var21 = (var19 & 15) + (var20 & 15) * 16;
+ int var19 = (int)((var14 * var7 + var16 * var5 + 0.5D) * tileSizeBase);
+ int var20 = (int)((var16 * var7 - var14 * var5 + 0.5D) * tileSizeBase);
+ int var21 = (var19 & tileSizeMask) + (var20 & tileSizeMask) * tileSizeBase;
var10 = this.field_76864_i[var21] >> 24 & 255;
var11 = (this.field_76864_i[var21] >> 16 & 255) * var11 / 255;
var12 = (this.field_76864_i[var21] >> 8 & 255) * var18 / 255;
- double d4 = -((double)(i % 16) / 15.0D - 0.5D);
- double d5 = (double)(i / 16) / 15.0D - 0.5D;
+ double d4 = -((double)(i % tileSizeBase) / tileSizeMask - 0.5D);
+ double d5 = (double)(i / tileSizeBase) / tileSizeMask - 0.5D;
int j1 = k;
- int k1 = (int)((d4 * d3 + d5 * d2 + 0.5D) * 16.0D);
- int l1 = (int)((d5 * d3 - d4 * d2 + 0.5D) * 16.0D);
- int i2 = (k1 & 15) + (l1 & 15) * 16;
+ int k1 = (int)((d4 * d3 + d5 * d2 + 0.5D) * tileSizeBase);
+ int l1 = (int)((d5 * d3 - d4 * d2 + 0.5D) * tileSizeBase);
+ int i2 = (k1 & tileSizeMask) + (l1 & tileSizeMask) * tileSizeBase;
j = this.field_76864_i[i2] >> 24 & 255;
k = (this.field_76864_i[i2] >> 16 & 255) * k / 255;
l = (this.field_76864_i[i2] >> 8 & 255) * j1 / 255;

View file

@ -34,64 +34,64 @@
public void func_76846_a()
@@ -27,39 +40,39 @@
int var5;
int var6;
int k;
int l;
- for (var1 = 0; var1 < 16; ++var1)
+ for (var1 = 0; var1 < tileSizeBase; ++var1)
- for (i = 0; i < 16; ++i)
+ for (i = 0; i < tileSizeBase; ++i)
{
- for (var2 = 0; var2 < 16; ++var2)
+ for (var2 = 0; var2 < tileSizeBase; ++var2)
- for (j = 0; j < 16; ++j)
+ for (j = 0; j < tileSizeBase; ++j)
{
var3 = 0.0F;
f = 0.0F;
for (int var4 = var1 - 1; var4 <= var1 + 1; ++var4)
for (int i1 = i - 1; i1 <= i + 1; ++i1)
{
- var5 = var4 & 15;
- var6 = var2 & 15;
- var3 += this.field_76855_g[var5 + var6 * 16];
+ var5 = var4 & tileSizeMask;
+ var6 = var2 & tileSizeMask;
+ var3 += this.field_76855_g[var5 + var6 * tileSizeBase];
- k = i1 & 15;
- l = j & 15;
- f += this.field_76855_g[k + l * 16];
+ k = i1 & tileSizeMask;
+ l = j & tileSizeMask;
+ f += this.field_76855_g[k + l * tileSizeBase];
}
- this.field_76858_h[var1 + var2 * 16] = var3 / 3.3F + this.field_76859_i[var1 + var2 * 16] * 0.8F;
+ this.field_76858_h[var1 + var2 * tileSizeBase] = var3 / 3.3F + this.field_76859_i[var1 + var2 * tileSizeBase] * 0.8F;
- this.field_76858_h[i + j * 16] = f / 3.3F + this.field_76859_i[i + j * 16] * 0.8F;
+ this.field_76858_h[i + j * tileSizeBase] = f / 3.3F + this.field_76859_i[i + j * tileSizeBase] * 0.8F;
}
}
- for (var1 = 0; var1 < 16; ++var1)
+ for (var1 = 0; var1 < tileSizeBase; ++var1)
- for (i = 0; i < 16; ++i)
+ for (i = 0; i < tileSizeBase; ++i)
{
- for (var2 = 0; var2 < 16; ++var2)
+ for (var2 = 0; var2 < tileSizeBase; ++var2)
- for (j = 0; j < 16; ++j)
+ for (j = 0; j < tileSizeBase; ++j)
{
- this.field_76859_i[var1 + var2 * 16] += this.field_76856_j[var1 + var2 * 16] * 0.05F;
+ this.field_76859_i[var1 + var2 * tileSizeBase] += this.field_76856_j[var1 + var2 * tileSizeBase] * 0.05F;
- this.field_76859_i[i + j * 16] += this.field_76856_j[i + j * 16] * 0.05F;
+ this.field_76859_i[i + j * tileSizeBase] += this.field_76856_j[i + j * tileSizeBase] * 0.05F;
- if (this.field_76859_i[var1 + var2 * 16] < 0.0F)
+ if (this.field_76859_i[var1 + var2 * tileSizeBase] < 0.0F)
- if (this.field_76859_i[i + j * 16] < 0.0F)
+ if (this.field_76859_i[i + j * tileSizeBase] < 0.0F)
{
- this.field_76859_i[var1 + var2 * 16] = 0.0F;
+ this.field_76859_i[var1 + var2 * tileSizeBase] = 0.0F;
- this.field_76859_i[i + j * 16] = 0.0F;
+ this.field_76859_i[i + j * tileSizeBase] = 0.0F;
}
- this.field_76856_j[var1 + var2 * 16] -= 0.1F;
+ this.field_76856_j[var1 + var2 * tileSizeBase] -= 0.1F;
- this.field_76856_j[i + j * 16] -= 0.1F;
+ this.field_76856_j[i + j * tileSizeBase] -= 0.1F;
if (Math.random() < 0.05D)
{
- this.field_76856_j[var1 + var2 * 16] = 0.5F;
+ this.field_76856_j[var1 + var2 * tileSizeBase] = 0.5F;
- this.field_76856_j[i + j * 16] = 0.5F;
+ this.field_76856_j[i + j * tileSizeBase] = 0.5F;
}
}
}
@@ -68,7 +81,7 @@
this.field_76858_h = this.field_76855_g;
this.field_76855_g = var12;
this.field_76855_g = afloat;
- for (var2 = 0; var2 < 256; ++var2)
+ for (var2 = 0; var2 < tileSizeSquare; ++var2)
- for (j = 0; j < 256; ++j)
+ for (j = 0; j < tileSizeSquare; ++j)
{
var3 = this.field_76855_g[var2];
f = this.field_76855_g[j];

View file

@ -34,67 +34,67 @@
public void func_76846_a()
@@ -28,39 +41,39 @@
int var5;
int var6;
int k;
int l;
- for (var1 = 0; var1 < 16; ++var1)
+ for (var1 = 0; var1 < tileSizeBase; ++var1)
- for (i = 0; i < 16; ++i)
+ for (i = 0; i < tileSizeBase; ++i)
{
- for (var2 = 0; var2 < 16; ++var2)
+ for (var2 = 0; var2 < tileSizeBase; ++var2)
- for (j = 0; j < 16; ++j)
+ for (j = 0; j < tileSizeBase; ++j)
{
var3 = 0.0F;
f = 0.0F;
for (int var4 = var2 - 2; var4 <= var2; ++var4)
for (int i1 = j - 2; i1 <= j; ++i1)
{
- var5 = var1 & 15;
- var6 = var4 & 15;
- var3 += this.field_76880_g[var5 + var6 * 16];
+ var5 = var1 & tileSizeMask;
+ var6 = var4 & tileSizeMask;
+ var3 += this.field_76880_g[var5 + var6 * tileSizeBase];
- k = i & 15;
- l = i1 & 15;
- f += this.field_76880_g[k + l * 16];
+ k = i & tileSizeMask;
+ l = i1 & tileSizeMask;
+ f += this.field_76880_g[k + l * tileSizeBase];
}
- this.field_76883_h[var1 + var2 * 16] = var3 / 3.2F + this.field_76884_i[var1 + var2 * 16] * 0.8F;
+ this.field_76883_h[var1 + var2 * tileSizeBase] = var3 / 3.2F + this.field_76884_i[var1 + var2 * tileSizeBase] * 0.8F;
- this.field_76883_h[i + j * 16] = f / 3.2F + this.field_76884_i[i + j * 16] * 0.8F;
+ this.field_76883_h[i + j * tileSizeBase] = f / 3.2F + this.field_76884_i[i + j * tileSizeBase] * 0.8F;
}
}
- for (var1 = 0; var1 < 16; ++var1)
+ for (var1 = 0; var1 < tileSizeBase; ++var1)
- for (i = 0; i < 16; ++i)
+ for (i = 0; i < tileSizeBase; ++i)
{
- for (var2 = 0; var2 < 16; ++var2)
+ for (var2 = 0; var2 < tileSizeBase; ++var2)
- for (j = 0; j < 16; ++j)
+ for (j = 0; j < tileSizeBase; ++j)
{
- this.field_76884_i[var1 + var2 * 16] += this.field_76881_j[var1 + var2 * 16] * 0.05F;
+ this.field_76884_i[var1 + var2 * tileSizeBase] += this.field_76881_j[var1 + var2 * tileSizeBase] * 0.05F;
- this.field_76884_i[i + j * 16] += this.field_76881_j[i + j * 16] * 0.05F;
+ this.field_76884_i[i + j * tileSizeBase] += this.field_76881_j[i + j * tileSizeBase] * 0.05F;
- if (this.field_76884_i[var1 + var2 * 16] < 0.0F)
+ if (this.field_76884_i[var1 + var2 * tileSizeBase] < 0.0F)
- if (this.field_76884_i[i + j * 16] < 0.0F)
+ if (this.field_76884_i[i + j * tileSizeBase] < 0.0F)
{
- this.field_76884_i[var1 + var2 * 16] = 0.0F;
+ this.field_76884_i[var1 + var2 * tileSizeBase] = 0.0F;
- this.field_76884_i[i + j * 16] = 0.0F;
+ this.field_76884_i[i + j * tileSizeBase] = 0.0F;
}
- this.field_76881_j[var1 + var2 * 16] -= 0.3F;
+ this.field_76881_j[var1 + var2 * tileSizeBase] -= 0.3F;
- this.field_76881_j[i + j * 16] -= 0.3F;
+ this.field_76881_j[i + j * tileSizeBase] -= 0.3F;
if (Math.random() < 0.2D)
{
- this.field_76881_j[var1 + var2 * 16] = 0.5F;
+ this.field_76881_j[var1 + var2 * tileSizeBase] = 0.5F;
- this.field_76881_j[i + j * 16] = 0.5F;
+ this.field_76881_j[i + j * tileSizeBase] = 0.5F;
}
}
}
@@ -69,9 +82,9 @@
this.field_76883_h = this.field_76880_g;
this.field_76880_g = var12;
this.field_76880_g = afloat;
- for (var2 = 0; var2 < 256; ++var2)
+ for (var2 = 0; var2 < tileSizeSquare; ++var2)
- for (j = 0; j < 256; ++j)
+ for (j = 0; j < tileSizeSquare; ++j)
{
- var3 = this.field_76880_g[var2 - this.field_76882_k * 16 & 255];
+ var3 = this.field_76880_g[var2 - this.field_76882_k * tileSizeBase & tileSizeSquareMask];
- f = this.field_76880_g[j - this.field_76882_k * 16 & 255];
+ f = this.field_76880_g[j - this.field_76882_k * tileSizeBase & tileSizeSquareMask];
if (var3 > 1.0F)
if (f > 1.0F)
{

View file

@ -14,4 +14,4 @@
+ if (FMLClientHandler.instance().isLoading()) return;
try
{
PrintWriter var1 = new PrintWriter(new FileWriter(this.field_74354_ai));
PrintWriter printwriter = new PrintWriter(new FileWriter(this.field_74354_ai));

View file

@ -12,31 +12,31 @@
import net.minecraft.entity.item.EntityBoat;
@@ -103,9 +106,10 @@
{
Entity var2 = null;
Entity entity = null;
+ Class var3 = null;
+ Class oclass = null;
try
{
- Class var3 = (Class)field_75625_b.get(p_75615_0_.func_74779_i("id"));
+ var3 = (Class)field_75625_b.get(p_75615_0_.func_74779_i("id"));
- Class oclass = (Class)field_75625_b.get(p_75615_0_.func_74779_i("id"));
+ oclass = (Class)field_75625_b.get(p_75615_0_.func_74779_i("id"));
if (var3 != null)
if (oclass != null)
{
@@ -119,7 +123,17 @@
if (var2 != null)
if (entity != null)
{
- var2.func_70020_e(p_75615_0_);
- entity.func_70020_e(p_75615_0_);
+ try
+ {
+ var2.func_70020_e(p_75615_0_);
+ entity.func_70020_e(p_75615_0_);
+ }
+ catch (Exception e)
+ {
+ FMLLog.log(Level.SEVERE, e,
+ "An Entity %s(%s) has thrown an exception during loading, its state cannot be restored. Report this to the mod author",
+ p_75615_0_.func_74779_i("id"), var3.getName());
+ var2 = null;
+ p_75615_0_.func_74779_i("id"), oclass.getName());
+ entity = null;
+ }
}
else

View file

@ -22,7 +22,7 @@
+ FMLNetworkHandler.makeEntitySpawnAdjustment(this.field_73132_a.field_70157_k, p_73117_1_, this.field_73128_d, this.field_73129_e, this.field_73126_f);
+ }
if (this.field_73143_t && !(var6 instanceof Packet24MobSpawn))
if (this.field_73143_t && !(packet instanceof Packet24MobSpawn))
{
@@ -424,6 +434,13 @@
if (this.field_73132_a.field_70128_L)

View file

@ -16,5 +16,5 @@
+ GameRegistry.onPickupNotification(p_70100_1_, this);
+
this.func_85030_a("random.pop", 0.2F, ((this.field_70146_Z.nextFloat() - this.field_70146_Z.nextFloat()) * 0.7F + 1.0F) * 2.0F);
p_70100_1_.func_71001_a(this, var3);
p_70100_1_.func_71001_a(this, i);

View file

@ -2,7 +2,7 @@
+++ ../src-work/minecraft/net/minecraft/entity/monster/EntitySlime.java
@@ -242,7 +242,7 @@
{
Chunk var1 = this.field_70170_p.func_72938_d(MathHelper.func_76128_c(this.field_70165_t), MathHelper.func_76128_c(this.field_70161_v));
Chunk chunk = this.field_70170_p.func_72938_d(MathHelper.func_76128_c(this.field_70165_t), MathHelper.func_76128_c(this.field_70161_v));
- if (this.field_70170_p.func_72912_H().func_76067_t() == WorldType.field_77138_c && this.field_70146_Z.nextInt(4) != 1)
+ if (this.field_70170_p.func_72912_H().func_76067_t().handleSlimeSpawnReduction(field_70146_Z, field_70170_p))

View file

@ -18,10 +18,10 @@
@@ -422,6 +423,7 @@
MerchantRecipeList var2;
var2 = new MerchantRecipeList();
+ VillagerRegistry.manageVillagerTrades(var2, this, this.func_70946_n(), this.field_70146_Z);
int var6;
MerchantRecipeList merchantrecipelist;
merchantrecipelist = new MerchantRecipeList();
+ VillagerRegistry.manageVillagerTrades(merchantrecipelist, this, this.func_70946_n(), this.field_70146_Z);
int j;
label50:
@@ -637,7 +639,7 @@

View file

@ -15,7 +15,7 @@
+ FMLCommonHandler.instance().onPlayerPreTick(this);
if (this.field_71074_e != null)
{
ItemStack var1 = this.field_71071_by.func_70448_g();
ItemStack itemstack = this.field_71071_by.func_70448_g();
@@ -296,6 +299,7 @@
{
this.field_71100_bB.func_75118_a(this);

View file

@ -14,4 +14,4 @@
+ GameRegistry.onItemCrafted(p_82870_1_, p_82870_2_, field_75239_a);
this.func_75208_c(p_82870_2_);
for (int var3 = 0; var3 < this.field_75239_a.func_70302_i_(); ++var3)
for (int i = 0; i < this.field_75239_a.func_70302_i_(); ++i)

View file

@ -1,11 +1,11 @@
--- ../src-base/minecraft/net/minecraft/item/ItemMap.java
+++ ../src-work/minecraft/net/minecraft/item/ItemMap.java
@@ -52,7 +52,7 @@
int var5 = 128 * (1 << var4.field_76197_d);
var4.field_76201_a = Math.round((float)p_77873_2_.func_72912_H().func_76079_c() / (float)var5) * var5;
var4.field_76199_b = Math.round((float)(p_77873_2_.func_72912_H().func_76074_e() / var5)) * var5;
- var4.field_76200_c = (byte)p_77873_2_.field_73011_w.field_76574_g;
+ var4.field_76200_c = p_77873_2_.field_73011_w.field_76574_g;
var4.func_76185_a();
p_77873_2_.func_72823_a(var3, var4);
int i = 128 * (1 << mapdata.field_76197_d);
mapdata.field_76201_a = Math.round((float)p_77873_2_.func_72912_H().func_76079_c() / (float)i) * i;
mapdata.field_76199_b = Math.round((float)(p_77873_2_.func_72912_H().func_76074_e() / i)) * i;
- mapdata.field_76200_c = (byte)p_77873_2_.field_73011_w.field_76574_g;
+ mapdata.field_76200_c = p_77873_2_.field_73011_w.field_76574_g;
mapdata.func_76185_a();
p_77873_2_.func_72823_a(s, mapdata);
}

View file

@ -37,16 +37,16 @@
public void func_72529_d()
{
- String var1 = this.field_72534_f.func_71203_ab().func_72399_a(this.field_72538_b.func_74430_c(), this.field_72543_h);
- String s = this.field_72534_f.func_71203_ab().func_72399_a(this.field_72538_b.func_74430_c(), this.field_72543_h);
+ FMLNetworkHandler.onConnectionReceivedFromClient(this, this.field_72534_f, this.field_72538_b.func_74430_c(), this.field_72543_h);
+ }
+
+ public void completeConnection(String var1)
+ public void completeConnection(String s)
+ {
if (var1 != null)
if (s != null)
{
@@ -272,4 +283,21 @@
@@ -272,4 +283,22 @@
{
return p_72531_0_.field_72544_i = p_72531_1_;
}
@ -63,8 +63,9 @@
+ // NOOP for login
+ }
+
+ @Override
+ public EntityPlayer getPlayer()
+ {
+ return null;
+ };
+ }
}

View file

@ -35,8 +35,8 @@
+
+ public void handleVanilla250Packet(Packet250CustomPayload p_72501_1_)
{
DataInputStream var2;
ItemStack var3;
DataInputStream datainputstream;
ItemStack itemstack;
@@ -1156,4 +1165,18 @@
}
}

View file

@ -10,10 +10,10 @@
import net.minecraft.server.MinecraftServer;
import net.minecraft.util.ReportedException;
@@ -51,6 +53,7 @@
throw new ReportedException(var4);
throw new ReportedException(crashreport);
}
+ FMLLog.log(Level.SEVERE, var5, "A critical server error occured handling a packet, kicking %s", var2.getPlayer().field_70157_k);
field_71751_a.log(Level.WARNING, "Failed to handle packet for " + var2.field_72574_e.func_70023_ak() + "/" + var2.field_72574_e.func_71114_r() + ": " + var5, var5);
var2.func_72565_c("Internal server error");
+ FMLLog.log(Level.SEVERE, exception, "A critical server error occured handling a packet, kicking %s", netserverhandler.getPlayer().field_70157_k);
field_71751_a.log(Level.WARNING, "Failed to handle packet for " + netserverhandler.field_72574_e.func_70023_ak() + "/" + netserverhandler.field_72574_e.func_71114_r() + ": " + exception, exception);
netserverhandler.func_72565_c("Internal server error");
}

View file

@ -32,9 +32,9 @@
public void func_73267_a(DataInputStream p_73267_1_) throws IOException
@@ -46,7 +54,16 @@
this.field_73560_c = (var3 & 8) == 8;
int var4 = var3 & -9;
this.field_73557_d = EnumGameType.func_77146_a(var4);
this.field_73560_c = (b0 & 8) == 8;
int i = b0 & -9;
this.field_73557_d = EnumGameType.func_77146_a(i);
- this.field_73558_e = p_73267_1_.readByte();
+
+ if (vanillaCompatible)
@ -52,7 +52,7 @@
@@ -64,7 +81,16 @@
}
p_73273_1_.writeByte(var2);
p_73273_1_.writeByte(i);
- p_73273_1_.writeByte(this.field_73558_e);
+
+ if (vanillaCompatible)
@ -68,10 +68,10 @@
p_73273_1_.writeByte(this.field_73556_g);
p_73273_1_.writeByte(this.field_73562_h);
@@ -84,6 +110,6 @@
var1 = this.field_73559_b.func_77127_a().length();
i = this.field_73559_b.func_77127_a().length();
}
- return 6 + 2 * var1 + 4 + 4 + 1 + 1 + 1;
+ return 6 + 2 * var1 + 4 + 4 + 1 + 1 + 1 + (vanillaCompatible ? 0 : 3);
- return 6 + 2 * i + 4 + 4 + 1 + 1 + 1;
+ return 6 + 2 * i + 4 + 4 + 1 + 1 + 1 + (vanillaCompatible ? 0 : 3);
}
}

View file

@ -15,11 +15,11 @@
{
+ FMLCommonHandler.instance().handleServerStarted();
+
long var1 = System.currentTimeMillis();
long i = System.currentTimeMillis();
+
+ FMLCommonHandler.instance().onWorldLoadTick(field_71305_c);
for (long var50 = 0L; this.field_71317_u; this.field_71296_Q = true)
for (long k0 = 0L; this.field_71317_u; this.field_71296_Q = true)
{
@@ -417,6 +424,7 @@
@ -31,15 +31,15 @@
{
@@ -425,6 +433,10 @@
}
catch (Throwable var48)
catch (Throwable throwable)
{
+ if (FMLCommonHandler.instance().shouldServerBeKilledQuietly())
+ {
+ return;
+ }
var48.printStackTrace();
field_71306_a.log(Level.SEVERE, "Encountered an unexpected exception " + var48.getClass().getSimpleName(), var48);
CrashReport var2 = null;
throwable.printStackTrace();
field_71306_a.log(Level.SEVERE, "Encountered an unexpected exception " + throwable.getClass().getSimpleName(), throwable);
CrashReport crashreport = null;
@@ -455,6 +467,10 @@
{
try
@ -64,7 +64,7 @@
public void func_71217_p()
{
+ FMLCommonHandler.instance().rescheduleTicks(Side.SERVER);
long var1 = System.nanoTime();
long i = System.nanoTime();
AxisAlignedBB.func_72332_a().func_72298_a();
+ FMLCommonHandler.instance().onPreServerTick();
++this.field_71315_w;
@ -82,18 +82,18 @@
}
this.field_71304_b.func_76320_a("tick");
+ FMLCommonHandler.instance().onPreWorldTick(var4);
CrashReport var6;
+ FMLCommonHandler.instance().onPreWorldTick(worldserver);
CrashReport crashreport;
try
@@ -578,6 +599,7 @@
throw new ReportedException(var6);
throw new ReportedException(crashreport);
}
+ FMLCommonHandler.instance().onPostWorldTick(var4);
+ FMLCommonHandler.instance().onPostWorldTick(worldserver);
this.field_71304_b.func_76319_b();
this.field_71304_b.func_76320_a("tracker");
var4.func_73039_n().func_72788_a();
worldserver.func_73039_n().func_72788_a();
@@ -705,7 +727,7 @@
public String getServerModName()

View file

@ -8,10 +8,10 @@
import cpw.mods.fml.relauncher.SideOnly;
import java.io.IOException;
@@ -53,6 +54,7 @@
catch (Exception var6)
catch (Exception exception)
{
var3.func_72527_a("Internal server error");
+ FMLLog.log(Level.SEVERE, var6, "Error handling login related packet - connection from %s refused", var3.func_72528_e());
field_71777_a.log(Level.WARNING, "Failed to handle packet for " + var3.func_72528_e() + ": " + var6, var6);
netloginhandler.func_72527_a("Internal server error");
+ FMLLog.log(Level.SEVERE, exception, "Error handling login related packet - connection from %s refused", netloginhandler.func_72528_e());
field_71777_a.log(Level.WARNING, "Failed to handle packet for " + netloginhandler.func_72528_e() + ": " + exception, exception);
}

View file

@ -12,11 +12,11 @@
@@ -12,10 +14,7 @@
public static void func_73699_a()
{
ConsoleLogFormatter var0 = new ConsoleLogFormatter();
ConsoleLogFormatter consolelogformatter = new ConsoleLogFormatter();
- field_73700_a.setUseParentHandlers(false);
- ConsoleHandler var1 = new ConsoleHandler();
- var1.setFormatter(var0);
- field_73700_a.addHandler(var1);
- ConsoleHandler consolehandler = new ConsoleHandler();
- consolehandler.setFormatter(consolelogformatter);
- field_73700_a.addHandler(consolehandler);
+ field_73700_a.setParent(FMLLog.getLogger());
try

View file

@ -24,7 +24,7 @@
+ FMLCommonHandler.instance().onServerStarted();
this.func_71210_a(new DedicatedPlayerList(this));
long var4 = System.nanoTime();
long j = System.nanoTime();
@@ -187,6 +192,8 @@
this.field_71339_n.func_72602_a();
}

View file

@ -13,7 +13,7 @@
p_72355_2_.func_71116_b();
+
+ FMLNetworkHandler.handlePlayerLogin(p_72355_2_, var6, p_72355_1_);
+ FMLNetworkHandler.handlePlayerLogin(p_72355_2_, netserverhandler, p_72355_1_);
}
public void func_72364_a(WorldServer[] p_72364_1_)
@ -23,19 +23,19 @@
{
+ GameRegistry.onPlayerLogout(p_72367_1_);
this.func_72391_b(p_72367_1_);
WorldServer var2 = p_72367_1_.func_71121_q();
var2.func_72900_e(p_72367_1_);
WorldServer worldserver = p_72367_1_.func_71121_q();
worldserver.func_72900_e(p_72367_1_);
@@ -324,6 +329,7 @@
var8.func_72838_d(var7);
this.field_72404_b.add(var7);
var7.func_71116_b();
+ GameRegistry.onPlayerRespawn(var7);
return var7;
worldserver.func_72838_d(entityplayermp1);
this.field_72404_b.add(entityplayermp1);
entityplayermp1.func_71116_b();
+ GameRegistry.onPlayerRespawn(entityplayermp1);
return entityplayermp1;
}
@@ -349,6 +355,8 @@
PotionEffect var7 = (PotionEffect)var6.next();
p_72356_1_.field_71135_a.func_72567_b(new Packet41EntityEffect(p_72356_1_.field_70157_k, var7));
PotionEffect potioneffect = (PotionEffect)iterator.next();
p_72356_1_.field_71135_a.func_72567_b(new Packet41EntityEffect(p_72356_1_.field_70157_k, potioneffect));
}
+
+ GameRegistry.onPlayerChangedDimension(p_72356_1_);

View file

@ -15,32 +15,32 @@
import net.minecraft.crash.CrashReportCategory;
@@ -82,9 +85,11 @@
{
TileEntity var1 = null;
TileEntity tileentity = null;
+ Class var2 = null;
+ Class oclass = null;
+
try
{
- Class var2 = (Class)field_70326_a.get(p_70317_0_.func_74779_i("id"));
+ var2 = (Class)field_70326_a.get(p_70317_0_.func_74779_i("id"));
- Class oclass = (Class)field_70326_a.get(p_70317_0_.func_74779_i("id"));
+ oclass = (Class)field_70326_a.get(p_70317_0_.func_74779_i("id"));
if (var2 != null)
if (oclass != null)
{
@@ -98,7 +103,17 @@
if (var1 != null)
if (tileentity != null)
{
- var1.func_70307_a(p_70317_0_);
- tileentity.func_70307_a(p_70317_0_);
+ try
+ {
+ var1.func_70307_a(p_70317_0_);
+ tileentity.func_70307_a(p_70317_0_);
+ }
+ catch (Exception e)
+ {
+ FMLLog.log(Level.SEVERE, e,
+ "A TileEntity %s(%s) has thrown an exception during loading, its state cannot be restored. Report this to the mod author",
+ p_70317_0_.func_74779_i("id"), var2.getName());
+ var1 = null;
+ p_70317_0_.func_74779_i("id"), oclass.getName());
+ tileentity = null;
+ }
}
else

View file

@ -11,15 +11,15 @@
}
}
- return var2 instanceof ItemTool && ((ItemTool)var2).func_77861_e().equals("WOOD") ? 200 : (var2 instanceof ItemSword && ((ItemSword)var2).func_77825_f().equals("WOOD") ? 200 : (var2 instanceof ItemHoe && ((ItemHoe)var2).func_77842_f().equals("WOOD") ? 200 : (var1 == Item.field_77669_D.field_77779_bT ? 100 : (var1 == Item.field_77705_m.field_77779_bT ? 1600 : (var1 == Item.field_77775_ay.field_77779_bT ? 20000 : (var1 == Block.field_71987_y.field_71990_ca ? 100 : (var1 == Item.field_77731_bo.field_77779_bT ? 2400 : 0)))))));
+ if (var2 instanceof ItemTool && ((ItemTool) var2).func_77861_e().equals("WOOD")) return 200;
+ if (var2 instanceof ItemSword && ((ItemSword) var2).func_77825_f().equals("WOOD")) return 200;
+ if (var2 instanceof ItemHoe && ((ItemHoe) var2).func_77842_f().equals("WOOD")) return 200;
+ if (var1 == Item.field_77669_D.field_77779_bT) return 100;
+ if (var1 == Item.field_77705_m.field_77779_bT) return 1600;
+ if (var1 == Item.field_77775_ay.field_77779_bT) return 20000;
+ if (var1 == Block.field_71987_y.field_71990_ca) return 100;
+ if (var1 == Item.field_77731_bo.field_77779_bT) return 2400;
- return item instanceof ItemTool && ((ItemTool)item).func_77861_e().equals("WOOD") ? 200 : (item instanceof ItemSword && ((ItemSword)item).func_77825_f().equals("WOOD") ? 200 : (item instanceof ItemHoe && ((ItemHoe)item).func_77842_f().equals("WOOD") ? 200 : (i == Item.field_77669_D.field_77779_bT ? 100 : (i == Item.field_77705_m.field_77779_bT ? 1600 : (i == Item.field_77775_ay.field_77779_bT ? 20000 : (i == Block.field_71987_y.field_71990_ca ? 100 : (i == Item.field_77731_bo.field_77779_bT ? 2400 : 0)))))));
+ if (item instanceof ItemTool && ((ItemTool) item).func_77861_e().equals("WOOD")) return 200;
+ if (item instanceof ItemSword && ((ItemSword) item).func_77825_f().equals("WOOD")) return 200;
+ if (item instanceof ItemHoe && ((ItemHoe) item).func_77842_f().equals("WOOD")) return 200;
+ if (i == Item.field_77669_D.field_77779_bT) return 100;
+ if (i == Item.field_77705_m.field_77779_bT) return 1600;
+ if (i == Item.field_77775_ay.field_77779_bT) return 20000;
+ if (i == Block.field_71987_y.field_71990_ca) return 100;
+ if (i == Item.field_77731_bo.field_77779_bT) return 2400;
+ return GameRegistry.getFuelValue(p_70398_0_);
}
}

View file

@ -6,8 +6,8 @@
{
- if (this.field_76579_a.func_72912_H().func_76067_t() == WorldType.field_77138_c)
- {
- FlatGeneratorInfo var1 = FlatGeneratorInfo.func_82651_a(this.field_76579_a.func_72912_H().func_82571_y());
- this.field_76578_c = new WorldChunkManagerHell(BiomeGenBase.field_76773_a[var1.func_82648_a()], 0.5F, 0.5F);
- FlatGeneratorInfo flatgeneratorinfo = FlatGeneratorInfo.func_82651_a(this.field_76579_a.func_72912_H().func_82571_y());
- this.field_76578_c = new WorldChunkManagerHell(BiomeGenBase.field_76773_a[flatgeneratorinfo.func_82648_a()], 0.5F, 0.5F);
- }
- else
- {

View file

@ -58,8 +58,8 @@
+ {
+ if (this == field_77138_c)
+ {
+ FlatGeneratorInfo var1 = FlatGeneratorInfo.func_82651_a(world.func_72912_H().func_82571_y());
+ return new WorldChunkManagerHell(BiomeGenBase.field_76773_a[var1.func_82648_a()], 0.5F, 0.5F);
+ FlatGeneratorInfo flatgeneratorinfo = FlatGeneratorInfo.func_82651_a(world.func_72912_H().func_82571_y());
+ return new WorldChunkManagerHell(BiomeGenBase.field_76773_a[flatgeneratorinfo.func_82648_a()], 0.5F, 0.5F);
+ }
+ else
+ {
@ -82,9 +82,9 @@
+ return this == field_77138_c ? 0.0D : 63.0D;
+ }
+
+ public boolean hasVoidParticles(boolean var1)
+ public boolean hasVoidParticles(boolean flag)
+ {
+ return this != field_77138_c && !var1;
+ return this != field_77138_c && !flag;
+ }
+
+ public double voidFadeMagnitude()

View file

@ -13,46 +13,46 @@
import net.minecraft.nbt.CompressedStreamTools;
@@ -247,10 +251,20 @@
p_75820_1_.field_76644_m = true;
var11 = new NBTTagCompound();
nbttagcompound1 = new NBTTagCompound();
- if (var21.func_70039_c(var11))
- if (entity.func_70039_c(nbttagcompound1))
- {
- var16.func_74742_a(var11);
- nbttaglist1.func_74742_a(nbttagcompound1);
- }
+
+ try
+ {
+ if (var21.func_70039_c(var11))
+ if (entity.func_70039_c(nbttagcompound1))
+ {
+ var16.func_74742_a(var11);
+ nbttaglist1.func_74742_a(nbttagcompound1);
+ }
+ }
+ catch (Exception e)
+ {
+ FMLLog.log(Level.SEVERE, e,
+ "An Entity type %s has thrown an exception trying to write state. It will not persist. Report this to the mod author",
+ var21.getClass().getName());
+ entity.getClass().getName());
+ }
}
}
@@ -262,8 +276,17 @@
{
TileEntity var22 = (TileEntity)var18.next();
var11 = new NBTTagCompound();
- var22.func_70310_b(var11);
- var17.func_74742_a(var11);
TileEntity tileentity = (TileEntity)iterator.next();
nbttagcompound1 = new NBTTagCompound();
- tileentity.func_70310_b(nbttagcompound1);
- nbttaglist2.func_74742_a(nbttagcompound1);
+ try
+ {
+ var22.func_70310_b(var11);
+ var17.func_74742_a(var11);
+ tileentity.func_70310_b(nbttagcompound1);
+ nbttaglist2.func_74742_a(nbttagcompound1);
+ }
+ catch (Exception e)
+ {
+ FMLLog.log(Level.SEVERE, e,
+ "A TileEntity type %s has throw an exception trying to write state. It will not persist. Report this to the mod author",
+ var22.getClass().getName());
+ tileentity.getClass().getName());
+ }
}
p_75820_3_.func_74782_a("TileEntities", var17);
p_75820_3_.func_74782_a("TileEntities", nbttaglist2);

View file

@ -14,6 +14,6 @@
{
this.field_73246_d.func_73153_a(p_73153_1_, p_73153_2_, p_73153_3_);
+ GameRegistry.generateWorld(p_73153_2_, p_73153_3_, field_73251_h, field_73246_d, p_73153_1_);
var4.func_76630_e();
chunk.func_76630_e();
}
}

View file

@ -10,22 +10,22 @@
public class StructureVillagePieces
@@ -20,6 +22,8 @@
var2.add(new StructureVillagePieceWeight(ComponentVillageField2.class, 3, MathHelper.func_76136_a(p_75084_0_, 2 + p_75084_1_, 4 + p_75084_1_ * 2)));
var2.add(new StructureVillagePieceWeight(ComponentVillageHouse2.class, 15, MathHelper.func_76136_a(p_75084_0_, 0, 1 + p_75084_1_)));
var2.add(new StructureVillagePieceWeight(ComponentVillageHouse3.class, 8, MathHelper.func_76136_a(p_75084_0_, 0 + p_75084_1_, 3 + p_75084_1_ * 2)));
+ VillagerRegistry.addExtraVillageComponents(var2, p_75084_0_, p_75084_1_);
arraylist.add(new StructureVillagePieceWeight(ComponentVillageField2.class, 3, MathHelper.func_76136_a(p_75084_0_, 2 + p_75084_1_, 4 + p_75084_1_ * 2)));
arraylist.add(new StructureVillagePieceWeight(ComponentVillageHouse2.class, 15, MathHelper.func_76136_a(p_75084_0_, 0, 1 + p_75084_1_)));
arraylist.add(new StructureVillagePieceWeight(ComponentVillageHouse3.class, 8, MathHelper.func_76136_a(p_75084_0_, 0 + p_75084_1_, 3 + p_75084_1_ * 2)));
+ VillagerRegistry.addExtraVillageComponents(arraylist, p_75084_0_, p_75084_1_);
+
Iterator var3 = var2.iterator();
Iterator iterator = arraylist.iterator();
while (var3.hasNext())
while (iterator.hasNext())
@@ -92,6 +96,10 @@
else if (var9 == ComponentVillageHouse3.class)
else if (oclass == ComponentVillageHouse3.class)
{
var10 = ComponentVillageHouse3.func_74921_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
object = ComponentVillageHouse3.func_74921_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
+ }
+ else
+ {
+ var10 = VillagerRegistry.getVillageComponent(p_75083_1_, p_75083_0_ , p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
+ object = VillagerRegistry.getVillageComponent(p_75083_1_, p_75083_0_ , p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
}
return (ComponentVillage)var10;
return (ComponentVillage)object;

View file

@ -10,57 +10,57 @@
import net.minecraft.nbt.CompressedStreamTools;
import net.minecraft.nbt.NBTTagCompound;
@@ -104,16 +106,24 @@
NBTTagCompound var2;
NBTTagCompound var3;
NBTTagCompound nbttagcompound;
NBTTagCompound nbttagcompound1;
+ WorldInfo worldInfo = null;
+
if (var1.exists())
if (file1.exists())
{
try
{
var2 = CompressedStreamTools.func_74796_a(new FileInputStream(var1));
var3 = var2.func_74775_l("Data");
- return new WorldInfo(var3);
+ worldInfo = new WorldInfo(var3);
+ FMLCommonHandler.instance().handleWorldDataLoad(this, worldInfo, var2);
nbttagcompound = CompressedStreamTools.func_74796_a(new FileInputStream(file1));
nbttagcompound1 = nbttagcompound.func_74775_l("Data");
- return new WorldInfo(nbttagcompound1);
+ worldInfo = new WorldInfo(nbttagcompound1);
+ FMLCommonHandler.instance().handleWorldDataLoad(this, worldInfo, nbttagcompound);
+ return worldInfo;
}
catch (Exception var5)
catch (Exception exception)
{
+ if (FMLCommonHandler.instance().shouldServerBeKilledQuietly())
+ {
+ throw (RuntimeException)var5;
+ throw (RuntimeException)exception;
+ }
var5.printStackTrace();
exception.printStackTrace();
}
}
@@ -126,7 +136,9 @@
{
var2 = CompressedStreamTools.func_74796_a(new FileInputStream(var1));
var3 = var2.func_74775_l("Data");
- return new WorldInfo(var3);
+ worldInfo = new WorldInfo(var3);
+ FMLCommonHandler.instance().handleWorldDataLoad(this, worldInfo, var2);
nbttagcompound = CompressedStreamTools.func_74796_a(new FileInputStream(file1));
nbttagcompound1 = nbttagcompound.func_74775_l("Data");
- return new WorldInfo(nbttagcompound1);
+ worldInfo = new WorldInfo(nbttagcompound1);
+ FMLCommonHandler.instance().handleWorldDataLoad(this, worldInfo, nbttagcompound);
+ return worldInfo;
}
catch (Exception var4)
catch (Exception exception1)
{
@@ -142,6 +154,8 @@
NBTTagCompound var3 = p_75755_1_.func_76082_a(p_75755_2_);
NBTTagCompound var4 = new NBTTagCompound();
var4.func_74782_a("Data", var3);
NBTTagCompound nbttagcompound1 = p_75755_1_.func_76082_a(p_75755_2_);
NBTTagCompound nbttagcompound2 = new NBTTagCompound();
nbttagcompound2.func_74782_a("Data", nbttagcompound1);
+
+ FMLCommonHandler.instance().handleWorldDataSave(this, p_75755_1_, var4);
+ FMLCommonHandler.instance().handleWorldDataSave(this, p_75755_1_, nbttagcompound2);
try
{
@@ -180,6 +194,8 @@
NBTTagCompound var2 = p_75761_1_.func_76066_a();
NBTTagCompound var3 = new NBTTagCompound();
var3.func_74782_a("Data", var2);
NBTTagCompound nbttagcompound = p_75761_1_.func_76066_a();
NBTTagCompound nbttagcompound1 = new NBTTagCompound();
nbttagcompound1.func_74782_a("Data", nbttagcompound);
+
+ FMLCommonHandler.instance().handleWorldDataSave(this, p_75761_1_, var3);
+ FMLCommonHandler.instance().handleWorldDataSave(this, p_75761_1_, nbttagcompound1);
try
{