-
Posts
751 -
Joined
-
Last visited
Everything posted by ObsequiousNewt
-
s/.bat/.sh/g
-
Item.blah.getIconFromDamage(meta); RegisterIcon only accepts a string though, so I guess I need to use a different method to get my textures? Also, is it possible to have one class for multiple items that does this, with a different texture per item? How would I differentiate the items, as they all have different IDs? No, like this: public Icon getIconFromDamage(meta){ return Item.blah.getIconFromDamage(meta); //or switch, if you want to differentiate between meta } No registration necessary.
-
[Unsolved] How to make an armor using Forge for SMP?
ObsequiousNewt replied to Soviet's topic in Modder Support
Line 56 of Alloycraft is...? -
The GuiHandler is probably correct since it's erroring in the container, which only gets opened after GuiHandler. (Conclusion: Post your Container, but it doesn't hurt to post the GuiHandler as well). Well, my only guess is that he had his GUI IDs wrong. Ah well.
-
Where are you getting those player and world objects? And are you using Minecraft.theMinecraft?
-
(solved)Custom Fishing Rod not retracting
ObsequiousNewt replied to Xwaffle's topic in Modder Support
Could we see the item class? Methinks the problem lies in creating the rod. -
Fixed that now, didn't change anything =/ The recipes were staying inside anyway, so that's quite strange. I removed that anyway, doesn't seem to have changed anything but at least I don't have a bit of useless code now Ah, you seemed to imply that they weren't. Anyway. Is the output actually being set? I notice that, while you have your own recipe classes defined, they don't seem to be getting used by your crafting manager.
-
[UNSOLVED]In game overlay text drawing size
ObsequiousNewt replied to mickey695's topic in Modder Support
There are so many things there that could be null. Split each field up into its own line and see which line it crashes at. -
config.get(Configuration.CATEGORY_BLOCK, "Test",400).getInt(); You're never actually setting your ID variable. Which would seem to imply that your block is getting set to 0. Which means that all the air in the world explodes and crashes your game. That would be my guess.
-
What is the variable's value when you try to use it?
-
IGuiHandler code, please.
-
Item.blah.getIconFromDamage(meta);
-
*EntityEnderEye
-
Establishing a Connection to FML Server
ObsequiousNewt replied to vbisbest's topic in Modder Support
Erm, doesn't Forge already do that? -
Looking for a modder to help make mod, will pay up to 100$
ObsequiousNewt replied to gabinthal's topic in Modder Support
A laudable opinion. Also, this thread should probably go in Mods or General Discussion. -
[SOLVED] Reading NBT data from TileEntityRenderer
ObsequiousNewt replied to DanGovier's topic in Modder Support
Yes. The first argument in TESR.renderTileEntityAt() is the TE to be rendered. So instead of creating side* fields in your TESR and using if (this.side0 == 0){ ... this.panel0.render((Entity)null, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0625F); you can just use if (te.side0 == 0){ ... this.panel0.render((Entity)null, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0625F); Note: you will have to cast your TE first. -
First of all, you have only 25 slots in your TE, so you're excluding the output. Secondly, re "items should STAY inside", you have redefined onCraftGUIClosed() in your container code so that they won't. I assume you copied ContainerWorkbench or something... at any rate, remove that. As to why your recipes don't work... if it persists after you add the output slot, I'll look at your recipe classes. I don't see any reason why they shouldn't work, but I haven't actually examined them.
-
[Unsolved]Custom modeled block doesn't show up in inventory
ObsequiousNewt replied to TwinAndy's topic in Modder Support
How about just a simple "thank you"? Anyway, since you didn't provide the code for the model, I couldn't test it, so I just copied and pasted your code. (Like I expected you would have tried on your own...) Add this to the FryerRenderer class I made for you. -snip- Also, I don't think you need to do two glPushMatrix()'s since you aren't doing anything special to your model between the second one and the first glPopMatrix(); one pair should be good enough. It doesn't work. Im sorry that i didn't gave you a model. ModelFryer package TwinAndysMods.SomeLittleThingsMod; import net.minecraft.client.model.ModelBase; import net.minecraft.client.model.ModelRenderer; import net.minecraft.entity.Entity; public class ModelFryer extends ModelBase { //fields ModelRenderer Shape1; ModelRenderer Shape2; ModelRenderer Shape3; ModelRenderer Shape4; ModelRenderer Shape5; ModelRenderer Shape6; ModelRenderer Shape7; ModelRenderer Shape8; ModelRenderer Shape9; ModelRenderer Shape10; ModelRenderer Shape11; ModelRenderer Shape12; public ModelFryer() { textureWidth = 64; textureHeight = 32; Shape1 = new ModelRenderer(this, 0, 0); Shape1.addBox(0F, 0F, 0F, 13, 1, 9); Shape1.setRotationPoint(-8F, 23F, -4F); Shape1.setTextureSize(64, 32); Shape1.mirror = true; setRotation(Shape1, 0F, 0F, 0F); Shape2 = new ModelRenderer(this, 0, 12); Shape2.addBox(0F, 0F, 0F, 1, 5, 9); Shape2.setRotationPoint(4F, 18F, -4F); Shape2.setTextureSize(64, 32); Shape2.mirror = true; setRotation(Shape2, 0F, 0F, 0F); Shape3 = new ModelRenderer(this, 44, 1); Shape3.addBox(0F, 0F, 0F, 1, 9, 9); Shape3.setRotationPoint(-8F, 14F, -4F); Shape3.setTextureSize(64, 32); Shape3.mirror = true; setRotation(Shape3, 0F, 0F, 0F); Shape4 = new ModelRenderer(this, 32, 26); Shape4.addBox(0F, 0F, 0F, 11, 5, 1); Shape4.setRotationPoint(-7F, 18F, 4F); Shape4.setTextureSize(64, 32); Shape4.mirror = true; setRotation(Shape4, 0F, 0F, 0F); Shape5 = new ModelRenderer(this, 32, 26); Shape5.addBox(0F, 0F, 0F, 11, 5, 1); Shape5.setRotationPoint(-7F, 18F, -4F); Shape5.setTextureSize(64, 32); Shape5.mirror = true; setRotation(Shape5, 0F, 0F, 0F); Shape6 = new ModelRenderer(this, 32, 19); Shape6.addBox(0F, 0F, 0F, 10, 1, 6); Shape6.setRotationPoint(-6.5F, 21F, -2.5F); Shape6.setTextureSize(64, 32); Shape6.mirror = true; setRotation(Shape6, 0F, 0F, 0F); Shape7 = new ModelRenderer(this, 0, 28); Shape7.addBox(0F, 0F, 0F, 10, 3, 1); Shape7.setRotationPoint(-6.5F, 18F, -2.5F); Shape7.setTextureSize(64, 32); Shape7.mirror = true; setRotation(Shape7, 0F, 0F, 0F); Shape8 = new ModelRenderer(this, 0, 28); Shape8.addBox(0F, 0F, 0F, 10, 3, 1); Shape8.setRotationPoint(-6.5F, 18F, 2.5F); Shape8.setTextureSize(64, 32); Shape8.mirror = true; setRotation(Shape8, 0F, 0F, 0F); Shape9 = new ModelRenderer(this, 22, 25); Shape9.addBox(0F, 0F, 0F, 1, 3, 4); Shape9.setRotationPoint(2.5F, 18F, -1.5F); Shape9.setTextureSize(64, 32); Shape9.mirror = true; setRotation(Shape9, 0F, 0F, 0F); Shape10 = new ModelRenderer(this, 22, 25); Shape10.addBox(0F, 0F, 0F, 1, 3, 4); Shape10.setRotationPoint(-6.5F, 18F, -1.5F); Shape10.setTextureSize(64, 32); Shape10.mirror = true; setRotation(Shape10, 0F, 0F, 0F); Shape11 = new ModelRenderer(this, 13, 11); Shape11.addBox(0F, 0F, 0F, 11, 0, 7); Shape11.setRotationPoint(-7F, 19F, -3F); Shape11.setTextureSize(64, 32); Shape11.mirror = true; setRotation(Shape11, 0F, 0F, 0F); Shape12 = new ModelRenderer(this, 0, 26); Shape12.addBox(0F, 0F, 0F, 6, 1, 1); Shape12.setRotationPoint(2.5F, 17F, 0F); Shape12.setTextureSize(64, 32); Shape12.mirror = true; setRotation(Shape12, 0F, 0F, 0F); } public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5) { super.render(entity, f, f1, f2, f3, f4, f5); setRotationAngles(f, f1, f2, f3, f4, f5); Shape1.render(f5); Shape2.render(f5); Shape3.render(f5); Shape4.render(f5); Shape5.render(f5); Shape6.render(f5); Shape7.render(f5); Shape8.render(f5); Shape9.render(f5); Shape10.render(f5); Shape11.render(f5); Shape12.render(f5); } public void renderAll(float f5){ Shape1.render(f5); Shape2.render(f5); Shape3.render(f5); Shape4.render(f5); Shape5.render(f5); Shape6.render(f5); Shape7.render(f5); Shape8.render(f5); Shape9.render(f5); Shape10.render(f5); Shape11.render(f5); Shape12.render(f5); } private void setRotation(ModelRenderer model, float x, float y, float z) { model.rotateAngleX = x; model.rotateAngleY = y; model.rotateAngleZ = z; } public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5) { } } FryerRenderer package TwinAndysMods.SomeLittleThingsMod; import net.minecraft.item.ItemStack; import net.minecraftforge.client.IItemRenderer; import org.lwjgl.opengl.GL11; public class FryerRenderer implements IItemRenderer { @Override public boolean handleRenderType(ItemStack item, ItemRenderType type) { return true; } @Override public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { return true; } @Override public void renderItem(ItemRenderType type, ItemStack item, Object... data) { switch(type) { case INVENTORY: { renderModelFryer(); return; } default: return; } } private ModelFryer aModel; public FryerRenderer() { aModel = new ModelFryer(); } private void renderModelFryer() { GL11.glPushMatrix(); GL11.glTranslatef(0.0F, 0.0F, 0.0F); // play around with these numbers until you get it where you want it. (should work by itself) GL11.glRotatef(180F, 0F, 0F, 1F); bindTextureByName("/textures/blocks/FryerTexture.png"); aModel.renderAll(0.0625F); GL11.glPopMatrix(); } private void bindTextureByName(String string) { } } I think i did something wron with the bindTextureByName.... I already gave you a thank you but if you still want to help me out a bit. I'll daresay you did. This probably isn't right, but try Minecraft.theMinecraft.renderEngine.bindTexture("..."); instead. -
When you remove what the effect remains? The code? The item?
-
Send me the file. I'll bet you a virtual cookie it's not actually Vorbis.
-
[Help][unsolved]Zooming with Item in hand[1.5.2]
ObsequiousNewt replied to kaikaii99's topic in Modder Support
Firstly, learn to use "else". Secondly, I notice your zoom code is inside the "if(type.contains(TickType.RENDER)){" in the first version, but outside it in the second. -
Syncing client tile entity data with server? [SOLVED]
ObsequiousNewt replied to QuantumLeaf7895's topic in Modder Support
If it renders as a normal block, you can't use TE data. -
[Unresolved] Multi-input output furnace
ObsequiousNewt replied to mrminecraftiful's topic in Modder Support
I did point you in the right direction. Use a HashMap. Probably a HashMap<Integer[],ItemStack[]>, where you put the id/meta/amount args as the key and the outputs as the value.