package hmggirlfront;


import net.minecraft.util.ResourceLocation;
import net.minecraft.util.SoundEvent;
import net.minecraftforge.event.RegistryEvent;

/**
 * Registers this mod's {@link SoundEvent}s.
 *
 * @author Choonster
 */
public class GFSoundEvent {
	
	public static SoundEvent fire_ibc_hg;
	public static SoundEvent fire_ibc_rifle;
	public static SoundEvent fire_ibc_rifle_heavy;
	public static SoundEvent ibc_step;
	public static SoundEvent reload_garand;
	public static SoundEvent fire_rifle5_gf;
	

	/**
	 * Register the {@link SoundEvent}s.
	 */
	public static void registerSounds(RegistryEvent.Register<SoundEvent> event) {
		
		fire_ibc_hg = registerSound("hmggirlfront.fire_ibc_hg", event);
		fire_ibc_rifle = registerSound("hmggirlfront.fire_ibc_rifle", event);
		fire_ibc_rifle_heavy = registerSound("hmggirlfront.fire_ibc_rifle_heavy", event);
		ibc_step = registerSound("hmggirlfront.ibc_step", event);
		reload_garand = registerSound("hmggirlfront.reload_garand", event);
		fire_rifle5_gf = registerSound("hmggirlfront.fire_rifle5_gf", event);
		
		
		event.getRegistry().register(fire_ibc_hg);		
		event.getRegistry().register(fire_ibc_rifle);		
		event.getRegistry().register(fire_ibc_rifle_heavy);		
		event.getRegistry().register(ibc_step);		
		event.getRegistry().register(reload_garand);		
		event.getRegistry().register(fire_rifle5_gf);		
	}

	/**
	 * Register a {@link SoundEvent}.
	 *
	 * @param soundName The SoundEvent's name without the testmod3 prefix
	 * @return The SoundEvent
	 */
	private static SoundEvent registerSound(String soundName, RegistryEvent.Register<SoundEvent> event) {
		/*final ResourceLocation soundID = new ResourceLocation(mod_GirlFront.MOD_ID, soundName);
		event.getRegistry().register(new SoundEvent(soundID).setRegistryName(soundID));		
		return new SoundEvent(new ResourceLocation(mod_GirlFront.MOD_ID, soundName)).setRegistryName(soundName);*/
		ResourceLocation soundID = new ResourceLocation(mod_GirlFront.MOD_ID, soundName);
		//event.getRegistry().register(new SoundEvent(soundID).setRegistryName(soundID));		
		return new SoundEvent(soundID).setRegistryName(soundID);
	}
}