mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2026-06-04 10:36:54 +00:00
checks if a player is OP before opping them
response to https://github.com/AtlasMediaGroup/TotalFreedomMod/pull/1/files/338fc81b7f1874a79265ec46b6f308a6523f656d#r533706741
This commit is contained in:
@@ -18,8 +18,11 @@ public class Command_opall extends FreedomCommand
|
|||||||
|
|
||||||
for (Player player : server.getOnlinePlayers())
|
for (Player player : server.getOnlinePlayers())
|
||||||
{
|
{
|
||||||
player.setOp(true);
|
if (player.isOp())
|
||||||
player.sendMessage(FreedomCommand.YOU_ARE_OP);
|
{
|
||||||
|
player.setOp(true);
|
||||||
|
player.sendMessage(FreedomCommand.YOU_ARE_OP);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user