diff --git a/README.md b/README.md index 417187b7c..b21bd1c9e 100644 --- a/README.md +++ b/README.md @@ -48,5 +48,6 @@ Contributing * Feel free to open an [Issue](https://github.com/Akarin-project/akarin/issues) if you have any problem with Akarin. * [Pull Request](https://github.com/Akarin-project/akarin/pulls) is welcomed, Akarin use [Mixin](https://github.com/SpongePowered/Mixin) to modify the code, you can checkout `sources` folder to see them. Moreover, add your name to the [LICENSE](https://github.com/Akarin-project/Akarin/blob/master/LICENSE.md) if you want to publish your code under the [MIT License](https://github.com/Akarin-project/Akarin/blob/master/licenses/MIT.md). * If you want to join the [Akarin-project](https://github.com/Akarin-project) team, you can send an email to `kira@kira.moe` with your experience and necessary information. Besides, welcome to join our [TIM Group](https://jq.qq.com/?_wv=1027&k=59q2kV4) to chat. +* Note that you need add `work/Paper/Paper-Server` to the `Build Path` of your IDE manually to organize the *NMS* import, the raw *NMS* dependency was dragged to the `Paper-Parent` project. ![Akarin project](https://i.loli.net/2018/05/13/5af7fbbfbcddf.png) \ No newline at end of file diff --git a/sources/src/main/java/io/akarin/server/mixin/core/MixinMetrics.java b/sources/src/main/java/io/akarin/server/mixin/core/MixinMetrics.java index a50d29068..e166aa2fe 100644 --- a/sources/src/main/java/io/akarin/server/mixin/core/MixinMetrics.java +++ b/sources/src/main/java/io/akarin/server/mixin/core/MixinMetrics.java @@ -3,7 +3,6 @@ package io.akarin.server.mixin.core; import java.util.List; import org.bukkit.Bukkit; -import io.akarin.api.LogWrapper; import org.json.simple.JSONArray; import org.json.simple.JSONObject; import org.spongepowered.asm.mixin.Final; diff --git a/sources/src/main/java/io/akarin/server/mixin/core/MixinVersionCommand.java b/sources/src/main/java/io/akarin/server/mixin/core/MixinVersionCommand.java index d32fbef7d..cb2237011 100644 --- a/sources/src/main/java/io/akarin/server/mixin/core/MixinVersionCommand.java +++ b/sources/src/main/java/io/akarin/server/mixin/core/MixinVersionCommand.java @@ -64,16 +64,16 @@ public class MixinVersionCommand { // (this is really a special case that we cancel new tasks instead let them wait). versionObtaining = true; - if (hasVersion) { - long current = System.currentTimeMillis(); + if (hasVersion) { + long current = System.currentTimeMillis(); if (current - lastCheckMillis > 7200000 /* 2 hours */) { lastCheckMillis = current; - hasVersion = false; - } else { - sender.sendMessage(versionMessage); + hasVersion = false; + } else { + sender.sendMessage(versionMessage); return; - } - } + } + } if (!hasVersion) { obtainVersion(sender); /* TODO Option: legacy-versioning-compat */ currentSender = sender; @@ -101,7 +101,7 @@ public class MixinVersionCommand { MCUtil.scheduleAsyncTask(() -> { // This should be lying in 'sendVersion' method, but comes here for relax main thread versionWaiters.add(sender); - sender.sendMessage("Checking version, please wait..."); + sender.sendMessage("Checking version, please wait..."); String version = Bukkit.getVersion(); if (version == null) {