mirror of
https://github.com/essentials/Essentials.git
synced 2025-09-28 15:19:06 +02:00
28 lines
698 B
Java
28 lines
698 B
Java
package com.earth2me.essentials.xmpp;
|
|
|
|
import com.earth2me.essentials.User;
|
|
import com.earth2me.essentials.commands.EssentialsCommand;
|
|
import com.earth2me.essentials.commands.NotEnoughArgumentsException;
|
|
import org.bukkit.Server;
|
|
|
|
|
|
public class Commandsetxmpp extends EssentialsCommand
|
|
{
|
|
public Commandsetxmpp()
|
|
{
|
|
super("setxmpp");
|
|
}
|
|
|
|
@Override
|
|
protected void run(final Server server, final User user, final String commandLabel, final String[] args) throws NotEnoughArgumentsException
|
|
{
|
|
if (args.length < 1)
|
|
{
|
|
throw new NotEnoughArgumentsException();
|
|
}
|
|
|
|
EssentialsXMPP.getInstance().setAddress(user.getBase(), args[0]);
|
|
user.sendMessage("XMPP address set to " + args[0]);
|
|
}
|
|
}
|