- Documentation
- Server functions
- updateResourceACLRequest
Function
updateResourceACLRequest
Grants or revokes a right a resource asked for. It creates the ACL list resource.name, adds it to the Resources group and sets the right in it. With byWho it writes to the server log who did it.
Syntax
bool updateResourceACLRequest(resource theResource, string rightName, bool access [, string byWho])Arguments
theResourceresource- The resource.
rightNamestring- The right name, e.g.
"function.kickPlayer". accessbooltrue= grant,false= revoke.byWhostring, optional- Who changed it (for the log).
Returns
true on success.
Example
updateResourceACLRequest(getResourceFromName("admin"), "function.kickPlayer", true, "konsola")
aclSave()
See also
getResourceACLRequestsReturns the rights a resource asks for inmeta.xml(aclrequestsin<info>). Each entry is a table with the right name and its state.aclSetRightSets a right on a list. Right names:"command.name","function.name","resource.name"or your own ("general.name"). The fourth argument sets an expiry.