mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-09-27 22:27:29 +02:00
parent
9fe43fe75c
commit
c09ff50604
@ -19,7 +19,7 @@ import java.util.UUID;
|
||||
public class IslandExpelCommand extends CompositeCommand {
|
||||
|
||||
private static final String CANNOT_EXPEL = "commands.island.expel.cannot-expel";
|
||||
private static final String SUCCESS = "general.success";
|
||||
private static final String SUCCESS = "commands.island.expel.success";
|
||||
|
||||
private @Nullable User target;
|
||||
|
||||
@ -110,13 +110,13 @@ public class IslandExpelCommand extends CompositeCommand {
|
||||
island.getWorld().playSound(target.getLocation(), Sound.ENTITY_GENERIC_EXPLODE, 1F, 1F);
|
||||
if (getIslands().hasIsland(getWorld(), target)) {
|
||||
// Success
|
||||
user.sendMessage(SUCCESS);
|
||||
user.sendMessage(SUCCESS, TextVariables.NAME, target.getName());
|
||||
// Teleport home
|
||||
getIslands().homeTeleport(getWorld(), target.getPlayer());
|
||||
return true;
|
||||
} else if (getIslands().getSpawn(getWorld()).isPresent()){
|
||||
// Success
|
||||
user.sendMessage(SUCCESS);
|
||||
user.sendMessage(SUCCESS, TextVariables.NAME, target.getName());
|
||||
getIslands().spawnTeleport(getWorld(), target.getPlayer());
|
||||
return true;
|
||||
} else if (getIWM().getAddon(getWorld())
|
||||
@ -126,7 +126,7 @@ public class IslandExpelCommand extends CompositeCommand {
|
||||
.orElse(false)
|
||||
&& target.performCommand(this.getTopLabel() + " create")) {
|
||||
getAddon().logWarning("Expel: " + target.getName() + " had no island, so one was created");
|
||||
user.sendMessage(SUCCESS);
|
||||
user.sendMessage(SUCCESS, TextVariables.NAME, target.getName());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -536,6 +536,7 @@ commands:
|
||||
cannot-ban-member: "&cYou cannot expel a team member!"
|
||||
not-on-island: "&cThat player is not on your island!"
|
||||
player-expelled-you: "&b[name]&c expelled you from the island!"
|
||||
success: "&aYou expelled &b[name] &afrom the island."
|
||||
|
||||
ranks:
|
||||
owner: "Owner"
|
||||
|
@ -197,6 +197,7 @@ commands:
|
||||
description: "sélectionne la langue"
|
||||
expel:
|
||||
parameters: "<joueur>"
|
||||
success: "&aVous avez expulsé &b[name] &ade votre île."
|
||||
|
||||
ranks:
|
||||
owner: "Propriétaire"
|
||||
|
Loading…
Reference in New Issue
Block a user