Jump to content

Kwibble

Forge Modder
  • Posts

    340
  • Joined

  • Last visited

Everything posted by Kwibble

  1. You do know there is a way to call, say, CollumStone.getUnlocalizedName().substring(5); to get the name? Because that is what you are supposed to use. And then you can model your texture names after that. I guess if you really wanted to, you could do this: private static String blockName = CollumStone.getLocalizedName(); public static String blockName() { return blockName; } And as I hinted at earlier, your texture names should not be capitalised and have spaces...
  2. Yep. You set the held item to null. But I am pretty sure the drop item method takes care of that itself...
  3. Umm... I was just pointing out why it wasn't working. Sometimes people don't realise simple things. And you don't seem to be a person with English as their first language. No offence. Some people aren't english scholars, but I didn't just write a three hundred page report on why it didn't work.
  4. Now I have a very different and very interesting issue. ArrayIndexOutOfBounds Crash Report: ---- Minecraft Crash Report ---- // On the bright side, I bought you a teddy bear! Time: 7/2/14 4:22 PM Description: Rendering screen java.lang.ArrayIndexOutOfBoundsException: 4 at net.minecraft.entity.player.InventoryPlayer.getStackInSlot(InventoryPlayer.java:648) at net.minecraft.inventory.Slot.getStack(Slot.java:88) at net.minecraft.client.gui.inventory.GuiContainer.func_146977_a(GuiContainer.java:223) at net.minecraft.client.gui.inventory.GuiContainer.drawScreen(GuiContainer.java:118) at com.kwibble.dendri.client.gui.inventory.dendrikbelt.GuiTabMain.drawScreen(GuiTabMain.java:52) at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1145) at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1025) at net.minecraft.client.Minecraft.run(Minecraft.java:912) at net.minecraft.client.main.Main.main(Main.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at net.minecraft.launchwrapper.Launch.launch(Launch.java:134) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- Head -- Stacktrace: at net.minecraft.entity.player.InventoryPlayer.getStackInSlot(InventoryPlayer.java:648) at net.minecraft.inventory.Slot.getStack(Slot.java:88) at net.minecraft.client.gui.inventory.GuiContainer.func_146977_a(GuiContainer.java:223) at net.minecraft.client.gui.inventory.GuiContainer.drawScreen(GuiContainer.java:118) at com.kwibble.dendri.client.gui.inventory.dendrikbelt.GuiTabMain.drawScreen(GuiTabMain.java:52) -- Screen render details -- Details: Screen name: com.kwibble.dendri.client.gui.inventory.dendrikbelt.GuiTabMain Mouse location: Scaled: (148, 48). Absolute: (300, 386) Screen size: Scaled: (427, 240). Absolute: (854, 480). Scale factor of 2 -- Affected level -- Details: Level name: MpServer All players: 1 total; [EntityClientPlayerMP['Kwibble'/247, l='MpServer', x=150.11, y=72.62, z=216.79]] Chunk stats: MultiplayerChunkCache: 225, 225 Level seed: 0 Level generator: ID 00 - default, ver 1. Features enabled: false Level generator options: Level spawn location: World: (212,64,252), Chunk: (at 4,4,12 in 13,15; contains blocks 208,0,240 to 223,255,255), Region: (0,0; contains chunks 0,0 to 31,31, blocks 0,0,0 to 511,255,511) Level time: 164742 game time, 7673 day time Level dimension: 0 Level storage version: 0x00000 - Unknown? Level weather: Rain time: 0 (now: false), thunder time: 0 (now: false) Level game mode: Game mode: creative (ID 1). Hardcore: false. Cheats: false Forced entities: 45 total; [EntityPig['Pig'/69, l='MpServer', x=124.50, y=76.00, z=140.69], EntityPig['Pig'/139, l='MpServer', x=224.19, y=69.00, z=174.53], EntityChicken['Chicken'/70, l='MpServer', x=119.03, y=68.00, z=168.72], EntityChicken['Chicken'/71, l='MpServer', x=117.16, y=70.00, z=185.53], EntityBat['Bat'/64, l='MpServer', x=105.07, y=42.67, z=252.05], EntityPig['Pig'/140, l='MpServer', x=224.25, y=72.00, z=185.97], EntityChicken['Chicken'/76, l='MpServer', x=136.44, y=70.00, z=175.75], EntityPig['Pig'/129, l='MpServer', x=211.38, y=82.00, z=200.03], EntityClientPlayerMP['Kwibble'/247, l='MpServer', x=150.11, y=72.62, z=216.79], EntityPig['Pig'/77, l='MpServer', x=130.75, y=73.00, z=161.53], EntityBat['Bat'/128, l='MpServer', x=210.06, y=16.43, z=171.59], EntityBat['Bat'/78, l='MpServer', x=130.02, y=33.30, z=241.75], EntityChicken['Chicken'/79, l='MpServer', x=131.38, y=62.30, z=285.75], EntityBat['Bat'/72, l='MpServer', x=131.25, y=16.80, z=233.65], EntityBat['Bat'/87, l='MpServer', x=152.43, y=18.55, z=222.98], EntityChicken['Chicken'/94, l='MpServer', x=164.05, y=68.00, z=211.93], EntityBat['Bat'/88, l='MpServer', x=156.78, y=22.10, z=229.78], EntityChicken['Chicken'/31, l='MpServer', x=72.44, y=76.00, z=296.53], EntityBat['Bat'/110, l='MpServer', x=177.47, y=26.10, z=232.47], EntityBat['Bat'/43, l='MpServer', x=93.38, y=24.10, z=139.25], EntityPig['Pig'/108, l='MpServer', x=185.94, y=66.00, z=207.16], EntityPig['Pig'/109, l='MpServer', x=188.97, y=66.00, z=214.03], EntityPig['Pig'/106, l='MpServer', x=180.56, y=74.00, z=155.31], EntityPig['Pig'/46, l='MpServer', x=93.84, y=68.00, z=145.44], EntityChicken['Chicken'/47, l='MpServer', x=81.56, y=73.00, z=147.44], EntityPig['Pig'/107, l='MpServer', x=185.50, y=77.00, z=186.31], EntityPig['Pig'/44, l='MpServer', x=87.25, y=64.00, z=139.53], EntityPig['Pig'/51, l='MpServer', x=94.53, y=65.00, z=206.50], EntityPig['Pig'/50, l='MpServer', x=90.50, y=63.00, z=189.80], EntityChicken['Chicken'/118, l='MpServer', x=198.72, y=64.38, z=214.19], EntityPig['Pig'/49, l='MpServer', x=96.53, y=67.00, z=171.69], EntityPig['Pig'/117, l='MpServer', x=199.66, y=81.00, z=177.50], EntityBat['Bat'/48, l='MpServer', x=85.44, y=17.89, z=172.58], EntityPig['Pig'/53, l='MpServer', x=93.03, y=64.00, z=208.50], EntitySheep['Sheep'/52, l='MpServer', x=92.91, y=63.00, z=217.41], EntitySheep['Sheep'/59, l='MpServer', x=108.56, y=64.00, z=163.44], EntityBat['Bat'/127, l='MpServer', x=210.58, y=16.05, z=163.13], EntityPig['Pig'/126, l='MpServer', x=219.25, y=74.00, z=151.69], EntityPig['Pig'/58, l='MpServer', x=99.78, y=67.00, z=148.50], EntitySheep['Sheep'/57, l='MpServer', x=101.06, y=68.00, z=141.56], EntityBat['Bat'/125, l='MpServer', x=215.41, y=18.10, z=148.72], EntitySheep['Sheep'/63, l='MpServer', x=98.53, y=67.00, z=237.56], EntityItem['item.item.porkchopRaw'/62, l='MpServer', x=99.88, y=41.13, z=204.88], EntityPig['Pig'/61, l='MpServer', x=104.19, y=46.00, z=194.63], EntityChicken['Chicken'/60, l='MpServer', x=104.59, y=65.00, z=170.56]] Retry entities: 0 total; [] Server brand: fml,forge Server type: Integrated singleplayer server Stacktrace: at net.minecraft.client.multiplayer.WorldClient.addWorldInfoToCrashReport(WorldClient.java:412) at net.minecraft.client.Minecraft.addGraphicsAndWorldToCrashReport(Minecraft.java:2524) at net.minecraft.client.Minecraft.run(Minecraft.java:933) at net.minecraft.client.main.Main.main(Main.java:112) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at net.minecraft.launchwrapper.Launch.launch(Launch.java:134) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) -- System Details -- Details: Minecraft Version: 1.7.2 Operating System: Mac OS X (x86_64) version 10.8.5 Java Version: 1.6.0_65, Apple Inc. Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Apple Inc. Memory: 891961120 bytes (850 MB) / 1065025536 bytes (1015 MB) up to 1065025536 bytes (1015 MB) JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M AABB Pool Size: 11555 (647080 bytes; 0 MB) allocated, 589 (32984 bytes; 0 MB) used IntCache: cache: 11, tcache: 0, allocated: 13, tallocated: 95 FML: MCP v9.03 FML v7.2.211.1121 Minecraft Forge 10.12.2.1121 4 mods loaded, 4 mods active mcp{9.03} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available FML{7.2.211.1121} [Forge Mod Loader] (forgeSrc-1.7.2-10.12.2.1121.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available Forge{10.12.2.1121} [Minecraft Forge] (forgeSrc-1.7.2-10.12.2.1121.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available dendri{1.7.2_0.0.1} [Dendri] (ModuleDendri) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available Launched Version: 1.7 LWJGL: 2.9.1 OpenGL: Intel HD Graphics 4000 OpenGL Engine GL version 2.1 INTEL-8.16.74, Intel Inc. Is Modded: Definitely; Client brand changed to 'fml,forge' Type: Client (map_client.txt) Resource Packs: [] Current Language: English (US) Profiler Position: N/A (disabled) Vec3 Pool Size: 777 (43512 bytes; 0 MB) allocated, 141 (7896 bytes; 0 MB) used Anisotropic Filtering: Off (1) #@!@# Game crashed! Crash report saved to: #@!@# /Volumes/Data/Users/102676/Developer/IDEA/MinecraftModding/MCCLIENT/./crash-reports/crash-2014-07-02_16.22.40-client.txt Disconnected from the target VM, address: '127.0.0.1:52997', transport: 'socket' AL lib: (EE) alc_cleanup: 1 device not closed Process finished with exit code 255 But what is really confusing me is this. Here is the inventorySlots list: 41 Slot 0: com.kwibble.dendri.inventory.SlotDendrikBelt@460cb578 Slot 1: com.kwibble.dendri.inventory.dendrikbelt.SlotMistBottle@6c5dfd35 Slot 2: com.kwibble.dendri.inventory.dendrikbelt.SlotMistBottle@e9ada28 Slot 3: com.kwibble.dendri.inventory.dendrikbelt.SlotMistBottle@58687f95 Slot 4: com.kwibble.dendri.inventory.dendrikbelt.SlotMistBottle@34903c8b Slot 5: net.minecraft.inventory.Slot@6976e4a2 Slot 6: net.minecraft.inventory.Slot@7c9c7dc5 Slot 7: net.minecraft.inventory.Slot@605506d Slot 8: net.minecraft.inventory.Slot@46e32731 Slot 9: net.minecraft.inventory.Slot@6b222652 Slot 10: net.minecraft.inventory.Slot@f020871 Slot 11: net.minecraft.inventory.Slot@4e783a69 Slot 12: net.minecraft.inventory.Slot@3742ebbe Slot 13: net.minecraft.inventory.Slot@a83234a Slot 14: net.minecraft.inventory.Slot@2781d4aa Slot 15: net.minecraft.inventory.Slot@3cb0f929 Slot 16: net.minecraft.inventory.Slot@6b611e0 Slot 17: net.minecraft.inventory.Slot@1b4f8c91 Slot 18: net.minecraft.inventory.Slot@3959199 Slot 19: net.minecraft.inventory.Slot@5089d5a5 Slot 20: net.minecraft.inventory.Slot@9296cf2 Slot 21: net.minecraft.inventory.Slot@7eaf8890 Slot 22: net.minecraft.inventory.Slot@362ee6ea Slot 23: net.minecraft.inventory.Slot@413a2870 Slot 24: net.minecraft.inventory.Slot@5134f284 Slot 25: net.minecraft.inventory.Slot@6b1de1c2 Slot 26: net.minecraft.inventory.Slot@76d0be7e Slot 27: net.minecraft.inventory.Slot@28a7f23 Slot 28: net.minecraft.inventory.Slot@52a0d422 Slot 29: net.minecraft.inventory.Slot@3cc72e8f Slot 30: net.minecraft.inventory.Slot@38c1cd75 Slot 31: net.minecraft.inventory.Slot@3b97d96f Slot 32: net.minecraft.inventory.Slot@6e4424f9 Slot 33: net.minecraft.inventory.Slot@3bd78ffd Slot 34: net.minecraft.inventory.Slot@452e49bc Slot 35: net.minecraft.inventory.Slot@61eaf91f Slot 36: net.minecraft.inventory.Slot@9899472 Slot 37: net.minecraft.inventory.Slot@2770cd42 Slot 38: net.minecraft.inventory.Slot@5eb3bc48 Slot 39: net.minecraft.inventory.Slot@6a0e4b8a Slot 40: net.minecraft.inventory.Slot@5081876b As you can see my custom slot is at index 4. But it is trying to read from the player's inventory. Any ideas/suggestions?
  5. You check to see if its server world before you add the enchantment... Also, you can add the enchanted item as the output of the recipe.
  6. Maybe if you copied all the chained methods that the leaves block uses normally? (the ones used when Minecraft first registers it in the Block class?) I am not sure if you have already done so, but it could be worth a try.
  7. The reason the client world crashes is because the server knows nothing about any client side code. Minecraft class? Poof. Nothing. Does not exist on the server. Have you tried what is in that link I posted except with world versions instead?
  8. And from your "60% worthless" post right there I assume you just copy/pasted the exact same code you had in the event handler. So of course its not going to work. As diesieben07 kindly told you: So you need to use the parameters given in the method, but first surround it all with a check to see if the world is server side world.
  9. Quick question die: Is it preferable to use pastebin/github over using code/spoiler tags?
  10. Either this is being called before the player actually spawns, or the players held item is null. Also, why aren't you using the onUpdate method in your custom item class? It gets called whenever the item is in the players inventory which means you could do your check from there.
  11. Next question: What blocks do you have that could be knocking the door back to the ground??
  12. I'll test it out tomorrow and get back to you. That, or someone else will help you solve it first
  13. Very nice! That is pretty much a combination of metadata and just storing the rotation... Good job
  14. Okay... @Override public void writeToNBT(NBTTagCompound nbt) { nbt.setInteger("ovenDirection", this.direction); } @Override public void readFromNBT(NBTTagCompound nbt) { this.direction = nbt.getInteger("ovenDirection"); } That should do it...
  15. * Kwibble has a major facepalm moment * Thanks for that... Lack of sleep on my part? Thanks for pointing that out.
  16. ... The params are this: Angle, X, Y, Z So you would want this: GL11.glRotatef(tileEntity.direction * (-90), 0.0F, 1.0F, 0.0F); Is that the ONLY rotation call you have? And does it look like that one above?
  17. That was the topic I was referring too. And did I say search? (I find that search bar to be horribly unreliable >.>) Anyway, glad you solved it - and welcome to the forums!
  18. Well, I guess it would be easiest to save to NBT then At any rate: There are two NBT methods for your tile entity - a method that loads the nbt, and a method that saves the nbt. You will want both: @Override public void writeToNBT(NBTTagCompound nbt) { } @Override public void readFromNBT(NBTTagCompound nbt) { } Now. Every NBTTagCompound has methods for writing primitive types: so ints, strings, bytes, everything you need! When saving these are used as such: nbtTagInstance.set***("identifierString", variable); // Where *** is the type you want to save (e.g. Integer), identifierString is the the string which identifies this value, and variable which is the variable you want to store For loading: variable = nbt.get***("identifierString"); // Where *** is the type you want to load (e.g. Integer), identiferString is the string used to save the variable (MUST BE THE SAME), and variable is the variable you want to load the saved value to P.S. Welcome to the forums
  19. Please browse the forums a bit first... There was a topic already made on this issue. I believe it will be in page 2 or 3 of Modder Support by now. Please look through there.
  20. Well, which would you prefer? Storing your already made direction value in nbt, or rewriting the code so that it has metadata?
  21. Hey TGG, remind you of I post I made a while back? Lemme find it... [EDIT] Okay, found it. http://www.minecraftforge.net/forum/index.php/topic,20383.0.html
  22. And as another thing - you don't save your direction variable to NBT or anything. So of course its going to be a default direction.
  23. I think you will find blocks such as this are metadata blocks - a new metadata for each direction faced with metadata 0 being the default direction.
  24. Are you sure? You need to rotate on the Y axis. I double edited...
  25. I am going to say this: Try the x axis instead and come back and say what happened. If it worked, great, if it didn't... We will be in touch. [EDIT] Rotate on the y axis - as weird as that sounds. Scratch my earlier statement. I got confused.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.