Paragliders

Paragliders

4M Downloads

adjusting spirit orb drops via datapack does not seem to work correctly

esotericist opened this issue ยท 7 comments

commented

minecraft 1.18.2, forge 40.1.54, paraglider 1.6.0.0

so after looking at the discussion in #53 i created a datapack with some overrides for paraglider... i was able to successfully change the number of spirit orbs needed for a heart container, but i had some trouble trying to reduce the number of spirit orbs gained through breaking spawners.

i found the relevant .json file here: https://github.com/Tictim/Paraglider/blob/release/1.18.2/src/generated/resources/data/paraglider/loot_modifiers/spirit_orbs/spawner.json
my datapack's path here matches that of the mod: datapacks/paraglider_adjusts/data/paraglider/loot_modifiers/spirit_orbs/spawner.json

when i put a 1 in my copy of that file, i still got two spirit orbs. i thought "okay, let's see if i can change it to anything else", and i found that if i put a 3, i get six spirit orbs. i am really unsure what's going on.

to be extra sure, i made sure to fully quit and restart the game, instead of relying on /reload, still no constructive effect.

commented

okay, even more confusingly: after both removing my attempt at modifying that loot table, and starting a new world, now i'm consistently getting 4 spirit orbs per spawner destroyed. i can find no evidence of any remaining data packs touching spirit orb drops other than my recipe adjustments for heart container and stamina vessel. i truly do not understand what is happening here.

edit: even removing that datapack, new world, i've got NOTHING that modifies anything related to paraglider as far as i know. still 4 spirit orbs. very confusing.

commented

my current working theory is that my drops for the spawners were always for some reason doubled, and that's why when i set it to 1 spirit orb in the datapack i "still" got two; this also explains why when i set it to 3 i got 6.

the datapack was fine. something in my mod pack is interfering with how many things we get from the spawner. i have no idea what.

commented

given i'm now very confident this is something caused by another mod in my pack (i tested paraglider on its own, and it behaved as expected), i think this issue can be safely closed as "not an issue with this mod or with modding it using a datapack. sorry for taking up attention unnecessarily.

commented

I'm not very bright on datapacks and haven't looked at it either, so I cannot comment about exactly how it interacts with custom datapacks. But considering the report, it seems like the file has been overwritten successfully but the game still detects two json files supplied, and forge does not filter those things and ends up creating loot modifier for each of the two files; hence the double drops.

One thing I could suggest, is de-listing the original loot modifier entry in forge:global_loot_modifiers and adding custom loot modifier entry with desired configuration.

commented

oh, i think i see what you mean. i'll try that and report back later.

commented

nope, can't work out how to remove the original entry short of editing the jar file and changing the json embedded in that.

commented

Sorry to comment on an already closed thread, but I might've found something to add from my own experience. I'm currently developing a 1.16.5 pack and was playing around with spirit orb drops and noticed I was getting the expected 2 as per usual, however after updating the forbidden and arcanus mod to a version where spawner shards were dropping from spawners (previously I was using version 16.2.0-beta-4 and I updated to 16.2.3) it seemed to change the drop rate of the spirit orbs from 2 to 4. Something to note, spawner shards not dropping was being caused by an incompatibility with the Apotheosis mod so that is also present here, the forbidden and arcanus dev fixed this in 16.2.0. Not sure if this is a direct incompatibility with forbidden and arcanus though or if it might just be a case where if any other mod edits the loot table of spawners it causes paragliders drops to double.

Just thought I would add some information in case anyone else is experiencing a similar problem. :)