Compare commits

..

2 Commits

Author SHA1 Message Date
Kyoukawa Meishin 9ad9baae2e 提升版本号至1.2.2 2025-10-19 21:39:48 +08:00
Kyoukawa Meishin f2f047ab90 更改了获取逻辑 2025-10-19 21:38:08 +08:00
3 changed files with 6 additions and 7 deletions
+1 -1
View File
@@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.mmlsystem</groupId>
<artifactId>StatusSystem</artifactId>
<version>1.2.1</version>
<version>1.2.2</version>
<repositories>
<repository>
@@ -65,9 +65,8 @@ public class StatusFoundation extends JavaPlugin {
objective.getScore(ChatColor.AQUA + "当前在线人数").setScore(7);
objective.getScore(ChatColor.GREEN + " " + Bukkit.getOnlinePlayers().size()).setScore(6);
objective.getScore(" ").setScore(5);
getTime(player);
objective.getScore(ChatColor.AQUA + "在线时长").setScore(4);
objective.getScore(ChatColor.GREEN + " " + getTimeString()).setScore(3);
objective.getScore(ChatColor.GREEN + " " + "获取中").setScore(3);
objective.getScore("").setScore(2);
objective.getScore(ChatColor.GRAY + "mymc.life").setScore(1);
@@ -87,8 +86,7 @@ public class StatusFoundation extends JavaPlugin {
}
objective.getScore(ChatColor.RED + " " + econ.getBalance(player) ).setScore(9);
objective.getScore(ChatColor.GREEN + " " + Bukkit.getOnlinePlayers().size()).setScore(6);
getTime(player);
objective.getScore(ChatColor.GREEN + " " + getTimeString()).setScore(3);
objective.getScore(ChatColor.GREEN + " " + getTime(player)).setScore(3);
}
}.runTaskTimer(this, 0L, 100L);
}
@@ -97,8 +95,9 @@ public class StatusFoundation extends JavaPlugin {
this.totalTime = time / 1000;
}
public void getTime(Player player) {
public String getTime(Player player) {
api.getPlayerOnlineTime(player, this::setTime);
return getTimeString();
}
public String getTimeString() {
+1 -1
View File
@@ -1,6 +1,6 @@
name: StatusSystem
main: com.mmlsystem.StatusSystem.StatusFoundation
version: 1.2.1
version: 1.2.2
api-version: 1.21
author: 杏川铭心
description: 提供服务器计分板UI功能。