Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-24 15:20:15 +01:00
Avoid relocation issues on BungeeCord
Dieser Commit ist enthalten in:
Ursprung
d50ceaa172
Commit
7b1eefb115
@ -2,7 +2,6 @@ package us.myles.ViaVersion;
|
||||
|
||||
import com.google.gson.JsonObject;
|
||||
import net.md_5.bungee.api.ProxyServer;
|
||||
import net.md_5.bungee.api.chat.TextComponent;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
import net.md_5.bungee.api.event.PlayerDisconnectEvent;
|
||||
import net.md_5.bungee.api.plugin.Listener;
|
||||
@ -111,13 +110,13 @@ public class BungeePlugin extends Plugin implements ViaPlatform, Listener {
|
||||
|
||||
@Override
|
||||
public void sendMessage(UUID uuid, String message) {
|
||||
getProxy().getPlayer(uuid).sendMessage(TextComponent.fromLegacyText(message));
|
||||
getProxy().getPlayer(uuid).sendMessage(message);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean kickPlayer(UUID uuid, String message) {
|
||||
if (getProxy().getPlayer(uuid) != null) {
|
||||
getProxy().getPlayer(uuid).disconnect(TextComponent.fromLegacyText(message));
|
||||
getProxy().getPlayer(uuid).disconnect(message);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -2,7 +2,6 @@ package us.myles.ViaVersion.bungee.commands;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.chat.TextComponent;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
import us.myles.ViaVersion.api.command.ViaCommandSender;
|
||||
|
||||
@ -19,7 +18,7 @@ public class BungeeCommandSender implements ViaCommandSender {
|
||||
|
||||
@Override
|
||||
public void sendMessage(String msg) {
|
||||
sender.sendMessage(TextComponent.fromLegacyText(msg));
|
||||
sender.sendMessage(msg);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren