mirror of
https://github.com/darksaid98/TownyChat.git
synced 2026-12-01 14:38:57 +00:00
- Remove usage of Version, using new Towny version checker instead.
This commit is contained in:
1 parent
69c0d2f092
commit
a1c7e9f7c2
3 files changed
+11
-6
No files matched your search
@@ -7,7 +7,7 @@
|
||||
<groupId>com.palmergames.bukkit</groupId>
|
||||
<artifactId>TownyChat</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<version>0.106</version>
|
||||
<version>0.107</version>
|
||||
|
||||
<licenses>
|
||||
<license>
|
||||
@@ -26,7 +26,7 @@
|
||||
<java.version>17</java.version>
|
||||
<project.bukkitAPIVersion>1.16</project.bukkitAPIVersion>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<towny.version>0.99.0.12</towny.version>
|
||||
<towny.version>0.99.1.0</towny.version>
|
||||
</properties>
|
||||
|
||||
<!-- For use with GitHub Package Registry -->
|
||||
|
||||
@@ -461,4 +461,6 @@ v0.106:
|
||||
- towny.rankpriority.#
|
||||
- towny.rankprefix.<somewordshere>
|
||||
- Fix version check, courtesy of Warrior with PR #48.
|
||||
- Update min. Towny version to 0.99.1.0.
|
||||
- Update min. Towny version to 0.99.1.0.
|
||||
v0.107:
|
||||
- Remove usage of Version, using new Towny version checker instead.
|
||||
@@ -16,7 +16,6 @@ import com.palmergames.bukkit.towny.Towny;
|
||||
import com.palmergames.bukkit.towny.scheduling.TaskScheduler;
|
||||
import com.palmergames.bukkit.towny.scheduling.impl.BukkitTaskScheduler;
|
||||
import com.palmergames.bukkit.towny.scheduling.impl.FoliaTaskScheduler;
|
||||
import com.palmergames.bukkit.util.Version;
|
||||
import com.palmergames.util.FileMgmt;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
@@ -59,7 +58,7 @@ public class Chat extends JavaPlugin {
|
||||
private DynmapAPI dynMap = null;
|
||||
private Essentials essentials = null;
|
||||
|
||||
private static Version requiredTownyVersion = Version.fromString("0.99.1.0");
|
||||
private static String requiredTownyVersion = "0.99.1.0";
|
||||
public static boolean usingPlaceholderAPI = false;
|
||||
public static boolean usingEssentialsDiscord = false;
|
||||
boolean chatConfigError = false;
|
||||
@@ -110,7 +109,11 @@ public class Chat extends JavaPlugin {
|
||||
}
|
||||
|
||||
private boolean townyVersionCheck() {
|
||||
return Version.fromString(Towny.getPlugin().getVersion()).compareTo(requiredTownyVersion) >= 0;
|
||||
try {
|
||||
return Towny.isTownyVersionSupported(requiredTownyVersion);
|
||||
} catch (NoSuchMethodError e) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
private void loadConfigs() {
|
||||
|
||||
Reference in new issue
Block a user