diff --git a/src/main/java/net/Indyuce/mmocore/manager/ExperienceManager.java b/src/main/java/net/Indyuce/mmocore/manager/ExperienceManager.java index 8fe36b42..3f941a7b 100644 --- a/src/main/java/net/Indyuce/mmocore/manager/ExperienceManager.java +++ b/src/main/java/net/Indyuce/mmocore/manager/ExperienceManager.java @@ -59,7 +59,6 @@ public class ExperienceManager implements MMOCoreManager { return Objects.requireNonNull(expTables.get(id), "Could not find exp table with ID '" + id + "'"); } - @Deprecated public ExperienceTable loadExperienceTable(Object obj) { if (obj instanceof ConfigurationSection) diff --git a/src/main/resources/default/classes/arcane-mage.yml b/src/main/resources/default/classes/arcane-mage.yml index 1d4aec7c..2ecd420a 100644 --- a/src/main/resources/default/classes/arcane-mage.yml +++ b/src/main/resources/default/classes/arcane-mage.yml @@ -35,13 +35,11 @@ exp-curve: levels max-level: 100 # This class must not display in /class -# becasue it is a subclass of mage +# because it is a subclass of mage options: display: false -triggers: - level-up: - - 'command{format="mmocore admin skill-points give %player% 1"}' +exp-table: class_exp_table attributes: max-health: diff --git a/src/main/resources/default/classes/mage.yml b/src/main/resources/default/classes/mage.yml index e10612ee..40de28fa 100644 --- a/src/main/resources/default/classes/mage.yml +++ b/src/main/resources/default/classes/mage.yml @@ -32,9 +32,7 @@ exp-curve: levels # The maximum level players can reach max-level: 100 -triggers: - level-up: - - 'command{format="mmocore admin skill-points give %player% 1"}' +exp-table: class_exp_table # This is the default mana display options, however it is not mandatory # to have it in your class config file. Other classes do not have this diff --git a/src/main/resources/default/classes/marksman.yml b/src/main/resources/default/classes/marksman.yml index a1cd00a5..53c174bb 100644 --- a/src/main/resources/default/classes/marksman.yml +++ b/src/main/resources/default/classes/marksman.yml @@ -31,9 +31,7 @@ exp-curve: levels # The maximum level players can reach max-level: 100 -triggers: - level-up: - - 'command{format="mmocore admin skill-points give %player% 1"}' +exp-table: class_exp_table # Particles displayed around the player # when he enters the casting mode. diff --git a/src/main/resources/default/classes/paladin.yml b/src/main/resources/default/classes/paladin.yml index bc9a7782..1914e23b 100644 --- a/src/main/resources/default/classes/paladin.yml +++ b/src/main/resources/default/classes/paladin.yml @@ -33,13 +33,7 @@ exp-curve: levels # The maximum level players can reach max-level: 100 -triggers: - level-up: - - 'command{format="mmocore admin skill-points give %player% 1"}' - - # Get some mana back when dealing magic damage. - magic-damage: - - 'mana{operation=GIVE;amount=1}' +exp-table: class_exp_table cast-particle: particle: VILLAGER_HAPPY diff --git a/src/main/resources/default/classes/rogue.yml b/src/main/resources/default/classes/rogue.yml index a11eb4b6..d22d3ce1 100644 --- a/src/main/resources/default/classes/rogue.yml +++ b/src/main/resources/default/classes/rogue.yml @@ -31,11 +31,10 @@ exp-curve: levels # The maximum level players can reach max-level: 100 -triggers: - level-up: - - 'command{format="mmocore admin skill-points give %player% 1"}' +exp-table: class_exp_table options: + # Mana and health regen only applies when out of combat off-combat-mana-regen: true off-combat-health-regen: true diff --git a/src/main/resources/default/classes/warrior.yml b/src/main/resources/default/classes/warrior.yml index 9c25487b..bf127b0f 100644 --- a/src/main/resources/default/classes/warrior.yml +++ b/src/main/resources/default/classes/warrior.yml @@ -53,15 +53,14 @@ mana: empty: WHITE name: 'Rage' +exp-table: class_exp_table + # Rage charges when dealing weapon and physical damage. triggers: weapon-damage: - 'mana{operation=GIVE;amount=2-3}' physical-damage: - 'mana{operation=GIVE;amount=2-3}' - - level-up: - - 'command{format="mmocore admin skill-points give %player% 1"}' cast-particle: particle: REDSTONE diff --git a/src/main/resources/default/exp-tables.yml b/src/main/resources/default/exp-tables.yml index 842f8d10..c347878d 100644 --- a/src/main/resources/default/exp-tables.yml +++ b/src/main/resources/default/exp-tables.yml @@ -31,6 +31,14 @@ example_exp_table: - 'exp{amount=80}' - 'command{format="broadcast Boy, %player_name% level up twice in one of his(her) professions!"}' +# Exp table used by class to provide +# one skill point every level up +class_exp_table: + skill_point: + period: 1 + triggers: + - 'command{format="mmocore admin skill-points give %player% 1"}' + second_exp_table: # Base exp every level up, sweet.