/*
 * This file is part of GoodTime-Industrial, licensed under MIT License (MIT).
 *
 * Copyright (c) 2015 GoodTime Studio <https://github.com/GoodTimeStudio>
 * Copyright (c) contributors
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 */

package com.mcgoodtime.gti.common.core;

import com.mcgoodtime.gti.client.gui.GuiCarbonizeFurnace;
import com.mcgoodtime.gti.client.gui.GuiEVSU;
import com.mcgoodtime.gti.client.gui.GuiFluidKineticGenerator;
import com.mcgoodtime.gti.common.inventory.ContainerCarbonizeFurnace;
import com.mcgoodtime.gti.common.inventory.ContainerEVSU;
import com.mcgoodtime.gti.common.inventory.ContainerFluidKineticGenerator;
import com.mcgoodtime.gti.common.tiles.TileCarbonizeFurnace;
import com.mcgoodtime.gti.common.tiles.TileEVSU;
import com.mcgoodtime.gti.common.tiles.TileFluidKineticGenerator;
import cpw.mods.fml.common.network.IGuiHandler;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.world.World;

public class GuiHandler implements IGuiHandler {

    private static GuiHandler instance;

    /**
     * Instantiate or get the default GuiHandler
     * @return The only instance of the GuiHandler
     */
    public static GuiHandler getInstance() {
        if (instance == null) {
            instance = new GuiHandler();
        }
        return instance;
    }

    private GuiHandler() {

    }

    @Override
    public Object getServerGuiElement(int id, EntityPlayer player, World world, int x, int y, int z) {
        if (id == EnumGui.GenGasKu.ordinal()) {
            return new ContainerFluidKineticGenerator(player, (TileFluidKineticGenerator)world.getTileEntity(x, y, z));
        }
        if (id == EnumGui.CarbonizeFurnace.ordinal()) {
            return new ContainerCarbonizeFurnace(player, (TileCarbonizeFurnace)world.getTileEntity(x, y, z));
        }
        if (id == EnumGui.EVSU.ordinal()) {
            return new ContainerEVSU(player, (TileEVSU)world.getTileEntity(x, y, z));
        }
        return null;
    }

    @Override
    public Object getClientGuiElement(int id, EntityPlayer player, World world, int x, int y, int z) {
        if (id == EnumGui.GenGasKu.ordinal()) {
            return new GuiFluidKineticGenerator(new ContainerFluidKineticGenerator(player, (TileFluidKineticGenerator)world.getTileEntity(x, y, z)));
        }
        if (id == EnumGui.CarbonizeFurnace.ordinal()) {
            return new GuiCarbonizeFurnace(new ContainerCarbonizeFurnace(player, (TileCarbonizeFurnace)world.getTileEntity(x, y, z)));
        }
        if (id == EnumGui.EVSU.ordinal()) {
            return new GuiEVSU(new ContainerEVSU(player, (TileEVSU)world.getTileEntity(x, y, z)));
        }
        /*
        if (id == EnumGui.HeatDryer.ordinal()) {
            return new
        }*/
        return null;
    }

    public enum EnumGui {
        GenGasKu,
        CarbonizeFurnace,
        EVSU,
        HeatDryer
    }
}

@@ -1462,32 +1462,83 @@
 neticGenerator;%0A
+import com.mcgoodtime.gti.client.gui.GuiHeatDryer;%0A
 import com.mcgoo
@@ -1583,32 +1583,32 @@
 rbonizeFurnace;%0A
-
 import com.mcgoo
@@ -1716,32 +1716,95 @@
 neticGenerator;%0A
+import com.mcgoodtime.gti.common.inventory.ContainerHeatDryer;%0A
 import com.mcgoo
@@ -1955,32 +1955,86 @@
 neticGenerator;%0A
+import com.mcgoodtime.gti.common.tiles.TileHeatDryer;%0A
 import cpw.mods.
@@ -2690,32 +2690,45 @@
  == EnumGui.
-GenGasKu
+FluidKineticGenerator
 .ordinal()) 
@@ -3167,32 +3167,188 @@
  z));%0A        %7D%0A
+        if (id == EnumGui.HeatDryer.ordinal()) %7B%0A            return new ContainerHeatDryer(player, (TileHeatDryer) world.getTileEntity(x, y, z));%0A        %7D%0A
         return n
@@ -3502,24 +3502,37 @@
 EnumGui.
-GenGasKu
+FluidKineticGenerator
 .ordinal
@@ -4055,19 +4055,8 @@
   %7D%0A
-        /*%0A
     
@@ -4122,16 +4122,108 @@
 turn new
+ GuiHeatDryer(new ContainerHeatDryer(player, (TileHeatDryer) world.getTileEntity(x, y, z)));
 %0A       
@@ -4224,18 +4224,16 @@
        %7D
-*/
 %0A       
@@ -4291,16 +4291,29 @@
     
-GenGasKu
+FluidKineticGenerator
 ,%0A  

Rename GenGasKu to FluidKineticGenerator and Add HeatDryer gui