mirror of
https://github.com/darksaid98/HuskHomes.git
synced 2026-12-02 06:28:49 +00:00
Fix various issues
This commit is contained in:
35 files changed
+236
-243
No files matched your search
@@ -36,7 +36,6 @@ import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChunkSnapshot;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.permissions.PermissionDefault;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
import org.bukkit.plugin.PluginDescriptionFile;
|
||||
import org.bukkit.plugin.java.JavaPlugin;
|
||||
@@ -52,6 +51,7 @@ import java.lang.reflect.InvocationTargetException;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.concurrent.atomic.AtomicBoolean;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.logging.Level;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@@ -72,7 +72,7 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes, BukkitTask
|
||||
private Spawn serverSpawn;
|
||||
private UnsafeBlocks unsafeBlocks;
|
||||
private Set<PluginHook> pluginHooks;
|
||||
private List<Command> registeredCommands;
|
||||
private List<Command> commands;
|
||||
private Server server;
|
||||
|
||||
@Nullable
|
||||
@@ -98,57 +98,54 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes, BukkitTask
|
||||
public void onEnable() {
|
||||
// Initialize HuskHomes
|
||||
final AtomicBoolean initialized = new AtomicBoolean(true);
|
||||
try {
|
||||
// Create adventure audience
|
||||
this.audiences = BukkitAudiences.create(this);
|
||||
// Create adventure audience
|
||||
this.audiences = BukkitAudiences.create(this);
|
||||
|
||||
// Load settings and locales
|
||||
log(Level.INFO, "Loading plugin configuration settings & locales...");
|
||||
initialized.set(reload());
|
||||
if (initialized.get()) {
|
||||
log(Level.INFO, "Successfully loaded plugin configuration settings & locales");
|
||||
} else {
|
||||
throw new IllegalStateException("Failed to load plugin configuration settings and/or locales");
|
||||
}
|
||||
// Load settings and locales
|
||||
log(Level.INFO, "Loading plugin configuration settings & locales...");
|
||||
initialized.set(reload());
|
||||
if (initialized.get()) {
|
||||
log(Level.INFO, "Successfully loaded plugin configuration settings & locales");
|
||||
} else {
|
||||
throw new IllegalStateException("Failed to load plugin configuration settings and/or locales");
|
||||
}
|
||||
|
||||
// Initialize the database
|
||||
log(Level.INFO, "Attempting to establish connection to the database...");
|
||||
final Database.DatabaseType databaseType = settings.getDatabaseType();
|
||||
this.database = switch (databaseType == null ? Database.DatabaseType.MYSQL : databaseType) {
|
||||
case MYSQL -> new MySqlDatabase(this);
|
||||
case SQLITE -> new SqLiteDatabase(this);
|
||||
};
|
||||
initialized.set(this.database.initialize());
|
||||
if (initialized.get()) {
|
||||
log(Level.INFO, "Successfully established a connection to the database");
|
||||
} else {
|
||||
throw new IllegalStateException("Failed to establish a connection to the database. " + "Please check the supplied database credentials in the config file");
|
||||
}
|
||||
// Initialize the database
|
||||
log(Level.INFO, "Attempting to establish connection to the database...");
|
||||
final Database.DatabaseType databaseType = settings.getDatabaseType();
|
||||
this.database = switch (databaseType == null ? Database.DatabaseType.MYSQL : databaseType) {
|
||||
case MYSQL -> new MySqlDatabase(this);
|
||||
case SQLITE -> new SqLiteDatabase(this);
|
||||
};
|
||||
initialized.set(this.database.initialize());
|
||||
if (initialized.get()) {
|
||||
log(Level.INFO, "Successfully established a connection to the database");
|
||||
} else {
|
||||
throw new IllegalStateException("Failed to establish a connection to the database. " +
|
||||
"Please check the supplied database credentials in the config file");
|
||||
}
|
||||
|
||||
// Initialize the network messenger if proxy mode is enabled
|
||||
if (getSettings().isCrossServer()) {
|
||||
log(Level.INFO, "Initializing the network messenger...");
|
||||
// Initialize the network messenger if proxy mode is enabled
|
||||
if (getSettings().isCrossServer()) {
|
||||
initialize("message broker", (plugin) -> {
|
||||
broker = switch (settings.getBrokerType()) {
|
||||
case PLUGIN_MESSAGE -> new PluginMessageBroker(this);
|
||||
case REDIS -> new RedisBroker(this);
|
||||
};
|
||||
broker.initialize();
|
||||
log(Level.INFO, "Successfully initialized the network messenger.");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// Prepare the validator
|
||||
this.validator = new Validator(this);
|
||||
// Prepare the validator
|
||||
this.validator = new Validator(this);
|
||||
this.cache = new Cache(this);
|
||||
this.manager = new Manager(this);
|
||||
|
||||
// Initialize the cache
|
||||
this.cache = new Cache(this);
|
||||
// Initialize the RTP engine with the default normal distribution engine
|
||||
setRandomTeleportEngine(new NormalDistributionEngine(this));
|
||||
|
||||
// Prepare the home and warp position manager
|
||||
this.manager = new Manager(this);
|
||||
|
||||
// Initialize the RTP engine with the default normal distribution engine
|
||||
setRandomTeleportEngine(new NormalDistributionEngine(this));
|
||||
|
||||
// Register plugin hooks (Economy, Maps, Plan)
|
||||
// Register plugin hooks (Economy, Maps, Plan)
|
||||
initialize("hooks", (plugin) -> {
|
||||
this.pluginHooks = new HashSet<>();
|
||||
if (settings.doEconomy()) {
|
||||
if (Bukkit.getPluginManager().getPlugin("RedisEconomy") != null) {
|
||||
@@ -178,66 +175,46 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes, BukkitTask
|
||||
|
||||
if (pluginHooks.size() > 0) {
|
||||
pluginHooks.forEach(PluginHook::initialize);
|
||||
log(Level.INFO, "Registered " + pluginHooks.size() + " plugin hooks: " + pluginHooks.stream().map(PluginHook::getHookName).collect(Collectors.joining(", ")));
|
||||
log(Level.INFO, "Registered " + pluginHooks.size() + " plugin hooks: " + pluginHooks.stream()
|
||||
.map(PluginHook::getHookName)
|
||||
.collect(Collectors.joining(", ")));
|
||||
}
|
||||
});
|
||||
|
||||
// Register events
|
||||
log(Level.INFO, "Registering events...");
|
||||
this.eventListener = new BukkitEventListener(this);
|
||||
log(Level.INFO, "Successfully registered events listener");
|
||||
// Register events
|
||||
initialize("events", (plugin) -> this.eventListener = new BukkitEventListener(this));
|
||||
|
||||
// Register permissions
|
||||
log(Level.INFO, "Registering permissions & commands...");
|
||||
Arrays.stream(Permission.values()).forEach(permission -> getServer().getPluginManager().addPermission(new org.bukkit.permissions.Permission(permission.node, switch (permission.defaultAccess) {
|
||||
case EVERYONE -> PermissionDefault.TRUE;
|
||||
case NOBODY -> PermissionDefault.FALSE;
|
||||
case OPERATORS -> PermissionDefault.OP;
|
||||
})));
|
||||
// Register commands
|
||||
initialize("commands", (plugin) -> this.commands = Arrays.stream(BukkitCommand.Type.values())
|
||||
.map(type -> {
|
||||
final Command command = type.getCommand();
|
||||
if (settings.isCommandDisabled(command)) {
|
||||
new BukkitCommand(new DisabledCommand(this), this).register();
|
||||
return null;
|
||||
} else {
|
||||
new BukkitCommand(command, this).register();
|
||||
return type.getCommand();
|
||||
}
|
||||
})
|
||||
.filter(Objects::nonNull)
|
||||
.collect(Collectors.toList()));
|
||||
|
||||
// Register commands
|
||||
this.registeredCommands = new ArrayList<>();
|
||||
Arrays.stream(BukkitCommand.Type.values()).forEach(commandType -> {
|
||||
// If the command is disabled, use the disabled CommandBase
|
||||
if (settings.getDisabledCommands().stream().anyMatch(disabledCommand -> {
|
||||
final String command = (disabledCommand.startsWith("/") ? disabledCommand.substring(1) : disabledCommand);
|
||||
return command.equalsIgnoreCase(commandType.getCommand().getName()) || commandType.getCommand().getAliases().stream().anyMatch(alias -> alias.equalsIgnoreCase(command));
|
||||
})) {
|
||||
new BukkitCommand(new DisabledCommand(this), this).register();
|
||||
return;
|
||||
}
|
||||
// Hook into bStats metrics
|
||||
initialize("metrics", (plugin) -> this.registerMetrics(METRICS_ID));
|
||||
|
||||
// Otherwise, register the command
|
||||
final Command command = commandType.getCommand();
|
||||
this.registeredCommands.add(command);
|
||||
new BukkitCommand(command, this).register();
|
||||
});
|
||||
log(Level.INFO, "Successfully registered permissions & commands.");
|
||||
|
||||
// Hook into bStats metrics
|
||||
registerMetrics(METRICS_ID);
|
||||
|
||||
// Check for updates
|
||||
if (settings.doCheckForUpdates()) {
|
||||
log(Level.INFO, "Checking for updates...");
|
||||
getLatestVersionIfOutdated().thenAccept(newestVersion -> newestVersion.ifPresent(newVersion -> log(Level.WARNING, "An update is available for HuskHomes, v" + newVersion + " (Currently running v" + getVersion() + ")")));
|
||||
}
|
||||
} catch (IllegalStateException exception) {
|
||||
log(Level.SEVERE, exception.getMessage());
|
||||
initialized.set(false);
|
||||
} catch (Exception exception) {
|
||||
log(Level.SEVERE, "An unhandled exception occurred initializing HuskHomes!", exception);
|
||||
initialized.set(false);
|
||||
} finally {
|
||||
// Validate initialization
|
||||
if (initialized.get()) {
|
||||
log(Level.INFO, "Successfully enabled HuskHomes v" + getVersion());
|
||||
} else {
|
||||
log(Level.SEVERE, "Failed to initialize HuskHomes. The plugin will now be disabled");
|
||||
getServer().getPluginManager().disablePlugin(this);
|
||||
}
|
||||
// Check for updates
|
||||
if (settings.doCheckForUpdates()) {
|
||||
log(Level.INFO, "Checking for updates...");
|
||||
getLatestVersionIfOutdated().thenAccept(newestVersion -> newestVersion.ifPresent(newVersion -> log(Level.WARNING, "An update is available for HuskHomes, v" + newVersion + " (Currently running v" + getVersion() + ")")));
|
||||
}
|
||||
}
|
||||
|
||||
private void initialize(@NotNull String name, @NotNull Consumer<HuskHomes> runner) {
|
||||
log(Level.INFO, "Initializing " + name + "...");
|
||||
runner.accept(this);
|
||||
log(Level.INFO, "Successfully initialized " + name);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDisable() {
|
||||
if (this.eventListener != null) {
|
||||
@@ -339,19 +316,17 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes, BukkitTask
|
||||
|
||||
@Override
|
||||
public void setServerSpawn(@NotNull Location location) {
|
||||
final Spawn newSpawn = new Spawn(location);
|
||||
this.serverSpawn = newSpawn;
|
||||
try {
|
||||
Annotaml.create(new File(getDataFolder(), "spawn.yml"), newSpawn);
|
||||
} catch (IOException e) {
|
||||
this.serverSpawn = Annotaml.create(new File(getDataFolder(), "spawn.yml"), new Spawn(location)).get();
|
||||
|
||||
// Update the world spawn location, too
|
||||
BukkitAdapter.adaptLocation(location).ifPresent(bukkitLocation -> {
|
||||
assert bukkitLocation.getWorld() != null;
|
||||
bukkitLocation.getWorld().setSpawnLocation(bukkitLocation);
|
||||
});
|
||||
} catch (IOException | InvocationTargetException | InstantiationException | IllegalAccessException e) {
|
||||
log(Level.WARNING, "Failed to save server spawn to disk", e);
|
||||
}
|
||||
|
||||
// Update the world spawn location, too
|
||||
BukkitAdapter.adaptLocation(location).ifPresent(bukkitLocation -> {
|
||||
assert bukkitLocation.getWorld() != null;
|
||||
bukkitLocation.getWorld().setSpawnLocation(bukkitLocation);
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -401,7 +376,7 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes, BukkitTask
|
||||
@Override
|
||||
@NotNull
|
||||
public List<Command> getCommands() {
|
||||
return registeredCommands;
|
||||
return commands;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -496,7 +471,7 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes, BukkitTask
|
||||
@Override
|
||||
public void onPluginMessageReceived(@NotNull String channel, @NotNull Player player, byte[] message) {
|
||||
if (broker != null && broker instanceof PluginMessageBroker pluginMessenger
|
||||
&& getSettings().getBrokerType() == Broker.Type.PLUGIN_MESSAGE) {
|
||||
&& getSettings().getBrokerType() == Broker.Type.PLUGIN_MESSAGE) {
|
||||
pluginMessenger.onReceive(channel, BukkitUser.adapt(player), message);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -43,6 +43,8 @@ public class BukkitCommand implements CommandExecutor, TabCompleter {
|
||||
final PluginCommand pluginCommand = Objects.requireNonNull(plugin.getCommand(command.getName()));
|
||||
pluginCommand.setExecutor(this);
|
||||
pluginCommand.setTabCompleter(this);
|
||||
pluginCommand.setDescription(command.getDescription());
|
||||
pluginCommand.setPermission(command.getPermission());
|
||||
|
||||
// Register commodore TAB completion
|
||||
if (CommodoreProvider.isSupported() && plugin.getSettings().doBrigadierTabCompletion()) {
|
||||
|
||||
@@ -5,7 +5,7 @@ import net.kyori.adventure.audience.Audience;
|
||||
import net.william278.huskhomes.BukkitHuskHomes;
|
||||
import net.william278.huskhomes.position.Location;
|
||||
import net.william278.huskhomes.position.Position;
|
||||
import net.william278.huskhomes.teleport.TeleportResult;
|
||||
import net.william278.huskhomes.teleport.TeleportationException;
|
||||
import net.william278.huskhomes.util.BukkitAdapter;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
@@ -16,7 +16,6 @@ import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.Map;
|
||||
import java.util.Optional;
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
@@ -24,18 +23,7 @@ import java.util.stream.Collectors;
|
||||
*/
|
||||
public class BukkitUser extends OnlineUser {
|
||||
|
||||
/**
|
||||
* Number of ticks to wait before {@link #sendPluginMessage(String, byte[]) sending a plugin message}.
|
||||
* </p>
|
||||
* This is needed because it is not possible to have players dispatch plugin messages in certain circumstance,
|
||||
* such as on the tick that they join the server.
|
||||
*/
|
||||
private static final long PLUGIN_MESSAGE_DISPATCH_DELAY = 3L;
|
||||
|
||||
// Instance of the implementing plugin
|
||||
private final BukkitHuskHomes plugin;
|
||||
|
||||
// The Bukkit player
|
||||
private final Player player;
|
||||
|
||||
private BukkitUser(@NotNull Player player) {
|
||||
@@ -55,20 +43,6 @@ public class BukkitUser extends OnlineUser {
|
||||
return new BukkitUser(player);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get an online {@link BukkitUser} by their exact username
|
||||
*
|
||||
* @param username the UUID of the player to find
|
||||
* @return an {@link Optional} containing the {@link BukkitUser} if found; {@link Optional#empty()} otherwise
|
||||
*/
|
||||
public static Optional<BukkitUser> get(@NotNull String username) {
|
||||
final Player player = Bukkit.getPlayerExact(username);
|
||||
if (player != null) {
|
||||
return Optional.of(adapt(player));
|
||||
}
|
||||
return Optional.empty();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Position getPosition() {
|
||||
return new Position(BukkitAdapter.adaptLocation(player.getLocation())
|
||||
@@ -95,10 +69,13 @@ public class BukkitUser extends OnlineUser {
|
||||
|
||||
|
||||
@Override
|
||||
public @NotNull Map<String, Boolean> getPermissions() {
|
||||
return player.getEffectivePermissions().stream().collect(
|
||||
Collectors.toMap(PermissionAttachmentInfo::getPermission,
|
||||
PermissionAttachmentInfo::getValue, (a, b) -> b));
|
||||
@NotNull
|
||||
public Map<String, Boolean> getPermissions() {
|
||||
return player.getEffectivePermissions().stream()
|
||||
.collect(Collectors.toMap(
|
||||
PermissionAttachmentInfo::getPermission,
|
||||
PermissionAttachmentInfo::getValue, (a, b) -> b
|
||||
));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -108,38 +85,43 @@ public class BukkitUser extends OnlineUser {
|
||||
}
|
||||
|
||||
@Override
|
||||
public CompletableFuture<TeleportResult> teleportLocally(@NotNull Location location, boolean asynchronous) {
|
||||
final Optional<org.bukkit.Location> bukkitLocation = BukkitAdapter.adaptLocation(location);
|
||||
if (bukkitLocation.isEmpty()) {
|
||||
return CompletableFuture.completedFuture(TeleportResult.FAILED_INVALID_WORLD);
|
||||
public void teleportLocally(@NotNull Location location, boolean asynchronous) throws TeleportationException {
|
||||
final Optional<org.bukkit.Location> resolvedLocation = BukkitAdapter.adaptLocation(location);
|
||||
if (resolvedLocation.isEmpty() || resolvedLocation.get().getWorld() == null) {
|
||||
throw new TeleportationException(TeleportationException.Type.WORLD_NOT_FOUND);
|
||||
}
|
||||
assert bukkitLocation.get().getWorld() != null;
|
||||
if (!bukkitLocation.get().getWorld().getWorldBorder().isInside(bukkitLocation.get())) {
|
||||
return CompletableFuture.completedFuture(TeleportResult.FAILED_ILLEGAL_COORDINATES);
|
||||
|
||||
final org.bukkit.Location bukkitLocation = resolvedLocation.get();
|
||||
if (!bukkitLocation.getWorld().getWorldBorder().isInside(resolvedLocation.get())) {
|
||||
throw new TeleportationException(TeleportationException.Type.ILLEGAL_TARGET_COORDINATES);
|
||||
}
|
||||
final CompletableFuture<TeleportResult> resultCompletableFuture = new CompletableFuture<>();
|
||||
|
||||
Bukkit.getScheduler().runTask(plugin, () -> {
|
||||
if (asynchronous) {
|
||||
PaperLib.teleportAsync(player, bukkitLocation.get(), PlayerTeleportEvent.TeleportCause.PLUGIN)
|
||||
.thenAccept(result -> resultCompletableFuture.complete(
|
||||
result ? TeleportResult.COMPLETED_LOCALLY : TeleportResult.FAILED_INVALID_WORLD));
|
||||
PaperLib.teleportAsync(player, bukkitLocation, PlayerTeleportEvent.TeleportCause.PLUGIN);
|
||||
} else {
|
||||
player.teleport(bukkitLocation.get(), PlayerTeleportEvent.TeleportCause.PLUGIN);
|
||||
resultCompletableFuture.complete(TeleportResult.COMPLETED_LOCALLY);
|
||||
player.teleport(bukkitLocation, PlayerTeleportEvent.TeleportCause.PLUGIN);
|
||||
}
|
||||
});
|
||||
return resultCompletableFuture;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the player momentum and return if they are moving
|
||||
*
|
||||
* @return {@code true} if the player is moving, {@code false} otherwise
|
||||
**/
|
||||
@Override
|
||||
public boolean isMoving() {
|
||||
// Get the player momentum and return if they are moving
|
||||
return player.getVelocity().length() >= 0.1;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the value of the player's "vanished" metadata tag if they have it
|
||||
*
|
||||
* @return {@code true} if the player is vanished, {@code false} otherwise
|
||||
*/
|
||||
@Override
|
||||
public boolean isVanished() {
|
||||
// Return the value of the player's "vanished" metadata tag if they have it
|
||||
return player.getMetadata("vanished")
|
||||
.stream()
|
||||
.map(MetadataValue::asBoolean)
|
||||
@@ -148,14 +130,10 @@ public class BukkitUser extends OnlineUser {
|
||||
}
|
||||
|
||||
/**
|
||||
* Send a Bukkit plugin message
|
||||
*
|
||||
* @implNote This is dispatched after {@link #PLUGIN_MESSAGE_DISPATCH_DELAY a delay} to ensure that the player
|
||||
* is ready to send receive messages
|
||||
* Send a Bukkit plugin message to the player
|
||||
*/
|
||||
public void sendPluginMessage(@NotNull String channel, final byte[] message) {
|
||||
Bukkit.getScheduler().runTaskLater(plugin,
|
||||
() -> player.sendPluginMessage(plugin, channel, message), PLUGIN_MESSAGE_DISPATCH_DELAY);
|
||||
player.sendPluginMessage(plugin, channel, message);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -28,12 +28,12 @@ commands:
|
||||
usage: /delhome <name>
|
||||
edithome:
|
||||
usage: /edithome <name> [rename|description|relocate|privacy] [args]
|
||||
publichome:
|
||||
usage: /publichome [<owner_name>.<home_name>]
|
||||
aliases: [phome]
|
||||
publichomelist:
|
||||
usage: /publichomelist [page]
|
||||
aliases: [phomelist, phomes]
|
||||
phome:
|
||||
usage: /phome [<owner_name>.<home_name>]
|
||||
aliases: [publichome]
|
||||
phomelist:
|
||||
usage: /phomelist [page]
|
||||
aliases: [publichomelist, phomes]
|
||||
warp:
|
||||
usage: /warp <name>
|
||||
setwarp:
|
||||
|
||||
@@ -55,15 +55,7 @@ public class Cache {
|
||||
.filter(player -> !player.isVanished())
|
||||
.map(User::getUsername)
|
||||
.toList());
|
||||
//todo
|
||||
// if (plugin.getSettings().isCrossServer()) {
|
||||
// return plugin.getMessenger()
|
||||
// .getOnlinePlayerNames(requester)
|
||||
// .thenApply(networkedPlayers -> {
|
||||
// getPlayers().addAll(Set.of(networkedPlayers));
|
||||
// return getPlayers();
|
||||
// });
|
||||
// }
|
||||
|
||||
return CompletableFuture.completedFuture(getPlayers());
|
||||
}
|
||||
|
||||
|
||||
@@ -325,7 +325,7 @@ public interface HuskHomes extends TaskRunner, EventDispatcher {
|
||||
|
||||
default <T extends Command> Optional<T> getCommand(@NotNull Class<T> type) {
|
||||
return getCommands().stream()
|
||||
.filter(command -> command.getClass().isInstance(type))
|
||||
.filter(command -> command.getClass() == type)
|
||||
.findFirst()
|
||||
.map(type::cast);
|
||||
}
|
||||
|
||||
@@ -87,6 +87,7 @@ public class EditHomeCommand extends SavedPositionCommand<Home> {
|
||||
}
|
||||
|
||||
private void setHomeDescription(@NotNull CommandUser executor, @NotNull Home home, boolean ownerEditing, @NotNull String[] args) {
|
||||
final String oldDescription = home.getMeta().getDescription();
|
||||
final Optional<String> optionalDescription = parseGreedyString(args, 1);
|
||||
if (optionalDescription.isEmpty()) {
|
||||
plugin.getLocales().getLocale("error_invalid_syntax",
|
||||
@@ -106,11 +107,11 @@ public class EditHomeCommand extends SavedPositionCommand<Home> {
|
||||
}
|
||||
|
||||
if (ownerEditing) {
|
||||
plugin.getLocales().getLocale("edit_home_update_description", home.getName(), newDescription)
|
||||
plugin.getLocales().getLocale("edit_home_update_description", home.getName(), oldDescription, newDescription)
|
||||
.ifPresent(executor::sendMessage);
|
||||
} else {
|
||||
plugin.getLocales().getLocale("edit_home_update_description_other", home.getOwner().getUsername(),
|
||||
home.getName(), newDescription)
|
||||
home.getName(), oldDescription, newDescription)
|
||||
.ifPresent(executor::sendMessage);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -64,7 +64,7 @@ public class RtpCommand extends Command {
|
||||
.orElseThrow(() -> new IllegalStateException("No user data found for " + teleporter.getUsername()));
|
||||
final Instant currentTime = Instant.now();
|
||||
if (executor.equals(teleporter) && !currentTime.isAfter(user.getRtpCooldown()) &&
|
||||
!executor.hasPermission(getPermission("bypass_cooldown"))) {
|
||||
!executor.hasPermission(getPermission("bypass_cooldown"))) {
|
||||
plugin.getLocales().getLocale("error_rtp_cooldown",
|
||||
Long.toString(currentTime.until(user.getRtpCooldown(), ChronoUnit.MINUTES) + 1))
|
||||
.ifPresent(executor::sendMessage);
|
||||
@@ -74,7 +74,7 @@ public class RtpCommand extends Command {
|
||||
plugin.getLocales().getLocale("teleporting_random_generation")
|
||||
.ifPresent(teleporter::sendMessage);
|
||||
final Optional<Position> position = plugin.getRandomTeleportEngine()
|
||||
.getRandomPosition(teleporter.getPosition().getWorld(), removeFirstArg(args));
|
||||
.getRandomPosition(teleporter.getPosition().getWorld(), args.length > 1 ? removeFirstArg(args) : args);
|
||||
if (position.isEmpty()) {
|
||||
plugin.getLocales().getLocale("error_rtp_randomization_timeout")
|
||||
.ifPresent(executor::sendMessage);
|
||||
|
||||
@@ -31,7 +31,10 @@ public class SetHomeCommand extends SetPositionCommand {
|
||||
plugin.getManager().homes().createHome(setter, event.getName(), event.getPosition());
|
||||
} catch (ValidationException e) {
|
||||
e.dispatchHomeError(setter, false, plugin, event.getName());
|
||||
return;
|
||||
}
|
||||
plugin.getLocales().getLocale("set_home_success", event.getName())
|
||||
.ifPresent(setter::sendMessage);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -18,7 +18,10 @@ public class SetWarpCommand extends SetPositionCommand {
|
||||
plugin.getManager().warps().createWarp(event.getName(), event.getPosition());
|
||||
} catch (ValidationException e) {
|
||||
e.dispatchWarpError(setter, plugin, event.getName());
|
||||
return;
|
||||
}
|
||||
plugin.getLocales().getLocale("set_warp_success", event.getName())
|
||||
.ifPresent(setter::sendMessage);
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -31,7 +31,7 @@ public class TpaAllCommand extends InGameCommand {
|
||||
}
|
||||
|
||||
plugin.getManager().requests().sendTeleportAllRequest(executor);
|
||||
plugin.getLocales().getLocale("teleporting_all_players")
|
||||
plugin.getLocales().getLocale("tpaall_request_sent")
|
||||
.ifPresent(executor::sendMessage);
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import net.william278.huskhomes.HuskHomes;
|
||||
import net.william278.huskhomes.position.Warp;
|
||||
import net.william278.huskhomes.teleport.Teleportable;
|
||||
import net.william278.huskhomes.user.CommandUser;
|
||||
import net.william278.huskhomes.user.OnlineUser;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.List;
|
||||
@@ -15,6 +16,16 @@ public class WarpCommand extends SavedPositionCommand<Warp> {
|
||||
super("warp", List.of(), Warp.class, List.of(), plugin);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void execute(@NotNull CommandUser executor, @NotNull String[] args) {
|
||||
if (args.length == 0) {
|
||||
plugin.getCommand(WarpListCommand.class)
|
||||
.ifPresent(command -> command.showWarpList(executor, 1));
|
||||
return;
|
||||
}
|
||||
super.execute(executor, args);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void execute(@NotNull CommandUser executor, @NotNull Warp warp, @NotNull String[] args) {
|
||||
if (plugin.getSettings().isPermissionRestrictWarps()) {
|
||||
|
||||
@@ -15,7 +15,7 @@ import java.util.stream.Collectors;
|
||||
public class WarpListCommand extends ListCommand {
|
||||
|
||||
protected WarpListCommand(@NotNull HuskHomes plugin) {
|
||||
super("homelist", List.of("homes"), "[player] [page]", plugin);
|
||||
super("warplist", List.of("warps"), "[player] [page]", plugin);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -41,6 +41,9 @@ public class Locales {
|
||||
* @return An {@link Optional} containing the locale corresponding to the id, if it exists
|
||||
*/
|
||||
public Optional<String> getRawLocale(@NotNull String localeId) {
|
||||
if (!rawLocales.containsKey(localeId)) { // debug
|
||||
return Optional.of(localeId + " (missing locale)"); // debug
|
||||
} // debug
|
||||
return Optional.ofNullable(rawLocales.get(localeId)).map(StringEscapeUtils::unescapeJava);
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@ package net.william278.huskhomes.config;
|
||||
import net.william278.annotaml.YamlComment;
|
||||
import net.william278.annotaml.YamlFile;
|
||||
import net.william278.annotaml.YamlKey;
|
||||
import net.william278.huskhomes.command.Command;
|
||||
import net.william278.huskhomes.database.Database;
|
||||
import net.william278.huskhomes.hook.EconomyHook;
|
||||
import net.william278.huskhomes.hook.MapHook;
|
||||
@@ -490,8 +491,12 @@ public class Settings {
|
||||
return warpsOnMap;
|
||||
}
|
||||
|
||||
public List<String> getDisabledCommands() {
|
||||
return disabledCommands;
|
||||
public boolean isCommandDisabled(Command type) {
|
||||
return disabledCommands.stream().anyMatch(disabled -> {
|
||||
final String command = (disabled.startsWith("/") ? disabled.substring(1) : disabled);
|
||||
return command.equalsIgnoreCase(type.getName())
|
||||
|| type.getAliases().stream().anyMatch(alias -> alias.equalsIgnoreCase(command));
|
||||
});
|
||||
}
|
||||
|
||||
public boolean doBrigadierTabCompletion() {
|
||||
|
||||
@@ -63,28 +63,30 @@ public class EventListener {
|
||||
/**
|
||||
* Handle inbound cross-server teleports
|
||||
*
|
||||
* @param onlineUser user to handle the checks for
|
||||
* @param teleporter user to handle the checks for
|
||||
*/
|
||||
private void handleInboundTeleport(@NotNull OnlineUser onlineUser) {
|
||||
plugin.getDatabase().getCurrentTeleport(onlineUser).ifPresent(teleport -> {
|
||||
private void handleInboundTeleport(@NotNull OnlineUser teleporter) {
|
||||
plugin.getDatabase().getCurrentTeleport(teleporter).ifPresent(teleport -> {
|
||||
if (teleport.getType() == Teleport.Type.RESPAWN) {
|
||||
final Optional<Position> bedPosition = onlineUser.getBedSpawnPosition();
|
||||
final Optional<Position> bedPosition = teleporter.getBedSpawnPosition();
|
||||
if (bedPosition.isEmpty()) {
|
||||
plugin.getLocalCachedSpawn()
|
||||
.map(spawn -> spawn.getPosition(plugin.getServerName()))
|
||||
.ifPresent(position -> onlineUser.teleportLocally(position,
|
||||
.ifPresent(position -> teleporter.teleportLocally(position,
|
||||
plugin.getSettings().isAsynchronousTeleports()));
|
||||
onlineUser.sendTranslatableMessage("block.minecraft.spawn.not_valid");
|
||||
teleporter.sendTranslatableMessage("block.minecraft.spawn.not_valid");
|
||||
} else {
|
||||
onlineUser.teleportLocally(bedPosition.get(), plugin.getSettings().isAsynchronousTeleports());
|
||||
teleporter.teleportLocally(bedPosition.get(), plugin.getSettings().isAsynchronousTeleports());
|
||||
}
|
||||
plugin.getDatabase().setCurrentTeleport(onlineUser, null);
|
||||
plugin.getDatabase().setRespawnPosition(onlineUser, bedPosition.orElse(null));
|
||||
plugin.getDatabase().setCurrentTeleport(teleporter, null);
|
||||
plugin.getDatabase().setRespawnPosition(teleporter, bedPosition.orElse(null));
|
||||
return;
|
||||
}
|
||||
|
||||
onlineUser.teleportLocally((Position) teleport.getTarget(), plugin.getSettings().isAsynchronousTeleports());
|
||||
plugin.getDatabase().setCurrentTeleport(onlineUser, null);
|
||||
teleporter.teleportLocally((Position) teleport.getTarget(), plugin.getSettings().isAsynchronousTeleports());
|
||||
plugin.getDatabase().setCurrentTeleport(teleporter, null);
|
||||
plugin.getLocales().getLocale("teleporting_complete")
|
||||
.ifPresent(teleporter::sendMessage);
|
||||
});
|
||||
}
|
||||
|
||||
@@ -97,14 +99,6 @@ public class EventListener {
|
||||
// Remove this user's home cache
|
||||
plugin.getCache().getHomes().remove(onlineUser.getUsername());
|
||||
|
||||
// Update the cached player list using another online player if possible
|
||||
plugin.getOnlineUsers()
|
||||
.stream()
|
||||
.filter(onlinePlayer -> !onlinePlayer.equals(onlineUser))
|
||||
.findAny()
|
||||
.ifPresent(updater -> plugin.getCache().updatePlayerListCache(plugin, updater));
|
||||
|
||||
|
||||
// Set offline position
|
||||
plugin.getDatabase().setOfflinePosition(onlineUser, onlineUser.getPosition());
|
||||
}
|
||||
|
||||
@@ -163,6 +163,7 @@ public class RequestsManager {
|
||||
.payload(Payload.withTeleportRequest(request))
|
||||
.target(targetUser)
|
||||
.build().send(plugin.getMessenger(), requester);
|
||||
return;
|
||||
}
|
||||
throw new IllegalArgumentException("Player not found");
|
||||
}
|
||||
|
||||
@@ -62,7 +62,7 @@ public abstract class Broker {
|
||||
*
|
||||
* @throws RuntimeException if the broker fails to initialize
|
||||
*/
|
||||
public abstract void initialize() throws RuntimeException;
|
||||
public abstract void initialize() throws IllegalStateException;
|
||||
|
||||
/**
|
||||
* Send a message to the broker
|
||||
|
||||
@@ -32,7 +32,7 @@ public class PluginMessageBroker extends Broker {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initialize() throws RuntimeException {
|
||||
public void initialize() throws IllegalStateException {
|
||||
plugin.initializePluginChannels();
|
||||
}
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ public class RedisBroker extends PluginMessageBroker {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initialize() throws RuntimeException {
|
||||
public void initialize() throws IllegalStateException {
|
||||
super.initialize();
|
||||
|
||||
final String password = plugin.getSettings().getRedisPassword();
|
||||
@@ -51,7 +51,7 @@ public class RedisBroker extends PluginMessageBroker {
|
||||
final Message message = plugin.getGson().fromJson(encodedMessage, Message.class);
|
||||
plugin.getOnlineUsers().stream()
|
||||
.filter(online -> message.getTarget().equals(Message.TARGET_ALL)
|
||||
|| online.getUsername().equals(message.getTarget()))
|
||||
|| online.getUsername().equals(message.getTarget()))
|
||||
.forEach(receiver -> handle(receiver, message));
|
||||
}
|
||||
}, getSubChannelId());
|
||||
|
||||
@@ -13,10 +13,8 @@ public class Home extends SavedPosition {
|
||||
private final User owner;
|
||||
private boolean isPublic;
|
||||
|
||||
public Home(double x, double y, double z, float yaw, float pitch,
|
||||
@NotNull World world, @NotNull String server,
|
||||
@NotNull PositionMeta positionMeta, @NotNull UUID uuid,
|
||||
@NotNull User owner, boolean isPublic) {
|
||||
public Home(double x, double y, double z, float yaw, float pitch, @NotNull World world, @NotNull String server,
|
||||
@NotNull PositionMeta positionMeta, @NotNull UUID uuid, @NotNull User owner, boolean isPublic) {
|
||||
super(x, y, z, yaw, pitch, world, server, positionMeta, uuid);
|
||||
this.owner = owner;
|
||||
this.setPublic(isPublic);
|
||||
|
||||
@@ -19,6 +19,7 @@ public class Server {
|
||||
/**
|
||||
* Default server identifier
|
||||
*/
|
||||
@NotNull
|
||||
public static String getDefaultServerName() {
|
||||
try {
|
||||
final Path serverDirectory = Path.of(System.getProperty("user.dir"));
|
||||
|
||||
@@ -85,6 +85,8 @@ public class Teleport {
|
||||
fireEvent((event) -> {
|
||||
executeEconomyActions();
|
||||
teleporter.teleportLocally(localTarget.get().getPosition(), async);
|
||||
plugin.getLocales().getLocale("teleporting_complete")
|
||||
.ifPresent(teleporter::sendMessage);
|
||||
});
|
||||
return;
|
||||
}
|
||||
@@ -96,6 +98,8 @@ public class Teleport {
|
||||
.type(Message.Type.TELEPORT_TO_NETWORKED_POSITION)
|
||||
.target(username.name())
|
||||
.build().send(plugin.getMessenger(), executor);
|
||||
plugin.getLocales().getLocale("teleporting_complete")
|
||||
.ifPresent(teleporter::sendMessage);
|
||||
});
|
||||
return;
|
||||
}
|
||||
@@ -105,10 +109,24 @@ public class Teleport {
|
||||
|
||||
fireEvent((event) -> {
|
||||
executeEconomyActions();
|
||||
teleporter.teleportLocally((Position) target, async);
|
||||
|
||||
final Position target = (Position) this.target;
|
||||
if (plugin.getSettings().isCrossServer() && target.getServer().equals(plugin.getServerName())) {
|
||||
teleporter.teleportLocally(target, async);
|
||||
plugin.getLocales().getLocale("teleporting_complete")
|
||||
.ifPresent(teleporter::sendMessage);
|
||||
return;
|
||||
}
|
||||
|
||||
plugin.getDatabase().setCurrentTeleport(teleporter, this);
|
||||
plugin.getMessenger().changeServer(teleporter, target.getServer());
|
||||
});
|
||||
}
|
||||
|
||||
private void teleport(@NotNull OnlineUser teleporter, @NotNull Position target) {
|
||||
|
||||
}
|
||||
|
||||
@NotNull
|
||||
private Optional<OnlineUser> resolveLocalTeleporter() throws TeleportationException {
|
||||
if (this.teleporter instanceof Username username) {
|
||||
|
||||
@@ -16,6 +16,8 @@ public class TeleportationException extends IllegalArgumentException {
|
||||
ALREADY_WARMING_UP,
|
||||
ECONOMY_ACTION_FAILED,
|
||||
WARMUP_ALREADY_MOVING,
|
||||
WORLD_NOT_FOUND,
|
||||
ILLEGAL_TARGET_COORDINATES,
|
||||
CANNOT_TELEPORT_TO_SELF
|
||||
}
|
||||
|
||||
@@ -33,6 +35,12 @@ public class TeleportationException extends IllegalArgumentException {
|
||||
case CANNOT_TELEPORT_TO_SELF -> plugin.getLocales()
|
||||
.getLocale("error_teleport_request_self")
|
||||
.ifPresent(user::sendMessage);
|
||||
case ILLEGAL_TARGET_COORDINATES -> plugin.getLocales()
|
||||
.getLocale("error_illegal_target_coordinates")
|
||||
.ifPresent(user::sendMessage);
|
||||
case WORLD_NOT_FOUND -> plugin.getLocales()
|
||||
.getLocale("error_invalid_world")
|
||||
.ifPresent(user::sendMessage);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -142,7 +142,7 @@ public abstract class OnlineUser extends User implements Teleportable, CommandUs
|
||||
* @param location the {@link Location} to teleport the player to
|
||||
* @param asynchronous if the teleport should be asynchronous
|
||||
*/
|
||||
public abstract CompletableFuture<TeleportResult> teleportLocally(@NotNull Location location, boolean asynchronous);
|
||||
public abstract void teleportLocally(@NotNull Location location, boolean asynchronous);
|
||||
|
||||
/**
|
||||
* Send a plugin message to the user
|
||||
|
||||
@@ -12,7 +12,7 @@ teleporting_all_players: '[Teleporting all players to your position…](#00fb9a)
|
||||
teleporting_random_generation: '[Finding a safe random position to teleport you to…](#00fb9a)'
|
||||
tpa_request_sent: '[You sent a teleport request asking to teleport to](#00fb9a) [%1%](#00fb9a bold)[.](#00fb9a)'
|
||||
tpahere_request_sent: '[You sent a teleport request asking](#00fb9a) [%1%](#00fb9a bold) [to teleport to you.](#00fb9a)'
|
||||
tpaall_request_sent: '[You sent a teleport request asking](#00fb9a) [%1%](#00fb9a bold) [player(s) to teleport to you.](#00fb9a)'
|
||||
tpaall_request_sent: '[You sent a teleport request to every player asking them to teleport to you.](#00fb9a)'
|
||||
tpa_request_received: '[%1%](#00fb9a bold) [has requested to teleport to you.](#00fb9a)'
|
||||
tpahere_request_received: '[%1%](#00fb9a bold) [has requested that you teleport to them.](#00fb9a)'
|
||||
teleport_request_buttons: '[Options:](gray) [[✔ Accept…]](#00fb9a show_text=�fb9a&Accept teleport request\n&8Click to accept %1%''s request run_command=/huskhomes:tpaccept %1%) [[❌ Decline…]](#ff3300 show_text=&#ff3300&Decline teleport request\n&8Click to decline %1%''s request run_command=/huskhomes:tpdeny %1%)'
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Public Homes:](#00fb9a) [(%1%-%2% of](#00fb9a
|
||||
warp_list_page_title: '[Warps:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Command List](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Click to suggest command suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Редактирайте уарп'
|
||||
back_command_description: 'Върнете се на предишната си позиция или където сте умряли'
|
||||
homelist_command_description: 'Списък с Вашите домове'
|
||||
warplist_command_description: 'Вижте списък с уарпове'
|
||||
publichomelist_command_description: 'Вижте списъка с публични домове'
|
||||
publichome_command_description: 'Телепортирайте се до публичен дом'
|
||||
phomelist_command_description: 'Вижте списъка с публични домове'
|
||||
phome_command_description: 'Телепортирайте се до публичен дом'
|
||||
tp_command_description: 'Телепортирайте се до друг играч или локация'
|
||||
tphere_command_description: 'Телепортирайте друг играч до Вас'
|
||||
tpa_command_description: 'Заявете да се телепортирате до друг играч'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Öffentliche Homes:](#00fb9a) [(%1%-%2% von](
|
||||
warp_list_page_title: '[Warps:](#00fb9a) [(%1%-%2% von](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Befehlsliste](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Klicke, um den Befehl im Chat einzufügen command suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Ändere einen Warp'
|
||||
back_command_description: 'Kehre zu deiner letzten Position oder zu deinem Todespunkt zurück'
|
||||
homelist_command_description: 'Erhalte eine Liste deiner Homes'
|
||||
warplist_command_description: 'Siehe die Liste der Warps'
|
||||
publichomelist_command_description: 'Siehe die Liste der öffentlichen Homes'
|
||||
publichome_command_description: 'Teleportiere dich zu einem öffentlichen Home'
|
||||
phomelist_command_description: 'Siehe die Liste der öffentlichen Homes'
|
||||
phome_command_description: 'Teleportiere dich zu einem öffentlichen Home'
|
||||
tp_command_description: 'Teleportiere dich zu einem Spieler oder zu einer Position'
|
||||
tphere_command_description: 'Teleportiere einen Spieler zu dir'
|
||||
tpa_command_description: 'Frage einem Spieler sich zu ihm zu teleportieren'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Public Homes:](#00fb9a) [(%1%-%2% of](#00fb9a
|
||||
warp_list_page_title: '[Warps:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Command List](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Click to suggest command suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Edit a warp'
|
||||
back_command_description: 'Return to your previous position, or where you died'
|
||||
homelist_command_description: 'Get a list of your homes'
|
||||
warplist_command_description: 'View the list of warps'
|
||||
publichomelist_command_description: 'View the list of public homes'
|
||||
publichome_command_description: 'Teleport to a public home'
|
||||
phomelist_command_description: 'View the list of public homes'
|
||||
phome_command_description: 'Teleport to a public home'
|
||||
tp_command_description: 'Teleport to another player or location'
|
||||
tphere_command_description: 'Teleport another player to you'
|
||||
tpa_command_description: 'Request to teleport to another player'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Public Homes:](#00fb9a) [(%1%-%2% of](#00fb9a
|
||||
warp_list_page_title: '[Warps:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[GreenShield](#green bold) [| lista de comandos](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Clic para sugerir el comando suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Editar un warp'
|
||||
back_command_description: 'Volver a su posición anterior, o donde murió'
|
||||
homelist_command_description: 'Obtenga una lista de sus casas'
|
||||
warplist_command_description: 'Ver la lista de warps'
|
||||
publichomelist_command_description: 'Ver la lista de casas públicos'
|
||||
publichome_command_description: 'Teletransporte a una vivienda pública'
|
||||
phomelist_command_description: 'Ver la lista de casas públicos'
|
||||
phome_command_description: 'Teletransporte a una vivienda pública'
|
||||
tp_command_description: 'Teletransportarse a otro jugador o lugar'
|
||||
tphere_command_description: 'Teletransportar a otro jugador hacia ti'
|
||||
tpa_command_description: 'Solicitud de teletransporte a otro jugador'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Home pubbliche:](#00fb9a) [(%1%-%2% of](#00fb
|
||||
warp_list_page_title: '[Lista Warp:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Lista comandi](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Clicca per usare il comando suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Modifica un warp'
|
||||
back_command_description: 'Ritorna in una tua posizione precedente, o dove sei morto.'
|
||||
homelist_command_description: 'Ricevi una lista delle tue home'
|
||||
warplist_command_description: 'Ricevi una lista dei warp esistenti'
|
||||
publichomelist_command_description: 'Ricevi una lista delle home pubbliche'
|
||||
publichome_command_description: 'Teletrasportati in una home pubblica'
|
||||
phomelist_command_description: 'Ricevi una lista delle home pubbliche'
|
||||
phome_command_description: 'Teletrasportati in una home pubblica'
|
||||
tp_command_description: 'Teletrasportati nella posizione di un altro giocatore'
|
||||
tphere_command_description: 'Teletrasporta un altro giocatore da te'
|
||||
tpa_command_description: 'Richiedi ad un altro giocatore di teletrasportarti da lui'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Public Homes:](#00fb9a) [(%1%-%2% of](#00fb9a
|
||||
warp_list_page_title: '[Warps:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Command List](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Click to suggest command suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Edit a warp'
|
||||
back_command_description: 'Return to your previous position, or where you died'
|
||||
homelist_command_description: 'Get a list of your homes'
|
||||
warplist_command_description: 'View the list of warps'
|
||||
publichomelist_command_description: 'View the list of public homes'
|
||||
publichome_command_description: 'Teleport to a public home'
|
||||
phomelist_command_description: 'View the list of public homes'
|
||||
phome_command_description: 'Teleport to a public home'
|
||||
tp_command_description: 'Teleport to another player or location'
|
||||
tphere_command_description: 'Teleport another player to you'
|
||||
tpa_command_description: 'Request to teleport to another player'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Herkese Açık Evler:](#00fb9a) [(%1%-%2% of]
|
||||
warp_list_page_title: '[Warplar:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Komut Listesi](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Komut önermek için tıklayın suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Warpları düzenler'
|
||||
back_command_description: 'Önceki konumunuza veya öldüğünüz yere dönüdürür'
|
||||
homelist_command_description: 'Evlerinizin bir listesini alır'
|
||||
warplist_command_description: 'Warp listesini görünütler'
|
||||
publichomelist_command_description: 'Herkese açık evlerin listesini görüntüler'
|
||||
publichome_command_description: 'Herkese açık bir eve ışınlar'
|
||||
phomelist_command_description: 'Herkese açık evlerin listesini görüntüler'
|
||||
phome_command_description: 'Herkese açık bir eve ışınlar'
|
||||
tp_command_description: 'Başka bir oyuncuya veya konuma ışınlar'
|
||||
tphere_command_description: 'Başka bir oyuncuyu sana ışınlar'
|
||||
tpa_command_description: 'Başka bir oyuncuya ışınlanma isteği atar'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ Public Homes:](#00fb9a) [(%1%-%2% of](#00fb9a
|
||||
warp_list_page_title: '[Warps:](#00fb9a) [(%1%-%2% of](#00fb9a) [%3%](#00fb9a bold)[)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| Command List](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7Click to suggest command suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: 'Редагувати варп'
|
||||
back_command_description: 'Повернутися на попередню позицію, або місце смерті'
|
||||
homelist_command_description: 'Cписок моїх домівок'
|
||||
warplist_command_description: 'Cписок варпів'
|
||||
publichomelist_command_description: 'Cписок публічних домівок'
|
||||
publichome_command_description: 'Телепортуватися до публічної домівки'
|
||||
phomelist_command_description: 'Cписок публічних домівок'
|
||||
phome_command_description: 'Телепортуватися до публічної домівки'
|
||||
tp_command_description: 'Телепортуватися до іншого гравця чи на позицію'
|
||||
tphere_command_description: 'Телепортувати гравця до себе'
|
||||
tpa_command_description: 'Надіслати гравцеві запит на телепортацію'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ 公共家:](#00fb9a) [(%1%-%2% 共](#00fb9a)
|
||||
warp_list_page_title: '[地标:](#00fb9a) [(%1%-%2% 共](#00fb9a) [%3%](#00fb9a bold)[ 个)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| 指令列表](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7点击使用命令 suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: '编辑地标'
|
||||
back_command_description: '返回到上次传送或死亡的位置'
|
||||
homelist_command_description: '您的家列表'
|
||||
warplist_command_description: '地标列表'
|
||||
publichomelist_command_description: '公开家的列表'
|
||||
publichome_command_description: '传送至公开的家'
|
||||
phomelist_command_description: '公开家的列表'
|
||||
phome_command_description: '传送至公开的家'
|
||||
tp_command_description: '传送到玩家或坐标'
|
||||
tphere_command_description: '将该玩家传送至您这里'
|
||||
tpa_command_description: '请求传送到该玩家'
|
||||
|
||||
@@ -64,7 +64,7 @@ public_home_list_page_title: '[☀ 公共家:](#00fb9a) [(%1%-%2% 共](#00fb9a)
|
||||
warp_list_page_title: '[地標:](#00fb9a) [(%1%-%2% 共](#00fb9a) [%3%](#00fb9a bold)[ 個)](#00fb9a)\n'
|
||||
command_list_title: '[HuskHomes](#00fb9a bold) [| 指令列表](#00fb9a)\n'
|
||||
home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %3% run_command=/huskhomes:edithome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:publichome %2%)'
|
||||
public_home_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7☻ %3%\n&7ℹ %4% run_command=/huskhomes:phome %2%)'
|
||||
warp_list_item: '[[%1%]](show_text=�fb9a&%1%\n&7ℹ %2% run_command=/huskhomes:warp %1%)'
|
||||
command_list_item: '[/%1%](#00fb9a show_text=&7點擊使用指令 suggest_command=/%1%) [%2%](gray show_text=�fb9a&/%1%\n&7%3%)'
|
||||
list_item_divider: ' [•](gray) '
|
||||
@@ -155,8 +155,8 @@ editwarp_command_description: '編輯地標'
|
||||
back_command_description: '返回到上次傳送或死亡的位置'
|
||||
homelist_command_description: '您的家列表'
|
||||
warplist_command_description: '地標列表'
|
||||
publichomelist_command_description: '公開的家列表'
|
||||
publichome_command_description: '傳送至公開的家'
|
||||
phomelist_command_description: '公開的家列表'
|
||||
phome_command_description: '傳送至公開的家'
|
||||
tp_command_description: '傳送至玩家或坐標'
|
||||
tphere_command_description: '將該玩家傳送至您身邊'
|
||||
tpa_command_description: '請求傳送到該玩家身邊'
|
||||
|
||||
Reference in new issue
Block a user