fixed gui
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -134,11 +134,9 @@ public class ExplosionConfig {
|
||||
}
|
||||
|
||||
public static ExplosionConfig load(World world) {
|
||||
return load(getFileOf(world));
|
||||
}
|
||||
|
||||
public static ExplosionConfig load(File file) {
|
||||
ExplosionConfig defaultConfig = new ExplosionConfig(Bukkit.getWorlds().get(0));
|
||||
world = world != null ? world : Bukkit.getWorlds().get(0);
|
||||
File file = getFileOf(world);
|
||||
ExplosionConfig defaultConfig = new ExplosionConfig(world);
|
||||
|
||||
if (FileValidationUtils.validate(file)) {
|
||||
try {
|
||||
|
||||
@@ -2,6 +2,7 @@ package io.github.itzispyder.explosionscontrol.data;
|
||||
|
||||
import io.github.itzispyder.explosionscontrol.utils.ItemPresets;
|
||||
import io.github.itzispyder.explosionscontrol.utils.Text;
|
||||
import io.github.itzispyder.explosionscontrol.utils.Timer;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.event.EventHandler;
|
||||
@@ -20,6 +21,7 @@ public class ExplosionGui {
|
||||
}
|
||||
|
||||
public Inventory loadGui() {
|
||||
Timer timer = Timer.start();
|
||||
String title = Text.color(starter + config.getWorld().getName());
|
||||
Inventory inv = Bukkit.createInventory(null, 54, title);
|
||||
ItemStack x = ItemPresets.GUI_BLANK;
|
||||
@@ -64,6 +66,8 @@ public class ExplosionGui {
|
||||
f,f,f,f,f,f,f,f,f
|
||||
});
|
||||
|
||||
Timer.End end = timer.end();
|
||||
|
||||
return inv;
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,6 @@ public class InventoryListener implements Listener {
|
||||
|
||||
if (world == null) {
|
||||
p.closeInventory();
|
||||
p.sendMessage("matching worlds: " + p.getWorld().getName().equals(name));
|
||||
p.sendMessage(Text.ofAll("&cWorld &7\"" + name + "&7\" &cis not found!"));
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user