From 37f5c0db2c0acce11f901def629cd1b21deed726 Mon Sep 17 00:00:00 2001 From: OneLiteFeather Date: Wed, 6 Mar 2024 15:02:39 +0100 Subject: [PATCH 1/5] Fix link and remove legacy color codes --- .../themeinerlp/bettergopaint/command/Handler.java | 13 ++++++------- .../bettergopaint/listeners/InteractListener.java | 5 +++-- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/main/java/dev/themeinerlp/bettergopaint/command/Handler.java b/src/main/java/dev/themeinerlp/bettergopaint/command/Handler.java index b2c2cc94..4584ff2a 100644 --- a/src/main/java/dev/themeinerlp/bettergopaint/command/Handler.java +++ b/src/main/java/dev/themeinerlp/bettergopaint/command/Handler.java @@ -62,15 +62,15 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String return true; } else if (args.length == 1) { if (args[0].equalsIgnoreCase("size")) { - p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "§/gp size [number]")); + p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "/gp size [number]")); return true; } else if (args[0].equalsIgnoreCase("toggle")) { if (pb.isEnabled()) { pb.toggleEnabled(); - p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "§cDisabled brush")); + p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "Disabled brush")); } else { pb.toggleEnabled(); - p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "§aEnabled brush")); + p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "Enabled brush")); } return true; } else if ((args[0].equalsIgnoreCase("reload") || args[0].equalsIgnoreCase("r")) && p.hasPermission( @@ -79,10 +79,9 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String p.sendMessage(MiniMessage.miniMessage().deserialize(prefix + "Reloaded")); return true; } else if (args[0].equalsIgnoreCase("info") || args[0].equalsIgnoreCase("i")) { - p.sendMessage(MiniMessage.miniMessage().deserialize(prefix+ " Created by: TheMeinerLP")); - p.sendMessage(MiniMessage.miniMessage().deserialize(prefix+ " Links: Twitter " + - "")); + p.sendMessage(MiniMessage.miniMessage().deserialize(prefix+ "Created by: TheMeinerLP")); + p.sendMessage(MiniMessage.miniMessage().deserialize(prefix+ "Links: Twitter")); return true; } if (p.hasPermission("bettergopaint.admin")) { diff --git a/src/main/java/dev/themeinerlp/bettergopaint/listeners/InteractListener.java b/src/main/java/dev/themeinerlp/bettergopaint/listeners/InteractListener.java index 6724bc9f..3d3a4d7f 100644 --- a/src/main/java/dev/themeinerlp/bettergopaint/listeners/InteractListener.java +++ b/src/main/java/dev/themeinerlp/bettergopaint/listeners/InteractListener.java @@ -60,7 +60,7 @@ public void onClick(PlayerInteractEvent e) { .getItemInHand() .getItemMeta() .getDisplayName() - .startsWith(" §b♦ ") && e.getPlayer().getItemInHand().getItemMeta().hasLore()) { + .startsWith(" ♦ ") && e.getPlayer().getItemInHand().getItemMeta().hasLore()) { final ExportedPlayerBrush epb = new ExportedPlayerBrush(e .getPlayer() .getItemInHand() @@ -99,7 +99,8 @@ public void onClick(PlayerInteractEvent e) { if (pb.isEnabled()) { BukkitAdapter.adapt(p).runAsyncIfFree(() -> pb.getBrush().paint(loc, p)); } else { - p.sendMessage(MiniMessage.miniMessage().deserialize(Settings.settings().GENERIC.PREFIX + "§cYour brush is disabled, left click to enable the brush.")); + p.sendMessage(MiniMessage.miniMessage().deserialize(Settings.settings().GENERIC.PREFIX + "Your brush is " + + "disabled, left click to enable the brush.")); } } if (e.getPlayer().getItemInHand().getType() == XMaterial.FEATHER.parseMaterial() && (e From 5e538d426831d1c0900302d9183a5a6c3a5b627c Mon Sep 17 00:00:00 2001 From: OneLiteFeather Date: Wed, 6 Mar 2024 15:14:36 +0100 Subject: [PATCH 2/5] Add 1.20.2 - 1.20.4 as supportedMinecraftVersions --- build.gradle.kts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build.gradle.kts b/build.gradle.kts index 8caf75a3..43b11011 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -59,6 +59,9 @@ val supportedMinecraftVersions = listOf( "1.19.4", "1.20", "1.20.1", + "1.20.2", + "1.20.3", + "1.20.4" ) repositories { From fbbe93719dee81141df20ec5f0c62c309df9c7e0 Mon Sep 17 00:00:00 2001 From: OneLiteFeather Date: Wed, 6 Mar 2024 15:19:03 +0100 Subject: [PATCH 3/5] Add 1.20.2 - 1.20.4 as supportedMinecraftVersions and 1.20.2 to minecraft version because of Paper CVE --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 43b11011..6b083c69 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -44,7 +44,7 @@ ext { version = "%s%s".format(Locale.ROOT, baseVersion, extension) group = "dev.themeinerlp.bettergopaint" -val minecraftVersion = "1.20.1" +val minecraftVersion = "1.20.2" val supportedMinecraftVersions = listOf( "1.16.5", "1.17", From 35641bf57840caf3d04e2a802474381b2de21b33 Mon Sep 17 00:00:00 2001 From: OneLiteFeather Date: Wed, 6 Mar 2024 16:18:35 +0100 Subject: [PATCH 4/5] Uppercase letters to match constant strings convention --- .../bettergopaint/utils/Constants.java | 23 +++++++++---------- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java b/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java index 0ea558b9..8a61b834 100644 --- a/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java +++ b/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java @@ -6,16 +6,15 @@ public final class Constants { public static final int BSTATS_ID = 18734; // Gui Items - - public static final String headSphere = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvZmU5OGY0ODU2MDE0N2MwYTJkNGVkYzE3ZjZkOTg1ZThlYjVkOTRiZDcyZmM2MDc0NGE1YThmMmQ5MDVhMTgifX19"; - public static final String headSpray = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvYjg4MGY3NjVlYTgwZGVlMzcwODJkY2RmZDk4MTJlZTM2ZmRhODg0ODY5MmE4NDFiZWMxYmJkOWVkNTFiYTIyIn19fQ=="; - public static final String headSplatter = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMzMzODI5MmUyZTY5ZjA5MDY5NGNlZjY3MmJiNzZmMWQ4Mzc1OGQxMjc0NGJiNmZmYzY4MzRmZGJjMWE5ODMifX19"; - public static final String headDisc = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvYjFmMjgyNTBkMWU0MjBhNjUxMWIwMzk2NDg2OGZjYTJmNTYzN2UzYWJhNzlmNGExNjNmNGE4ZDYxM2JlIn19fQ=="; - public static final String headBucket = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNTAxOGI0NTc0OTM5Nzg4YTJhZDU1NTJiOTEyZDY3ODEwNjk4ODhjNTEyMzRhNGExM2VhZGI3ZDRjOTc5YzkzIn19fQ=="; - public static final String headAngle = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNmRlNDQ4ZjBkYmU3NmJiOGE4MzJjOGYzYjJhMDNkMzViZDRlMjc4NWZhNWU4Mjk4YzI2MTU1MDNmNDdmZmEyIn19fQ=="; - public static final String headOverlay = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvZGYzMWQ2Zjk2NTRmODc0ZWE5MDk3YWRlZWEwYzk2OTk2ZTc4ZTNmZDM3NTRmYmY5ZWJlOTYzYWRhZDliZTRjIn19fQ=="; - public static final String headFracture = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMjNkZjczZWVlNjIyNGM1YzVkOTQ4ZDJhMzQ1ZGUyNWYyMDhjYmQ5YWY3MTA4Y2UxZTFiNjFhNTg2ZGU5OGIyIn19fQ=="; - public static final String headGradient = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNjA2MmRhM2QzYjhmMWZkMzUzNDNjYzI3OWZiMGZlNWNmNGE1N2I1YWJjNDMxZmJiNzhhNzNiZjJhZjY3NGYifX19"; - public static final String headPaint = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvODBiM2E5ZGZhYmVmYmRkOTQ5YjIxN2JiZDRmYTlhNDg2YmQwYzNmMGNhYjBkMGI5ZGZhMjRjMzMyZGQzZTM0MiJ9fX0="; - public static final String headBlend = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNWU5MTg0YWYxZGU3ZTViN2M0YWQ0MTFjNTZhZjRmOTMzNjY1MzYxNTkyOWJjOTVkNzEzYjdhNDJjZmYzZmJhZCJ9fX0="; + public static final String HEADSPHERE = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvZmU5OGY0ODU2MDE0N2MwYTJkNGVkYzE3ZjZkOTg1ZThlYjVkOTRiZDcyZmM2MDc0NGE1YThmMmQ5MDVhMTgifX19"; + public static final String HEADSPRAY = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvYjg4MGY3NjVlYTgwZGVlMzcwODJkY2RmZDk4MTJlZTM2ZmRhODg0ODY5MmE4NDFiZWMxYmJkOWVkNTFiYTIyIn19fQ=="; + public static final String HEADSPLATTER = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMzMzODI5MmUyZTY5ZjA5MDY5NGNlZjY3MmJiNzZmMWQ4Mzc1OGQxMjc0NGJiNmZmYzY4MzRmZGJjMWE5ODMifX19"; + public static final String HEADDISC = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvYjFmMjgyNTBkMWU0MjBhNjUxMWIwMzk2NDg2OGZjYTJmNTYzN2UzYWJhNzlmNGExNjNmNGE4ZDYxM2JlIn19fQ=="; + public static final String HEADBUCKET = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNTAxOGI0NTc0OTM5Nzg4YTJhZDU1NTJiOTEyZDY3ODEwNjk4ODhjNTEyMzRhNGExM2VhZGI3ZDRjOTc5YzkzIn19fQ=="; + public static final String HEADANGLE = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNmRlNDQ4ZjBkYmU3NmJiOGE4MzJjOGYzYjJhMDNkMzViZDRlMjc4NWZhNWU4Mjk4YzI2MTU1MDNmNDdmZmEyIn19fQ=="; + public static final String HEADOVERLAY = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvZGYzMWQ2Zjk2NTRmODc0ZWE5MDk3YWRlZWEwYzk2OTk2ZTc4ZTNmZDM3NTRmYmY5ZWJlOTYzYWRhZDliZTRjIn19fQ=="; + public static final String HEADFRACTURE = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMjNkZjczZWVlNjIyNGM1YzVkOTQ4ZDJhMzQ1ZGUyNWYyMDhjYmQ5YWY3MTA4Y2UxZTFiNjFhNTg2ZGU5OGIyIn19fQ=="; + public static final String HEADGRADIENT = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNjA2MmRhM2QzYjhmMWZkMzUzNDNjYzI3OWZiMGZlNWNmNGE1N2I1YWJjNDMxZmJiNzhhNzNiZjJhZjY3NGYifX19"; + public static final String HEADPAINT = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvODBiM2E5ZGZhYmVmYmRkOTQ5YjIxN2JiZDRmYTlhNDg2YmQwYzNmMGNhYjBkMGI5ZGZhMjRjMzMyZGQzZTM0MiJ9fX0="; + public static final String HEADBLEND = "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNWU5MTg0YWYxZGU3ZTViN2M0YWQ0MTFjNTZhZjRmOTMzNjY1MzYxNTkyOWJjOTVkNzEzYjdhNDJjZmYzZmJhZCJ9fX0="; } From 0d4800f57864dbcd82a5ce0c64ce625afa469716 Mon Sep 17 00:00:00 2001 From: OneLiteFeather Date: Wed, 6 Mar 2024 16:22:46 +0100 Subject: [PATCH 5/5] Add license text --- .../bettergopaint/command/ReloadCommand.java | 18 ++++++++++++++++++ .../bettergopaint/utils/Constants.java | 18 ++++++++++++++++++ 2 files changed, 36 insertions(+) diff --git a/src/main/java/dev/themeinerlp/bettergopaint/command/ReloadCommand.java b/src/main/java/dev/themeinerlp/bettergopaint/command/ReloadCommand.java index b9c05103..a1af2fb6 100644 --- a/src/main/java/dev/themeinerlp/bettergopaint/command/ReloadCommand.java +++ b/src/main/java/dev/themeinerlp/bettergopaint/command/ReloadCommand.java @@ -1,3 +1,21 @@ +/* + * goPaint is designed to simplify painting inside of Minecraft. + * Copyright (C) Arcaniax-Development + * Copyright (C) Arcaniax team and contributors + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ package dev.themeinerlp.bettergopaint.command; import cloud.commandframework.annotations.CommandMethod; diff --git a/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java b/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java index 8a61b834..e1479cc1 100644 --- a/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java +++ b/src/main/java/dev/themeinerlp/bettergopaint/utils/Constants.java @@ -1,3 +1,21 @@ +/* + * goPaint is designed to simplify painting inside of Minecraft. + * Copyright (C) Arcaniax-Development + * Copyright (C) Arcaniax team and contributors + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ package dev.themeinerlp.bettergopaint.utils; public final class Constants {