From e50c9fc99f5bd16ab915b37a9a44da67c4844cbe Mon Sep 17 00:00:00 2001 From: libraryaddict Date: Sat, 18 Apr 2020 01:07:48 +1200 Subject: [PATCH] Allow multiple options in disguise option perm --- .../disguise/utilities/parser/DisguiseParser.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/main/java/me/libraryaddict/disguise/utilities/parser/DisguiseParser.java b/src/main/java/me/libraryaddict/disguise/utilities/parser/DisguiseParser.java index 6e79dd76..983cb786 100644 --- a/src/main/java/me/libraryaddict/disguise/utilities/parser/DisguiseParser.java +++ b/src/main/java/me/libraryaddict/disguise/utilities/parser/DisguiseParser.java @@ -264,7 +264,18 @@ public class DisguiseParser { continue; } - if (!split[3].replace("_", "").equalsIgnoreCase(type.toReadable().replace(" ", ""))) { + boolean applicable = false; + + for (String s : split[3].split("/")) { + if (!s.equals("*") && !s.replace("_", "").equalsIgnoreCase(type.toReadable().replace(" ", ""))) { + continue; + } + + applicable = true; + break; + } + + if (!applicable) { continue; }