mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-27 09:15:38 +00:00
Now made qdeop require you to be op else it wont try to deop the player.
This commit is contained in:
parent
9a2dc52e87
commit
c490a3d62e
@ -33,12 +33,15 @@ public class Command_qdeop extends TFM_Command
|
|||||||
for (final Player player : server.getOnlinePlayers())
|
for (final Player player : server.getOnlinePlayers())
|
||||||
{
|
{
|
||||||
if (player.getName().toLowerCase().contains(targetName) || player.getDisplayName().toLowerCase().contains(targetName))
|
if (player.getName().toLowerCase().contains(targetName) || player.getDisplayName().toLowerCase().contains(targetName))
|
||||||
|
{
|
||||||
|
if (player.isOp())
|
||||||
{
|
{
|
||||||
matchedPlayerNames.add(player.getName());
|
matchedPlayerNames.add(player.getName());
|
||||||
player.setOp(false);
|
player.setOp(false);
|
||||||
player.sendMessage(TotalFreedomMod.YOU_ARE_NOT_OP);
|
player.sendMessage(TotalFreedomMod.YOU_ARE_NOT_OP);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!matchedPlayerNames.isEmpty())
|
if (!matchedPlayerNames.isEmpty())
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user