public class NEIServerUtils
extends java.lang.Object
| Constructor and Description |
|---|
NEIServerUtils() |
| Modifier and Type | Method and Description |
|---|---|
static void |
advanceDisabledTimes(World world) |
static boolean |
areStacksIdentical(ItemStack stack1,
ItemStack stack2) |
static boolean |
areStacksSameType(ItemStack stack1,
ItemStack stack2) |
static boolean |
areStacksSameTypeCrafting(ItemStack stack1,
ItemStack stack2)
ItemStacks with damage -1 are wildcards allowing all damages. |
static boolean |
canItemFitInInventory(EntityPlayer player,
ItemStack itemstack) |
static int |
compareStacks(ItemStack stack1,
ItemStack stack2)
A simple function for comparing ItemStacks in a compatible with comparators.
|
static ItemStack |
copyStack(ItemStack itemstack) |
static ItemStack |
copyStack(ItemStack itemstack,
int i) |
static void |
cycleCreativeInv(EntityPlayerMP player,
int steps) |
static void |
deleteAllItems(EntityPlayerMP player) |
static boolean |
doesEnchantmentConflict(java.util.List<int[]> enchantments,
Enchantment e) |
static ItemStack[] |
extractRecipeItems(java.lang.Object obj) |
static java.lang.StringBuilder |
fixTrailingCommaList(java.lang.StringBuilder sb) |
static int |
getCreativeMode(EntityPlayerMP player) |
static int |
getEnchantmentLevel(ItemStack itemstack,
int e) |
static java.util.List<int[]> |
getEnchantments(ItemStack itemstack) |
static GameType |
getGameType(int mode) |
static java.util.List<java.lang.Integer> |
getRange(int start,
int end) |
static ItemStack |
getSlotContents(EntityPlayer player,
int slot,
boolean containerInv) |
static long |
getTime(World world) |
static void |
givePlayerItem(EntityPlayerMP player,
ItemStack stack,
boolean infinite,
boolean doGive) |
static void |
healPlayer(EntityPlayer player) |
static boolean |
isRaining(World world) |
static void |
logOnce(java.lang.Throwable t,
java.util.Set<java.lang.String> stackTraces,
java.lang.String message) |
static void |
logOnce(java.lang.Throwable t,
java.util.Set<java.lang.String> stackTraces,
java.lang.String message,
java.lang.String identifier) |
static NBTTagCompound |
readNBT(java.io.File file) |
static void |
sendNotice(ICommandSender sender,
IChatComponent msg,
java.lang.String permission) |
static IChatComponent |
setColour(IChatComponent msg,
EnumChatFormatting colour) |
static void |
setGamemode(EntityPlayerMP player,
int mode) |
static void |
setHourForward(World world,
int hour,
boolean notify) |
static void |
setSlotContents(EntityPlayer player,
int slot,
ItemStack item,
boolean containerInv) |
static void |
setTime(long l,
World world) |
static boolean |
stackHasEnchantment(ItemStack itemstack,
int e) |
static java.lang.RuntimeException |
throwCME(java.lang.String msg) |
static void |
toggleMagnetMode(EntityPlayerMP player) |
static void |
toggleRaining(World world,
boolean notify) |
static void |
writeNBT(NBTTagCompound tag,
java.io.File file) |
public static boolean isRaining(World world)
public static void toggleRaining(World world,
boolean notify)
public static void healPlayer(EntityPlayer player)
public static long getTime(World world)
public static void setTime(long l,
World world)
public static void setSlotContents(EntityPlayer player,
int slot,
ItemStack item,
boolean containerInv)
public static ItemStack getSlotContents(EntityPlayer player,
int slot,
boolean containerInv)
public static void deleteAllItems(EntityPlayerMP player)
public static void setHourForward(World world,
int hour,
boolean notify)
public static void advanceDisabledTimes(World world)
public static boolean canItemFitInInventory(EntityPlayer player,
ItemStack itemstack)
public static void sendNotice(ICommandSender sender,
IChatComponent msg,
java.lang.String permission)
public static boolean areStacksSameType(ItemStack stack1,
ItemStack stack2)
stack1 - The ItemStack being compared.stack2 - The ItemStack to compare to.public static boolean areStacksSameTypeCrafting(ItemStack stack1,
ItemStack stack2)
ItemStacks with damage -1 are wildcards allowing all damages. Eg all colours of wool are allowed to create Beds.stack1 - The ItemStack being compared.stack2 - The ItemStack to compare to.public static int compareStacks(ItemStack stack1,
ItemStack stack2)
stack1 - The ItemStack being compared.stack2 - The ItemStack to compare to.public static boolean areStacksIdentical(ItemStack stack1,
ItemStack stack2)
public static IChatComponent setColour(IChatComponent msg,
EnumChatFormatting colour)
public static void givePlayerItem(EntityPlayerMP player,
ItemStack stack,
boolean infinite,
boolean doGive)
public static ItemStack copyStack(ItemStack itemstack,
int i)
public static ItemStack copyStack(ItemStack itemstack)
public static void toggleMagnetMode(EntityPlayerMP player)
public static int getCreativeMode(EntityPlayerMP player)
public static GameType getGameType(int mode)
public static void setGamemode(EntityPlayerMP player,
int mode)
public static void cycleCreativeInv(EntityPlayerMP player,
int steps)
public static java.util.List<int[]> getEnchantments(ItemStack itemstack)
public static boolean stackHasEnchantment(ItemStack itemstack,
int e)
public static int getEnchantmentLevel(ItemStack itemstack,
int e)
public static boolean doesEnchantmentConflict(java.util.List<int[]> enchantments,
Enchantment e)
public static java.lang.RuntimeException throwCME(java.lang.String msg)
public static ItemStack[] extractRecipeItems(java.lang.Object obj)
public static java.util.List<java.lang.Integer> getRange(int start,
int end)
public static java.lang.StringBuilder fixTrailingCommaList(java.lang.StringBuilder sb)
public static void logOnce(java.lang.Throwable t,
java.util.Set<java.lang.String> stackTraces,
java.lang.String message)
public static void logOnce(java.lang.Throwable t,
java.util.Set<java.lang.String> stackTraces,
java.lang.String message,
java.lang.String identifier)
public static NBTTagCompound readNBT(java.io.File file)
throws java.io.IOException
java.io.IOExceptionpublic static void writeNBT(NBTTagCompound tag,
java.io.File file)
throws java.io.IOException
java.io.IOException