Everything posted by BlazeAxtrius
-
1.8 CreativeTabs crash
It shows an error "The method onMinecartPass must override or implement a supertype method. Solutions shown are "Create onMinecartPass() in super type AllRails" "Create onMinecartPass() in super type ExpandedRails" "Remove @Override annotation"
-
1.8 CreativeTabs crash
public void onMinecartPass(World world, EntityMinecart cart, BlockPos pos1, int x, int y, int z) { if (world.getBlockState(pos1).getBlock() == ERMBase.armedRail) { IBlockState blockMetaData = world.getBlockState(pos1); world.createExplosion(cart, x, y, z, 0.3F, false); world.newExplosion(cart, x, y, z, 3.5F, true, true); } } I changed the code in this and it doesn't show any errors, but this rail is supposed to explode when the cart passes it, which it doesn't do. I don't understand why it doesn't explode. Also I don't know how to fix this or do i even need it. The BOLD part. public void onMinecartPass(World world, EntityMinecart cart, BlockPos pos1, int x, int y, int z) { IBlockState blockMetaData = world.getBlockState(pos1); [b]if ((blockMetaData & 0x8) == 0)[/b] { { cart.motionX *= 3.5D; cart.motionY *= 0.0D; cart.motionZ *= 3.5D; } }
-
1.8 CreativeTabs crash
God damn. I wonder what a BlockPos is... you description is really accurate . I don't know how to write it man. public void onMinecartPass(World world, EntityMinecart cart, int x, int y, int z) It doesn't accept "int" when i put .getBlockState.
-
1.8 CreativeTabs crash
It might have something to do with getBlockState.... I read something about that, however with .getBlockState I don't know how to make it work. .getBlockState requires (blockpos1) but my method uses (x, y, z) and it doesn't work this way. Also the Tabs names are (itemgroup.NoralmRails). How can I remove the "itemgroup." thing?
-
1.8 CreativeTabs crash
Ok. I fixed it. I am extremely retarded. I was using "rails" that i have excluded from the mod because I don't know how to fix .getBlock and .getBlockMetadata. Some rails have properties and I have excluded them so I can fix the rest that just rails. If you can help me fix that too that will be great. Here is how a rail with properties looks. I put 2 because one of them didn't have .getBlock. package com.expanded.rails.mod.rails; import net.minecraft.block.Block; import net.minecraft.entity.item.EntityMinecart; import net.minecraft.world.World; public class DiamondRail extends AllRails { public DiamondRail(int par1) { super(par1); setHardness(0.7F); setStepSound(Block.soundTypeMetal); setUnlocalizedName("expandedrails:DiamondRail"); // TODO Auto-generated constructor stub } public float getRailMaxSpeed(World world, EntityMinecart cart, int y, int x, int z) { return 0.5f; } public void onMinecartPass(World world, EntityMinecart cart, int x, int y, int z) { int blockMetaData = world.[b]getBlockMetadata[/b](x, y, z); if ((blockMetaData & 0x8) == 0) { { cart.motionX *= 3.5D; cart.motionY *= 0.0D; cart.motionZ *= 3.5D; } } } } package com.expanded.rails.mod.rails; import net.minecraft.block.Block; import net.minecraft.entity.item.EntityMinecart; import net.minecraft.world.World; import com.expanded.rails.mod.ERMBase; public class ArmedRail extends AllRails { public ArmedRail(int par1) { super(par1); setHardness(0.7F); setStepSound(Block.soundTypeMetal); setUnlocalizedName("expandedrails:ArmedRail"); // TODO Auto-generated constructor stub } public void onMinecartPass(World world, EntityMinecart cart, int x, int y, int z) { if ([b]world.getBlock[/b](x, y, z) == ERMBase.armedRail) { int blockMetaData = [b]world.getBlockMetadata[/b](x, y, z); world.createExplosion(cart, x, y, z, 0.3F, false); world.newExplosion(cart, x, y, z, 3.5F, true, true); } } }
-
1.8 CreativeTabs crash
I have the felling that it is this one The Item getTabIconItem() I put in because i was getting an error for missing variables. but in 1.6.4 and 1.7.x it was working even when this method was returning null;
-
1.8 CreativeTabs crash
I changed the code however the game still crashed when I click the arrow that leads to my customtabs. Eclipse doesn't show any errors. public static final CreativeTabs tabNormalRails = new CreativeTabs(modid+"tabNormalRails") { public Item getTabIconItem() { // TODO Auto-generated method stub return Item.getItemFromBlock(diamondRail); } your getIconItemStack() method does nothing because no code ever calls it. When your creative tab is rendered, it calls the getTabIconItem() method to find out which Item's icon it should draw on the tab. You return null, the caller tries to draw it, and crashes because it expects a proper item. Your getTabIconItem() method needs to return the block's corresponding item as Voltab suggested. Which tutorial did you use? -TGG i have no memory. I updated to the mod to 1.6.4 (that was 1 year ago) and then i decided to make the Tabs. I changed my PC so I don't have it in my history otherwise it was going to be easy.
-
1.8 CreativeTabs crash
Its a block. I used a tutorial to make it. The idea is that these rails are blocks and not items. That is why Item getTabIconItem() doesn't work and I use the ItemStack getIconItemStack() Here is my github btw. https://github.com/BlazeAxtrius/ExpandedRailsMod
-
1.8 CreativeTabs crash
public static final CreativeTabs tabNormalRails = new CreativeTabs(modid+"tabNormalRails") { public ItemStack getIconItemStack() { return new ItemStack(ERMBase.diamondRail, 1, 0); } @Override public Item getTabIconItem() { // TODO Auto-generated method stub return null; } The game start normally but when I try to get to the second page in the inventory, the game crashes. This code is in the main mod file.
-
[1.7.2] Custom minecart
Yeah I am not good with entities at all. I dont understand them.
-
[1.7.2] Custom minecart
So after I fixed my mod, I decided to make a custom minecart. Everything is great I made the item, I set the texture and it works.(i can place it and use it) but I cant change the texture in-game. Meaning in the inventory for example its a white minecart but when i place it, it has the normal texture. How can i fix this?
-
[Forge 1.7.2] Custom crafting table help
Well thank you for the help with the github and textures. I managed to fix my crafting table with the help of this. - https://github.com/NealeGaming/nealecraft/tree/master/net/nealecraft/mod Thank you everyone and have a nice day.
-
[Forge 1.7.2] Custom crafting table help
Finally I fixed all the textures. Now just the crafting table is left.
-
[Forge 1.7.2] Custom crafting table help
If you mean the "public static int ...ID;" and "...RailID = cofig.get..." if i remove any of them or try to change them well then the game doesnt run. I get this "java.lang.IllegalArgumentException: Illegal object for naming null" Ah nvm I did something worng that is why it didnt work. P.S: I changed it. I guess that is what you meant.
-
[Forge 1.7.2] Custom crafting table help
Ok. How is that?
-
[Forge 1.7.2] Custom crafting table help
I am not sure but I think I made what you asked. Also thank you for fixing my texture problem. After I made the AllRails class that fixed everything. Thanks for the idea.
-
[Forge 1.7.2] Custom crafting table help
I am trying to make 1 class that has all the code for the texture and just make all rails from the ERMBase class be linked with it. I have a problem tho because all rails dont have textures when they are turned. Now however when I made this new class it worked. 1 of the rails has all the textures the ArmedRail. So why is that when the code is exactly the same as before? Also I am not sure if that is what you meant but I dont think I will be able to do it on my own.
-
[Forge 1.7.2] Custom crafting table help
I see that but the way you are trying to do it is ... weird. I need explanation how to make it more readable. From my eyes it is good but obviously it isn't.
-
[Forge 1.7.2] Custom crafting table help
Thanks a lot for the help. I still have 0 idea what I have to do. Guess I have to asking people for help cause it seems no one gives a damn about other people. Because ,you know, saying in simple words is too mainstream. Lets make it difficult for the person that obviously doesnt know what to do.
-
[Forge 1.7.2] Custom crafting table help
I dont know how to clean it up and even if i did I already made it this way. I prefer it this way. I is 1 million times easier for me. I know where everything is and it is easy to find. What is so messy about it? Please enlighten me.
-
[Forge 1.7.2] Custom crafting table help
What exactly do i have to learn about it?
-
[Forge 1.7.2] Custom crafting table help
bump
-
[Forge 1.7.2] Custom crafting table help
So I made a custom crafting table for 1.6.4 when it came out. Now i am trying to update my mod for 1.7.2 but the crafting table doesnt seem to work. I put the recipe in it and it doesnt give me a result. I have looked at a tutorial about crafting table 1.7.2 and I made everything the tutorial said. I hope I didnt miss anything but I watched this - Here is my github - https://github.com/BlazeAxtrius/ExpandedRailsMod Please help.
-
[1.6.4][1.6.2][1.5.2] [Forge] [SSP/SMP] Expanded Rails Mod v1.3
More rails are added (Triple rails) Have fun.
-
cpw.mods.fml.common.LoaderException: java.lang.ClassNotFoundException
I finally made it. Thanks for the help.
IPS spam blocked by CleanTalk.