MahdaviScape [562]
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Commands for mods.

4 posters

Go down

Commands for mods. Empty Commands for mods.

Post  Specialist78 Sun Feb 13, 2011 7:21 am

Well, recently I got promoted and I've realized that moderators kind of have no commands,
except ::mute and ::emote....
So I was thinking, maybe add ::jail (::unjail) and ::teleto?

Specialist78
Moderator
Moderator

Posts : 10
Join date : 2011-02-05

Back to top Go down

Commands for mods. Empty Re: Commands for mods.

Post  pea2nuts Sun Feb 13, 2011 1:10 pm

Code:
if(cmd[0].equals("::teletome")) {
                if (player.getRights() <= 1)
      return;
      Player other = World.getInstance().getPlayerList().get(World.getInstance().getIdFromName(command.substring((command.indexOf(" ") + 1))));
        if (other != null) {
        other.tele(player.getLocation().getX(), player.getLocation().getY(), player.getLocation().getZ());
      }
  }
  if(cmd[0].equals("::teleto")) {
                if (player.getRights() <= 1)
      return;
      Player other = World.getInstance().getPlayerList().get(World.getInstance().getIdFromName(command.substring((command.indexOf(" ") + 1))));
        if (other != null) {
        player.tele(other.getLocation().getX(), other.getLocation().getY(), other.getLocation().getZ());
      }
  }

pea2nuts

Posts : 17
Join date : 2011-02-12

Back to top Go down

Commands for mods. Empty Re: Commands for mods.

Post  Mahdavi Sun Feb 13, 2011 5:25 pm

pea2nuts wrote:
Code:
if(cmd[0].equals("::teletome")) {
                if (player.getRights() <= 1)
      return;
      Player other = World.getInstance().getPlayerList().get(World.getInstance().getIdFromName(command.substring((command.indexOf(" ") + 1))));
        if (other != null) {
        other.tele(player.getLocation().getX(), player.getLocation().getY(), player.getLocation().getZ());
      }
  }
  if(cmd[0].equals("::teleto")) {
                if (player.getRights() <= 1)
      return;
      Player other = World.getInstance().getPlayerList().get(World.getInstance().getIdFromName(command.substring((command.indexOf(" ") + 1))));
        if (other != null) {
        player.tele(other.getLocation().getX(), other.getLocation().getY(), other.getLocation().getZ());
      }
  }

This code would not work, I already fixed this issue.

Mahdavi
Owner
Owner

Posts : 20
Join date : 2011-01-04
Age : 28

https://mahdaviscape.forumotion.com

Back to top Go down

Commands for mods. Empty Re: Commands for mods.

Post  Kruxifix Fri Feb 18, 2011 9:37 pm

[CLOSED]
Kruxifix
Kruxifix
Owner
Owner

Posts : 32
Join date : 2011-01-11
Location : MahdaviScape

http://www.mahdaviscape.forumotion.com

Back to top Go down

Commands for mods. Empty Re: Commands for mods.

Post  Sponsored content


Sponsored content


Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum