Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

Hi, I'm doing fashion to food, I decided to go to the Forge for the textures. Here is my mod_test

package net.minecraft.src;

import net.minecraft.src.forge.*;


public class mod_test extends BaseMod implements ITextureProvider
{

public static final Item foodtest = new ItemFood(6000, 1, false).setIconIndex(10).setItemName("foodtest ");


public String getVersion()
    {
        return "Test";
    }

public String getTextureFile()
{
return "/textures/new_items.png";
}	

public void load()
{

{
   MinecraftForgeClient.preloadTexture("/textures/new_items.png");
}



ModLoader.addName(foodtest , "New Food");
ModLoader.addRecipe(new ItemStack(foodtest , 1), new Object[]{ "X", Character.valueOf('X'), Block.dirt});
foodtest .iconIndex = ModLoader.addOverride("/gui/items.png", "/textures/new_items.png");


}
}

When only the data registered in the mod_test Forge texture does not work.

 

And when adding in the ItemFood it works.

import net.minecraft.src.forge.*;

public class ItemFood extends Item implements ITextureProvider


public String getTextureFile()
        {
        return "/textures/new_items.png";
        }

 

But I do not want to do that, I do not want to add there is, can we do differently as a fact, that it worked?

 

.setTextureFile(blah)

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

No, there isnt metadata specific terrain files.

You have 256 icons to deal with, no freak reason to ever need that many.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

No, there isnt metadata specific terrain files.

You have 256 icons to deal with, no freak reason to ever need that many.

 

Hmm because I'm writing a code API that allows others to easily add custom versions of a block via metadata and they can't access my texture file.

 

Is it possible to use ModLoader.addOverride towards one of my custom created textures files?

  • Author

Sorry but I have little to understand, can explained to me in detail? I have only so mod_test all files have been, I do not want to prescribe to the standard files, and all of its own.

  • 2 weeks later...

No, there isnt metadata specific terrain files.

You have 256 icons to deal with, no freak reason to ever need that many.

 

Hmm because I'm writing a code API that allows others to easily add custom versions of a block via metadata and they can't access my texture file.

 

Is it possible to use ModLoader.addOverride towards one of my custom created textures files?

Yeah.

So, what would happen if I did push that shiny red button over there? ... Really? ... Can I try it? ... Damn.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.