Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Posts

  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Koolade446's Achievements

Tree Puncher

Tree Puncher (2/8)



  1. I know how to use generics my friend. My question was how I can make my entity able to render the item in hand
  2. Okay I'm new to modding so whats a better way to do this?
  3. Hi, so I'm trying to add a custom boss who holds a sword. I made a model in blockbench and imported it and coded a renderer. the entity renders fine but as soon as I give it the sword the game crashes Model: Renderer: Crash Log:
  4. well then where the heck do I get vanilla source code? I've tried using a decompiler on the vanilla Jar but thier file naming scheme makes no sense at all its like $q87634576auyfgiatf.class
  5. Hi i am trying to give players a lore book the first time they log in so far i have this: @SubscribeEvent public void onPlayerJoin(EntityJoinWorldEvent e) { if (e.getEntity() instanceof PlayerEntity) { PlayerEntity pe = (PlayerEntity) e.getEntity(); if (!pe.getPersistentData().getBoolean("hasLoggedIn")) { pe.addItemStackToInventory(new ItemStack(RegistryHandler.BOOK.get())); pe.getPersistentData().putBoolean("hasLoggedIn", true); } } } this does give the item on log in and also only works once but it also gives the player the item when they respawn I don't want this how do I fix it.
  6. My bad for late reply forge decided not to notify me that’s you replied I will send you code in a bit.
  7. So I'm trying to add custom armor but whenever I apply it and go into f5 mode the game crashes. I'm pretty sure the error comes from not having a model for the armor but i cant figure out how to set the model. Crash report: https://pastebin.com/CXLivSLz
  8. 1. I know that’s why the listener is added in CommenSetup 2. Thank you for the information I will use this method in the future
  9. So I spent forever trying to figure this out so hopefully this solves the problem for those of you in the same situation. So we use the BiomeLoadingEvent to catch when biomes are loading and add our ConfiguredFeature. Ore Generation like so: public class WorldGen { public static final ConfiguredFeature<?, ?> yourOre = Feature.ORE.withConfiguration( new OreFeatureConfig(OreFeatureConfig.FillerBlockType.BASE_STONE_OVERWORLD, YourRegistryHandler.YOUR_ORE.get().getDefaultState(), 4)) //vein size .range(12).square() //maximum y level where ore can spawn .count(3); //how many veins maximum per chunck public static void generateOre(final BiomeLoadingEvent event) { BiomeGenerationSettingsBuilder generation = event.getGeneration(); if (event.getCategory().equals(Biome.Category.ICY)) { //OPTIONAL IF STATMENT allows you to generate ores in specfifc biome types for exmaple icy biomes generation.withFeature(GenerationStage.Decoration.UNDERGROUND_ORES, yourOre); } } } Now we need to know where to register this event do NOT use EventBus it will crash your mod on startup by trying to register generation before registering your ore block instead we register this in our main class like so: //if you use the mdk this function will be pre generated so we only add our refrence here private void setup(final FMLCommonSetupEvent event) { // some preinit code LOGGER.info("HELLO FROM PREINIT"); LOGGER.info("DIRT BLOCK >> {}", Blocks.DIRT.getRegistryName()); MinecraftForge.EVENT_BUS.addListener(EventPriority.HIGH, WorldGen::generateOre); //our refrence } ALTERNITIVE use if you are generating a bunch of ores in the same way
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.