mirror of
https://github.com/darksaid98/HuskHomes.git
synced 2026-12-01 22:16:08 +00:00
Add /edithome, use instant for timestamps, new locales
This commit is contained in:
1 parent
eddae1051c
commit
a91128ca3d
24 files changed
+793
-205
No files matched your search
@@ -12,6 +12,7 @@ public enum BukkitCommandType {
|
||||
SET_HOME_COMMAND(new SetHomeCommand(BukkitHuskHomes.getInstance())),
|
||||
HOME_LIST_COMMAND(new HomeListCommand(BukkitHuskHomes.getInstance())),
|
||||
DEL_HOME_COMMAND(new DelHomeCommand(BukkitHuskHomes.getInstance())),
|
||||
EDIT_HOME_COMMAND(new EditHomeCommand(BukkitHuskHomes.getInstance())),
|
||||
PUBLIC_HOME_COMMAND(new PublicHomeCommand(BukkitHuskHomes.getInstance())),
|
||||
PUBLIC_HOME_LIST_COMMAND(new PublicHomeListCommand(BukkitHuskHomes.getInstance())),
|
||||
WARP_COMMAND(new WarpCommand(BukkitHuskHomes.getInstance())),
|
||||
|
||||
@@ -3,6 +3,7 @@ package net.william278.huskhomes.player;
|
||||
import de.themoep.minedown.MineDown;
|
||||
import io.papermc.lib.PaperLib;
|
||||
import net.md_5.bungee.api.ChatMessageType;
|
||||
import net.md_5.bungee.api.chat.BaseComponent;
|
||||
import net.william278.huskhomes.BukkitHuskHomes;
|
||||
import net.william278.huskhomes.position.Location;
|
||||
import net.william278.huskhomes.position.Position;
|
||||
@@ -96,7 +97,11 @@ public class BukkitPlayer extends OnlineUser {
|
||||
|
||||
@Override
|
||||
public void sendMessage(@NotNull MineDown mineDown) {
|
||||
player.spigot().sendMessage(mineDown.replace().toComponent());
|
||||
final BaseComponent[] messageComponents = mineDown.replace().toComponent();
|
||||
if (messageComponents.length == 0) {
|
||||
return;
|
||||
}
|
||||
player.spigot().sendMessage(messageComponents);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -147,7 +152,7 @@ public class BukkitPlayer extends OnlineUser {
|
||||
/**
|
||||
* Send a Bukkit plugin message
|
||||
*/
|
||||
public void sendPluginMessage(@NotNull Plugin source, @NotNull String channel, @NotNull byte[] message) {
|
||||
public void sendPluginMessage(@NotNull Plugin source, @NotNull String channel, final byte[] message) {
|
||||
player.sendPluginMessage(source, channel, message);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user