Everything posted by Eternaldoom
- 
	
		
		[SOLVED]Ore harvest level question
		
		The harvest levels are defined in the item's ToolMaterial. I think they are the first number. The ToolMaterials can be found in Item. Note that the diamond material is called emerald.
 - 
	
		
		[1.7.10] Rotate an Item's texture in inventory?
		
		I have a problem now. It renders correctly in the inventory, but often has a weird colored background. Any ideas how to fix this? Here is my Item Renderer code: public class ItemRendererCannon implements IItemRenderer{ public static RenderItem renderitem = new RenderItem(); @Override public boolean handleRenderType(ItemStack item, ItemRenderType type) { switch (type) { case EQUIPPED: return false; case EQUIPPED_FIRST_PERSON: return false; case ENTITY: return false; case INVENTORY: return true; default: return false; } } @Override public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { return false; } @Override public void renderItem(ItemRenderType type, ItemStack item, Object... data) { switch(type){ case EQUIPPED: break; case EQUIPPED_FIRST_PERSON: break; case ENTITY: break; case INVENTORY: Draw2D(item); break; default: break; } } public void Draw2D(ItemStack item){ IIcon icon = item.getItem().getIcon(item, 0); Tessellator tessellator = Tessellator.instance; tessellator.startDrawingQuads(); double minU1 = (double)icon.getMinU(); double minV1 = (double)icon.getMinV(); double maxU1 = (double)icon.getMaxU(); double maxV1 = (double)icon.getMaxV(); tessellator.addVertexWithUV(16.0, 16.0, 0.0, minU1, maxV1); tessellator.addVertexWithUV(16.0, 0.0, 0.0, maxU1, maxV1); tessellator.addVertexWithUV( 0.0, 0.0, 0.0, maxU1, minV1); tessellator.addVertexWithUV( 0.0, 16.0, 0.0, minU1, minV1); tessellator.draw(); } } There is a screenshot at https://cloud.githubusercontent.com/assets/6693944/4097725/b5ba9626-2fe0-11e4-91e3-952fcab11ca9.png Note the colored background of the items in the hotbar. Any idea how to fix this? It it caused by messing with the image vertices?
 - 
	
		
		ForgeSubscribe and Overriding Vanilla Systems
		
		Yes, use SubscribeEvent. It should be pretty similar with mobs.
 - 
	
		
		How to set up an avatar on Forge Forums?
		
		That worked thanks!
 - 
	
		
		Why does my custom mob move so slowly?
		
		You need to override applyEntityAttributes(). In that method, add this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(some speed);
 - 
	
		
		[1.7.10] Error when loading new modeled blocks. [SOLVED]
		
		Get rid of the first Shape5.mirror=true in your model. Btw, does your mod have a github repo? I'd love to contribute
 - 
	
		
		Generating custom crops in Villager Farms
		
		I think you have to use some kind of terrain generation event.
 - 
	
		
		[1.7.10] (SOLVED) issue with colour codes
		
		Use EnumChatFormatting.YOURCOLOR + "your string"
 - 
	
		
		[1.7.2] How to make a new arrow?
		
		https://github.com/Eternaldoom/Realms-of-Chaos/blob/master/com/eternaldoom/realmsofchaos/entity/projectile/EntityHeliotropeArrow.java. Basically I just copied and pasted the vanilla one and changed a few methods.
 - 
	
		
		[SOLVED]Sorry for more of a git question
		
		Use src/main/java as a source folder instead of src.
 - 
	
		
		[1.7.10] Event Armor Equipped ?
		
		You mean right when you put on armor? I don't think there is an event for that, but it would be easy to detect.
 - 
	
		
		[1.7.2] Rebind texture from a different class
		
		What part do you not understand? Also, post your code.
 - 
	
		
		Mac Installation Issues (Disclaimer: First Post!)
		
		After gradlew setupDecompWorkspace run gradlew eclipse. That generates the eclipse project files. That bootstrap class path warning is harmless, I get it all the time.
 - 
	
		
		[1.7.10]How do I use the new skin format with my custom mob?
		
		Look at ModelBiped and the other Model classes. You can use Techne to model it and generate the code. The main problem would be making all of the texture offsets match the new skin layout.
 - 
	
		
		[1.7.10] custom flowers are not spawning in custom biome
		
		Make your own WorldGenFlowers class that accepts metadata as a parameter. Here is one you can copy and paste: public class ModWorldGenFlowers extends WorldGenerator { private Block flower; private int meta; public ModWorldGenFlowers(Block flower, int metadata) { this.flower = flower; this.meta = metadata; } public boolean generate(World world, Random rand, int i, int j, int k) { for (int var6 = 0; var6 < 64; ++var6) { int var7 = i + rand.nextInt( - rand.nextInt(; int var8 = j + rand.nextInt(4) - rand.nextInt(4); int var9 = k + rand.nextInt( - rand.nextInt(; if (world.isAirBlock(var7, var8, var9) && (!world.provider.hasNoSky || var8 < 255) && this.flower.canBlockStay(world, var7, var8, var9)) { world.setBlock(var7, var8, var9, this.flower, this.meta, 2); } } return true; } }
 - 
	
		
		[1.7.10]How can I get a certain metadata item use bFull3D?
		
		I don't think that's possible since the Item's damage is actually stored in the ItemStack.
 - 
	
		
		How to override base minecraft code
		
		Sorry, I can't seem to make the item stay still. There is probably a way to make the boat drop 5 planks, but I'm not sure how.
 - 
	
		
		[1.7.10] custom flowers are not spawning in custom biome
		
		Change y in your decorate method to world.getHeightValue(x, z) add the following to your decorate method: new WorldGenFlowers(ModBlocks.plasticFlower).generate(world, random, x, y, z);
 - 
	
		
		[1.7.10]How do I use the new skin format with my custom mob?
		
		Make a new model.
 - 
	
		
		Missing Block Break Texture
		
		get rid of if(type == IItemRenderer.ItemRenderType.ENTITY)
 - 
	
		
		[1.7.10] custom flowers are not spawning in custom biome
		
		What are the addFlower and plantFlower functions? Are they in BiomeGenBase? If so, just use WorldGenFlowers to generate your flowers. And maybe move your world gen code to a class that implements IWorldGenerator.
 - 
	
		
		[1.7.10] [Unsolved] How to add Wavefront Armor?
		
		Try using a RenderPlayerEvent that checks to see what items are in the player's armor slots. It's probably event.renderer.modelArmor.
 - 
	
		
		Missing Block Break Texture
		
		Look at https://github.com/Eternaldoom/ChaosBeasts/blob/master/com/chaosmodders/chaosbeasts/items/rendering/ItemRendererLobsterStatue.java
 - 
	
		
		[1.7.10] [SOLVED] Item with Inventory
		
		Use NBT data, sort of like a chest but on your item.
 - 
	
		
		[1.7.10] Checking if player is Opped (Solved)
		
		Im pretty sure it's a searge name. Maybe look at CommandOp?
 
IPS spam blocked by CleanTalk.