mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-12 08:17:35 +00:00
1.8.9 update
This commit is contained in:
1 parent
6644e8c9ed
commit
56eba05237
42 files changed
+858
-160
No files matched your search
@@ -387,7 +387,7 @@ public class ForgeHooksClient
|
||||
}
|
||||
else
|
||||
{
|
||||
model.getItemCameraTransforms().func_181689_a(cameraTransformType);
|
||||
model.getItemCameraTransforms().applyTransform(cameraTransformType);
|
||||
}
|
||||
return model;
|
||||
}
|
||||
|
||||
@@ -153,7 +153,7 @@ public class GuiIngameForge extends GuiIngame
|
||||
|
||||
Scoreboard scoreboard = this.mc.theWorld.getScoreboard();
|
||||
ScoreObjective objective = null;
|
||||
ScorePlayerTeam scoreplayerteam = scoreboard.getPlayersTeam(mc.thePlayer.getCommandSenderName());
|
||||
ScorePlayerTeam scoreplayerteam = scoreboard.getPlayersTeam(mc.thePlayer.getName());
|
||||
if (scoreplayerteam != null)
|
||||
{
|
||||
int slot = scoreplayerteam.getChatFormat().getColorIndex();
|
||||
@@ -276,7 +276,7 @@ public class GuiIngameForge extends GuiIngame
|
||||
|
||||
if (f1 > 0.0F)
|
||||
{
|
||||
func_180474_b(f1, res);
|
||||
renderPortal(f1, res);
|
||||
}
|
||||
|
||||
post(PORTAL);
|
||||
|
||||
@@ -17,10 +17,10 @@ public class Attributes
|
||||
static
|
||||
{
|
||||
DEFAULT_BAKED_FORMAT = new VertexFormat();
|
||||
DEFAULT_BAKED_FORMAT.func_181721_a(new VertexFormatElement(0, EnumType.FLOAT, EnumUsage.POSITION, 3));
|
||||
DEFAULT_BAKED_FORMAT.func_181721_a(new VertexFormatElement(0, EnumType.UBYTE, EnumUsage.COLOR, 4));
|
||||
DEFAULT_BAKED_FORMAT.func_181721_a(new VertexFormatElement(0, EnumType.FLOAT, EnumUsage.UV, 2));
|
||||
DEFAULT_BAKED_FORMAT.func_181721_a(new VertexFormatElement(0, EnumType.BYTE, EnumUsage.PADDING, 4));
|
||||
DEFAULT_BAKED_FORMAT.addElement(new VertexFormatElement(0, EnumType.FLOAT, EnumUsage.POSITION, 3));
|
||||
DEFAULT_BAKED_FORMAT.addElement(new VertexFormatElement(0, EnumType.UBYTE, EnumUsage.COLOR, 4));
|
||||
DEFAULT_BAKED_FORMAT.addElement(new VertexFormatElement(0, EnumType.FLOAT, EnumUsage.UV, 2));
|
||||
DEFAULT_BAKED_FORMAT.addElement(new VertexFormatElement(0, EnumType.BYTE, EnumUsage.PADDING, 4));
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -59,9 +59,9 @@ public interface IFlexibleBakedModel extends IBakedModel
|
||||
return parent.isBuiltInRenderer();
|
||||
}
|
||||
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
return parent.getTexture();
|
||||
return parent.getParticleTexture();
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
|
||||
@@ -63,7 +63,7 @@ public interface IPerspectiveAwareModel extends IFlexibleBakedModel
|
||||
ImmutableMap.Builder<TransformType, TRSRTransformation> builder = ImmutableMap.builder();
|
||||
for(TransformType type : TransformType.values())
|
||||
{
|
||||
builder.put(type, new TRSRTransformation(transforms.func_181688_b(type)));
|
||||
builder.put(type, new TRSRTransformation(transforms.getTransform(type)));
|
||||
}
|
||||
return builder.build();
|
||||
}
|
||||
@@ -89,7 +89,7 @@ public interface IPerspectiveAwareModel extends IFlexibleBakedModel
|
||||
public boolean isAmbientOcclusion() { return parent.isAmbientOcclusion(); }
|
||||
public boolean isGui3d() { return parent.isGui3d(); }
|
||||
public boolean isBuiltInRenderer() { return parent.isBuiltInRenderer(); }
|
||||
public TextureAtlasSprite getTexture() { return parent.getTexture(); }
|
||||
public TextureAtlasSprite getParticleTexture() { return parent.getParticleTexture(); }
|
||||
public ItemCameraTransforms getItemCameraTransforms() { return parent.getItemCameraTransforms(); }
|
||||
public List<BakedQuad> getFaceQuads(EnumFacing side) { return parent.getFaceQuads(side); }
|
||||
public List<BakedQuad> getGeneralQuads() { return parent.getGeneralQuads(); }
|
||||
|
||||
@@ -53,9 +53,9 @@ public interface ISmartBlockModel extends IBakedModel
|
||||
return parent.isBuiltInRenderer();
|
||||
}
|
||||
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
return parent.getTexture();
|
||||
return parent.getParticleTexture();
|
||||
}
|
||||
|
||||
public ItemCameraTransforms getItemCameraTransforms()
|
||||
|
||||
@@ -113,7 +113,7 @@ public class ItemLayerModel implements IRetexturableModel
|
||||
public boolean isAmbientOcclusion() { return true; }
|
||||
public boolean isGui3d() { return false; }
|
||||
public boolean isBuiltInRenderer() { return false; }
|
||||
public TextureAtlasSprite getTexture() { return particle; }
|
||||
public TextureAtlasSprite getParticleTexture() { return particle; }
|
||||
public ItemCameraTransforms getItemCameraTransforms() { return ItemCameraTransforms.DEFAULT; }
|
||||
public List<BakedQuad> getFaceQuads(EnumFacing side) { return ImmutableList.of(); }
|
||||
public List<BakedQuad> getGeneralQuads() { return quads; }
|
||||
|
||||
@@ -293,7 +293,7 @@ public class ModelFluid implements IModelCustomData
|
||||
return false;
|
||||
}
|
||||
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
return still;
|
||||
}
|
||||
|
||||
@@ -5,8 +5,6 @@ import java.util.List;
|
||||
|
||||
import javax.vecmath.Matrix4f;
|
||||
|
||||
import org.apache.commons.lang3.tuple.Pair;
|
||||
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.block.model.BakedQuad;
|
||||
@@ -22,9 +20,10 @@ import net.minecraft.util.EnumFacing;
|
||||
import net.minecraft.util.EnumWorldBlockLayer;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.client.MinecraftForgeClient;
|
||||
import net.minecraftforge.client.model.ItemLayerModel.BakedModel;
|
||||
import net.minecraftforge.fml.common.FMLLog;
|
||||
|
||||
import org.apache.commons.lang3.tuple.Pair;
|
||||
|
||||
import com.google.common.base.Function;
|
||||
import com.google.common.base.Optional;
|
||||
import com.google.common.collect.ImmutableList;
|
||||
@@ -209,10 +208,10 @@ public class MultiLayerModel implements IModelCustomData
|
||||
}
|
||||
|
||||
@Override
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
compute();
|
||||
return base.getTexture();
|
||||
return base.getParticleTexture();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -100,9 +100,9 @@ public class MultiModel implements IModel
|
||||
}
|
||||
|
||||
@Override
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
return internalBase.getTexture();
|
||||
return internalBase.getParticleTexture();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -936,7 +936,7 @@ public class B3DLoader implements ICustomModelLoader
|
||||
return false;
|
||||
}
|
||||
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
// FIXME somehow specify particle texture in the model
|
||||
return textures.values().asList().get(0);
|
||||
|
||||
@@ -1469,7 +1469,7 @@ public class OBJModel implements IRetexturableModel, IModelCustomData
|
||||
}
|
||||
|
||||
@Override
|
||||
public TextureAtlasSprite getTexture()
|
||||
public TextureAtlasSprite getParticleTexture()
|
||||
{
|
||||
return this.sprite;
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ public class VertexLighterFlat extends QuadGatheringTransformer
|
||||
VertexFormat format = parent.getVertexFormat();
|
||||
if(format.hasNormal()) return format;
|
||||
format = new VertexFormat(format);
|
||||
format.func_181721_a(new VertexFormatElement(0, VertexFormatElement.EnumType.FLOAT, VertexFormatElement.EnumUsage.NORMAL, 4));
|
||||
format.addElement(new VertexFormatElement(0, VertexFormatElement.EnumType.FLOAT, VertexFormatElement.EnumUsage.NORMAL, 4));
|
||||
return format;
|
||||
}
|
||||
|
||||
|
||||
@@ -39,9 +39,9 @@ public class ForgeVersion
|
||||
//This number is incremented every time Jenkins builds Forge, and never reset. Should always be 0 in the repo code.
|
||||
public static final int buildVersion = 0;
|
||||
// This is the minecraft version we're building for - used in various places in Forge/FML code
|
||||
public static final String mcVersion = "1.8.8";
|
||||
public static final String mcVersion = "1.8.9";
|
||||
// This is the MCP data version we're using
|
||||
public static final String mcpVersion = "9.18";
|
||||
public static final String mcpVersion = "9.19";
|
||||
@SuppressWarnings("unused")
|
||||
private static Status status = PENDING;
|
||||
@SuppressWarnings("unused")
|
||||
|
||||
@@ -526,11 +526,11 @@ public class GuiModList extends GuiScreen
|
||||
GuiModList.this.mc.renderEngine.bindTexture(logoPath);
|
||||
WorldRenderer wr = tess.getWorldRenderer();
|
||||
int offset = (this.left + this.listWidth/2) - (logoDims.width / 2);
|
||||
wr.func_181668_a(7, DefaultVertexFormats.field_181707_g);
|
||||
wr.func_181662_b(offset, top + logoDims.height, zLevel).func_181673_a(0, 1).func_181675_d();
|
||||
wr.func_181662_b(offset + logoDims.width, top + logoDims.height, zLevel).func_181673_a(1, 1).func_181675_d();
|
||||
wr.func_181662_b(offset + logoDims.width, top, zLevel).func_181673_a(1, 0).func_181675_d();
|
||||
wr.func_181662_b(offset, top, zLevel).func_181673_a(0, 0).func_181675_d();
|
||||
wr.begin(7, DefaultVertexFormats.POSITION_TEX);
|
||||
wr.pos(offset, top + logoDims.height, zLevel).tex(0, 1).endVertex();
|
||||
wr.pos(offset + logoDims.width, top + logoDims.height, zLevel).tex(1, 1).endVertex();
|
||||
wr.pos(offset + logoDims.width, top, zLevel).tex(1, 0).endVertex();
|
||||
wr.pos(offset, top, zLevel).tex(0, 0).endVertex();
|
||||
tess.draw();
|
||||
GlStateManager.disableBlend();
|
||||
top += logoDims.height + 10;
|
||||
|
||||
@@ -283,11 +283,11 @@ public abstract class GuiScrollingList
|
||||
this.client.renderEngine.bindTexture(Gui.optionsBackground);
|
||||
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
float scale = 32.0F;
|
||||
worldr.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
worldr.func_181662_b(this.left, this.bottom, 0.0D).func_181673_a(this.left / scale, (this.bottom + (int)this.scrollDistance) / scale).func_181669_b(0x20, 0x20, 0x20, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(this.right, this.bottom, 0.0D).func_181673_a(this.right / scale, (this.bottom + (int)this.scrollDistance) / scale).func_181669_b(0x20, 0x20, 0x20, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(this.right, this.top, 0.0D).func_181673_a(this.right / scale, (this.top + (int)this.scrollDistance) / scale).func_181669_b(0x20, 0x20, 0x20, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(this.left, this.top, 0.0D).func_181673_a(this.left / scale, (this.top + (int)this.scrollDistance) / scale).func_181669_b(0x20, 0x20, 0x20, 0xFF).func_181675_d();
|
||||
worldr.begin(7, DefaultVertexFormats.POSITION_TEX_COLOR);
|
||||
worldr.pos(this.left, this.bottom, 0.0D).tex(this.left / scale, (this.bottom + (int)this.scrollDistance) / scale).color(0x20, 0x20, 0x20, 0xFF).endVertex();
|
||||
worldr.pos(this.right, this.bottom, 0.0D).tex(this.right / scale, (this.bottom + (int)this.scrollDistance) / scale).color(0x20, 0x20, 0x20, 0xFF).endVertex();
|
||||
worldr.pos(this.right, this.top, 0.0D).tex(this.right / scale, (this.top + (int)this.scrollDistance) / scale).color(0x20, 0x20, 0x20, 0xFF).endVertex();
|
||||
worldr.pos(this.left, this.top, 0.0D).tex(this.left / scale, (this.top + (int)this.scrollDistance) / scale).color(0x20, 0x20, 0x20, 0xFF).endVertex();
|
||||
tess.draw();
|
||||
}
|
||||
|
||||
@@ -310,15 +310,15 @@ public abstract class GuiScrollingList
|
||||
int max = entryRight;
|
||||
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
GlStateManager.disableTexture2D();
|
||||
worldr.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
worldr.func_181662_b(min, slotTop + slotBuffer + 2, 0).func_181673_a(0, 1).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(max, slotTop + slotBuffer + 2, 0).func_181673_a(1, 1).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(max, slotTop - 2, 0).func_181673_a(1, 0).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(min, slotTop - 2, 0).func_181673_a(0, 0).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(min + 1, slotTop + slotBuffer + 1, 0).func_181673_a(0, 1).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(max - 1, slotTop + slotBuffer + 1, 0).func_181673_a(1, 1).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(max - 1, slotTop - 1, 0).func_181673_a(1, 0).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(min + 1, slotTop - 1, 0).func_181673_a(0, 0).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.begin(7, DefaultVertexFormats.POSITION_TEX_COLOR);
|
||||
worldr.pos(min, slotTop + slotBuffer + 2, 0).tex(0, 1).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(max, slotTop + slotBuffer + 2, 0).tex(1, 1).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(max, slotTop - 2, 0).tex(1, 0).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(min, slotTop - 2, 0).tex(0, 0).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(min + 1, slotTop + slotBuffer + 1, 0).tex(0, 1).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
worldr.pos(max - 1, slotTop + slotBuffer + 1, 0).tex(1, 1).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
worldr.pos(max - 1, slotTop - 1, 0).tex(1, 0).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
worldr.pos(min + 1, slotTop - 1, 0).tex(0, 0).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
tess.draw();
|
||||
GlStateManager.enableTexture2D();
|
||||
}
|
||||
@@ -346,23 +346,23 @@ public abstract class GuiScrollingList
|
||||
}
|
||||
|
||||
GlStateManager.disableTexture2D();
|
||||
worldr.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
worldr.func_181662_b(scrollBarLeft, this.bottom, 0.0D).func_181673_a(0.0D, 1.0D).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarRight, this.bottom, 0.0D).func_181673_a(1.0D, 1.0D).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarRight, this.top, 0.0D).func_181673_a(1.0D, 0.0D).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarLeft, this.top, 0.0D).func_181673_a(0.0D, 0.0D).func_181669_b(0x00, 0x00, 0x00, 0xFF).func_181675_d();
|
||||
worldr.begin(7, DefaultVertexFormats.POSITION_TEX_COLOR);
|
||||
worldr.pos(scrollBarLeft, this.bottom, 0.0D).tex(0.0D, 1.0D).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarRight, this.bottom, 0.0D).tex(1.0D, 1.0D).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarRight, this.top, 0.0D).tex(1.0D, 0.0D).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarLeft, this.top, 0.0D).tex(0.0D, 0.0D).color(0x00, 0x00, 0x00, 0xFF).endVertex();
|
||||
tess.draw();
|
||||
worldr.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
worldr.func_181662_b(scrollBarLeft, barTop + height, 0.0D).func_181673_a(0.0D, 1.0D).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarRight, barTop + height, 0.0D).func_181673_a(1.0D, 1.0D).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarRight, barTop, 0.0D).func_181673_a(1.0D, 0.0D).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarLeft, barTop, 0.0D).func_181673_a(0.0D, 0.0D).func_181669_b(0x80, 0x80, 0x80, 0xFF).func_181675_d();
|
||||
worldr.begin(7, DefaultVertexFormats.POSITION_TEX_COLOR);
|
||||
worldr.pos(scrollBarLeft, barTop + height, 0.0D).tex(0.0D, 1.0D).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarRight, barTop + height, 0.0D).tex(1.0D, 1.0D).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarRight, barTop, 0.0D).tex(1.0D, 0.0D).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarLeft, barTop, 0.0D).tex(0.0D, 0.0D).color(0x80, 0x80, 0x80, 0xFF).endVertex();
|
||||
tess.draw();
|
||||
worldr.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
worldr.func_181662_b(scrollBarLeft, barTop + height - 1, 0.0D).func_181673_a(0.0D, 1.0D).func_181669_b(0xC0, 0xC0, 0xC0, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarRight - 1, barTop + height - 1, 0.0D).func_181673_a(1.0D, 1.0D).func_181669_b(0xC0, 0xC0, 0xC0, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarRight - 1, barTop, 0.0D).func_181673_a(1.0D, 0.0D).func_181669_b(0xC0, 0xC0, 0xC0, 0xFF).func_181675_d();
|
||||
worldr.func_181662_b(scrollBarLeft, barTop, 0.0D).func_181673_a(0.0D, 0.0D).func_181669_b(0xC0, 0xC0, 0xC0, 0xFF).func_181675_d();
|
||||
worldr.begin(7, DefaultVertexFormats.POSITION_TEX_COLOR);
|
||||
worldr.pos(scrollBarLeft, barTop + height - 1, 0.0D).tex(0.0D, 1.0D).color(0xC0, 0xC0, 0xC0, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarRight - 1, barTop + height - 1, 0.0D).tex(1.0D, 1.0D).color(0xC0, 0xC0, 0xC0, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarRight - 1, barTop, 0.0D).tex(1.0D, 0.0D).color(0xC0, 0xC0, 0xC0, 0xFF).endVertex();
|
||||
worldr.pos(scrollBarLeft, barTop, 0.0D).tex(0.0D, 0.0D).color(0xC0, 0xC0, 0xC0, 0xFF).endVertex();
|
||||
tess.draw();
|
||||
}
|
||||
|
||||
@@ -391,11 +391,11 @@ public abstract class GuiScrollingList
|
||||
GlStateManager.shadeModel(GL11.GL_SMOOTH);
|
||||
Tessellator tessellator = Tessellator.getInstance();
|
||||
WorldRenderer worldrenderer = tessellator.getWorldRenderer();
|
||||
worldrenderer.func_181668_a(7, DefaultVertexFormats.field_181706_f);
|
||||
worldrenderer.func_181662_b(right, top, 0.0D).func_181666_a(r1, g1, b1, a1).func_181675_d();
|
||||
worldrenderer.func_181662_b(left, top, 0.0D).func_181666_a(r1, g1, b1, a1).func_181675_d();
|
||||
worldrenderer.func_181662_b(left, bottom, 0.0D).func_181666_a(r2, g2, b2, a2).func_181675_d();
|
||||
worldrenderer.func_181662_b(right, bottom, 0.0D).func_181666_a(r2, g2, b2, a2).func_181675_d();
|
||||
worldrenderer.begin(7, DefaultVertexFormats.POSITION_COLOR);
|
||||
worldrenderer.pos(right, top, 0.0D).color(r1, g1, b1, a1).endVertex();
|
||||
worldrenderer.pos(left, top, 0.0D).color(r1, g1, b1, a1).endVertex();
|
||||
worldrenderer.pos(left, bottom, 0.0D).color(r2, g2, b2, a2).endVertex();
|
||||
worldrenderer.pos(right, bottom, 0.0D).color(r2, g2, b2, a2).endVertex();
|
||||
tessellator.draw();
|
||||
GlStateManager.shadeModel(GL11.GL_FLAT);
|
||||
GlStateManager.disableBlend();
|
||||
|
||||
@@ -185,11 +185,11 @@ public class GuiUtils
|
||||
float vScale = 1f / 0x100;
|
||||
Tessellator tessellator = Tessellator.getInstance();
|
||||
WorldRenderer wr = tessellator.getWorldRenderer();
|
||||
wr.func_181668_a(7, DefaultVertexFormats.field_181707_g);
|
||||
wr.func_181662_b(x , y + height, zLevel).func_181673_a( u * uScale, ((v + height) * vScale)).func_181675_d();
|
||||
wr.func_181662_b(x + width, y + height, zLevel).func_181673_a((u + width) * uScale, ((v + height) * vScale)).func_181675_d();
|
||||
wr.func_181662_b(x + width, y , zLevel).func_181673_a((u + width) * uScale, ( v * vScale)).func_181675_d();
|
||||
wr.func_181662_b(x , y , zLevel).func_181673_a( u * uScale, ( v * vScale)).func_181675_d();
|
||||
wr.begin(7, DefaultVertexFormats.POSITION_TEX);
|
||||
wr.pos(x , y + height, zLevel).tex( u * uScale, ((v + height) * vScale)).endVertex();
|
||||
wr.pos(x + width, y + height, zLevel).tex((u + width) * uScale, ((v + height) * vScale)).endVertex();
|
||||
wr.pos(x + width, y , zLevel).tex((u + width) * uScale, ( v * vScale)).endVertex();
|
||||
wr.pos(x , y , zLevel).tex( u * uScale, ( v * vScale)).endVertex();
|
||||
tessellator.draw();
|
||||
}
|
||||
|
||||
|
||||
@@ -112,7 +112,7 @@ import com.google.gson.JsonParser;
|
||||
@SuppressWarnings("unused")
|
||||
public class Loader
|
||||
{
|
||||
public static final String MC_VERSION = "1.8.8";
|
||||
public static final String MC_VERSION = "1.8.9";
|
||||
private static final Splitter DEPENDENCYPARTSPLITTER = Splitter.on(":").omitEmptyStrings().trimResults();
|
||||
private static final Splitter DEPENDENCYSPLITTER = Splitter.on(";").omitEmptyStrings().trimResults();
|
||||
/**
|
||||
|
||||
@@ -49,7 +49,7 @@ public class ModClassLoader extends URLClassLoader
|
||||
public ModClassLoader(ClassLoader parent) {
|
||||
super(new URL[0], null);
|
||||
this.mainClassLoader = (LaunchClassLoader)parent;
|
||||
this.sources = new ArrayList();
|
||||
this.sources = Lists.newArrayList();
|
||||
}
|
||||
|
||||
public void addFile(File modFile) throws MalformedURLException
|
||||
|
||||
+3
-4
@@ -1,19 +1,18 @@
|
||||
package net.minecraftforge.fml.common.network.handshake;
|
||||
|
||||
import io.netty.channel.ChannelFutureListener;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraftforge.fml.common.FMLLog;
|
||||
import net.minecraftforge.fml.common.Loader;
|
||||
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
||||
import net.minecraftforge.fml.common.network.handshake.FMLHandshakeMessage.ServerHello;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLMessage;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLNetworkHandler;
|
||||
import net.minecraftforge.fml.common.registry.GameData;
|
||||
import net.minecraftforge.fml.common.registry.PersistentRegistryManager;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import io.netty.channel.ChannelFutureListener;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
|
||||
/**
|
||||
* Packet handshake sequence manager- client side (responding to remote server)
|
||||
|
||||
+1
-2
@@ -16,14 +16,13 @@ import net.minecraftforge.fml.common.ModContainer;
|
||||
import net.minecraftforge.fml.common.network.ByteBufUtils;
|
||||
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLProxyPacket;
|
||||
import net.minecraftforge.fml.common.registry.GameData;
|
||||
import net.minecraftforge.fml.common.registry.PersistentRegistryManager;
|
||||
|
||||
import com.google.common.base.Charsets;
|
||||
import com.google.common.base.Joiner;
|
||||
import com.google.common.collect.Iterables;
|
||||
import com.google.common.collect.Maps;
|
||||
import com.google.common.collect.Sets;
|
||||
import net.minecraftforge.fml.common.registry.PersistentRegistryManager;
|
||||
|
||||
public abstract class FMLHandshakeMessage {
|
||||
public static FMLProxyPacket makeCustomChannelRegistration(Set<String> channels)
|
||||
|
||||
+3
-3
@@ -1,5 +1,8 @@
|
||||
package net.minecraftforge.fml.common.network.handshake;
|
||||
|
||||
import io.netty.channel.ChannelFutureListener;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
|
||||
import java.util.Iterator;
|
||||
import java.util.Map;
|
||||
import java.util.Map.Entry;
|
||||
@@ -10,11 +13,8 @@ import net.minecraftforge.fml.common.Loader;
|
||||
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLMessage;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLNetworkHandler;
|
||||
import net.minecraftforge.fml.common.registry.GameData;
|
||||
import net.minecraftforge.fml.common.registry.PersistentRegistryManager;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import io.netty.channel.ChannelFutureListener;
|
||||
import io.netty.channel.ChannelHandlerContext;
|
||||
|
||||
enum FMLHandshakeServerState implements IHandshakeState<FMLHandshakeServerState>
|
||||
{
|
||||
|
||||
+3
-4
@@ -18,9 +18,6 @@ import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
|
||||
import net.minecraftforge.fml.common.registry.PersistentRegistryManager;
|
||||
import org.apache.logging.log4j.Level;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayerMP;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.network.EnumConnectionState;
|
||||
@@ -48,9 +45,11 @@ import net.minecraftforge.fml.common.network.PacketLoggingHandler;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLMessage;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLNetworkHandler;
|
||||
import net.minecraftforge.fml.common.network.internal.FMLProxyPacket;
|
||||
import net.minecraftforge.fml.common.registry.GameData;
|
||||
import net.minecraftforge.fml.common.registry.PersistentRegistryManager;
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
|
||||
import org.apache.logging.log4j.Level;
|
||||
|
||||
@SuppressWarnings("rawtypes")
|
||||
public class NetworkDispatcher extends SimpleChannelInboundHandler<Packet> implements ChannelOutboundHandler {
|
||||
private static boolean DEBUG_HANDSHAKE = Boolean.parseBoolean(System.getProperty("fml.debugNetworkHandshake", "false"));
|
||||
|
||||
-2
@@ -149,7 +149,6 @@ public class FMLControlledNamespacedRegistry<I> extends RegistryNamespacedDefaul
|
||||
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
void set(FMLControlledNamespacedRegistry<I> otherRegistry)
|
||||
{
|
||||
if (this.superType != otherRegistry.superType)
|
||||
@@ -623,7 +622,6 @@ public class FMLControlledNamespacedRegistry<I> extends RegistryNamespacedDefaul
|
||||
* This iterator is used by some regular MC methods to visit all blocks, we need to include substitutions
|
||||
* Compare #typeSafeIterable()
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public Iterator<I> iterator()
|
||||
{
|
||||
|
||||
@@ -14,10 +14,6 @@ package net.minecraftforge.fml.common.registry;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import com.google.common.collect.BiMap;
|
||||
import com.google.common.collect.HashBiMap;
|
||||
import com.google.common.collect.Maps;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.item.Item;
|
||||
@@ -29,6 +25,9 @@ import net.minecraftforge.fml.common.FMLLog;
|
||||
import net.minecraftforge.fml.common.Loader;
|
||||
import net.minecraftforge.fml.common.ModContainer;
|
||||
|
||||
import com.google.common.collect.BiMap;
|
||||
import com.google.common.collect.HashBiMap;
|
||||
|
||||
public class GameData
|
||||
{
|
||||
static final int MIN_BLOCK_ID = 0;
|
||||
@@ -214,7 +213,7 @@ public class GameData
|
||||
private static BiMap<Block, Item> BLOCK_TO_ITEM = HashBiMap.create();
|
||||
|
||||
//Internal: DO NOT USE, will change without warning.
|
||||
public static Map getBlockItemMap()
|
||||
public static Map<Block, Item> getBlockItemMap()
|
||||
{
|
||||
return BLOCK_TO_ITEM;
|
||||
}
|
||||
|
||||
@@ -25,17 +25,6 @@ import java.util.Map;
|
||||
import java.util.Random;
|
||||
import java.util.Set;
|
||||
|
||||
import com.google.common.base.Objects;
|
||||
import com.google.common.base.Strings;
|
||||
import com.google.common.base.Throwables;
|
||||
import com.google.common.collect.ImmutableList;
|
||||
import com.google.common.collect.Lists;
|
||||
import com.google.common.collect.Maps;
|
||||
import com.google.common.collect.ObjectArrays;
|
||||
import com.google.common.collect.Sets;
|
||||
import com.google.common.primitives.Ints;
|
||||
import org.apache.logging.log4j.Level;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
@@ -47,7 +36,6 @@ import net.minecraft.nbt.JsonToNBT;
|
||||
import net.minecraft.nbt.NBTBase;
|
||||
import net.minecraft.nbt.NBTException;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.potion.Potion;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.world.World;
|
||||
@@ -60,6 +48,18 @@ import net.minecraftforge.fml.common.LoaderException;
|
||||
import net.minecraftforge.fml.common.LoaderState;
|
||||
import net.minecraftforge.fml.common.ObfuscationReflectionHelper;
|
||||
|
||||
import org.apache.logging.log4j.Level;
|
||||
|
||||
import com.google.common.base.Objects;
|
||||
import com.google.common.base.Strings;
|
||||
import com.google.common.base.Throwables;
|
||||
import com.google.common.collect.ImmutableList;
|
||||
import com.google.common.collect.Lists;
|
||||
import com.google.common.collect.Maps;
|
||||
import com.google.common.collect.ObjectArrays;
|
||||
import com.google.common.collect.Sets;
|
||||
import com.google.common.primitives.Ints;
|
||||
|
||||
public class GameRegistry
|
||||
{
|
||||
private static Set<IWorldGenerator> worldGenerators = Sets.newHashSet();
|
||||
@@ -199,7 +199,6 @@ public class GameRegistry
|
||||
* @param name The mod-unique name to register it as, will get prefixed by your modid.
|
||||
* @param itemCtorArgs Arguments to pass (after the required {@code Block} parameter) to the ItemBlock constructor (optional).
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public static Block registerBlock(Block block, Class<? extends ItemBlock> itemclass, String name, Object... itemCtorArgs)
|
||||
{
|
||||
if (Loader.instance().isInState(LoaderState.CONSTRUCTING))
|
||||
|
||||
@@ -42,7 +42,6 @@ public final class ConsoleCommandCompleter implements Completer
|
||||
}
|
||||
|
||||
final String input = buffer;
|
||||
@SuppressWarnings("unchecked")
|
||||
Future<List<String>> tabComplete = this.server.callFromMainThread(new Callable<List<String>>() {
|
||||
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user