Package rsb.methods
Class Skills
java.lang.Object
rsb.methods.MethodProvider
rsb.methods.Skills
This class is for all the skill calculations.
Example usage: skills.getRealLevel(Skills.ATTACK);
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int[]
A table containing the experiences that begin each level.Fields inherited from class rsb.methods.MethodProvider
methods
-
Method Summary
Modifier and TypeMethodDescriptioncreateTracker
(int... skills) Deprecated.boolean
doHover
(int component) Moves the mouse over a given component in the stats tab.int
getCurrentExp
(int index) Gets the current experience for the given skill.int
getCurrentLevel
(int index) Gets the effective level of the given skill (accounting for temporary boosts and reductions).int
getExpToNextLevel
(int index) Gets the experience remaining until reaching the next level in a given skill.static int
Gets the index of the skill with a given name.static int
getLevelAt
(int exp) Gets the level at the given experience.int
getMaxExp
(int index) Gets the maximum experience of a given skill.int
getMaxLevel
(int index) Gets the maximum level of a given skill.int
getPercentToNextLevel
(int index) Gets the percentage to the next level in a given skill.int
getRealLevel
(int index) Gets the player's current level in a skill based on their experience in that skill.static net.runelite.api.Skill
getSkill
(int index)
-
Field Details
-
XP_TABLE
public static final int[] XP_TABLEA table containing the experiences that begin each level.
-
-
Method Details
-
getSkill
public static net.runelite.api.Skill getSkill(int index) -
getIndex
Gets the index of the skill with a given name. This is not case sensitive.- Parameters:
statName
- The skill's name.- Returns:
- The index of the specified skill; otherwise -1.
-
getLevelAt
public static int getLevelAt(int exp) Gets the level at the given experience.- Parameters:
exp
- The experience.- Returns:
- The level based on the experience given.
-
getCurrentExp
public int getCurrentExp(int index) Gets the current experience for the given skill.- Parameters:
index
- The index of the skill.- Returns:
- -1 if the skill is unavailable
-
getCurrentLevel
public int getCurrentLevel(int index) Gets the effective level of the given skill (accounting for temporary boosts and reductions).- Parameters:
index
- The index of the skill.- Returns:
- The current level of the given Skill.
-
getRealLevel
public int getRealLevel(int index) Gets the player's current level in a skill based on their experience in that skill.- Parameters:
index
- The index of the skill.- Returns:
- The real level of the skill.
- See Also:
-
getPercentToNextLevel
public int getPercentToNextLevel(int index) Gets the percentage to the next level in a given skill.- Parameters:
index
- The index of the skill.- Returns:
- The percent to the next level of the provided skill or 0 if level of skill is 99.
-
getMaxLevel
public int getMaxLevel(int index) Gets the maximum level of a given skill.- Parameters:
index
- The index of the skill.- Returns:
- The max level of the skill.
-
getMaxExp
public int getMaxExp(int index) Gets the maximum experience of a given skill.- Parameters:
index
- The index of the skill.- Returns:
- The max experience of the skill.
-
getExpToNextLevel
public int getExpToNextLevel(int index) Gets the experience remaining until reaching the next level in a given skill.- Parameters:
index
- The index of the skill.- Returns:
- The experience to the next level of the skill.
-
doHover
public boolean doHover(int component) Moves the mouse over a given component in the stats tab.- Parameters:
component
- The component index.- Returns:
true
if the mouse was moved over the given component index.
-
createTracker
Deprecated.Creates a new SkillTracker.- Parameters:
skills
- Skills to track.- Returns:
- New instance of SkillTracker.
- See Also:
-