Cleanup the guis.

This commit is contained in:
Brianna 2019-08-07 19:47:56 -04:00
parent 84dd2e024b
commit a4bb52979d
18 changed files with 134 additions and 136 deletions

View File

@ -7,6 +7,8 @@ import com.songoda.epicenchants.utils.objects.ItemBuilder;
import org.bukkit.configuration.file.FileConfiguration;
import org.bukkit.event.Listener;
import java.util.Optional;
import static com.songoda.epicenchants.utils.single.GeneralUtils.*;
public class MainInfoMenu extends FastInv implements Listener {
@ -18,6 +20,7 @@ public class MainInfoMenu extends FastInv implements Listener {
.map(s -> "contents." + s)
.map(config::getConfigurationSection)
.forEach(section -> addItem(getSlots(section.getString("slot")), new ItemBuilder(section).build(), event -> {
if (section.getString("group") == null) return;
Group group = instance.getGroupManager().getValue(section.getString("group"))
.orElseThrow(() -> new IllegalArgumentException("Invalid group: " + section.getString("group")));
instance.getInfoManager().getMenu(group).ifPresent(menu -> menu.open(event.getPlayer()));

View File

@ -34,6 +34,22 @@ contents:
accept-before:
material: INK_SACK
data: 1
display-name: "&cWaiting for you..."
lore:
- "&7The alchemist is waiting"
- "&7for your enchange..."
accept-after:
material: INK_SACK
data: 10
display-name: "&eClick to confirm"
lore:
- "&cCost: {exp_cost} EXP"
- ""
- "&7Click to confirm the exchange"
- "&7after which you will receive"
- "&7the item displayed above."
explanation:
material: PAINTING
display-name: "&8[&eThe Alchemist&8]"
lore:
- "&7The alchemist will exchange:"
@ -47,18 +63,6 @@ contents:
- "&7(of the same rarity) &ffor"
- "&fthe same dust"
- "&7(of a higher percentage)"
accept-after:
material: INK_SACK
data: 1
display-name: "&eClick to confirm"
lore:
- "&cCost: {exp_cost} EXP"
- ""
- "&7Click to confirm the exchange"
- "&7after which you will receive"
- "&7the item displayed above."
explanation:
material: PAINTING
slot: 4
corners:
material: STAINED_GLASS_PANE
@ -69,4 +73,4 @@ contents:
material: STAINED_GLASS_PANE
data: 3
display-name: "&r"
slot: "2,3,5,6,18,26,38,39,40,41,42"
slot: "2,3,5,6,18,26,38,39,40,41,42"

View File

@ -1,10 +1,10 @@
title: "Enchanter"
rows: 3
#You can choose to fill the entire inventory with this material
#fill:
# material: "MATERIAL_HERE"
# display-name: "&r"
#You can choose to fill the entire inventory with this material
#fill:
# material: "MATERIAL_HERE"
# display-name: "&r"
contents:
1:
@ -89,6 +89,12 @@ contents:
slot: 15
explanation:
material: PAINTING
display-name: "&6&lEnchanter"
lore:
- "&7Click to &6buy &7a tiered enchantment book."
- ""
- "&6Right Click &7the book for a &6random &7enchant"
- "&7of that tier."
slot: 4
corners:
material: STAINED_GLASS_PANE

View File

@ -21,6 +21,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&b&lElite Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: STAINED_GLASS_PANE
@ -35,12 +39,4 @@ contents:
back:
material: FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -21,6 +21,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&6&lLegendary Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: STAINED_GLASS_PANE
@ -35,12 +39,4 @@ contents:
back:
material: FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -21,6 +21,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&f&lSimple Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: STAINED_GLASS_PANE
@ -35,12 +39,4 @@ contents:
back:
material: FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -21,6 +21,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&e&lUltimate Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: STAINED_GLASS_PANE
@ -35,12 +39,4 @@ contents:
back:
material: FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -21,6 +21,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&a&lUnique Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: STAINED_GLASS_PANE
@ -35,12 +39,4 @@ contents:
back:
material: FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -29,6 +29,13 @@ contents:
slot: 49
explanation:
material: PAINTING
display-name: "&6&lTinkerer"
lore:
- "&6Click &7to insert the books you would"
- "&7like to &6deposit&7."
- ""
- "&7The &6left &7is the items you are &6depositing&7."
- "&7The &6right &7is the items you are &6receiving&7."
slot: 4
corners:
material: STAINED_GLASS_PANE

View File

@ -30,7 +30,22 @@ contents:
- "&7will receive from the alchemist"
- "&7will be displayed here."
accept-before:
material: MAGENTA_DYE
material: RED_DYE
display-name: "&cWaiting for you..."
lore:
- "&7The alchemist is waiting"
- "&7for your enchange..."
accept-after:
material: LIME_DYE
display-name: "&eClick to confirm"
lore:
- "&cCost: {exp_cost} EXP"
- ""
- "&7Click to confirm the exchange"
- "&7after which you will receive"
- "&7the item displayed above."
explanation:
material: PAINTING
display-name: "&8[&eThe Alchemist&8]"
lore:
- "&7The alchemist will exchange:"
@ -44,17 +59,6 @@ contents:
- "&7(of the same rarity) &ffor"
- "&fthe same dust"
- "&7(of a higher percentage)"
accept-after:
material: MAGENTA_DYE
display-name: "&eClick to confirm"
lore:
- "&cCost: {exp_cost} EXP"
- ""
- "&7Click to confirm the exchange"
- "&7after which you will receive"
- "&7the item displayed above."
explanation:
material: PAINTING
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE
@ -63,4 +67,4 @@ contents:
edge:
material: LIGHT_BLUE_STAINED_GLASS_PANE
display-name: "&r"
slot: "2,3,5,6,18,26,38,39,40,41,42"
slot: "2,3,5,6,18,26,38,39,40,41,42"

View File

@ -1,10 +1,10 @@
title: "Enchanter"
rows: 3
#You can choose to fill the entire inventory with this material
#fill:
# material: "MATERIAL_HERE"
# display-name: "&r"
#You can choose to fill the entire inventory with this material
#fill:
# material: "MATERIAL_HERE"
# display-name: "&r"
contents:
1:
@ -53,7 +53,7 @@ contents:
eco-cost: 0
slot: 13
4:
material: "PURPLE_DYE"
material: "YELLOW_DYE"
display-name: "&e&lUltimate Enchantment &7(Right Click)"
lore:
- "&7Examine to receive a random"
@ -84,6 +84,12 @@ contents:
slot: 15
explanation:
material: PAINTING
display-name: "&6&lEnchanter"
lore:
- "&7Click to &6buy &7a tiered enchantment book."
- ""
- "&6Right Click &7the book for a &6random &7enchant"
- "&7of that tier."
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE

View File

@ -20,6 +20,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&b&lElite Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE
@ -34,12 +38,4 @@ contents:
back:
material: OAK_FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 37
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 43
slot: "0,8"

View File

@ -20,6 +20,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&6&lLegendary Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE
@ -34,12 +38,4 @@ contents:
back:
material: OAK_FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -21,6 +21,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&f&lSimple Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE
@ -35,12 +39,4 @@ contents:
back:
material: OAK_FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -9,8 +9,7 @@ group: ULTIMATE
enchant-item:
description-color: "&f"
material: "PURPLE_DYE"
data: 11
material: "YELLOW_DYE"
display-name: "{group_color}{enchant}"
lore:
- "&7Max level: &f{max_level}"
@ -21,6 +20,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&e&lUltimate Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE
@ -35,12 +38,4 @@ contents:
back:
material: OAK_FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -20,6 +20,10 @@ enchant-item:
contents:
explanation:
material: PAINTING
display-name: "&a&lUnique Enchants"
lore:
- "&7Hover over each item to see"
- "&7information about each enchant."
slot: 4
corners:
material: BLUE_STAINED_GLASS_PANE
@ -34,12 +38,4 @@ contents:
back:
material: OAK_FENCE_GATE
display-name: "&cBack to main"
slot: "0,8"
next-page:
material: MAP
display-name: "&cNext page"
slot: 43
previous-page:
material: MAP
display-name: "&cPrevious page"
slot: 37
slot: "0,8"

View File

@ -18,7 +18,7 @@ contents:
group: ELITE
slot: 13
4:
material: "PURPLE_DYE"
material: "YELLOW_DYE"
display-name: "&e&lUltimate Enchantments"
group: ULTIMATE
slot: 14
@ -38,4 +38,4 @@ contents:
whites:
material: WHITE_STAINED_GLASS_PANE
display-name: "&r"
slot: "10,16"
slot: "10,16"

View File

@ -12,33 +12,42 @@ slots: "(9,14) (10,15) (11,16) (12,17)
contents:
accept-left:
material: "LIME_DYE"
material: "INK_SACK"
data: 10
display-name: "&eClick to accept trade"
slot: 45
accept-right:
material: "LIME_DYE"
material: "INK_SACK"
data: 10
display-name: "&eClick to accept trade"
slot: 53
deposit-all:
material: "SUNFLOWER"
material: "DOUBLE_PLANT"
display-name: "&l&eDeposit All"
lore:
- "&7Click to deposit all tinkerable items."
slot: 49
explanation:
material: PAINTING
slot: 4
display-name: "&6&lTinkerer"
lore:
- "&6Click &7to insert the books you would"
- "&7like to &6deposit&7."
- ""
- "&7The &6left &7is the items you are &6depositing&7."
- "&7The &6right &7is the items you are &6receiving&7."
corners:
material: BLUE_STAINED_GLASS_PANE
material: STAINED_GLASS_PANE
data: 11
display-name: "&r"
slot: "0,1,7,8,46,52"
edge:
material: LIGHT_BLUE_STAINED_GLASS_PANE
material: STAINED_GLASS_PANE
data: 3
display-name: "&r"
slot: "2,3,5,6,47,48,50,51"
line:
material: WHITE_STAINED_GLASS_PANE
material: STAINED_GLASS_PANE
display-name: "&r"
slot: "13,22,31,40"