O3Bubbles09

Untitled

Feb 12th, 2013
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 1.13 KB | None | 0 0
  1. package shelter.common;
  2.  
  3. import java.util.EnumSet;
  4.  
  5. import net.minecraft.entity.player.EntityPlayer;
  6. import net.minecraft.entity.player.EntityPlayerMP;
  7. import net.minecraft.item.ItemStack;
  8. import net.minecraft.server.management.ServerConfigurationManager;
  9. import cpw.mods.fml.client.FMLClientHandler;
  10. import cpw.mods.fml.common.FMLCommonHandler;
  11. import cpw.mods.fml.common.ITickHandler;
  12. import cpw.mods.fml.common.TickType;
  13.  
  14. public class ArmorTicker implements ITickHandler {
  15.  
  16.     private void onTickInGame(EntityPlayer player) {
  17.         ItemStack boots = FMLCommonHandler.instance().getMinecraftServerInstance().getServer().getServerConfigurationManager(ServerConfigurationManager.playerEntityList);
  18.        
  19.         if(boots != null && boots.itemID == shelter.common.Shelter.copperBoots.itemID) {
  20.             player.capabilities.allowFlying = true;
  21.             System.out.println("Code exacuted!");
  22.         }
  23.     }
  24.     private void onTickInGui() {
  25.  
  26.     }
  27.     public EnumSet<TickType> ticks() {
  28.         return null;
  29.     }
  30.     public String getLabel() {
  31.         return null;
  32.     }
  33.     public void tickStart(EnumSet<TickType> type, Object... tickData) {
  34.        
  35.     }
  36.     public void tickEnd(EnumSet<TickType> type, Object... tickData) {
  37.        
  38.     }
  39. }
Advertisement
Add Comment
Please, Sign In to add comment