mirror of
https://github.com/TotalFreedomMC/TotalFreedomMod.git
synced 2025-08-05 12:02:53 +00:00
Added a telnet checker.
This commit is contained in:
parent
46494a2c87
commit
31e03d6348
1 changed files with 19 additions and 0 deletions
|
@ -405,6 +405,25 @@ public class TFM_AdminList
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static boolean isTelnetAdmin(CommandSender sender, boolean verifySuperadmin)
|
||||||
|
{
|
||||||
|
if (verifySuperadmin)
|
||||||
|
{
|
||||||
|
if (!isSuperAdmin(sender))
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
final TFM_Admin entry = getEntry((Player) sender);
|
||||||
|
if (entry != null)
|
||||||
|
{
|
||||||
|
return entry.isTelnetAdmin();
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
public static boolean isIdentityMatched(Player player)
|
public static boolean isIdentityMatched(Player player)
|
||||||
{
|
{
|
||||||
if (!isSuperAdmin(player))
|
if (!isSuperAdmin(player))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue