-
Notifications
You must be signed in to change notification settings - Fork 17
Ranks
IvanCraft623 edited this page Jun 16, 2022
·
1 revision
Class that manage ranks
$rankmanager = $ranksystem->getRankManager();
Class that contains the data of a rank
Gets a rank through its name.
$rank = $rankmanager->getRank("Admin");
This rank is the one that players will have by default in case they have not been assigned any.
$defaultrank = $rankmanager->getDefault();
You can set the default rank:
$rankmanager->setDefault($rank);
$rankmanager->create("YouTuber", // Rank name
[
"prefix" => "§8[§cYou§fTuber§8] ", // NameTag prefix
"nameColor" => "§e" // NameTag name color
],
[
"prefix" => "§8[§cYou§fTuber§8] ", // Chat prefix
"nameColor" => "§e" // Chat name color
"chatFormat" => "§8: §7" // Chat format
],
["example.perm"] // permissions
);
You can provide the rank name or the object.
$rankmanager->delete("YouTuber");
// or
$rankmanager->delete($rank);