Package rsb.util

Class SkillTracker

java.lang.Object
rsb.util.SkillTracker

@Deprecated public class SkillTracker extends Object
Deprecated.
A class for tracking experience gains in specified skills. The three arrays (skills, startExp, currentExp) are constantly congruent, and updated as such.
Author:
GigiaJ
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    int[]
    Deprecated.
     
    int
    Deprecated.
     
    int
    Deprecated.
     
    int[]
    Deprecated.
     
    long
    Deprecated.
     
    boolean
    Deprecated.
     
    int[]
    Deprecated.
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    SkillTracker(RuneLite bot, int... skills)
    Deprecated.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(int skill)
    Deprecated.
    Adds a skill into the skills array and updates it.
    boolean
    arrayContains(int index, int[] array)
    Deprecated.
    Determines if an array contains the specified index.
    int
    getArrayIndex(int secondaryIndex, int[] array)
    Deprecated.
    Determines the true index for an item within the specified array.
    int[]
    Deprecated.
    Calculates the true gains of the skills being tracked.
    int[]
    Deprecated.
    Calculates the experience gained per hour.
    getName(int skill)
    Deprecated.
    Retrieves the name of the indicated skill.
    long
    Deprecated.
    Calculates the current runtime.
    int[]
    Deprecated.
    Calculates number of seconds until level gain
    void
    growAtEnd(int growth)
    Deprecated.
    Expands the current array (skillsList) by the specified growth.
    boolean
    Deprecated.
    Determines if the current SkillTracker is started.
    void
    remove(int index)
    Deprecated.
    Removes an item using index (of item in array).
    boolean
    removeSkill(int index)
    Deprecated.
    Removes an item from the current array.
    static String
    SecToHMS(int sec)
    Deprecated.
    Converts a number of seconds into a string of form hh:mm:ss
    void
    Deprecated.
    Updates all the skills within the current array and starts the time at the currentTimeMillis.
    int[]
    Deprecated.
    Returns the main value of the skills array.
    void
    update(int index)
    Deprecated.
    Updates a single skill dependent on the index of the skill.
    void
    Deprecated.
    Updates all skills within the skills array.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • skills

      public int[] skills
      Deprecated.
    • startExp

      public int[] startExp
      Deprecated.
    • currentExp

      public int[] currentExp
      Deprecated.
    • firstIndex

      public transient int firstIndex
      Deprecated.
    • lastIndex

      public transient int lastIndex
      Deprecated.
    • start

      public long start
      Deprecated.
    • started

      public boolean started
      Deprecated.
  • Constructor Details

    • SkillTracker

      public SkillTracker(RuneLite bot, int... skills)
      Deprecated.
  • Method Details

    • start

      public void start()
      Deprecated.
      Updates all the skills within the current array and starts the time at the currentTimeMillis.
    • isStarted

      public boolean isStarted()
      Deprecated.
      Determines if the current SkillTracker is started.
      Returns:
      true if the tracker is started; otherwise false
    • getRuntime

      public long getRuntime()
      Deprecated.
      Calculates the current runtime.
      Returns:
      the runtime of the tracker
    • updateAll

      public void updateAll()
      Deprecated.
      Updates all skills within the skills array.
    • update

      public void update(int index)
      Deprecated.
      Updates a single skill dependent on the index of the skill.
      Parameters:
      index - the index of the skill to update
    • remove

      public void remove(int index)
      Deprecated.
      Removes an item using index (of item in array). Recommended to use removeItem to remove via skill index.
      Parameters:
      index - the skill to remove from the array
    • removeSkill

      public boolean removeSkill(int index)
      Deprecated.
      Removes an item from the current array.
      Parameters:
      index - Of the skill to remove.
      Returns:
      true If removed.
    • add

      public void add(int skill)
      Deprecated.
      Adds a skill into the skills array and updates it. Start experience will be calculated during the the exact time the item is added into the array.
      Parameters:
      skill - The skill to add.
    • arrayContains

      public boolean arrayContains(int index, int[] array)
      Deprecated.
      Determines if an array contains the specified index.
      Parameters:
      index - the index to check
      array - the array to check
      Returns:
      true if the array contains the index; otherwise false
    • getArrayIndex

      public int getArrayIndex(int secondaryIndex, int[] array)
      Deprecated.
      Determines the true index for an item within the specified array.
      Parameters:
      secondaryIndex - the inner index in the array to check
      array - the array to check
      Returns:
      the true index
    • growAtEnd

      public void growAtEnd(int growth)
      Deprecated.
      Expands the current array (skillsList) by the specified growth.
      Parameters:
      growth - the integer amount to increase the array size by
    • toArray

      public int[] toArray()
      Deprecated.
      Returns the main value of the skills array.
      Returns:
      the skills array
    • getGains

      public int[] getGains()
      Deprecated.
      Calculates the true gains of the skills being tracked. (Updates current experience)
      Returns:
      an array containing the calculated gains of the skills tracked
    • getHourlyGains

      public int[] getHourlyGains()
      Deprecated.
      Calculates the experience gained per hour. (Updates current experience)
      Returns:
      the calculated hourly gains
    • getName

      public String getName(int skill)
      Deprecated.
      Retrieves the name of the indicated skill.
      Parameters:
      skill - the index to check for
      Returns:
      the name of the skill at a specified index
    • getSecTNL

      public int[] getSecTNL()
      Deprecated.
      Calculates number of seconds until level gain
      Returns:
      the calculated value estimate for gaining a level
    • SecToHMS

      public static String SecToHMS(int sec)
      Deprecated.
      Converts a number of seconds into a string of form hh:mm:ss
      Parameters:
      sec - the seconds to convert into the HMS format
      Returns:
      the hour minutes and seconds representation of the parameter