mirror of
https://github.com/TheDeus-Group/TFM-4.3-Reloaded.git
synced 2025-01-03 19:28:18 +00:00
Fix discord command sender not being senior (this is retarded)
This commit is contained in:
parent
8f544a74bf
commit
8d13ee731e
1 changed files with 35 additions and 2 deletions
|
@ -3,6 +3,9 @@ package me.StevenLawson.TotalFreedomMod.discord.sender;
|
|||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Server;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.command.ConsoleCommandSender;
|
||||
import org.bukkit.conversations.Conversation;
|
||||
import org.bukkit.conversations.ConversationAbandonedEvent;
|
||||
import org.bukkit.permissions.PermissibleBase;
|
||||
import org.bukkit.permissions.Permission;
|
||||
import org.bukkit.permissions.PermissionAttachment;
|
||||
|
@ -12,7 +15,7 @@ import org.javacord.api.entity.user.User;
|
|||
|
||||
import java.util.Set;
|
||||
|
||||
public class DiscordCommandSender implements CommandSender {
|
||||
public class DiscordCommandSender implements ConsoleCommandSender {
|
||||
private final User user;
|
||||
protected final PermissibleBase perm;
|
||||
|
||||
|
@ -28,7 +31,7 @@ public class DiscordCommandSender implements CommandSender {
|
|||
|
||||
@Override
|
||||
public void sendMessage(String[] strings) {
|
||||
user.sendMessage(String.join("", strings));
|
||||
user.sendMessage(String.join("\n", strings));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -104,4 +107,34 @@ public class DiscordCommandSender implements CommandSender {
|
|||
@Override
|
||||
public void setOp(boolean b) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isConversing() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void acceptConversationInput(String s) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean beginConversation(Conversation conversation) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void abandonConversation(Conversation conversation) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void abandonConversation(Conversation conversation, ConversationAbandonedEvent conversationAbandonedEvent) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void sendRawMessage(String s) {
|
||||
user.sendMessage(s);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue