// Path: src/minecraft/andrew/powersuits/common/GuiHandler.java
// public class GuiHandler implements IGuiHandler {
// 
//     public static int craftingGuiID = 0;
//     public static int manualGuiID = 1;
// 
//     @Override
//     public Object getServerGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) {
//         switch (ID) {
//             case 0:
//                 return new PortableCraftingContainer(player.inventory, world, (int) player.posX, (int) player.posY, (int) player.posZ);
//             default:
//                 return null;
//         }
//     }
// 
//     @Override
//     public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) {
//         switch (ID) {
//             case 0:
//                 return new PortableCraftingGui(player, world, (int) player.posX, (int) player.posY, (int) player.posZ);
//             case 1:
//                 ItemStack stack = player.getCurrentEquippedItem();
//                 return new ManualGui(stack, ClientProxy.manual);
//             default:
//                 return null;
//         }
//     }
// 
// }
// 
// Path: src/minecraft/andrew/powersuits/common/ModularPowersuitsAddons.java
// @Mod(modid = "PowersuitAddons", name = "Andrew's Modular Powersuits Addons", version = "@VERSION@", dependencies = "required-after:mmmPowersuits", acceptedMinecraftVersions = "[1.5,)")
// @NetworkMod(clientSideRequired = true, serverSideRequired = false,
//         clientPacketHandlerSpec = @SidedPacketHandler(channels = {"psa"}, packetHandler = AndrewPacketHandler.class),
//         serverPacketHandlerSpec = @SidedPacketHandler(channels = {"psa"}, packetHandler = AndrewPacketHandler.class))
// public class ModularPowersuitsAddons {
// 
//     public static GuiHandler guiHandler = new GuiHandler();
// 
//     public static ItemBook book;
// 
//     @Instance("PowersuitAddons")
//     public static ModularPowersuitsAddons INSTANCE;
// 
//     @SidedProxy(clientSide = "andrew.powersuits.client.ClientProxy", serverSide = "andrew.powersuits.common.CommonProxy")
//     public static CommonProxy proxy;
// 
//     @PreInit
//     public void preInit(FMLPreInitializationEvent event) {
//         AddonConfig.setConfigFolderBase(event.getModConfigurationDirectory());
//         AddonConfig.initItems();
//         proxy.registerRenderers();
//         //proxy.readManuals();
//     }
// 
//     @Init
//     public void load(FMLInitializationEvent event) {
//         //book = new ItemBook(AddonConfig.manualID);
//         AddonComponent.populate();
//         AddonConfig.loadPowerModules();
//         Localization.loadCurrentLanguage();
//         AddonConfig.loadOptions();
//         proxy.registerHandlers();
//         NetworkRegistry.instance().registerGuiHandler(this, guiHandler);
//     }
// 
//     @PostInit
//     public void postInit(FMLPostInitializationEvent event) {
//         AddonRecipeManager.addRecipes();
//         AddonConfig.getConfig().save();
//     }
// }


import andrew.powersuits.common.GuiHandler;
import andrew.powersuits.common.ModularPowersuitsAddons;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.machinemuse.powersuits.common.Config;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
package andrew.powersuits.book;


/**
 * Created by User: Andrew2448
 * 11:54 PM 7/26/13
 */
public class ItemBook extends Item {

    public ItemBook(int i) {
        super(i);
        setMaxStackSize(1);
        setCreativeTab(Config.getCreativeTab());
    }

    @Override
    public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) {
// Path: src/minecraft/andrew/powersuits/common/GuiHandler.java
// public class GuiHandler implements IGuiHandler {
// 
//     public static int craftingGuiID = 0;
//     public static int manualGuiID = 1;
// 
//     @Override
//     public Object getServerGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) {
//         switch (ID) {
//             case 0:
//                 return new PortableCraftingContainer(player.inventory, world, (int) player.posX, (int) player.posY, (int) player.posZ);
//             default:
//                 return null;
//         }
//     }
// 
//     @Override
//     public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) {
//         switch (ID) {
//             case 0:
//                 return new PortableCraftingGui(player, world, (int) player.posX, (int) player.posY, (int) player.posZ);
//             case 1:
//                 ItemStack stack = player.getCurrentEquippedItem();
//                 return new ManualGui(stack, ClientProxy.manual);
//             default:
//                 return null;
//         }
//     }
// 
// }
// 
// Path: src/minecraft/andrew/powersuits/common/ModularPowersuitsAddons.java
// @Mod(modid = "PowersuitAddons", name = "Andrew's Modular Powersuits Addons", version = "@VERSION@", dependencies = "required-after:mmmPowersuits", acceptedMinecraftVersions = "[1.5,)")
// @NetworkMod(clientSideRequired = true, serverSideRequired = false,
//         clientPacketHandlerSpec = @SidedPacketHandler(channels = {"psa"}, packetHandler = AndrewPacketHandler.class),
//         serverPacketHandlerSpec = @SidedPacketHandler(channels = {"psa"}, packetHandler = AndrewPacketHandler.class))
// public class ModularPowersuitsAddons {
// 
//     public static GuiHandler guiHandler = new GuiHandler();
// 
//     public static ItemBook book;
// 
//     @Instance("PowersuitAddons")
//     public static ModularPowersuitsAddons INSTANCE;
// 
//     @SidedProxy(clientSide = "andrew.powersuits.client.ClientProxy", serverSide = "andrew.powersuits.common.CommonProxy")
//     public static CommonProxy proxy;
// 
//     @PreInit
//     public void preInit(FMLPreInitializationEvent event) {
//         AddonConfig.setConfigFolderBase(event.getModConfigurationDirectory());
//         AddonConfig.initItems();
//         proxy.registerRenderers();
//         //proxy.readManuals();
//     }
// 
//     @Init
//     public void load(FMLInitializationEvent event) {
//         //book = new ItemBook(AddonConfig.manualID);
//         AddonComponent.populate();
//         AddonConfig.loadPowerModules();
//         Localization.loadCurrentLanguage();
//         AddonConfig.loadOptions();
//         proxy.registerHandlers();
//         NetworkRegistry.instance().registerGuiHandler(this, guiHandler);
//     }
// 
//     @PostInit
//     public void postInit(FMLPostInitializationEvent event) {
//         AddonRecipeManager.addRecipes();
//         AddonConfig.getConfig().save();
//     }
// }


// Path: src/minecraft/andrew/powersuits/book/ItemBook.java
import andrew.powersuits.common.GuiHandler;
import andrew.powersuits.common.ModularPowersuitsAddons;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.machinemuse.powersuits.common.Config;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;

package andrew.powersuits.book;


/**
 * Created by User: Andrew2448
 * 11:54 PM 7/26/13
 */
public class ItemBook extends Item {

    public ItemBook(int i) {
        super(i);
        setMaxStackSize(1);
        setCreativeTab(Config.getCreativeTab());
    }

    @Override
    public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player) {
        player.openGui(ModularPowersuitsAddons.INSTANCE, GuiHandler.manualGuiID, world, 0, 0, 0);