Jump to content

Recommended Posts

Posted (edited)

Hello Guys,

 

i have a Problem with my Textures. The confussing Situation for me is, that my Copper has Texture but the other Ores not.

grafikfehler.png.beafac6ef120fa520ab260c3c94226d9.png

I have a 2 Classes for my Ores. BlockOre and BlockOreHard.

 

BlockOre

public class BlockOre extends BlockBase {

	private String oreName;

	public BlockOre(String name, String oreName) {
		super(Material.ROCK, name);

		this.oreName = oreName;

		setHardness(3f);
		setResistance(5f);
	}

	public void initOreDict() {
		OreDictionary.registerOre(oreName, this);
	}

	@Override
	public BlockOre setCreativeTab(CreativeTabs tab) {
		super.setCreativeTab(tab);
		return this;
	}

}

BlockOreHard

public class BlockOreHard extends BlockBase {

	private String oreName;

	public BlockOreHard(String name, String oreName) {
		super(Material.ROCK, name);

		this.oreName = oreName;

		setHardness(5f);
		setResistance(5f);
	}

	public void initOreDict() {
		OreDictionary.registerOre(oreName, this);
	}

	@Override
	public BlockOreHard setCreativeTab(CreativeTabs tab) {
		super.setCreativeTab(tab);
		return this;
	}

}

ModBlocks:

public class ModBlocks {

	public static BlockOre oreCopper = new BlockOre("ore_copper", "oreCopper");
	public static BlockOre oreAlumin = new BlockOre("ore_alumin", "oreAlumin");
	
	public static BlockOreHard oreRubin = new BlockOreHard("ore_rubin", "oreRubin");
	
	public static BlockWood woodfloor = new BlockWood("woodfloor", "woodfloor");

	public static void register(IForgeRegistry<Block> registry) {
		registry.registerAll(
				oreCopper,
				oreAlumin,
				oreRubin,
				woodfloor
				
		);

	}

	public static void registerItemBlocks(IForgeRegistry<Item> registry) {
		registry.registerAll(
				oreCopper.createItemBlock(),
				oreAlumin.createItemBlock(),
				oreRubin.createItemBlock(),
				woodfloor.createItemBlock()
		);
	}

	public static void registerModels() {
		oreCopper.registerItemModel(Item.getItemFromBlock(oreCopper));
		oreAlumin.registerItemModel(Item.getItemFromBlock(oreAlumin));
		oreRubin.registerItemModel(Item.getItemFromBlock(oreRubin));
		woodfloor.registerItemModel(Item.getItemFromBlock(woodfloor));

	}

}

In my classes and my Console i have no Error and no Message that the Texture dont can be loaded. The Files are in the same Ressource Folder then my Copper.

I hope you have any Idea why my Graphics dont load. I have try many things and find no Solution. I excuse for my bad English, i´m a German Guy and in my School, i have not learned many English.

Edited by DerWaldfried
Posted
9 minutes ago, diesieben07 said:

Show where you call the methods in the ModBlocks class (probably your main mod class and your sided proxy classes).

Show BlockBase.

I hope you mean that i show this here ^^ Well i have searched on the classes over 4 Days and dont have found a error or something. Here now my Base, MainClass and my Network Classes.....

 

BlockBase

public class BlockBase extends Block {

	protected String name;

	public BlockBase(Material material, String name) {
		super(material);

		this.name = name;

		setUnlocalizedName(name);
		setRegistryName(name);

		setCreativeTab(FriedAdventure.creativeTab);
	}

	public void registerItemModel(Item item) {
		FriedAdventure.proxy.registerItemRenderer(item, 0, name);
	}

	@Override
	public BlockBase setCreativeTab(CreativeTabs tab) {
		super.setCreativeTab(tab);
		return this;
	}

	public Item createItemBlock() {
		return new ItemBlock(this).setRegistryName(getRegistryName());
	}

}

CommonProxy

public class CommonProxy {

	public void registerItemRenderer(Item item, int meta, String id) {

	}

	public String localize(String unlocalized, Object... args) {
		return I18n.translateToLocalFormatted(unlocalized, args);
	}

	public void registerRenderers() {
	}

}

ClientProxy

public class ClientProxy extends CommonProxy {

	@Override
	public void registerItemRenderer(Item item, int meta, String id) {
		ModelLoader.setCustomModelResourceLocation(item, meta, new ModelResourceLocation(FriedAdventure.modId + ":" + id, "inventory"));
	}

	@Override
	public String localize(String unlocalized, Object... args) {
		return I18n.format(unlocalized, args);
	}

	@Override
	public void registerRenderers() {
		
	}
}

MainClass

@Mod(modid = FriedAdventure.modId, name = FriedAdventure.name, version = FriedAdventure.version)
public class FriedAdventure {

	public static final String modId = "friedadventure";
	public static final String name = "FriedAdventure";
	public static final String version = "1.0.0";

	@Mod.Instance(modId)
	public static FriedAdventure instance;

	@SidedProxy(serverSide = "de.waldfried.friedadventure.proxy.CommonProxy", clientSide = "de.waldfried.friedadventure.proxy.ClientProxy")
	public static CommonProxy proxy;

	public static final FrieAdventTab creativeTab = new FrieAdventTab();

	public static SimpleNetworkWrapper network;

	@Mod.EventHandler
	public void preInit(FMLPreInitializationEvent event) {
		proxy.registerRenderers();
		GameRegistry.registerWorldGenerator(new ModWorldGen(), 3);
	}

	@Mod.EventHandler
	public void init(FMLInitializationEvent event) {
		ModRecipes.init();
	}

	@Mod.EventHandler
	public void postInit(FMLPostInitializationEvent event) {

	}

	@Mod.EventBusSubscriber
	public static class RegsitrationHandler {

		@SubscribeEvent
		public static void registerItems(RegistryEvent.Register<Item> event) {
			ModItems.register(event.getRegistry());
			ModBlocks.registerItemBlocks(event.getRegistry());
		}

		@SubscribeEvent
		public static void registerBlocks(RegistryEvent.Register<Block> event) {
			ModBlocks.register(event.getRegistry());
		}

		@SubscribeEvent
		public static void registerModels(ModelRegistryEvent event) {
			ModItems.registerModels();
			ModBlocks.registerModels();
		}

	}

}

 

When you mean to view by my self , then sorry ^^ Well, my code is not the cleanest Solution but i hope you can tell me a Solution.

Posted

Well,

 

i now have Activate the Expanded Error Logging from Forge and become this Message:

Quote

[11:27:24] [main/ERROR] [TEXTURE ERRORS]: +=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: The following texture errors were found.
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: ==================================================
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:   DOMAIN friedadventure
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: --------------------------------------------------
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:   domain friedadventure is missing 0 textures
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:     domain friedadventure has 1 location:
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:       mod friedadventure resources at C:\Users\patri\Documents\FriedAdventure\bin
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: -------------------------
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:     The following other errors were reported for domain friedadventure:
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: -------------------------
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:     Problem: broken aspect ratio and not an animation
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:       textures/blocks/ore_alumin.png
[11:27:24] [main/ERROR] [TEXTURE ERRORS]:       textures/blocks/ore_rubin.png
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: ==================================================
[11:27:24] [main/ERROR] [TEXTURE ERRORS]: +=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=

But this give me no Sense. it is 1:1 the same Json like Copper only a other Texture oO Alumin:

{
    "forge_marker": 1,
    "defaults": {
        "textures": {
            "all": "friedadventure:blocks/ore_alumin"
        }
    },
    "variants": {
        "normal": {
            "model": "cube_all"
        },
        "inventory": {
            "model": "cube_all"
        }
    }
}

Copper:

{
	"forge_marker": 1,
	"defaults": {
		"textures": {
			"all": "friedadventure:blocks/ore_copper"
		}
	},
	"variants": {
		"normal": {
			"model": "cube_all"
		},
		"inventory": {
			"model": "cube_all"
		}
	}
}

Or come the error from

Quote

    "forge_marker": 1,

this ? I mean i dont give any Animation Point and i dont give any rotation informations oO

Posted
1 minute ago, DerWaldfried said:

This has worked.... Wow... Sry oO What a simple Solution and I do not come to this simple solution . Thanks a lot. Now it works.

If you solved this problem, please insert a [SOLVED] in the title so that people with similar problem may be able to fix it too :)

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • When I first heard about Bitcoin back in 2018, I was skeptical. The idea of a decentralized, digital currency seemed too good to be true. But I was intrigued as I learned more about the technology behind it and its potential. I started small, investing just a few hundred dollars, dipping my toes into the cryptocurrency waters. At first, it was exhilarating to watch the value of my investment grow exponentially. I felt like I was part of the future, an early adopter of this revolutionary new asset. But that euphoria was short-lived. One day, I logged into my digital wallet only to find it empty - my Bitcoin had vanished without a trace. It turned out that the online exchange I had trusted had been hacked, and my funds were stolen. I was devastated, both financially and emotionally. All the potential I had seen in Bitcoin was tainted by the harsh reality that with decentralization came a lack of regulation and oversight. My hard-earned money was gone, lost to the ether of the digital world. This experience taught me a painful lesson about the price of trust in the uncharted territory of cryptocurrency. While the technology holds incredible promise, the risks can be catastrophic if you don't approach it with extreme caution. My Bitcoin investment gamble had failed, and I was left to pick up the pieces, wiser but poorer for having placed my faith in the wrong hands. My sincere appreciation goes to MUYERN TRUST HACKER. You are my hero in recovering my lost funds. Send a direct m a i l ( muyerntrusted ( @ ) mail-me ( . )c o m ) or message on whats app : + 1 ( 4-4-0 ) ( 3 -3 -5 ) ( 0-2-0-5 )
    • You could try posting a log (if there is no log at all, it may be the launcher you are using, the FAQ may have info on how to enable the log) as described in the FAQ, however this will probably need to be reported to/remedied by the mod author.
    • So me and a couple of friends are playing with a shitpost mod pack and one of the mods in the pack is corail tombstone and for some reason there is a problem with it, where on death to fire the player will get kicked out of the server and the tombstone will not spawn basically deleting an entire inventory, it doesn't matter what type of fire it is, whether it's from vanilla fire/lava, or from modded fire like ice&fire/lycanites and it's common enough to where everyone on the server has experienced at least once or twice and it doesn't give any crash log. a solution to this would be much appreciated thank you!
    • It is 1.12.2 - I have no idea if there is a 1.12 pack
  • Topics

×
×
  • Create New...

Important Information

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