Everything posted by ProPane865
-
JSON File not Found
This way of registering items is not exactly efficient. EDIT: DaemonUmbra seems to have read my mind lol. Read my code! package com.mods.propane865.undergrounddiscovery; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import com.mods.propane865.undergrounddiscovery.items.CustomAxeItem; import com.mods.propane865.undergrounddiscovery.items.CustomPickaxeItem; import com.mods.propane865.undergrounddiscovery.lists.ArmorMaterialList; import com.mods.propane865.undergrounddiscovery.lists.BlockList; import com.mods.propane865.undergrounddiscovery.lists.ItemList; import com.mods.propane865.undergrounddiscovery.lists.ToolMaterialList; import com.mods.propane865.undergrounddiscovery.world.OreGeneration; import net.minecraft.block.Block; import net.minecraft.block.SoundType; import net.minecraft.block.material.Material; import net.minecraft.inventory.EquipmentSlotType; import net.minecraft.item.ArmorItem; import net.minecraft.item.BlockItem; import net.minecraft.item.HoeItem; import net.minecraft.item.Item; import net.minecraft.item.ItemGroup; import net.minecraft.item.ShovelItem; import net.minecraft.item.SwordItem; import net.minecraft.util.ResourceLocation; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.event.RegistryEvent; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent; import net.minecraftforge.fml.event.lifecycle.FMLCommonSetupEvent; import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext; @Mod("undergrounddiscovery") public class Main { public static Main instance; public static final String MODID = "undergrounddiscovery"; private static final Logger LOGGER = LogManager.getLogger(MODID); public static final ItemGroup MORE_METALS = new MoreMetals(); public Main() { instance = this; FMLJavaModLoadingContext.get().getModEventBus().addListener(this::setup); FMLJavaModLoadingContext.get().getModEventBus().addListener(this::clientRegistries); MinecraftForge.EVENT_BUS.register(this); } private void setup(final FMLCommonSetupEvent event) { OreGeneration.setupOreGeneration(); LOGGER.info("Setup method registered."); } private void clientRegistries(final FMLClientSetupEvent event) { LOGGER.info("clientRegistries method registered."); } @Mod.EventBusSubscriber(bus=Mod.EventBusSubscriber.Bus.MOD) public static class RegistryEvents { @SubscribeEvent public static void registerItems(final RegistryEvent.Register<Item> event) { event.getRegistry().registerAll ( ItemList.copper_ingot = new Item(new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_ingot")), ItemList.copper_block = new BlockItem(BlockList.copper_block, new Item.Properties().group(MORE_METALS)).setRegistryName(BlockList.copper_block.getRegistryName()), ItemList.copper_ore = new BlockItem(BlockList.copper_ore, new Item.Properties().group(MORE_METALS)).setRegistryName(BlockList.copper_ore.getRegistryName()), ItemList.copper_axe = new CustomAxeItem(ToolMaterialList.copper, 0.0f, -3.1f, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_axe")), ItemList.copper_hoe = new HoeItem(ToolMaterialList.copper, -3.0f, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_hoe")), ItemList.copper_pickaxe = new CustomPickaxeItem(ToolMaterialList.copper, (int) -3.0f, -3.0f, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_pickaxe")), ItemList.copper_shovel = new ShovelItem(ToolMaterialList.copper, -4.0f, -3.0f, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_shovel")), ItemList.copper_sword = new SwordItem(ToolMaterialList.copper, (int) -1.0f, -2.4f, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_sword")), ItemList.copper_helmet = new ArmorItem(ArmorMaterialList.copper, EquipmentSlotType.HEAD, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_helmet")), ItemList.copper_chestplate = new ArmorItem(ArmorMaterialList.copper, EquipmentSlotType.CHEST, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_chestplate")), ItemList.copper_leggings = new ArmorItem(ArmorMaterialList.copper, EquipmentSlotType.LEGS, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_leggings")), ItemList.copper_boots = new ArmorItem(ArmorMaterialList.copper, EquipmentSlotType.FEET, new Item.Properties().group(MORE_METALS)).setRegistryName(location("copper_boots")) ); LOGGER.info("Items registered."); } @SubscribeEvent public static void registerBlocks(final RegistryEvent.Register<Block> event) { event.getRegistry().registerAll ( BlockList.copper_block = new Block(Block.Properties.create(Material.IRON).hardnessAndResistance(2.0f, 3.0f).lightValue(0).sound(SoundType.METAL)).setRegistryName(location("copper_block")), BlockList.copper_ore = new Block(Block.Properties.create(Material.ROCK).hardnessAndResistance(1.5f, 2.0f).lightValue(0).sound(SoundType.STONE)).setRegistryName(location("copper_ore")) ); LOGGER.info("Blocks registered."); } private static ResourceLocation location(String name) { return new ResourceLocation(MODID, name); } } } NOTE: My code is for 1.14.3 and above ONLY!
-
Forge installed but not loading
One final suggestion. Open vanilla Minecraft, wait until you are at the main menu, close Minecraft, and re-install forge using the installer. If this doesn't work, you are out of luck.
-
Forge installed but not loading
Launcher. Double click on it to install after downloading.
-
Forge installed but not loading
Reinstall, or try using the zip instead of the installer.
-
Forge installed but not loading
Do they have a jar file in them, or is it just the JSON file?
-
Forge installed but not loading
Did you install in .minecraft? Also, I notice you are using a different launcher than usual. Is that the problem? Also, you selected release 1.14 but you are supposed to select forge 1.14 in the launcher version
-
Forge installed but not loading
send screenshots please
-
JSON File not Found
Show me your source code please...
-
Help with creating a GUI in Forge!
Hello, I just created a forge account because I wanted to post things like this on the forums. Anyway, I am here to ask about how to create a GUI. I recall that there was a feature back in 1.12 to create a GUI for any block with a TileEntity that opens on a right click. The right click event still exists to this day, but the GUI seems to be missing for Forge 1.13/1.14! I have read all the docs for Forge 1.13 and only found ONE LINE that even mentions about a GUI, and it has a link that goes to a NONEXISTENT PAGE! Does anyone know if they removed or replaced the GUI system? BTW here is a link to the place where I found the GUI link: https://mcforge.readthedocs.io/en/1.13.x/blocks/interaction/#guis
IPS spam blocked by CleanTalk.