// Path: src/main/java/com/github/worldsender/mcanm/client/config/MCAnmConfiguration.java
// public class MCAnmConfiguration {
// 
// 	private Configuration config;
// 	private Property enableReload;
// 
// 	public MCAnmConfiguration(File loadFile) {
// 		config = new Configuration(loadFile);
// 		config.load();
// 		enableReload = config.get(Configuration.CATEGORY_GENERAL, Reference.config_reload_enabled, true)
// 				.setLanguageKey(Reference.gui_config_reload_enabled);
// 		save();
// 	}
// 
// 	public void onConfigChange(@SuppressWarnings("unused") OnConfigChangedEvent occe) {
// 		save();
// 	}
// 
// 	public void save() {
// 		if (config.hasChanged())
// 			config.save();
// 	}
// 
// 	public boolean isReloadEnabled() {
// 		return this.enableReload.getBoolean();
// 	}
// 
// 	public void addPropertiesToDisplayList(List<IConfigElement> list) {
// 		list.add(new ConfigElement(enableReload));
// 	}
// }
// 
// Path: src/main/java/com/github/worldsender/mcanm/test/CubeEntity.java
// public class CubeEntity extends EntityPig implements IAnimatedObject {
// 	public static final IAnimation animation = CommonLoader
// 			.loadAnimation(new ResourceLocation("mcanm:models/Cube/idle.mcanm"));
// 
// 	public CubeEntity(World w) {
// 		super(w);
// 	}
// 
// 	@Override
// 	public RenderPassInformation preRenderCallback(float subFrame, RenderPassInformation callback) {
// 		return callback.setAnimation(Optional.of(animation)).setFrame(this.ticksExisted % 90 + subFrame);
// 	}
// }
// 
// Path: src/main/java/com/github/worldsender/mcanm/test/CubeEntityV2.java
// public class CubeEntityV2 extends EntityPig {
// 	public CubeEntityV2(World w) {
// 		super(w);
// 	}
// }


import org.apache.logging.log4j.Logger;
import com.github.worldsender.mcanm.client.config.MCAnmConfiguration;
import com.github.worldsender.mcanm.test.CubeEntity;
import com.github.worldsender.mcanm.test.CubeEntityV2;
import net.minecraft.launchwrapper.Launch;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fml.client.event.ConfigChangedEvent.OnConfigChangedEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.SidedProxy;
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.registry.EntityRegistry;

		isDebug = isDeobfEnv == null ? false : isDeobfEnv.booleanValue();
	}

	@Mod.Instance(Reference.core_modid)
	public static MCAnm instance;

	@SidedProxy(
			modId = Reference.core_modid,
			clientSide = "com.github.worldsender.mcanm.client.ClientProxy",
			serverSide = "com.github.worldsender.mcanm.server.ServerProxy")
	public static Proxy proxy;

	private MCAnmConfiguration config;
	private Logger logger;

	@Mod.EventHandler
	public void preInit(FMLPreInitializationEvent pre) {
		logger = pre.getModLog();
		config = new MCAnmConfiguration(pre.getSuggestedConfigurationFile());
		proxy.preInit();
		MinecraftForge.EVENT_BUS.register(this);
		logger.info("Successfully loaded MC Animations");
	}

	@Mod.EventHandler
	public void init(@SuppressWarnings("unused") FMLInitializationEvent event) {
		if (isDebug) {
			ResourceLocation ID_CUBE = new ResourceLocation("mcanm:cube");
			ResourceLocation ID_CUBE_V2 = new ResourceLocation("mcanm:cube2");
			EntityRegistry.registerModEntity(ID_CUBE, CubeEntity.class, "Cube", 0, this, 80, 1, true);

// Path: src/main/java/com/github/worldsender/mcanm/client/config/MCAnmConfiguration.java
// public class MCAnmConfiguration {
// 
// 	private Configuration config;
// 	private Property enableReload;
// 
// 	public MCAnmConfiguration(File loadFile) {
// 		config = new Configuration(loadFile);
// 		config.load();
// 		enableReload = config.get(Configuration.CATEGORY_GENERAL, Reference.config_reload_enabled, true)
// 				.setLanguageKey(Reference.gui_config_reload_enabled);
// 		save();
// 	}
// 
// 	public void onConfigChange(@SuppressWarnings("unused") OnConfigChangedEvent occe) {
// 		save();
// 	}
// 
// 	public void save() {
// 		if (config.hasChanged())
// 			config.save();
// 	}
// 
// 	public boolean isReloadEnabled() {
// 		return this.enableReload.getBoolean();
// 	}
// 
// 	public void addPropertiesToDisplayList(List<IConfigElement> list) {
// 		list.add(new ConfigElement(enableReload));
// 	}
// }
// 
// Path: src/main/java/com/github/worldsender/mcanm/test/CubeEntity.java
// public class CubeEntity extends EntityPig implements IAnimatedObject {
// 	public static final IAnimation animation = CommonLoader
// 			.loadAnimation(new ResourceLocation("mcanm:models/Cube/idle.mcanm"));
// 
// 	public CubeEntity(World w) {
// 		super(w);
// 	}
// 
// 	@Override
// 	public RenderPassInformation preRenderCallback(float subFrame, RenderPassInformation callback) {
// 		return callback.setAnimation(Optional.of(animation)).setFrame(this.ticksExisted % 90 + subFrame);
// 	}
// }
// 
// Path: src/main/java/com/github/worldsender/mcanm/test/CubeEntityV2.java
// public class CubeEntityV2 extends EntityPig {
// 	public CubeEntityV2(World w) {
// 		super(w);
// 	}
// }


// Path: src/main/java/com/github/worldsender/mcanm/MCAnm.java
import org.apache.logging.log4j.Logger;
import com.github.worldsender.mcanm.client.config.MCAnmConfiguration;
import com.github.worldsender.mcanm.test.CubeEntity;
import com.github.worldsender.mcanm.test.CubeEntityV2;
import net.minecraft.launchwrapper.Launch;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.fml.client.event.ConfigChangedEvent.OnConfigChangedEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.common.SidedProxy;
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
import net.minecraftforge.fml.common.registry.EntityRegistry;

		isDebug = isDeobfEnv == null ? false : isDeobfEnv.booleanValue();
	}

	@Mod.Instance(Reference.core_modid)
	public static MCAnm instance;

	@SidedProxy(
			modId = Reference.core_modid,
			clientSide = "com.github.worldsender.mcanm.client.ClientProxy",
			serverSide = "com.github.worldsender.mcanm.server.ServerProxy")
	public static Proxy proxy;

	private MCAnmConfiguration config;
	private Logger logger;

	@Mod.EventHandler
	public void preInit(FMLPreInitializationEvent pre) {
		logger = pre.getModLog();
		config = new MCAnmConfiguration(pre.getSuggestedConfigurationFile());
		proxy.preInit();
		MinecraftForge.EVENT_BUS.register(this);
		logger.info("Successfully loaded MC Animations");
	}

	@Mod.EventHandler
	public void init(@SuppressWarnings("unused") FMLInitializationEvent event) {
		if (isDebug) {
			ResourceLocation ID_CUBE = new ResourceLocation("mcanm:cube");
			ResourceLocation ID_CUBE_V2 = new ResourceLocation("mcanm:cube2");
			EntityRegistry.registerModEntity(ID_CUBE, CubeEntity.class, "Cube", 0, this, 80, 1, true);

			EntityRegistry.registerModEntity(ID_CUBE_V2, CubeEntityV2.class, "CubeV2", 1, this, 80, 1, true);
