mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-27 01:05:38 +00:00
Merge branch 'master' of https://github.com/Obi2kanobi/TotalFreedomMod into Obi2kanobi-master
This commit is contained in:
commit
878075c898
@ -16,7 +16,7 @@ public class Command_stfu extends TFM_Command
|
|||||||
@Override
|
@Override
|
||||||
public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole)
|
public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole)
|
||||||
{
|
{
|
||||||
if (args.length != 1)
|
if (args.length == 0 || args.length > 2)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -98,6 +98,7 @@ public class Command_stfu extends TFM_Command
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
||||||
final Player player = getPlayer(args[0]);
|
final Player player = getPlayer(args[0]);
|
||||||
|
|
||||||
if (player == null)
|
if (player == null)
|
||||||
@ -115,10 +116,16 @@ public class Command_stfu extends TFM_Command
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
||||||
if (!TFM_AdminList.isSuperAdmin(player))
|
if (!TFM_AdminList.isSuperAdmin(player))
|
||||||
{
|
{
|
||||||
TFM_Util.adminAction(sender.getName(), "Muting " + player.getName(), true);
|
TFM_Util.adminAction(sender.getName(), "Muting " + player.getName(), true);
|
||||||
playerdata.setMuted(true);
|
playerdata.setMuted(true);
|
||||||
|
if (args.length == 2 && args[1].equalsIgnoreCase("-s"))
|
||||||
|
{
|
||||||
|
Command_smite.smite(player);
|
||||||
|
}
|
||||||
|
|
||||||
playerMsg("Muted " + player.getName());
|
playerMsg("Muted " + player.getName());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user