vConsole.java 594 B

12345678910111213141516171819
  1. public class vConsole {
  2. public boolean onConsoleCommand(String[] split) {
  3. String args = etc.combineSplit(1, split, "");
  4. //Return true if you don't want the server command to be parsed by the server.
  5. String server = Colors.LightGreen + "[Server]" + Colors.DarkPurple;
  6. if(split[0].equalsIgnoreCase("stop")){
  7. vChat.gmsg(server + "Rebooting the server");
  8. return false;
  9. }
  10. //Make say nicer
  11. if(split[0].equalsIgnoreCase("say"))
  12. {
  13. //Send out the message
  14. vChat.gmsg(server + args);
  15. return true;
  16. }
  17. return false;
  18. }
  19. }