From ef886a85f9f8d5db21691709753c2d12d0cab407 Mon Sep 17 00:00:00 2001 From: Samuel Caldwell <33561697+IncompleteIntegers@users.noreply.github.com> Date: Sat, 24 Jul 2021 22:48:59 -0700 Subject: [PATCH 1/7] Added bug reporting note to README --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 462d3ab..33fdd96 100644 --- a/README.md +++ b/README.md @@ -23,4 +23,8 @@ mvn clean package * Limited item NBT editing * Obtain player skulls +### Reporting Bugs +* Minor bugs may be reported with Issues +* Please report any Major/Game-breaking bugs privately to any of the devs + Contributions are welcomed & appreciated! From bf263951ae67f2ce4c723fe531dbb8af31c0e6a8 Mon Sep 17 00:00:00 2001 From: theoparker24 <87245945+cytocracy@users.noreply.github.com> Date: Mon, 26 Jul 2021 16:42:42 -0500 Subject: [PATCH 2/7] fixed jakes stupidity --- .../ParadisuPlugin/commands/snwcommands.java | 26 +++++++++---------- src/main/resources/plugin.yml | 2 +- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java b/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java index bb90ec2..3c21401 100644 --- a/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java +++ b/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java @@ -745,31 +745,31 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String String name = player.getName(); - name.concat(", "); + name = name.concat(", "); if (player.hasPermission("meta.rank.owner")) { - owners.concat(name); + owners = owners.concat(name); } else if (player.hasPermission("meta.rank.dev")) { - devs.concat(name); + devs = devs.concat(name); } else if (player.hasPermission("meta.rank.builders")) { - builders.concat(name); + builders = builders.concat(name); } else if (player.hasPermission("meta.rank.staff")) { - staff.concat(name); + staff = staff.concat(name); } else if (player.hasPermission("meta.rank.supporters")) { - supporters.concat(name); + supporters = supporters.concat(name); } else { - visitors.concat(name); + visitors = visitors.concat(name); } } - owners = owners.substring(0, owners.length()); - devs = devs.substring(0, devs.length()); - builders = builders.substring(0, builders.length()); - staff = staff.substring(0, staff.length()); - supporters = supporters.substring(0, supporters.length()); - visitors = visitors.substring(0, visitors.length()); + owners = owners.substring(0, owners.length() -2); + devs = devs.substring(0, devs.length() -2); + builders = builders.substring(0, builders.length() -2); + staff = staff.substring(0, staff.length() -2); + supporters = supporters.substring(0, supporters.length() -2); + visitors = visitors.substring(0, visitors.length() -2); player.sendMessage("§3§l============= §f" + onlineammount + " §d§oOnline Players §3§l=============\n" + " \n"); diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml index b4c0169..a6fc356 100644 --- a/src/main/resources/plugin.yml +++ b/src/main/resources/plugin.yml @@ -1,5 +1,5 @@ name: ParadisuPlugin -version: 2.5.0 +version: 2.5.1 authors: [JakeDaDream, RealInstantRamen, andyinnie, _Kastle] main: me.jakedadream.ParadisuPlugin.paradisumain api-version: 1.16 From f884d2852c5ee99900742a96aa344d26b1081fb1 Mon Sep 17 00:00:00 2001 From: theoparker24 <87245945+cytocracy@users.noreply.github.com> Date: Mon, 26 Jul 2021 16:52:30 -0500 Subject: [PATCH 3/7] Revert "Added bug reporting note to README" This reverts commit ef886a85f9f8d5db21691709753c2d12d0cab407. --- README.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/README.md b/README.md index 33fdd96..462d3ab 100644 --- a/README.md +++ b/README.md @@ -23,8 +23,4 @@ mvn clean package * Limited item NBT editing * Obtain player skulls -### Reporting Bugs -* Minor bugs may be reported with Issues -* Please report any Major/Game-breaking bugs privately to any of the devs - Contributions are welcomed & appreciated! From d5d201d87ad6ac5620685374cd9cfe42b6d15238 Mon Sep 17 00:00:00 2001 From: theoparker24 <87245945+cytocracy@users.noreply.github.com> Date: Mon, 26 Jul 2021 16:57:54 -0500 Subject: [PATCH 4/7] Revert "fixed jakes stupidity" This reverts commit bf263951ae67f2ce4c723fe531dbb8af31c0e6a8. --- .../ParadisuPlugin/commands/snwcommands.java | 26 +++++++++---------- src/main/resources/plugin.yml | 2 +- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java b/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java index 3c21401..bb90ec2 100644 --- a/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java +++ b/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java @@ -745,31 +745,31 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String String name = player.getName(); - name = name.concat(", "); + name.concat(", "); if (player.hasPermission("meta.rank.owner")) { - owners = owners.concat(name); + owners.concat(name); } else if (player.hasPermission("meta.rank.dev")) { - devs = devs.concat(name); + devs.concat(name); } else if (player.hasPermission("meta.rank.builders")) { - builders = builders.concat(name); + builders.concat(name); } else if (player.hasPermission("meta.rank.staff")) { - staff = staff.concat(name); + staff.concat(name); } else if (player.hasPermission("meta.rank.supporters")) { - supporters = supporters.concat(name); + supporters.concat(name); } else { - visitors = visitors.concat(name); + visitors.concat(name); } } - owners = owners.substring(0, owners.length() -2); - devs = devs.substring(0, devs.length() -2); - builders = builders.substring(0, builders.length() -2); - staff = staff.substring(0, staff.length() -2); - supporters = supporters.substring(0, supporters.length() -2); - visitors = visitors.substring(0, visitors.length() -2); + owners = owners.substring(0, owners.length()); + devs = devs.substring(0, devs.length()); + builders = builders.substring(0, builders.length()); + staff = staff.substring(0, staff.length()); + supporters = supporters.substring(0, supporters.length()); + visitors = visitors.substring(0, visitors.length()); player.sendMessage("§3§l============= §f" + onlineammount + " §d§oOnline Players §3§l=============\n" + " \n"); diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml index a6fc356..b4c0169 100644 --- a/src/main/resources/plugin.yml +++ b/src/main/resources/plugin.yml @@ -1,5 +1,5 @@ name: ParadisuPlugin -version: 2.5.1 +version: 2.5.0 authors: [JakeDaDream, RealInstantRamen, andyinnie, _Kastle] main: me.jakedadream.ParadisuPlugin.paradisumain api-version: 1.16 From 7cbc42b1a64fae207789f9977ada71a3d23d41ba Mon Sep 17 00:00:00 2001 From: theoparker24 <87245945+cytocracy@users.noreply.github.com> Date: Mon, 26 Jul 2021 16:57:59 -0500 Subject: [PATCH 5/7] Revert "Revert "Added bug reporting note to README"" This reverts commit f884d2852c5ee99900742a96aa344d26b1081fb1. --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 462d3ab..33fdd96 100644 --- a/README.md +++ b/README.md @@ -23,4 +23,8 @@ mvn clean package * Limited item NBT editing * Obtain player skulls +### Reporting Bugs +* Minor bugs may be reported with Issues +* Please report any Major/Game-breaking bugs privately to any of the devs + Contributions are welcomed & appreciated! From 5c575ccfe69994b262f79caa1046cbe9b311a698 Mon Sep 17 00:00:00 2001 From: theoparker24 <87245945+cytocracy@users.noreply.github.com> Date: Mon, 26 Jul 2021 17:00:31 -0500 Subject: [PATCH 6/7] Revert "Added framework for new model system" This reverts commit be41cce1ea2118b0d52e28ac4124959d17f98a94. --- .../commands/modelcommands.java | 78 +++++++++++ .../modelmanager/modelcommands.java | 130 ------------------ .../modelmanager/modelitemmanager.java | 100 -------------- .../ParadisuPlugin/paradisumain.java | 86 +----------- src/main/resources/hatmodels.yml | 1 - src/main/resources/propmodels.yml | 1 - 6 files changed, 81 insertions(+), 315 deletions(-) create mode 100644 src/main/java/me/jakedadream/ParadisuPlugin/commands/modelcommands.java delete mode 100644 src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelcommands.java delete mode 100644 src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelitemmanager.java delete mode 100644 src/main/resources/hatmodels.yml delete mode 100644 src/main/resources/propmodels.yml diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/commands/modelcommands.java b/src/main/java/me/jakedadream/ParadisuPlugin/commands/modelcommands.java new file mode 100644 index 0000000..f40cb94 --- /dev/null +++ b/src/main/java/me/jakedadream/ParadisuPlugin/commands/modelcommands.java @@ -0,0 +1,78 @@ +package me.jakedadream.ParadisuPlugin.commands; + +import org.bukkit.ChatColor; +import org.bukkit.command.Command; +import org.bukkit.command.CommandExecutor; +import org.bukkit.command.CommandSender; +import org.bukkit.entity.Player; + +public class modelcommands implements CommandExecutor { + + private String getParsedName(String[] args) { + String name = ""; + for (int i = 0; i < args.length; i++) { + name = name.concat(args[i]); + name = name.concat(" "); + } + return ChatColor.translateAlternateColorCodes('&', name); + } + + + + @Override + public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) { + if (!(sender instanceof Player)) { + sender.sendMessage(ChatColor.RED + "Only players can use that command!"); + return true; + } + Player player = (Player) sender; + + switch (cmd.getName().toLowerCase()) { + + case "mgive": + if (player.hasPermission("snw.model")) { + + // model menu + player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fOpening the Catalog of Default Models!"); + } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } + return true; + + + case "hgive": + if (player.hasPermission("snw.model")) { + + // hat menu + player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fOpening the Catalog of Hat Models!"); + } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } + return true; + + + case "mhat": + if (player.hasPermission("snw.model")) { + + // model on head + + player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fPlaced the model on your head!"); + } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } + return true; + + + case "createmodelcfsection": + if (player.hasPermission("snw.model")) { + + // create new default model section in config file + + player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fNew Model Section created!"); + } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } + return true; + + + + + default: + return false; + } + } +} + + diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelcommands.java b/src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelcommands.java deleted file mode 100644 index a0d6d88..0000000 --- a/src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelcommands.java +++ /dev/null @@ -1,130 +0,0 @@ -package me.jakedadream.ParadisuPlugin.modelmanager; - -import me.jakedadream.ParadisuPlugin.paradisumain; -import org.bukkit.ChatColor; -import org.bukkit.command.Command; -import org.bukkit.command.CommandExecutor; -import org.bukkit.command.CommandSender; -import org.bukkit.configuration.ConfigurationSection; -import org.bukkit.entity.Player; - -import java.util.Random; - -public class modelcommands implements CommandExecutor { - - private String getParsedName(String[] args) { - String name = ""; - for (int i = 0; i < args.length; i++) { - name = name.concat(args[i]); - name = name.concat(" "); - } - return ChatColor.translateAlternateColorCodes('&', name); - } - - - - @Override - public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) { - if (!(sender instanceof Player)) { - sender.sendMessage(ChatColor.RED + "Only players can use that command!"); - return true; - } - Player player = (Player) sender; - - switch (cmd.getName().toLowerCase()) { - - case "mgive": - if (player.hasPermission("snw.model")) { - // model menu - player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fOpening the Catalog of Default Models!"); - } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } - return true; - - - case "hgive": - if (player.hasPermission("snw.model")) { - - // hat menu - player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fOpening the Catalog of Hat Models!"); - } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } - return true; - - - case "mhat": - if (player.hasPermission("snw.model")) { - - // model on head - - player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fPlaced the model on your head!"); - } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } - return true; - - - case "createmodelcfsection": - if (player.hasPermission("snw.model")) { - // - Random rand = new Random(); Integer upperbound = 1000; Integer int_random = rand.nextInt(upperbound); - String randstring = int_random.toString(); - // - if (args.length > 1) { - player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §7Please add an argument & specify between Props & Hats."); - } else if (args.length == 1) { - // ------------------------------------------------------------------------------------------------------------------------------------------------ - if (args[1] == "prop") { - // - String sectionname = "new_model_template_" + randstring; - paradisumain.getPropModelsConfig().createSection(sectionname); - ConfigurationSection cs = paradisumain.filePropModelsConfig.getConfigurationSection(sectionname); - - cs.set("displayname", "Unset Model Name"); - cs.set("enchantslot1", "Enchantment.LUCK"); - cs.set("enchantslot2", "Enchantment.LUCK"); - cs.set("enchantslot3", "Enchantment.LUCK"); - - cs.set("enchantslot1level", "0"); - cs.set("enchantslot2level", "0"); - cs.set("enchantslot3level", "0"); - - cs.set("lore1", "DEFAULT LORE 1"); - cs.set("lore2", "DEFAULT LORE 2"); - cs.set("lore3", "DEFAULT LORE 3"); - cs.set("lore4", "DEFAULT LORE 4"); - cs.set("lore5", "DEFAULT LORE 5"); - cs.set("lore6", "DEFAULT LORE 6"); - cs.set("lore7", "DEFAULT LORE 7"); - cs.set("lore8", "DEFAULT LORE 8"); - cs.set("lore9", "DEFAULT LORE 9"); - cs.set("lore10", "DEFAULT LORE 10"); - - cs.set("unbreakable", "false"); - cs.set("hideunbreakable", "false"); - cs.set("hideenchants", "false"); - // - paradisumain.savePropModelsConfig(); - // - player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fNew Model Section created!"); - // - } else if (args[1] == "hat") { - // - - - - - player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §fNew Model Section created!"); - // - } else {player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §7Please specify between Props & Hats.");} - } else {player.sendMessage("§3[§dParadisu §f§lMODELS §bツ§3] §7Too many args.");} - // ------------------------------------------------------------------------------------------------------------------------------------------------ - } else { player.sendMessage("§3[§dParadisu §bツ§3] §7You do not have permission to use that command."); } - return true; - - - - - default: - return false; - } - } -} - - diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelitemmanager.java b/src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelitemmanager.java deleted file mode 100644 index 3928559..0000000 --- a/src/main/java/me/jakedadream/ParadisuPlugin/modelmanager/modelitemmanager.java +++ /dev/null @@ -1,100 +0,0 @@ -package me.jakedadream.ParadisuPlugin.modelmanager; - -import me.jakedadream.ParadisuPlugin.paradisumain; -import org.bukkit.Material; -import org.bukkit.configuration.ConfigurationSection; -import org.bukkit.inventory.ItemFlag; -import org.bukkit.inventory.ItemStack; -import org.bukkit.inventory.meta.ItemMeta; - -import java.util.ArrayList; -import java.util.List; - -public class modelitemmanager { - - public static ItemStack createPropModel() { - ItemStack propmodelitem = new ItemStack(Material.DIAMOND_AXE, 1); - ItemMeta meta = propmodelitem.getItemMeta(); - // - List propmodellore = new ArrayList<>(); - // - String cs = "uhhhhhhhhhh plz go back to this"; // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - ConfigurationSection gs = paradisumain.getPropModelsConfig().getConfigurationSection(cs); - // - meta.setCustomModelData(Integer.valueOf(gs.getName())); - // - meta.setDisplayName(gs.getString("displayname")); // displayname - //s - meta.addEnchant(gs.getString("enchantslot1"), gs.getString("enchantslot1level")); // enchant slot 1 - meta.addEnchant(gs.getString("enchantslot2"), gs.getString("enchantslot2level")); // enchant slot 2 - meta.addEnchant(gs.getString("enchantslot3"), gs.getString("enchantslot3level")); // enchant slot 3 - // - propmodellore.add(gs.getString("lore1")); // lore line 1 - propmodellore.add(gs.getString("lore2")); // lore line 2 - propmodellore.add(gs.getString("lore3")); // lore line 3 - propmodellore.add(gs.getString("lore4")); // lore line 4 - propmodellore.add(gs.getString("lore5")); // lore line 5 - propmodellore.add(gs.getString("lore6")); // lore line 6 - propmodellore.add(gs.getString("lore7")); // lore line 7 - propmodellore.add(gs.getString("lore8")); // lore line 8 - propmodellore.add(gs.getString("lore9")); // lore line 9 - propmodellore.add(gs.getString("lore10")); // lore line 10 - // - meta.setLore(propmodellore); // sets prop lore - // - meta.addItemFlags(ItemFlag.HIDE_ATTRIBUTES); - meta.setUnbreakable(Boolean.parseBoolean(gs.getString("unbreakable"))); // unbreakable? true/false - meta.addItemFlags(ItemFlag.valueOf(gs.getString("hideunbreakable"))); // hide unbreakable? true/false - meta.addItemFlags(ItemFlag.valueOf(gs.getString("hideenchants"))); // hide enchants? true/false - // - - return propmodelitem; - } - - - - - - - public static ItemStack createHatModel() { - ItemStack hatmodelitem = new ItemStack(Material.DIAMOND_AXE, 1); - ItemMeta meta = hatmodelitem.getItemMeta(); - // - List hatmodellore = new ArrayList<>(); - // - String cs = "uhhhhhhhhhh plz go back to this"; // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - ConfigurationSection gs = paradisumain.getHatModelsConfig().getConfigurationSection(cs); - // - meta.setCustomModelData(Integer.valueOf(gs.getName())); - // - meta.setDisplayName(gs.getString("displayname")); // displayname - //s - meta.addEnchant(gs.getString("enchantslot1"), gs.getString("enchantslot1level")); // enchant slot 1 - meta.addEnchant(gs.getString("enchantslot2"), gs.getString("enchantslot2level")); // enchant slot 2 - meta.addEnchant(gs.getString("enchantslot3"), gs.getString("enchantslot3level")); // enchant slot 3 - // - hatmodellore.add(gs.getString("lore1")); // lore line 1 - hatmodellore.add(gs.getString("lore2")); // lore line 2 - hatmodellore.add(gs.getString("lore3")); // lore line 3 - hatmodellore.add(gs.getString("lore4")); // lore line 4 - hatmodellore.add(gs.getString("lore5")); // lore line 5 - hatmodellore.add(gs.getString("lore6")); // lore line 6 - hatmodellore.add(gs.getString("lore7")); // lore line 7 - hatmodellore.add(gs.getString("lore8")); // lore line 8 - hatmodellore.add(gs.getString("lore9")); // lore line 9 - hatmodellore.add(gs.getString("lore10")); // lore line 10 - // - meta.setLore(hatmodellore); // sets prop lore - // - meta.addItemFlags(ItemFlag.HIDE_ATTRIBUTES); - meta.setUnbreakable(Boolean.parseBoolean(gs.getString("unbreakable"))); // unbreakable? true/false - meta.addItemFlags(ItemFlag.valueOf(gs.getString("hideunbreakable"))); // hide unbreakable? true/false - meta.addItemFlags(ItemFlag.valueOf(gs.getString("hideenchants"))); // hide enchants? true/false - // - - return hatmodelitem; - } - - - -} diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/paradisumain.java b/src/main/java/me/jakedadream/ParadisuPlugin/paradisumain.java index 8a755fb..98cda8b 100644 --- a/src/main/java/me/jakedadream/ParadisuPlugin/paradisumain.java +++ b/src/main/java/me/jakedadream/ParadisuPlugin/paradisumain.java @@ -1,6 +1,6 @@ package me.jakedadream.ParadisuPlugin; -import me.jakedadream.ParadisuPlugin.modelmanager.modelcommands; +import me.jakedadream.ParadisuPlugin.commands.modelcommands; import me.jakedadream.ParadisuPlugin.commands.snwcommands; import me.jakedadream.ParadisuPlugin.commands.warps; import me.jakedadream.ParadisuPlugin.events.*; @@ -163,18 +163,9 @@ public void onDisable() { } - - public static File sourceWarpFile; public static FileConfiguration fileWarpConfig; - public static File sourcePropModelsFile; - public static FileConfiguration filePropModelsConfig; - - public static File sourceHatModelsFile; - public static FileConfiguration fileHatModelsConfig; - - public void createWarpFiles() { sourceWarpFile = new File(getDataFolder(), "warps.yml"); @@ -196,60 +187,11 @@ public void createWarpFiles() { } } - public void createPropModelsFiles() { - - sourcePropModelsFile = new File(getDataFolder(), "propmodels.yml"); - - if (!sourcePropModelsFile.exists()) { - sourcePropModelsFile.getParentFile().mkdirs(); - saveResource("propmodels.yml", false); - } - - filePropModelsConfig = new YamlConfiguration(); - - try { - filePropModelsConfig.load(sourcePropModelsFile); - } catch (IOException | InvalidConfigurationException e) { - e.printStackTrace(); - } - // if (filePropModelsConfig.getConfigurationSection("aliases") == null){ - // filePropModelsConfig.createSection("aliases"); - // } - } - - public void createHatModelsFiles() { - - sourceHatModelsFile = new File(getDataFolder(), "hatmodels.yml"); - - if (!sourceHatModelsFile.exists()) { - sourceHatModelsFile.getParentFile().mkdirs(); - saveResource("hatmodels.yml", false); - } - - fileHatModelsConfig = new YamlConfiguration(); - - try { - fileHatModelsConfig.load(sourceHatModelsFile); - } catch (IOException | InvalidConfigurationException e) { - e.printStackTrace(); - } - // if (fileHatModelsConfig.getConfigurationSection("aliases") == null){ - // fileHatModelsConfig.createSection("aliases"); - // } - } - - - //gets fileWarpConfig public static FileConfiguration getWarpConfig() { return fileWarpConfig; } - public static FileConfiguration getPropModelsConfig() { - return filePropModelsConfig; - } - public static FileConfiguration getHatModelsConfig() {return fileHatModelsConfig;} - //use if edited through commands public static void saveWarpConfig(){ @@ -260,32 +202,10 @@ public static void saveWarpConfig(){ } } - public static void savePropModelsConfig(){ - try { - filePropModelsConfig.save(sourcePropModelsFile); - } catch (IOException e){ - System.out.println("couldn't save file"); - } - } - - public static void saveHatModelsConfig(){ - try { - fileHatModelsConfig.save(sourceHatModelsFile); - } catch (IOException e){ - System.out.println("couldn't save file"); - } - } - //use if edited file through text editor public static void reloadWarpConfig(){ - fileWarpConfig = YamlConfiguration.loadConfiguration(sourceWarpFile);} - - public static void reloadPropModelsConfig(){ - filePropModelsConfig = YamlConfiguration.loadConfiguration(sourcePropModelsFile);} - - public static void reloadHatModelsConfig(){ - filePropModelsConfig = YamlConfiguration.loadConfiguration(sourcePropModelsFile);} - + fileWarpConfig = YamlConfiguration.loadConfiguration(sourceWarpFile); + } } diff --git a/src/main/resources/hatmodels.yml b/src/main/resources/hatmodels.yml deleted file mode 100644 index d3f34fb..0000000 --- a/src/main/resources/hatmodels.yml +++ /dev/null @@ -1 +0,0 @@ -# This is the Hat Models config file \ No newline at end of file diff --git a/src/main/resources/propmodels.yml b/src/main/resources/propmodels.yml deleted file mode 100644 index 9c19f58..0000000 --- a/src/main/resources/propmodels.yml +++ /dev/null @@ -1 +0,0 @@ -# This is the Prop Models config file \ No newline at end of file From f5aa8bc809fa43f6241944e7efa3e89943f721f5 Mon Sep 17 00:00:00 2001 From: theoparker24 <87245945+cytocracy@users.noreply.github.com> Date: Mon, 26 Jul 2021 17:06:16 -0500 Subject: [PATCH 7/7] fixed jakes stupidity but didn't break stuff this time --- .../ParadisuPlugin/commands/snwcommands.java | 26 +++++++++---------- src/main/resources/plugin.yml | 4 +-- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java b/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java index bb90ec2..b2bcf76 100644 --- a/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java +++ b/src/main/java/me/jakedadream/ParadisuPlugin/commands/snwcommands.java @@ -745,31 +745,31 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String String name = player.getName(); - name.concat(", "); + name = name.concat(", "); if (player.hasPermission("meta.rank.owner")) { - owners.concat(name); + owners = owners.concat(name); } else if (player.hasPermission("meta.rank.dev")) { - devs.concat(name); + devs = devs.concat(name); } else if (player.hasPermission("meta.rank.builders")) { - builders.concat(name); + builders = builders.concat(name); } else if (player.hasPermission("meta.rank.staff")) { - staff.concat(name); + staff = staff.concat(name); } else if (player.hasPermission("meta.rank.supporters")) { - supporters.concat(name); + supporters = supporters.concat(name); } else { - visitors.concat(name); + visitors = visitors.concat(name); } } - owners = owners.substring(0, owners.length()); - devs = devs.substring(0, devs.length()); - builders = builders.substring(0, builders.length()); - staff = staff.substring(0, staff.length()); - supporters = supporters.substring(0, supporters.length()); - visitors = visitors.substring(0, visitors.length()); + owners = owners.substring(0, owners.length() -2); + devs = devs.substring(0, devs.length() -2); + builders = builders.substring(0, builders.length() -2); + staff = staff.substring(0, staff.length() -2); + supporters = supporters.substring(0, supporters.length() -2); + visitors = visitors.substring(0, visitors.length() -2); player.sendMessage("§3§l============= §f" + onlineammount + " §d§oOnline Players §3§l=============\n" + " \n"); diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml index b4c0169..8e07781 100644 --- a/src/main/resources/plugin.yml +++ b/src/main/resources/plugin.yml @@ -1,6 +1,6 @@ name: ParadisuPlugin -version: 2.5.0 -authors: [JakeDaDream, RealInstantRamen, andyinnie, _Kastle] +version: 2.5.1 +authors: [JakeDaDream, RealInstantRamen, andyinnie, _Kastle, cytocracy] main: me.jakedadream.ParadisuPlugin.paradisumain api-version: 1.16 commands: