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

A Soulspark

  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About A Soulspark

  • Rank
    Tree Puncher

Recent Profile Visitors

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

  1. huh, I wonder if this even is used in vanilla at all. thanks!
  2. wait, you can use tags for an entry result? interesting so if I have multiple items in that tag, it'll drop one at random?
  3. In my mod there are some compatibility blocks to better work with other mods. The problem is, these mods aren't always loaded of course, they're not dependencies! So, I have to make sure to check if they're loaded before the loot tables loaded, otherwise it throws annoying errors at the console. I asked this question earlier in the Discord, and Unbekannt suggested to load a datapack conditionally, with all the loot tables inside it. Not quite sure how I do that tho, and if there are any better alternatives? 🤔 (I tried using the LootTableLoadEvent to disable loading certain loot t
  4. Huh, I didn't know that! So an import is just a thing to help code readability? Oh, I saw a post of yours from a few years ago describing this process, but I wasn't sure if it still applied today. I'll do that then, thanks!
  5. I'm once again asking about mod compatibility :v This time, it's more of a curiosity than a necessity, as I've already come up with a solution to my problem, but I was wondering: How do you run some code in 1.16 only if a mod is present? I know there is ModList.get().isLoaded(<modid>) but if I import a class that isn't loaded it will still break.
  6. alright, I think this turned out well. I had already done this "multiple items per block" thing before, but this time I managed to solve the duplicate items in Creative by adding a fillItemGroup() override to my items. I still had to split the blocks into Empty and Water Kettles because I'll later add Milk Kettles too. Still, it indeed would've been a lot messier if I'd done it with 3 blocks and 2 tile entities lmao. thanks for the guidance!
  7. ok, I'll try that. but is it possible to have multiple block items for the same block, just with different states? last time I tried this, the Creative inventory got messed up and it just added one of the items multiple times. p.s.: I do need multiple items because there are recipes where only hot kettles can be used.
  8. That's true, but an empty kettle doesn't need a tile entity, whereas the other two do, and they have other states that are only necessary in each case. e.g. the boiling kettle has a fullness state, for how many uses it has left. this isn't necessary for empty or full kettles, as their "fullness" doesn't change: it's 0% or 100%. Plus, each version also has a different item/name/texture, and it was really troublesome to manage all that in a single item and block. If what I'm trying to do is extremely forbidden, then I could revert ofc. But this just sounds like it makes mor
  9. After accepting the way I was doing things in my mod wasn't quite ideal, I decided I have to upgrade a certain block when users update into the newest version of my mod. This block currently has a Content blockstate (an enum with 3 values) and it should convert into a different block for each value. So, tea_kettle:kettle[content=empty] -> tea_kettle:empty_kettle tea_kettle:kettle[content=water] -> tea_kettle:water_kettle tea_kettle:kettle[content=hot_water] -> tea_kettle:boiling_kettle I just don't know how to do that! Maybe I'd need to keep the t
  10. Yep, this is what I was considering doing too, checking for the LIT state. I think even modded furnaces that don't extend AbstractFurnaceBlock usually still have that. Thanks!
  11. In my mod, you can place a tea kettle block on top of any burning furnace to make it boil. However, I'm only checking if it's an instanceof AbstractFurnaceBlock, which isn't the case for some modded furnaces. How exactly can I add compatibility with these other mods? I could check if the block is in a tag containing many modded furnaces, but how do I check if it's burning then? There must be a better alternative to this.
  12. Ok, that seems to make sense! Though I'm having a bit of trouble with the damaging part, since the getRemainingItems() function only gives you an Inventory. I believe the best way to damage the item is through attemptDamageItem(), but idk how to get a java.util.Random instance in this context. Here's the code for reference: @Override public NonNullList<ItemStack> getRemainingItems(CraftingInventory inv) { // get the default remaining items for a shapeless recipe NonNullList<ItemStack> remainingItems = super.getRemainingItems(inv); // loop through each slot i
  13. So, I want to add shapeless recipes where you use Shears + (some item) to craft another item, but the shears stay, albeit with -1 durability. After a bit of a search, it seems like you can use getContainerItem() and similar methods to achieve this, but that's out of scope here with a vanilla item. Then, how am I supposed to approach this? Maybe through a custom recipe type where one of the ingredients stay after crafting, but how do I even do that?
  • Create New...

Important Information

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