Scripting/Squirrel/Functions/Player.Admin
This wiki is using an old backup from 2020
Some information may be old/missing
This function is just a variable. There are no built-in commands for admins, like they used to be in earlier versions.
Syntax
Player.Admin;
Player.Admin = toggle;
Arguments
- bool toggle Set Admin true/false
Example
function onPlayerCommand(cmd, args, player) {
if (cmd == "heal") {
if(player.Admin) {
player.Health = 100;
}
}
}
Notes
Call onPlayerCommand was used in this example.