mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2025-02-13 12:38:58 +00:00
24 lines
768 B
Java
24 lines
768 B
Java
package com.earth2me.essentials.commands;
|
|
|
|
import com.earth2me.essentials.CommandSource;
|
|
import com.earth2me.essentials.utils.FormatUtil;
|
|
import org.bukkit.Server;
|
|
|
|
import static com.earth2me.essentials.I18n.tl;
|
|
|
|
// This command can be used to echo messages to the users screen, mostly useless but also an #EasterEgg
|
|
public class Commandping extends EssentialsCommand {
|
|
public Commandping() {
|
|
super("ping");
|
|
}
|
|
|
|
@Override
|
|
public void run(final Server server, final CommandSource sender, final String commandLabel, final String[] args) throws Exception {
|
|
if (args.length < 1) {
|
|
|
|
sender.sendMessage(tl("pong"));
|
|
} else {
|
|
sender.sendMessage(FormatUtil.replaceFormat(getFinalArg(args, 0)));
|
|
}
|
|
}
|
|
}
|