gt:             if (quot > 0) {
context: package net.dungeonrealms.game.mastery;
  
  import net.dungeonrealms.common.Constants;
  import net.minecraft.server.v1_9_R2.Item;
  import org.bukkit.ChatColor;
  import org.bukkit.Material;
  import org.bukkit.entity.Player;
  import org.bukkit.inventory.ItemStack;
  import org.bukkit.inventory.meta.SkullMeta;
  
  import java.lang.reflect.Field;
  import java.text.SimpleDateFormat;
  import java.util.*;
  import java.util.logging.Logger;
  
  /**
   * Created by Nick on 9/17/2015.
   */
  public class Utils {
  
      public static Logger log = Constants.log;
  
      /**
       * Get a players head.
       *
       * @param player
       * @return
       * @since 1.0
       */
      public static ItemStack getPlayerHead(Player player) {
          ItemStack head = new ItemStack(Material.SKULL_ITEM, 1, (short) 3);
          SkullMeta meta = (SkullMeta) head.getItemMeta();
          meta.setOwner(player.getName());
          head.setItemMeta(meta);
          return head;
      }
  
      public static int randInt(int min, int max) {
  
          Random rand = new Random();
  
          return rand.nextInt((max - min) + 1) + min;
      }
  
      public static boolean isInt(String s) {
          try {
              Integer.parseInt(s);
          } catch (NumberFormatException nfe) {
              return false;
          }
          return true;
      }
  
      /**
       * Given a name in the format lowercaseprefix# (e.g. us0), converts to proper format (e.g. US-0)
       *
       * @param name
       * @return
       */
      public static String getFormattedShardName(String name) {
          return name.split("(?=[0-9])", 2)[0].toUpperCase() + "-" + name.split("(?=[0-9])", 2)[1];
      }
  
      public static void setMaxStackSize(Item item, int i){
          try {
  
              Field field = Item.class.getDeclaredField("maxStackSize");
              field.setAccessible(true);
              field.setInt(item, i);
  
          } catch (Exception e) {}
      }
  
      public static <T> Set<T> findDuplicates(Collection<T> list) {
          Set<T> duplicates = new HashSet<T>();
          Set<T> uniques = new HashSet<T>();
  
          for(T t : list) {
              if(!uniques.add(t)) {
                  duplicates.add(t);
              }
          }
  
          return duplicates;
      }
  
  
      public static int getRandomFromTier(int tier, String lvlRange) {
          Random r = new Random();
          int Low = 1;
          int High = 10;
          int R;
          //TODO: Remove the +2 from every level when we implement high/low properly
          switch (tier) {
              case 1:
                  Low = 1;
                  if (lvlRange.equalsIgnoreCase("high"))
                      Low = 5;
                  High = 10;
                  if (lvlRange.equalsIgnoreCase("low"))
                      High = 5;
                  R = r.nextInt(High - Low) + Low + 2;
                  return R;
              case 2:
                  Low = 10;
                  if (lvlRange.equalsIgnoreCase("high"))
                      Low = 15;
                  High = 20;
                  if (lvlRange.equalsIgnoreCase("low"))
                      High = 15;
                  R = r.nextInt(High - Low) + Low + 2;
                  return R;
              case 3:
                  Low = 20;
                  if (lvlRange.equalsIgnoreCase("high"))
                      Low = 25;
                  High = 30;
                  if (lvlRange.equalsIgnoreCase("low"))
                      High = 25;
                  R = r.nextInt(High - Low) + Low + 2;
                  return R;
              case 4:
                  Low = 30;
                  if (lvlRange.equalsIgnoreCase("high"))
                      Low = 35;
                  High = 40;
                  if (lvlRange.equalsIgnoreCase("low"))
                      High = 35;
                  R = r.nextInt(High - Low) + Low + 2;
                  return R;
              case 5:
                  Low = 40;
                  if (lvlRange.equalsIgnoreCase("high"))
                      Low = 45;
                  High = 100;
                  if (lvlRange.equalsIgnoreCase("low"))
                      High = 95;
                  R = r.nextInt(High - Low) + Low + 2;
                  return R;
          }
          return 1;
      }
  
      private final static int CENTER_PX = 154;
  
      public static void sendCenteredMessage(Player player, String message) {
          if (message == null || message.equals("")) player.sendMessage("");
  
          int messagePxSize = 0;
          boolean previousCode = false;
          boolean isBold = false;
  
          for (char c : message.toCharArray()) {
              if (c == '&') {
                  previousCode = true;
                  continue;
              } else if (previousCode == true) {
                  previousCode = false;
                  if (c == 'l' || c == 'L') {
                      isBold = true;
                      continue;
                  } else isBold = false;
              } else {
                  DefaultFontInfo dFI = DefaultFontInfo.getDefaultFontInfo(c);
                  messagePxSize += isBold ? dFI.getBoldLength() : dFI.getLength();
                  messagePxSize++;
              }
          }
  
          int halvedMessageSize = messagePxSize / 2;
          int toCompensate = CENTER_PX - halvedMessageSize;
          int spaceLength = DefaultFontInfo.SPACE.getLength() + 1;
          int compensated = 0;
          StringBuilder sb = new StringBuilder();
          while (compensated < toCompensate) {
              sb.append(" ");
              compensated += spaceLength;
          }
          player.sendMessage(ChatColor.translateAlternateColorCodes('&', sb.toString() + message));
      }
  
      public static String ucfirst(String string) {
          return Character.toUpperCase(string.charAt(0)) + string.substring(1).toLowerCase();
      }
  
      /**
       * Convert seconds into a human readable format.
       *
       * @param seconds
       * @return seconds.
       */
      public static String formatTimeAgo(int seconds) {
          if (seconds == 0) return "0 seconds"; // @note: 0 seconds is a special case.
  
          String date = "";
  
          String[] unitNames = {"week", "day", "hour", "minute", "second"};
          int[] unitValues = {604800, 86400, 3600, 60, 1};
  
          // Loop through all of the units.
          for (int i = 0; i < unitNames.length; i++) {
              int quot = seconds / unitValues[i];
  