1 Commits
Author SHA1 Message Date
caseload e635d42c9a update 1.3.2 2024-10-03 21:57:54 -05:00
6 changed files with 8 additions and 6 deletions

No files matched your search

+1 -1
View File
@@ -6,7 +6,7 @@
<groupId>me.caseload</groupId>
<artifactId>KnockbackSync</artifactId>
<version>1.3</version>
<version>1.3.2</version>
<packaging>jar</packaging>
<name>KnockbackSync</name>
@@ -22,6 +22,7 @@ public final class KnockbackSync extends JavaPlugin {
private boolean toggled;
private boolean runnable;
private boolean updateAvailable;
private boolean notifyUpdate;
private long runnableInterval;
private long combatTimer;
@@ -58,7 +59,8 @@ public final class KnockbackSync extends JavaPlugin {
runnable = getConfig().getBoolean("runnable.enabled", true);
runnableInterval = getConfig().getLong("runnable.interval", 5L);
combatTimer = getConfig().getLong("runnable.timer", 30L);
spikeThreshold = getConfig().getLong("spike_threshold", 25L);
spikeThreshold = getConfig().getLong("spike_threshold", 20L);
notifyUpdate = getConfig().getBoolean("notify_updates", true);
if (runnable)
new PingRunnable().runTaskTimerAsynchronously(this, 0L, runnableInterval);
@@ -19,7 +19,7 @@ public class PlayerJoinQuitListener implements Listener {
Player player = event.getPlayer();
PlayerDataManager.addPlayerData(player.getUniqueId(), new PlayerData(player));
if (KnockbackSync.getInstance().isUpdateAvailable() && player.hasPermission("knockbacksync.update"))
if (KnockbackSync.getInstance().isUpdateAvailable() && KnockbackSync.getInstance().isNotifyUpdate() && player.hasPermission("knockbacksync.update"))
player.sendMessage(ChatColor.translateAlternateColorCodes(
'&',
"&6An updated version of &eKnockbackSync &6is now available for download at: &bhttps://github.com/CASELOAD7000/knockback-sync/releases/latest"
@@ -29,7 +29,7 @@ public class PlayerData {
private final Player player;
// Please read the GitHub FAQ before adjusting.
private static final long PING_OFFSET = 20;
private static final long PING_OFFSET = 25;
@NotNull
private final Map<Integer, Long> timeline = new HashMap<>();
+1 -1
View File
@@ -21,7 +21,7 @@ runnable:
# The minimum change in ping required for it to be considered a lag spike.
# If the difference between the latest and previous ping is greater than or equal to
# the threshold, the previous ping value is used to avoid calculation inaccuracies.
spike_threshold: 25
spike_threshold: 20
enable_message: "&aSuccessfully enabled KnockbackSync."
disable_message: "&cSuccessfully disabled KnockbackSync."
+1 -1
View File
@@ -1,5 +1,5 @@
name: KnockbackSync
version: '1.3'
version: '1.3.2'
main: me.caseload.knockbacksync.KnockbackSync
api-version: '1.18'
authors: [ Caseload ]