mirror of
https://github.com/TotalFreedomMC/TotalFreedomMod.git
synced 2025-07-31 09:52:47 +00:00
Merge pull request #3 from AtlasMediaGroup/Elmon11-patch-2
checks if a player is OP before opping them
This commit is contained in:
commit
495c91f5bb
1 changed files with 5 additions and 2 deletions
|
@ -18,8 +18,11 @@ public class Command_opall extends FreedomCommand
|
|||
|
||||
for (Player player : server.getOnlinePlayers())
|
||||
{
|
||||
player.setOp(true);
|
||||
player.sendMessage(FreedomCommand.YOU_ARE_OP);
|
||||
if (!player.isOp())
|
||||
{
|
||||
player.setOp(true);
|
||||
player.sendMessage(FreedomCommand.YOU_ARE_OP);
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue