Jump to content

zenek1290

Members
  • Posts

    13
  • Joined

  • Last visited

Everything posted by zenek1290

  1. I have no clue what can I do to make it work... ExampleMod.java ModStructureTypes.java ModStructurePieces.java CubeStructure.java CubePiece.java
  2. Ok, locate function is working with my structure, but no blocks are added to the world.
  3. I registered it In that way. I changed my code a lot since then, Your suggestion earlier on was really helpful.
  4. Since that time I changed my code a lot so structure registration is finally working properly. Only things that I still have problem with are setting structure placing config and adding this structure to world. Here is my function where all those stuff are done.
  5. Ok, this is what I came up to. ExampleMod.java ModStructureTypes.java ModStructurePieces.java CubePiece.java CubeStructure.java Good is that I finally was able to register my structure. Structure is still not generating in overworld. And I still got this Info in console, [16:54:30] [Client thread/DEBUG] [ne.mi.re.ObjectHolderRef/]: Unable to lookup examplemod:cube_structure for public static net.minecraft.world.gen.feature.structure.Structure com.example.examplemod.world.gen.ModStructureTypes.CUBE_STRUCTURE. This means the object wasn't registered. It's likely just mod options.
  6. Here is what i came up to, but my code isn't working, I started looking for some code examples on github but it's still wasn't enough. CubePiece.java CubeStructure.java ModStructureTypes.java ExampleMod.java
  7. Hi, recently I was looking for some Strucutre Generation Tutorial for 1.14.4, but sadly there is none. 1.14.4 Structure Generation is totally different from 1.12.2. Can You guys help me with this?
  8. │ ├── assets │ │ └── dungeons │ │ ├── models │ │ │ └── item │ │ │ └── example_item.json │ │ └── textures │ │ └── item │ │ └── example_item.png
  9. I was wrong, it was different folder, my error is gone. Thanks for Your support.
  10. I tried it, but sadly it's not a solution.
  11. Hi Guys, I recently started making minecraft mods and came up to my first problem that I cannot resolve... Problem is with loading texture of an item to the game. Here is my code and file tree. File Tree . ├── main │ ├── java │ │ └── com │ │ └── zenek1290 │ │ ├── Dungeons.java │ │ └── ModEventSubscriber.java │ └── resources │ ├── META-INF │ │ └── mods.toml │ ├── assets │ │ └── dungeons │ │ └── models │ │ └── item │ │ └── example_item.json │ ├── assets.dungeons.textures.items │ │ └── example_item.png │ └── pack.mcmeta └── test ├── java └── resources ModEventSubscriber.java package com.zenek1290; import net.minecraft.item.Item; import net.minecraft.util.ResourceLocation; import net.minecraftforge.event.RegistryEvent; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.common.Mod; import net.minecraftforge.registries.IForgeRegistryEntry; @Mod.EventBusSubscriber(modid = Dungeons.MODID, bus = Mod.EventBusSubscriber.Bus.MOD) public final class ModEventSubscriber { @SubscribeEvent public static void onRegisterItem(RegistryEvent.Register<Item> event) { event.getRegistry().registerAll( setup(new Item(new Item.Properties()), "example_item") ); } public static <T extends IForgeRegistryEntry<T>> T setup(final T entry, final String name) { return setup(entry, new ResourceLocation(Dungeons.MODID, name)); } public static <T extends IForgeRegistryEntry<T>> T setup(final T entry, final ResourceLocation registryName) { entry.setRegistryName(registryName); return entry; } } example_item.json { "parent": "item/generated", "textures": { "layer0": "dungeons:items/example_item" } }
×
×
  • Create New...

Important Information

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