Add missing forward-slash prefix to clickable commands. Fixes #401
This commit is contained in:
parent
c68d3e8e2f
commit
f5432cd227
@ -35,7 +35,7 @@ public class CmdDeinvite extends FCommand {
|
|||||||
for (String id : myFaction.getInvites()) {
|
for (String id : myFaction.getInvites()) {
|
||||||
FPlayer fp = FPlayers.getInstance().getById(id);
|
FPlayer fp = FPlayers.getInstance().getById(id);
|
||||||
String name = fp != null ? fp.getName() : id;
|
String name = fp != null ? fp.getName() : id;
|
||||||
msg.then(name + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_DEINVITE_CLICKTODEINVITE.format(name)).command(Conf.baseCommandAliases.get(0) + " deinvite " + name);
|
msg.then(name + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_DEINVITE_CLICKTODEINVITE.format(name)).command("/" + Conf.baseCommandAliases.get(0) + " deinvite " + name);
|
||||||
}
|
}
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
return;
|
return;
|
||||||
|
@ -35,7 +35,7 @@ public class CmdFWarp extends FCommand {
|
|||||||
FancyMessage msg = new FancyMessage(TL.COMMAND_FWARP_WARPS.toString()).color(ChatColor.GOLD);
|
FancyMessage msg = new FancyMessage(TL.COMMAND_FWARP_WARPS.toString()).color(ChatColor.GOLD);
|
||||||
Map<String, LazyLocation> warps = myFaction.getWarps();
|
Map<String, LazyLocation> warps = myFaction.getWarps();
|
||||||
for (String s : warps.keySet()) {
|
for (String s : warps.keySet()) {
|
||||||
msg.then(s + " ").tooltip(TL.COMMAND_FWARP_CLICKTOWARP.toString()).command(Conf.baseCommandAliases.get(0) + " warp " + s).color(ChatColor.WHITE);
|
msg.then(s + " ").tooltip(TL.COMMAND_FWARP_CLICKTOWARP.toString()).command("/" + Conf.baseCommandAliases.get(0) + " warp " + s).color(ChatColor.WHITE);
|
||||||
}
|
}
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
} else if (args.size() > 1) {
|
} else if (args.size() > 1) {
|
||||||
|
@ -50,7 +50,7 @@ public class CmdInvite extends FCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Tooltips, colors, and commands only apply to the string immediately before it.
|
// Tooltips, colors, and commands only apply to the string immediately before it.
|
||||||
FancyMessage message = new FancyMessage(fme.describeTo(you, true)).tooltip(TL.COMMAND_INVITE_CLICKTOJOIN.toString()).command(Conf.baseCommandAliases.get(0) + " join " + myFaction.getTag()).then(TL.COMMAND_INVITE_INVITEDYOU.toString()).color(ChatColor.YELLOW).tooltip(TL.COMMAND_INVITE_CLICKTOJOIN.toString()).command(Conf.baseCommandAliases.get(0) + " join " + myFaction.getTag()).then(myFaction.describeTo(you)).tooltip(TL.COMMAND_INVITE_CLICKTOJOIN.toString()).command(Conf.baseCommandAliases.get(0) + " join " + myFaction.getTag());
|
FancyMessage message = new FancyMessage(fme.describeTo(you, true)).tooltip(TL.COMMAND_INVITE_CLICKTOJOIN.toString()).command("/" + Conf.baseCommandAliases.get(0) + " join " + myFaction.getTag()).then(TL.COMMAND_INVITE_INVITEDYOU.toString()).color(ChatColor.YELLOW).tooltip(TL.COMMAND_INVITE_CLICKTOJOIN.toString()).command("/" + Conf.baseCommandAliases.get(0) + " join " + myFaction.getTag()).then(myFaction.describeTo(you)).tooltip(TL.COMMAND_INVITE_CLICKTOJOIN.toString()).command("/" + Conf.baseCommandAliases.get(0) + " join " + myFaction.getTag());
|
||||||
|
|
||||||
message.send(you.getPlayer());
|
message.send(you.getPlayer());
|
||||||
|
|
||||||
|
@ -37,12 +37,12 @@ public class CmdKick extends FCommand {
|
|||||||
FancyMessage msg = new FancyMessage(TL.COMMAND_KICK_CANDIDATES.toString()).color(ChatColor.GOLD);
|
FancyMessage msg = new FancyMessage(TL.COMMAND_KICK_CANDIDATES.toString()).color(ChatColor.GOLD);
|
||||||
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.NORMAL)) {
|
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.NORMAL)) {
|
||||||
String s = player.getName();
|
String s = player.getName();
|
||||||
msg.then(s + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_KICK_CLICKTOKICK.toString() + s).command(Conf.baseCommandAliases.get(0) + " kick " + s);
|
msg.then(s + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_KICK_CLICKTOKICK.toString() + s).command("/" + Conf.baseCommandAliases.get(0) + " kick " + s);
|
||||||
}
|
}
|
||||||
if (fme.getRole() == Role.ADMIN) {
|
if (fme.getRole() == Role.ADMIN) {
|
||||||
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.MODERATOR)) {
|
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.MODERATOR)) {
|
||||||
String s = player.getName();
|
String s = player.getName();
|
||||||
msg.then(s + " ").color(ChatColor.GRAY).tooltip(TL.COMMAND_KICK_CLICKTOKICK.toString() + s).command(Conf.baseCommandAliases.get(0) + " kick " + s);
|
msg.then(s + " ").color(ChatColor.GRAY).tooltip(TL.COMMAND_KICK_CLICKTOKICK.toString() + s).command("/" + Conf.baseCommandAliases.get(0) + " kick " + s);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -34,7 +34,7 @@ public class CmdMod extends FCommand {
|
|||||||
FancyMessage msg = new FancyMessage(TL.COMMAND_MOD_CANDIDATES.toString()).color(ChatColor.GOLD);
|
FancyMessage msg = new FancyMessage(TL.COMMAND_MOD_CANDIDATES.toString()).color(ChatColor.GOLD);
|
||||||
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.NORMAL)) {
|
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.NORMAL)) {
|
||||||
String s = player.getName();
|
String s = player.getName();
|
||||||
msg.then(s + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_MOD_CLICKTOPROMOTE.toString() + s).command(Conf.baseCommandAliases.get(0) + " mod " + s);
|
msg.then(s + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_MOD_CLICKTOPROMOTE.toString() + s).command("/" + Conf.baseCommandAliases.get(0) + " mod " + s);
|
||||||
}
|
}
|
||||||
|
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
|
@ -25,7 +25,7 @@ public class CmdShowInvites extends FCommand {
|
|||||||
for (String id : myFaction.getInvites()) {
|
for (String id : myFaction.getInvites()) {
|
||||||
FPlayer fp = FPlayers.getInstance().getById(id);
|
FPlayer fp = FPlayers.getInstance().getById(id);
|
||||||
String name = fp != null ? fp.getName() : id;
|
String name = fp != null ? fp.getName() : id;
|
||||||
msg.then(name + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_SHOWINVITES_CLICKTOREVOKE.format(name)).command(Conf.baseCommandAliases.get(0) + " deinvite " + name);
|
msg.then(name + " ").color(ChatColor.WHITE).tooltip(TL.COMMAND_SHOWINVITES_CLICKTOREVOKE.format(name)).command("/" + Conf.baseCommandAliases.get(0) + " deinvite " + name);
|
||||||
}
|
}
|
||||||
|
|
||||||
sendFancyMessage(msg);
|
sendFancyMessage(msg);
|
||||||
|
Loading…
Reference in New Issue
Block a user