Read desc

Added new command LibsDisguises
Tells the command user who made the plugin.
And if the player who called the command is called by the attractive
name 'libraryaddict' then it also tells that curious user the version of
the plugin.
Worried about it being a exploit? Why? I know of all bugs/exploits and
could just try them all out if I didn't know the version. If there was a
exploit in the first place anyways.
The command is there to give credit to me, and so I can urge servers to
update.

Against this command?
I see you don't like plugin developers getting credit for their work
that you use for free.
Please move back to disguisecraft.
This commit is contained in:
libraryaddict 2014-04-07 00:15:47 +12:00
parent 2879834a7e
commit ce75918001
3 changed files with 22 additions and 0 deletions

View File

@ -4,6 +4,7 @@ version: ${project.version}
author: libraryaddict author: libraryaddict
depend: [ProtocolLib] depend: [ProtocolLib]
commands: commands:
libsdisguises:
disguise: disguise:
aliases: [d, dis] aliases: [d, dis]
disguiseentity: disguiseentity:

View File

@ -108,6 +108,7 @@ public class LibsDisguises extends JavaPlugin {
getCommand("disguiseradius").setExecutor(new DisguiseRadiusCommand(getConfig().getInt("DisguiseRadiusMax"))); getCommand("disguiseradius").setExecutor(new DisguiseRadiusCommand(getConfig().getInt("DisguiseRadiusMax")));
getCommand("undisguiseradius").setExecutor(new UndisguiseRadiusCommand(getConfig().getInt("UndisguiseRadiusMax"))); getCommand("undisguiseradius").setExecutor(new UndisguiseRadiusCommand(getConfig().getInt("UndisguiseRadiusMax")));
getCommand("disguisehelp").setExecutor(new DisguiseHelpCommand()); getCommand("disguisehelp").setExecutor(new DisguiseHelpCommand());
getCommand("libsdisguises").setExecutor(new LibsDisguisesCommand());
registerValues(); registerValues();
} }

View File

@ -0,0 +1,20 @@
package me.libraryaddict.disguise.commands;
import org.bukkit.Bukkit;
import org.bukkit.ChatColor;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
public class LibsDisguisesCommand implements CommandExecutor {
@Override
public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) {
sender.sendMessage(ChatColor.GOLD + "Lib's Disguises was created by libraryaddict");
if (sender.getName().equals("libraryaddict")) {
sender.sendMessage(ChatColor.GRAY + "The server is running version "
+ Bukkit.getPluginManager().getPlugin("LibsDisguises").getDescription().getVersion());
}
return true;
}
}