package com.r3944realms.leashedplayer.datagen.provider;


import com.r3944realms.leashedplayer.content.sounds.ModSoundRegister;
import net.minecraft.data.PackOutput;
import net.neoforged.neoforge.common.data.ExistingFileHelper;
import net.neoforged.neoforge.common.data.SoundDefinition;
import net.neoforged.neoforge.common.data.SoundDefinitionsProvider;

public class ModSoundDefinitionsProvider extends SoundDefinitionsProvider {
    /**
     * Creates a new instance of this data provider.
     *
     * @param output The {@linkplain PackOutput} instance provided by the data generator.
     * @param modId  The mod ID of the current mod.
     * @param helper The existing file helper provided by the event you are initializing this provider in.
     */
    public ModSoundDefinitionsProvider(PackOutput output, String modId, ExistingFileHelper helper) {
        super(output, modId, helper);
    }

    public SoundDefinition getSoundDefinition(String subTitle, SoundDefinition.Sound... sounds) {
        return SoundDefinition.definition().subtitle(subTitle).with(sounds);
    }

    @Override
    public void registerSounds() {
        add(
                ModSoundRegister.FOX_MUSIC,
                getSoundDefinition(
                        ModSoundRegister.getSubTitleTranslateKey("what_does_the_fox_say"),
                        sound(ModSoundRegister.RL_FOX_MUSIC, SoundDefinition.SoundType.SOUND)
                )
        );

    }
}
