Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(!(sender instanceof Player)) return false;
- Player player = (Player)sender;
- if(command.getName() == "teleport") {
- if(args.length == 1) {
- List<Player> matches = getServer().matchPlayer(args[0])
- if(matches.size()>1) {
- player.teleport(matches.get(0));
- } else {
- player.sendMessage(target.getName() + " could not be found.");
- }
- } else {
- player.sendMessage("Invalid command.");
- }
- return true;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement