• 0

    posted a message on Metadata-directional block missing face in inventory bar
    Quote from SpiritFire
    Hey guys,I've got a couple of blocks I'm working on, in two seperate mods, and both are demonstrating the same thing; if, when I get the icons, I set them to a side in particular, the face shows in the inventory bar correctly.However, if it gets decided via metadata (like the furnace, along with other tutorials I've found online), the face is missing completely from the inventory bar. I've tried all variations I can think of, to no avail.Here's my code:
    @SideOnly(Side.CLIENT)private Icon blockFront;@SideOnly(Side.CLIENT)private Icon blockSide;@SideOnly(Side.CLIENT)private Icon blockTop;[email protected](Side.CLIENT)public void registerIcons(IconRegister icon) {this.blockFront = icon.registerIcon(Names.TextureRoot + ":front_" + (this.isActive ? "on" : "off"));this.blockSide = icon.registerIcon(Names.TextureRoot + ":side");this.blockTop = icon.registerIcon(Names.TextureRoot + ":top");this.blockIcon = this.blockSide;}@SideOnly(Side.CLIENT)public Icon getIcon(int side, int meta) { return side == 1 ? this.blockTop : (side == 0 ? this.blockTop : (side != meta ? this.blockIcon : this.blockFront));}
    I don't want to hard-code the sides in, because I want it to be directional, like most other blocks. How can I set it to show the face of my block in my inventory, without giving up the metadata? I've googled all the terms I could think of, to no avail. Thanks :)

    I had your problem, i fixed it with this getIcon method:
    public Icon getIcon(int side, int meta) {
    if (this.isActive) {
    if (meta == 5 && side == 5)
    return iconBuffer[1];
    if (meta == 2 && side == 2)
    return iconBuffer[1];
    if (meta == 4 && side == 4)
    return iconBuffer[1];
    if (meta == 3 && side == 3)
    return iconBuffer[1];
    } else {
    if (meta == 5 && side == 5)
    return iconBuffer[0];
    if (meta == 2 && side == 2)
    return iconBuffer[0];
    if (meta == 4 && side == 4)
    return iconBuffer[0];
    if (meta == 3 && side == 3)
    return iconBuffer[0];
    }
    if (meta == 0 && side == 3)
    return iconBuffer[0];
    
    return iconBuffer[2];
    }
    The last if() is for the inventory rendering, in inventory the block does not have meta, so if meta is 0 and the side is 3, it will use the front texture.
    my variables are:
    0 = front disabled
    1 = front enabled
    2 = sides
    I don't know that this is what you want, but there is how i fixed it.
    Posted in: Modification Development
  • 0

    posted a message on Furnace with hopper crash
    You need to get the same methods from the vannila furnace and replace with your furnace "auto generated" methods.
    What is happening is that hopper tries to interact with it, gets null from your machine then it crashes.
    Posted in: Modification Development
  • 0

    posted a message on [1.6.2] RxD's Fart Explosions Resource Pack
    Quote from MushroomNinja

    Im sorry if Im missing it but do you have a download?

    Yes.
    v1
    Posted in: Resource Packs
  • 0

    posted a message on [1.6.2] RxD's Fart Explosions Resource Pack
    Quote from FailStoner

    I am not lying about this but I had to go to the hospital and get some medical help because I laughed so hard hahaha and also make villagers fart too that would be even more funny.

    Yeah will do this later.
    Posted in: Resource Packs
  • 0

    posted a message on [1.6.2] RxD's Fart Explosions Resource Pack
    Quote from Blaziken584

    wut .___.

    Haha, a quaint little fart pack, nice xD

    Though some of the farts sound more like they should be from a horror game, it's a silly resource pack deserving of its weird title.

    Quote from WillieWest

    I'm going to use this, but if I die because I was too busy laughing, I'm blaming you.

    [Represent]

    Lol, i can do more sounds, any suggestions?
    Posted in: Resource Packs
  • 3

    posted a message on [1.6.2] RxD's Fart Explosions Resource Pack
    [1.6.2] RxD's Fart Explosions Resource Pack [1.6.2]
    This resource pack edits the explosion sounds to fart sounds

    Installation Instructions:
    Place the downloaded .zip in .minecraft/resourcepacks, then select my pack in-game to use it. No mcpatcher/optifine needed.

    Downloads:

    Changelog:
    v1: Initial Version

    Credits:
    @Mightypork: His Amazing Resource Pack Workbench, an IDE for making Resource Packs.
    @RxDMinecrafter: Creator
    Posted in: Resource Packs
  • 0

    posted a message on mod that implements java in-game?
    There is also weasel, from Powercraft.
    Posted in: Requests / Ideas For Mods
  • 0

    posted a message on [1.6.2] DrZhark's MagicCarpet Mod v1.2

    He posted .minecraft with the mod, is this correct?
    Posted in: Minecraft Mods
  • 0

    posted a message on [Aesthetic] Animated Player - Compatibility and Flying! [v1.5.1]
    Is allowed to post .minecraft of your mod?
    look this video description:
    Posted in: Minecraft Mods
  • 1

    posted a message on [1.3.2/1.4.2] Duke's Mini Mods *Quick Equipped*
    nice work
    Posted in: Minecraft Mods
  • 0

    posted a message on (1.3.2) Absorber Block Mod (1.0_Beta)
    so if we right click it in a diamond block we get 2 diamond blocks? ...
    Posted in: Minecraft Mods
  • 0

    posted a message on [1.3.2] Mo' Gen Mod - [2.0.4] - 80+ New Block/Items!
    add more generation!
    Posted in: Minecraft Mods
  • 0

    posted a message on [1.3.2] Hungry Miners! (3 crops, 1 weapon, and 34+ recipes!)
    nice mod... maybe a sushi lol
    Posted in: Minecraft Mods
  • 0

    posted a message on [1.3.2] Spongepack! New Biome, Items, and a Block!
    lol what a crazy idea mod
    Posted in: Minecraft Mods
  • 0

    posted a message on [SSP]Enchanting Plus 1.0b(previously Unofficial Better Enchanting)
    you may want to update the modloader version too for forge haters... like me
    Posted in: Minecraft Mods
  • To post a comment, please or register a new account.