Add Bungee command.
This commit is contained in:
parent
a3dbdae3df
commit
3d45f52518
@ -65,7 +65,7 @@ public class BungeeCord
|
|||||||
/**
|
/**
|
||||||
* Current version.
|
* Current version.
|
||||||
*/
|
*/
|
||||||
public String version = (getClass().getPackage().getImplementationVersion() == null) ? "unknown" : getClass().getPackage().getImplementationVersion();
|
public static String version = (BungeeCord.class.getPackage().getImplementationVersion() == null) ? "unknown" : BungeeCord.class.getPackage().getImplementationVersion();
|
||||||
/**
|
/**
|
||||||
* Fully qualified connections.
|
* Fully qualified connections.
|
||||||
*/
|
*/
|
||||||
@ -96,6 +96,7 @@ public class BungeeCord
|
|||||||
commandMap.put("ip", new CommandIP());
|
commandMap.put("ip", new CommandIP());
|
||||||
commandMap.put("alert", new CommandAlert());
|
commandMap.put("alert", new CommandAlert());
|
||||||
commandMap.put("motd", new CommandMotd());
|
commandMap.put("motd", new CommandMotd());
|
||||||
|
commandMap.put("bungee", new CommandBungee());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
15
src/main/java/net/md_5/bungee/command/CommandBungee.java
Normal file
15
src/main/java/net/md_5/bungee/command/CommandBungee.java
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
package net.md_5.bungee.command;
|
||||||
|
|
||||||
|
import net.md_5.bungee.BungeeCord;
|
||||||
|
import net.md_5.bungee.ChatColor;
|
||||||
|
|
||||||
|
public class CommandBungee extends Command
|
||||||
|
{
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void execute(CommandSender sender, String[] args)
|
||||||
|
{
|
||||||
|
sender.sendMessage(ChatColor.BLUE + "This server is running BungeeCord version " + BungeeCord.version + " by md_5");
|
||||||
|
sender.sendMessage(ChatColor.BLUE + "Your current permission level is " + getPermission(sender).name());
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user