Skip to content
Nifim edited this page Jul 1, 2018 · 3 revisions

Player skills can be indexed by skill id, skill name, or by category name.

Magic, Combat, Puppet Skills

great_sword = player.skills["Great Sword"]
print(great_sword.level, great_sword.capped)

magic, combat, and puppet skills return a table containing:

  • level : A number repersenting the skills current level.
  • capped : A boolean representing the if the skill is capped. true = capped, false = uncapped.

Crafting Skills

goldsmithing = player.skills.Goldsmithing
print(goldsmithing.level, goldsmithing.rank_id, goldsmithing.capped)

crafting skills return a table containing:

  • level : A number repersenting the skills current level.
  • rank_id : A number representing the skills current rank id.
  • capped : A boolean representing the if the skill is capped. true = capped, false = uncapped.

Index by category

combat_skills = player.skills.Combat
for id, skill in pairs(combat_skills) do
    print("Combat Skill: ", id, skill.level, skill.capped)
end

Indexing the skills table with a category returns a table containing skill matching the category indexed.
The tabel returned can be indexed by skill ID or skill name.

Clone this wiki locally