diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 74ed61e..4deaa76 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -4,12 +4,10 @@
-
-
-
+
-
-
+
+
@@ -55,13 +53,20 @@
-
+
@@ -84,6 +89,28 @@
false
+
+
+
+
+
+
+
+
+
+
+ true
+ true
+ false
+ false
+
+
@@ -97,6 +124,11 @@
+
+
+
+
+
@@ -131,13 +163,22 @@
1695657371321
-
+
+
+ 1699756821626
+
+
+
+ 1699756821626
+
+
-
+
+
\ No newline at end of file
diff --git a/build.gradle b/build.gradle
index 46dbf23..42d0eb0 100644
--- a/build.gradle
+++ b/build.gradle
@@ -9,10 +9,12 @@ repositories {
mavenCentral()
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
maven { url 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/' }
+ maven { url "https://repo.opencollab.dev/main/" }
}
dependencies {
compileOnly 'org.spigotmc:spigot-api:1.16.5-R0.1-SNAPSHOT'
+ compileOnly 'org.geysermc.geyser:api:2.2.0-SNAPSHOT'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.1'
}
diff --git a/src/main/java/cf/sobrooms/commands/PingCommand.java b/src/main/java/cf/sobrooms/commands/PingCommand.java
index 0fe0402..59ed592 100644
--- a/src/main/java/cf/sobrooms/commands/PingCommand.java
+++ b/src/main/java/cf/sobrooms/commands/PingCommand.java
@@ -6,6 +6,7 @@ import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
+import org.geysermc.geyser.api.GeyserApi;
public class PingCommand implements CommandExecutor {
public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) {
@@ -25,7 +26,8 @@ public class PingCommand implements CommandExecutor {
if (ping_host.equals("404svh")) {
sender.sendMessage("Failed to fetch server ping.");
} else {
- sender.sendMessage(ChatColor.ITALIC + "Server ping: %sms".formatted(ping_host));
+ if (GeyserApi.api().isBedrockPlayer(player.getUniqueId()))
+ sender.sendMessage(ChatColor.RED + "" + ChatColor.ITALIC + "This command will not work properly on bedrock clients.");
sender.sendMessage(ChatColor.ITALIC + "Player ping: %sms".formatted(player.getPing()));
}
return true;