forked from Upstream/mmocore
!Removed useless util classes
This commit is contained in:
parent
6cdd7608d5
commit
8edbec6d21
@ -11,9 +11,9 @@ import org.bukkit.inventory.ItemStack;
|
||||
|
||||
import net.Indyuce.mmocore.MMOCore;
|
||||
import net.Indyuce.mmocore.api.droptable.dropitem.DropItem;
|
||||
import net.Indyuce.mmocore.api.load.PostLoadObject;
|
||||
import net.Indyuce.mmocore.api.loot.LootBuilder;
|
||||
import net.mmogroup.mmolib.api.MMOLineConfig;
|
||||
import net.mmogroup.mmolib.api.util.PostLoadObject;
|
||||
|
||||
public class DropTable extends PostLoadObject {
|
||||
private final String id;
|
||||
|
@ -10,10 +10,10 @@ import org.bukkit.enchantments.Enchantment;
|
||||
import org.bukkit.potion.PotionType;
|
||||
|
||||
import net.Indyuce.mmocore.MMOCore;
|
||||
import net.Indyuce.mmocore.api.load.PostLoadObject;
|
||||
import net.Indyuce.mmocore.api.util.math.formula.LinearValue;
|
||||
import net.mmogroup.mmolib.MMOLib;
|
||||
import net.mmogroup.mmolib.api.MMOLineConfig;
|
||||
import net.mmogroup.mmolib.api.util.PostLoadObject;
|
||||
|
||||
public class Profession extends PostLoadObject {
|
||||
private final String id, name;
|
||||
|
@ -1,27 +0,0 @@
|
||||
package net.Indyuce.mmocore.api.load;
|
||||
|
||||
import org.bukkit.configuration.ConfigurationSection;
|
||||
|
||||
public abstract class PostLoadObject {
|
||||
private ConfigurationSection config;
|
||||
|
||||
/*
|
||||
* objects which must load some data afterwards, like quests which must load
|
||||
* their parent quests after all quests were initialized or classes which
|
||||
* must load their subclasses
|
||||
*/
|
||||
public PostLoadObject(ConfigurationSection config) {
|
||||
this.config = config;
|
||||
}
|
||||
|
||||
public void postLoad() {
|
||||
whenPostLoaded(config);
|
||||
|
||||
/*
|
||||
* clean config object for garbage collection
|
||||
*/
|
||||
config = null;
|
||||
}
|
||||
|
||||
protected abstract void whenPostLoaded(ConfigurationSection config);
|
||||
}
|
@ -26,7 +26,6 @@ import com.mojang.authlib.properties.Property;
|
||||
import net.Indyuce.mmocore.MMOCore;
|
||||
import net.Indyuce.mmocore.api.experience.ExpCurve;
|
||||
import net.Indyuce.mmocore.api.experience.source.type.ExperienceSource;
|
||||
import net.Indyuce.mmocore.api.load.PostLoadObject;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.EventTrigger;
|
||||
import net.Indyuce.mmocore.api.player.profess.resource.ManaDisplayOptions;
|
||||
import net.Indyuce.mmocore.api.player.profess.resource.PlayerResource;
|
||||
@ -40,6 +39,7 @@ import net.Indyuce.mmocore.api.util.math.particle.CastingParticle;
|
||||
import net.md_5.bungee.api.ChatColor;
|
||||
import net.mmogroup.mmolib.MMOLib;
|
||||
import net.mmogroup.mmolib.api.MMOLineConfig;
|
||||
import net.mmogroup.mmolib.api.util.PostLoadObject;
|
||||
import net.mmogroup.mmolib.version.VersionMaterial;
|
||||
|
||||
public class PlayerClass extends PostLoadObject {
|
||||
|
@ -13,10 +13,10 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||
|
||||
import net.Indyuce.mmocore.MMOCore;
|
||||
import net.Indyuce.mmocore.api.experience.Profession;
|
||||
import net.Indyuce.mmocore.api.load.PostLoadObject;
|
||||
import net.Indyuce.mmocore.api.player.PlayerData;
|
||||
import net.Indyuce.mmocore.api.quest.objective.Objective;
|
||||
import net.mmogroup.mmolib.api.MMOLineConfig;
|
||||
import net.mmogroup.mmolib.api.util.PostLoadObject;
|
||||
|
||||
public class Quest extends PostLoadObject {
|
||||
private final String id;
|
||||
|
@ -8,7 +8,6 @@ import java.util.Map;
|
||||
import java.util.Set;
|
||||
import java.util.logging.Level;
|
||||
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.*;
|
||||
import org.apache.commons.lang.Validate;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Material;
|
||||
@ -20,6 +19,12 @@ import net.Indyuce.mmocore.api.player.PlayerData;
|
||||
import net.Indyuce.mmocore.api.player.profess.ClassOption;
|
||||
import net.Indyuce.mmocore.api.player.profess.PlayerClass;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.EventTriggerHandler;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.AttackEventTrigger;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.BlockBrokenTrigger;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.BlockPlacedTrigger;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.ClassChosenEventTrigger;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.LevelUpEventTrigger;
|
||||
import net.Indyuce.mmocore.api.player.profess.event.trigger.MultipleLevelUpEventTrigger;
|
||||
|
||||
public class ClassManager extends MMOManager {
|
||||
private final Map<String, PlayerClass> map = new HashMap<>();
|
||||
|
@ -12,8 +12,8 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||
|
||||
import net.Indyuce.mmocore.MMOCore;
|
||||
import net.Indyuce.mmocore.api.block.BlockType;
|
||||
import net.Indyuce.mmocore.api.load.PostLoadObject;
|
||||
import net.mmogroup.mmolib.api.MMOLineConfig;
|
||||
import net.mmogroup.mmolib.api.util.PostLoadObject;
|
||||
|
||||
public class RestrictionManager {
|
||||
// private Set<String> breakBlackList = new HashSet<>();
|
||||
|
Loading…
Reference in New Issue
Block a user