diff --git a/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/PlaceholderIntegration.java b/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/PlaceholderIntegration.java index 5bd18c27..8f38eab5 100644 --- a/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/PlaceholderIntegration.java +++ b/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/PlaceholderIntegration.java @@ -41,7 +41,13 @@ public PlaceholderIntegration(DependencyManager depManager) @Override public @NotNull String getVersion() { - return "1.3.3"; + return "1.5.0"; + } + + @Override + public boolean persist() + { + return true; } private void addPlaceholders(List providerList) @@ -70,7 +76,7 @@ private boolean providerEquals(IPlaceholderProvider source, IPlaceholderProvider return source.getPlaceholderIdentifier().equals(target.getPlaceholderIdentifier()); } - private static final String defaultString = "???"; + private static final String defaultString = "invalid_placeholder"; @Override public @Nullable String onPlaceholderRequest(Player player, @NotNull String param) diff --git a/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/builtin/StateNameProvider.java b/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/builtin/StateNameProvider.java index 058407fe..39795fe4 100644 --- a/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/builtin/StateNameProvider.java +++ b/src/main/java/xyz/nifeather/morph/misc/integrations/placeholderapi/builtin/StateNameProvider.java @@ -32,14 +32,14 @@ public class StateNameProvider extends MorphPluginObject implements IPlaceholder { return state != null ? state.getDisguiseIdentifier() - : "???"; + : "not_disguised"; } case "name" -> { return state != null ? PlainTextComponentSerializer.plainText().serialize(state.getServerDisplay()) - : "???"; + : "not_disguised"; } case "status" -> @@ -51,7 +51,7 @@ public class StateNameProvider extends MorphPluginObject implements IPlaceholder if (param.startsWith("provider_is")) { var spilt = param.split("\\?", 2); - if (spilt.length < 2) return "false"; + if (spilt.length < 2) return "invalid_provider_param"; var namespace = spilt[1]; return state != null @@ -62,13 +62,13 @@ public class StateNameProvider extends MorphPluginObject implements IPlaceholder if (param.startsWith("id_is")) { var spilt = param.split("\\?", 2); - if (spilt.length < 2) return "false"; + if (spilt.length < 2) return "invalid_id_param"; return state != null ? state.getDisguiseIdentifier().equals(spilt[1]) ? "true" : "false" : "false"; } - return "not_enough_param"; + return "invalid_param"; } }