Disc duration gets rounded down during generation
SailLively opened this issue ยท 1 comments
I added the Willhelm scream, and some other sound effects. One file says 0 in the play_duration.mcfunction files in the datapack. And I found that at least 4 more were scuffed out of the 72 new discs I added. Now, these were already rendered as a 48kHz 766kbps mono .ogg files (save quality rate as the cat.ogg file I found in the Minecraft directory). Please fix.
https://drive.google.com/file/d/1HsYVpmgl0YUq273vGFObc4gd7JP6VOpf/view?usp=drive_link
seems to be consistent with this file that it generates a 0 duration
SideNote:
Also, I modified the creeper loottable code to also rename the disk because the custom discs still show as 11 with a plugin I have. (Interaction visualizer)
Please add that as an option in the settings.
this is how I modified it
I had to edit this issue many times. hopefully all the information you need is included but feel free if you need anything else for testing.
I was able to generate a 0 duration datapack from the file that you sent, so I'll look into it. Thanks for the detailed report!
As for the loot table, I'm trying to make the custom discs behave as much like vanilla discs as possible. If you install a plugin that changes the behavior of music discs then I would expect you to have to modify your custom discs to match. There are a lot of possible plugins and mods that can be installed and unfortunately I can't add settings to accomodate all of them. That said, I bet you could write a function to copy the Lore NBT contents into the Name NBT of your music disc so you don't have to manually edit the datapack after generating it.