Everything posted by GotoLink
-
[1.6.2]Minecraft Item Animations
Can we see the timing file then ?
-
[1.6.2] Player Names
Probably to prevent someone from destroying Minecraft security system by changing people login at will. But I am not Mojang, I can't tell for sure. I can just read the code.
-
[SOLVED][1.5.2] Dual Input Furnace Recipe Problem
Basically, all you did is merging two furnaces into one. That isn't what you want to do, is it ? (even if it was, you wouldn't do it this way) The smelting list (which is a map) needs to be unique for inputs to be linked. All that a smelting map does, is saving input as key, and output as value. Now, all you need to figure out, is what your inputs and outputs should be, coding-wise.
-
Custom log not rotating correctly.
Look at your parent class, the BlockLog class: you can see there are four types of log: {"oak", "spruce", "birch", "jungle"} Thus, they are all registered in creative inventory with getSubBlocks(args) method. You may want to change it. BlockLog is also a child class of BlockRotatedPillar, which has onBlockPlaced(args) method. This is where rotation occurs. Read it to understand and check if changes are needed. Actually, you may want to extend BlockRotatedPillar instead of BlockLog.
-
[1.6.2] Player Names
Well, with an EntityPlayer instance : entityPlayer.username But it is a final field. You can't change it. "username is random" is a false assumption, by the way.
-
[1.6.2]Different Drops in 1 Class!
I don't remember well the drop system... Try with metadata ?
-
[1.6.2]Minecraft Item Animations
Hi What do you use to render the item ? When do you play the animation ? Is it with multiple textures or a single one with a timing file ?
-
Need help with world not rendering
I suggest commenting that line in your overlay code Minecraft.getMinecraft().fontRenderer.drawString(charge+"/"+nump+" MyJ", 1, 1, 16777215); You should review your code in there, because from what I understand you set a new NBTTagcompound (without any info or tag ?) for each new armor the player is wearing, but only load the data from "instanceof IItemMysticRechargeableArmor". And line NBTTagCompound tag1 = player.getEntityData(); is unused. Also, I don't understand why you use render ticks for this. Player ticks or client ticks should be enough ?
-
Custom Mob Egg Wont Spawn !!
Remove this: nt id = getUniqueEntityId(); EntityList.IDtoClassMapping.put(id, entity); You already registered the entity with EntityRegistry.registerModEntity(...)
-
Need help with world not rendering
But you don't need those values since you are using TileEntitySpecialRenderer's. They are only needed if you use ISimpleBlockRenderingHandler and RenderingRegistry.registerBlockHandler(id, blockhandler);
-
[SOLVED] Textures not working, although configured.
Well you texture is blockashton.png. You gave "ashtonblock" to load.
-
Texture Problem
Well put a public abstract Icon getModuleIcon(); In your abstract class. Anyone extending your class will need to provide this icon. If your class isn't abstract: public Icon getModuleIcon() { return defaultIcon; } But then you'll have to register this default icon yourself, and people not overriding it will get the same. Of course, you can provide more arguments if you have some.
-
Need help with world not rendering
You are not doing anything with those in your client proxy ? public static int MysticCapacitorRenderId; public static int MysticGeneratorRenderId; public static int MysticRedGrinderid; public static int MysticCrystalGeneratorRenderId; public static int MysticCapacitormrk2RenderID; public static int MysticLiquidStorageRenderid; I have seen some living entities in your code, but there aren't supposed to spawn naturally, are they ?
-
Bow render in 3rd person
this.itemIcon = par1IconRegister.registerIcon("blalalal" + ":" + getUnlocalizedName()); Is this line supposed to work ? public class ItemBow extends ItemBow I you knew your java... public class ModBow extends ItemBow{ public static final String[] bowPullIconNameArray = new String[] {"mybow_pull_0", "mybow_pull_1", "mybow_pull_2"}; @SideOnly(Side.CLIENT) private Icon[] iconArray; public ModBow (int par1) { super(par1); this.setCreativeTab(MainClass.Tab); } /** * called when the player releases the use item button. Args: itemstack, world, entityplayer, itemInUseCount */ public void onPlayerStoppedUsing(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer, int par4) { int j = this.getMaxItemUseDuration(par1ItemStack) - par4; ArrowLooseEvent event = new ArrowLooseEvent(par3EntityPlayer, par1ItemStack, j); MinecraftForge.EVENT_BUS.post(event); if (event.isCanceled()) { return; } j = event.charge; boolean flag = par3EntityPlayer.capabilities.isCreativeMode || EnchantmentHelper.getEnchantmentLevel(Enchantment.infinity.effectId, par1ItemStack) > 0; if (flag || par3EntityPlayer.inventory.hasItem(Item.arrow.itemID)) { float f = (float)j / 10.0F; f = (f * f + f * 2.0F) / 3.0F; if ((double)f < 0.1D) { return; } if (f > 1.0F) { f = 1.0F; } EntityArrow entityarrow = new EntityArrow(par2World, par3EntityPlayer, f * 2.0F); if (f == 1.0F) { entityarrow.setIsCritical(true); } int k = EnchantmentHelper.getEnchantmentLevel(Enchantment.power.effectId, par1ItemStack); if (k > 0) { entityarrow.setDamage(entityarrow.getDamage() + (double)k * 0.5D + 0.5D); } int l = EnchantmentHelper.getEnchantmentLevel(Enchantment.punch.effectId, par1ItemStack); if (l > 0) { entityarrow.setKnockbackStrength(l); } if (EnchantmentHelper.getEnchantmentLevel(Enchantment.flame.effectId, par1ItemStack) > 0) { entityarrow.setFire(100); } par1ItemStack.damageItem(1, par3EntityPlayer); par2World.playSoundAtEntity(par3EntityPlayer, "random.bow", 1.0F, 1.0F / (itemRand.nextFloat() * 0.4F + 1.2F) + f * 0.5F); if (flag) { entityarrow.canBePickedUp = 2; } else { par3EntityPlayer.inventory.consumeInventoryItem(Item.arrow.itemID); } if (!par2World.isRemote) { par2World.spawnEntityInWorld(entityarrow); } } } @SideOnly(Side.CLIENT) public void registerIcons(IconRegister par1IconRegister) { this.itemIcon = par1IconRegister.registerIcon(MagicElementsMod.modid + ":" + getUnlocalizedName()); this.iconArray = new Icon[bowPullIconNameArray.length]; for (int i = 0; i < this.iconArray.length; ++i) { this.iconArray[i] = par1IconRegister.registerIcon(MagicElementsMod.modid + ":" + bowPullIconNameArray[i]); } } @SideOnly(Side.CLIENT) /** * used to cycle through icons based on their used duration, i.e. for the bow */ public Icon getIcon(ItemStack stack, int renderPass, EntityPlayer player, ItemStack usingItem, int useRemaining) { if(player.getItemInUse() == null) return this.itemIcon; int Pulling = stack.getMaxItemUseDuration() - useRemaining; if (Pulling >= 18) { return iconArray[2]; } else if (Pulling > 13) { return iconArray[1]; } else if (Pulling > 0) { return iconArray[0]; } return itemIcon; } }
-
Minecraft Forge 1.6.2 src and temp folder missed!
Any error during installation ? You didn't need to download mcp by the way, Forge does it on install.
-
[1.6.2] How to make mcmod.info file the right way ?
mcmod.info can be placed anywhere in the mod, it doesn't matter. You should check if modid and version are the same as declared in the mod. You can also remove any line with no info: [{ "modid": "camomod", "name": "Camo Mod", "description": "Camouflage your stuff because you never gonna now what happen", "version": "0.1", "mcversion": "1.6.2", "authors": [ "Graphicscore", "Setix", "mehrmrhr" ], "credits": "Code by Graphicscore and GFX by mehrmrhr", "logoFile": "/assets/textures/logo.png", "useDependencyInformation": "true" }] I am not sure about the logo file either. You might want to remove the path and put the logo image next to this file.
-
NBT's are not saving or saving too soon when the game is quit
Only with types being respectively, 3, 2, 1 and 4. You can use whatever packet type indeed, but in this case, the tileentity needs to override like this: @Override onDataPacket(INetworkManager net, Packet132TileEntityData pkt) { this.readFromNBT(pkt.customParam1); }
-
Recompile errors after fresh forge installation [SOLVED] [1.6.2]
No errors when you installed Forge ?
-
Having multiple instances of one block
Yes, you'll need a tile entity. With it, only one block is needed. The block would contain all the wanted behaviour, which will be triggered according to the values in the tile entity. For your "lux" example, the block should override getLightValue(IBlockAccess, int, int, int) and return value from the tile entity (which would be a combination of the light value from the original block, and value provided by your "aspect") Basically, your tile entity would need to contain at least id and metadata from the original block.
-
Rendering hand with custom redered item.
Forge provides reflection helper classes, if you are afraid of lines. Sure you can do with a coremod, but it is clearly not needed in this case.
-
Rendering hand with custom redered item.
Why not using reflection ? You have the renderplayer instance, you can access modelBipedMain field ?
-
[1.6.2] How to make mcmod.info file the right way ?
You need to add opening [ and closing ] at the very beginning and end respectively. Actually, you can just remove this part: { "modinfoversion": 2, "modlist": and the final bracket.
-
Dynamic block creating
You can use Map.put(new key,new value) or List.add(object). That is, if you need to save something in the process.
-
[SOLVED]How can I abort the player's left-click action?
That function is called if you use the right arguments. See my code for a working example.
-
Custom Food Class
And you can setMaxStackSize(int). Hardcoded in item, really ?
IPS spam blocked by CleanTalk.