AclGroupList

From Multi Theft Auto: Wiki
Revision as of 18:46, 12 July 2014 by MarioKart (talk | contribs) (OOP syntax added)
Jump to navigation Jump to search

This function returns a table of all the ACL groups.

Syntax

table aclGroupList ()

OOP Syntax Help! I don't understand this!

Method: ACLGroup.list(...)


Returns

Returns a table of all the ACL groups if successful, returns an empty table if no ACL groups exist. false/nil can be returned if this function fails for some other reason.

Example

This example shows, how to output all ACL Group Names by showAclGroups

function showGroups(player)
	local groups = {}
	groups = aclGroupList()
	for i,v in ipairs(groups) do
		local name = aclGroupGetName(v)
		outputChatBox(tostring(name),player)
	end
end
addCommandHandler("showAclGroups",showGroups)

See Also