9
0
mirror of https://github.com/HibiscusMC/HMCCosmetics.git synced 2025-12-30 12:29:16 +00:00

clean: make Type abstract

This commit is contained in:
Craftinators
2023-03-01 00:44:00 -05:00
parent 37a8a2379d
commit 461642d64b
2 changed files with 4 additions and 9 deletions

View File

@@ -5,7 +5,7 @@ import org.bukkit.event.inventory.ClickType;
import org.bukkit.inventory.meta.ItemMeta;
import org.spongepowered.configurate.ConfigurationNode;
public class Type {
public abstract class Type {
private final String id;
@@ -21,12 +21,8 @@ public class Type {
public void run(CosmeticUser user, ConfigurationNode config) {
run(user, config, null);
}
public void run(CosmeticUser user, ConfigurationNode config, ClickType clickType) {
// Override
}
public ItemMeta setLore(CosmeticUser user, ConfigurationNode config, ItemMeta itemMeta) {
//TODO: Finish this
return null; // Override
}
public abstract void run(CosmeticUser user, ConfigurationNode config, ClickType clickType);
public abstract ItemMeta setLore(CosmeticUser user, ConfigurationNode config, ItemMeta itemMeta);
}

View File

@@ -18,7 +18,6 @@ import java.util.List;
public class TypeEmpty extends Type {
// This can be used as an example for making your own types.
public TypeEmpty() {
super("empty");
// This is an empty type, meaning, when a menu item has a type of "empty" it will run the code in the method run.