Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 04/09/23 in all areas

  1. Tags, don't have that structure. They are an isA relation. They let you do a blockState.is(TagKey) check to see if a block is part of the tag and that's it. You can write your own datapack type with whatever structure you like. See minecraft's PreparableReloadListener and its subclasses, you can register your own using the AddReloadListenerEvent that's how forge's internal mod loads dynamic loot modifiers: https://github.com/MinecraftForge/MinecraftForge/blob/2815e69407fe64523b6f4165a9fd965333634afd/src/main/java/net/minecraftforge/common/ForgeInternalHandler.java#L120 https://github.com/MinecraftForge/MinecraftForge/blob/1.19.x/src/main/java/net/minecraftforge/common/loot/LootModifierManager.java Or you can just use a config file: https://forge.gemwire.uk/wiki/Configs
    1 point
  2. Tags will be your goto for mod compatiblity. Of course the other mods must know about your tag and should add values to them. What you need to do is to create your custom tag using the Forge documentation https://docs.minecraftforge.net/en/1.19.2/resources/server/tags/ Then, when you need to check for a block (I'm assuming you want to see if a block falls inside a list of detectable blocks) you need to use the BlockState#is method. For example, let's say you create your tag "mymodid:detectable_blocks" and inside it you have specified the iron_ores or the diamond_ores (by the way you can also reference other tags in it, so if you reference the #forge:ores/iron tag you'll match also modded iron ores). When you want to check if a block is part of that tag you need to use the following statement blockstate.is(MyTags.DETECTABLE_BLOCKS) Assuming that somehwer in your code you have a class called MyTags and inside that class you have your tag defined as DETECTABLE_BLOCKS. Tags might look complicated but in reality they are really easy to use and deal with and of course are the recommended approach to maximimze mod compatibility
    1 point
  3. Why do you keep repostin the same error report? It is the midnight_hats mod. Contact the mod author. https://forums.minecraftforge.net/topic/122361-help-with-an-error-i-keep-having-when-trying-to-launch-my-modpack/#comment-532966 or uninstall the mod.
    0 points
×
×
  • Create New...

Important Information

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