Posted November 26, 20213 yr i have added a sword but i dont really know how to add pickaxe,axe,shovel and a hoe, if someone could take a look at my script and help me that would help a lot. Here Is My Github Repository: https://github.com/TechnoKraken/Citrine-1.17.1
November 27, 20213 yr you have already add pickaxe,axe,shovel and a hoe here whats your question/problem
November 27, 20213 yr Author it just the mechanics dosent work, all the tools are swords instead of sword,pickaxe,axe,shovel,hoe
November 27, 20213 yr Author i only made one material and its for a sword and i dont know to make multiple materials in the same script if u could show me how that would be great
November 27, 20213 yr i mean did you use did you call TierSortingRegistry.registerTier in FMLCommonSetupEvent Edited November 27, 20213 yr by Luis_ST
November 27, 20213 yr 18 minutes ago, Luis_ST said: TierSortingRegistry.registerTier call this method in FMLCommonSetupEvent, look into the javadoc for more infos
November 27, 20213 yr Author so should i type TierSortingRegistry.registerTier(); under FMLCommonSetupEvent?
November 27, 20213 yr yeah, but you need to pass in the required parameters (a Tier, List, List) 13 minutes ago, Luis_ST said: look into the javadoc for more infos
November 27, 20213 yr Author what am i supposed to put instead of (a Tier, List, List) i am in the javadoc and i dont really understand what to put in there
November 27, 20213 yr im stupid it's (Tier, ResourceLocation, List, List) parameters: your Tier a ResourceLocation the name combined with your mod id a List of Tiers (the Vanilla) which should be lesser than your Tier a List of Tiers (the Vanilla) which should be better than your Tier example
November 27, 20213 yr Author i have typed TierSortingRegistry.registerTier(BLIZZARDED, Citrine.MOD_ID, List, List); Edited November 27, 20213 yr by technokraken
November 27, 20213 yr Author here is my script if u wanna see it, u can just send a working one back if u have time, it would be really nice if u could because im pretty new at java scripting Script package com.technokraken.ct.citrine; import com.technokraken.ct.citrine.block.ModBlocks; import com.technokraken.ct.citrine.item.ModItems; import com.technokraken.ct.citrine.item.ToolMaterialInit; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.item.*; import net.minecraft.world.level.block.Blocks; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.common.TierSortingRegistry; import net.minecraftforge.eventbus.api.IEventBus; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent; import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import java.util.List; // The value here should match an entry in the META-INF/mods.toml file @Mod(Citrine.MOD_ID) public class Citrine { public static final String MOD_ID = "ct"; // Directly reference a log4j logger. private static final Logger LOGGER = LogManager.getLogger(); public Citrine() { IEventBus eventBus = FMLJavaModLoadingContext.get().getModEventBus(); ModItems.register(eventBus); ModBlocks.register(eventBus); eventBus.addListener(this::setup); MinecraftForge.EVENT_BUS.register(this); } private void setup(final FMLCommonSetupEvent event) { TierSortingRegistry.registerTier(BLIZZARDED, Citrine.MOD_ID, 3, 4); // some preinit code LOGGER.info("HELLO FROM PREINIT"); LOGGER.info("DIRT BLOCK >> {}", Blocks.DIRT.getRegistryName()); } } Edited November 27, 20213 yr by technokraken
November 27, 20213 yr 18 minutes ago, Luis_ST said: your Tier a ResourceLocation the name combined with your mod id a List of Tiers (the Vanilla) which should be lesser than your Tier a List of Tiers (the Vanilla) which should be better than your Tier do you know basic java, since a String != ResourceLocation and int != List?
November 27, 20213 yr Author i have seen a few tutorials on how to script minecraft forge so i dont really know all that basic java stuff, and what there do Edited November 27, 20213 yr by technokraken
November 27, 20213 yr learn basic java bevor modding Minecraft Official documentation: https://docs.oracle.com/javase/tutorial/ Absolute basics with an interactive editor: https://www.codecademy.com/learn/learn-java Ongoing online course with assignments: https://java-programming.mooc.fi/
November 27, 20213 yr Author but it takes so long to learn :C Edited November 27, 20213 yr by technokraken
November 27, 20213 yr Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
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.