
Yagoki
Members-
Posts
290 -
Joined
-
Last visited
Everything posted by Yagoki
-
[1.6.2]FML doesn't launch when minecraft.jar is modified.
Yagoki replied to bl4ckscor3's topic in Modder Support
you need to wait until they adopt the new way of installing (i.e. with the installer) OR don't use forge (for now), your choice. -
[1.6.2]FML doesn't launch when minecraft.jar is modified.
Yagoki replied to bl4ckscor3's topic in Modder Support
forge no longer allows jar modification http://files.minecraftforge.net/minecraftforge/minecraftforge-changelog-1.6.2-9.10.0.789.txt now just beware of the wrath of Lex -
[1.6.2:Forge 9.10.0.776] Installer miss something
Yagoki replied to Larandar's topic in Support & Bug Reports
I get the same crash http://pastebin.com/zMPTwCEB also fails to de-compile minecraft for MCP (could be user error), can't find logs but will paste the console output http://pastebin.com/G2BqRZeS -
[1.6] Missing getServerData() from Minecraft.java
Yagoki replied to maxpowa's topic in Modder Support
what do you need from the ServerData? there could be other ways to get it. -
update forge. It was obfuscated, but has been fixed now (I updated today and just noticed it had changed from the obfuscated form). If you don't want to update i think it was renderitem.func_110797_b, but just look through the achievements gui code
-
names seem to now be reliant on the texture being found, had this myself. The texture directory has changed from mods/*modid*/textures/blocks||items/texture.png to assets/*modid*/textures/blocks||items/texture.png. Blocks should be added in the preInit now (I have personally always done this makes config cleaner) If you've allready done all this make sure your strings match and your're running the latest forge version, this wasn't working in the early versions for 1.6 look through my github if you need hints on how to do your packages.
-
I can't find where you're creating the getStackInSlot(int var1) method in TileEntityIronWorkBench. My previous response was based on the assumption that this was declared in the super class, but as you're saying that this is not the case (as getStackInSlot(int var1) is an IInventory method) then i don't even know how this is managing to even run in eclipse. a java.lang.AbstractMethodError gets thrown by java when you attempt to call a method which has no method body. i.e. in an interface you create only the method names and parameters, there are no bracers following them. If you do not fill the method in the implementation then this method will be impossible to call giving you the mentioned error http://docs.oracle.com/javase/6/docs/api/java/lang/AbstractMethodError.html
-
error is being caused by this bit, but you should all ready know that. public ItemStack getStackInSlot(int var1) { return var1 >= this.getSizeInventory() ? null : this.parent.getStackInSlot(var1); } try splitting it up like so, and give us the new error report public ItemStack getStackInSlot(int var1) { ItemStack stack = null; if(var1 < this.getSizeInventory()) stack = this.parent.getStackInSlot(var1); // I think error will be thrown here. return stack; } given that it is a java.lang.AbstractMethodError, It is probably that there is an unimplemented method in the class . I'm not definite, but you could try removing any of the unnecessary implementations in the class public class TileEntityIronWorkBench extends TileEntityCommonWorkbench implements IInventory, IBenchHammer, NetworkTileEntityEventListener, NetworkClientTileEntityEventListener i.e. if they are implemented by the super class this could be causing you issues by re-implementing them in the sub class, but again not definite just trying to help. (try removing IInventory for example, as I guess that this is implemented by TileEntityCommonWorkbench, the implementation will carry down to the sub classes so that they can also be called as IInventory without having to re state it)
-
GUI Issue - Buttons rendering behind background .png
Yagoki replied to Zetal's topic in Modder Support
huh... that's odd. Here's my only GUI with buttons & a background, have a look through it if you want as it definitely works https://github.com/Yagoki/MTech/blob/master/MTech/mtech/client/gui/GuiAlter.java important method for this stuff is just the drawScreen method, It's for MC 1.6, but nothing has really changed since 1.5 in this, other than how you bind textures. Also there is a lot of stuff you don't need in this (all the GL11 is because this is fancy ) Also try looking through vanilla classes to see what they do. The only one which springs to mind is the achievements gui, (which the above is a cleaned up ripoff of), but there may be others that you can think of. P.S. sorry if I was a bit offensive/rude in my earlier posts, a touch grumpy after having to update all my classes + real life stuff. -
GUI Issue - Buttons rendering behind background .png
Yagoki replied to Zetal's topic in Modder Support
also there were a few things which could cause problems in your mod, such as how you were adding your buttons (doing this every tick could possible sabotage people (like me) who are running on old/low end PCs, each time you declare a variable in java it has to be given some memory space, doing this every tick slows it down (marginally). If you make it once and save it as local (such as in buttonList) this does not have to be re done every time therefore slightly faster and better coding practice) also you were giving some of them the same ID -
GUI Issue - Buttons rendering behind background .png
Yagoki replied to Zetal's topic in Modder Support
yes, I got that. The re-write was mostly for my benefit when reading it, and to try and be helpful. It "should" fix it, the problem in your code is super.drawScreen(par1, par2, par3); // draws buttons this.drawGuiContainerBackgroundLayer(par3, par1, par2);//draws background this.drawGuiContainerForegroundLayer(par1, par2); // is empty -
GUI Issue - Buttons rendering behind background .png
Yagoki replied to Zetal's topic in Modder Support
Sorry, I don't like having a go at people over messy code but... cleaned it up a bit and removed a few things I couldn't see uses for. Also fixed where your methods should be to the ones which are already provided, so should work. Button rendering gets handled by GuiScreen in drawScreen() so you don't have to deal with that, unless you override the super. try this code, also made it so that yo don't have to rework your entire code if you add another class, just add it to the array. http://pastebin.com/K2p1SnTa -
GUI Issue - Buttons rendering behind background .png
Yagoki replied to Zetal's topic in Modder Support
Can you show us the code/method which actually does all the rendering, perhaps even the whole class so we don't have to chase stuff down later on. If you want an example of a GUI to help you I have three on my guthub (link below, package: mtech.client.gui.*). -
the object type Player is pretty much just an empty object, I think that maybe it is used over EntityPlayer as there is not always a player involved... or something, you probably wont ever have to worry about this, just cast it. Anyway packet handling:https://github.com/Yagoki/MTech/blob/master/MTech/mtech/handler/packet/MyPacketHandler.java
-
[Solved]Multi texture block bug in inventory
Yagoki replied to decebaldecebal's topic in Modder Support
What is the metadata of the block when it's in your hand? given that this is how you call the front texture this should probably be thought about. (I'm guessing 0 and that it is rendering on the bottom of the item) hint: if you want to see the metadata in minecraft (sans NEI), just hold F3 and press H -
could you not just call drawVerticalLine(x, y1, y2, color) and drawHorizontalLine(x1, y, x2, color) to draw each edge individually? seems a lot more simple to me... private static void drawOutlineRect(int x, int y, int x1, int y1, int color) { this.drawHorizontalLine(x, y, x1, color); this.drawHorizontalLine(x, y1 ,x1,color); this.drawVerticalLine(x, y, y1, color); this.drawVerticalLine(x1, y, y1, color); }
-
doesn't disable after the armor has been removed...
-
The exact classes I used there still work for me... (Note this is all from the project I use to test stuff (mostly for this site), so it isn't organized at all)
-
I fixed it at about 00:30 (GMT), and didn't have any internet at that time. Managed to identify it as being badly written vanilla code (in my opinion). There was this line "GL11.glDisable(GL11.GL_TEXTURE_2D);" in the vanilla code which I had to remove. This is (as far as I can tell) has no use in the original code as it then gets re-enabled in a method directly, after which draws the lines between achievements. Just had to remove this line and it's all good. (alternatively I could have put GL11.glEnable(GL11.GL_TEXTURE_2D)) Thanks for the help anyway. By the looks of it you took a similar method to fixing it as I did, The Item render thingi calls GL11.glEnable(GL11.GL_TEXTURE_2D), which is why it fixed it.
-
hmm... close, but no cigar... well that didn't work... It didn't break anything but no progress towards removing the whiteness. good idea though
-
hehe, that's mostly what I did when I made it, just not overly slowly (It was fairly obvious what wasn't needed in the code) I think the problem is most likely to be with binding texture for the frame, given that it overlays the whole gui goes white, bar the button which is drawn just after this: GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glEnable(GL11.GL_BLEND); GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); mc.renderEngine.bindTexture("/achievement/bg.png");//gets the texture drawTexturedModalRect(i1, j1, 0, 0, guiPaneWidth, guiPaneHeight);//draws the relevant parts GL11.glPopMatrix(); zLevel = 0.0F; GL11.glDepthFunc(GL11.GL_LEQUAL); GL11.glDisable(GL11.GL_DEPTH_TEST); GL11.glEnable(GL11.GL_TEXTURE_2D); so the big problem is probably something in that lump of GL11, or something which should get called from the loop rendering the parts, but doesn't because there are no parts to be rendered.