mirror of
https://github.com/ClassiCube/MCGalaxy.git
synced 2025-10-04 11:08:38 -04:00
Make /whonick and /whonick bot consistent
And change message when no PlayerClick for /botinfo
This commit is contained in:
parent
d52d08b4b2
commit
bc6a3fe166
@ -211,8 +211,9 @@ namespace MCGalaxy.Commands.Bots {
|
|||||||
if (botName.Length == 0) {
|
if (botName.Length == 0) {
|
||||||
if (!p.Supports(CpeExt.PlayerClick)) {
|
if (!p.Supports(CpeExt.PlayerClick)) {
|
||||||
p.Message("Your client does not support clicking on entities.");
|
p.Message("Your client does not support clicking on entities.");
|
||||||
p.Message("You must type either %T/botinfo [name] %Sor");
|
p.Message("You must type %T/botinfo [name] %Sto see info.");
|
||||||
p.Message("%T/whonick bot [nickname] %Sto see bot info.");
|
p.Message("To help find the name of a nicknamed bot, try");
|
||||||
|
p.Message("%T/whonick bot [nickname]");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
p.checkingBotInfo = true;
|
p.checkingBotInfo = true;
|
||||||
|
@ -37,9 +37,8 @@ namespace MCGalaxy.Commands.Info {
|
|||||||
|
|
||||||
static void ForPlayer(Player p, string message) {
|
static void ForPlayer(Player p, string message) {
|
||||||
Player nick = FindNick(p, message);
|
Player nick = FindNick(p, message);
|
||||||
|
|
||||||
if (nick == null) return;
|
if (nick == null) return;
|
||||||
p.Message("This player's real username is " + nick.name);
|
p.Message("The player nicknamed {0} %Sis named {1}", nick.DisplayName, nick.name);
|
||||||
}
|
}
|
||||||
static Player FindNick(Player p, string nick) {
|
static Player FindNick(Player p, string nick) {
|
||||||
nick = Colors.Strip(nick);
|
nick = Colors.Strip(nick);
|
||||||
@ -50,9 +49,9 @@ namespace MCGalaxy.Commands.Info {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void ForBot(Player p, string message) {
|
static void ForBot(Player p, string message) {
|
||||||
PlayerBot nick = FindBotNick(p, message);
|
PlayerBot bot = FindBotNick(p, message);
|
||||||
if (nick == null) return;
|
if (bot == null) return;
|
||||||
nick.DisplayInfo(p);
|
p.Message("The bot nicknamed {0} %Sis named {1}", bot.DisplayName, bot.name);
|
||||||
}
|
}
|
||||||
static PlayerBot FindBotNick(Player p, string nick) {
|
static PlayerBot FindBotNick(Player p, string nick) {
|
||||||
nick = Colors.Strip(nick);
|
nick = Colors.Strip(nick);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user