I've been working on making a samsite for my admin base.. I tried everything searching searching fixed the code still i'm getting this error :
[2016-04-03 10:04:47] WARNING: WTA-basesamsite\ad_base_s.lua:26: Bad argument @ 'isObjectInACLGroup' [Expected acl-group at argument 2, got boolean]
[2016-04-03 10:04:53] WARNING: WTA-basesamsite\ad_base_s.lua:60: Bad argument @ 'isObjectInACLGroup' [Expected acl-group at argument 2, got boolean]
My isObjectInACLGroup part Code:
function hit ( pla, dim )
if getElementType ( pla ) == "player" then
local vehicle = getPedOccupiedVehicle ( pla )
if vehicle or not vehicle then
local account = getPlayerAccount ( pla )
if account then
local accountname = getAccountName ( account )
if isObjectInACLGroup ( "user." .. tostring(accountname), aclGetGroup ( "Admin" ) ) then
else
if isObjectInACLGroup ( "user." .. tostring(accountname), aclGetGroup ( "Super Moderator" ) ) then
else
if isObjectInACLGroup ( "user." .. tostring(accountname), aclGetGroup ( "Moderator" ) ) then
outputChatBox ( "[WTA]Welcome Sir, "..getPlayerName(pla).."!", pla, 0, 150, 0 )
else
setElementData ( pla, "inRestrictedArea", "true" )
triggerClientEvent ( pla, "destroyTrepassor", g_root, pla )
outputChatBox ( "***WTA Headquarters Restricted Area!***", pla, 255, 0, 0 )
outputChatBox ( "* "..getPlayerName(pla)..".has entered The WTA Headquarters Restricted Area.Enjoy The Fireworks Bro!", g_root, 70, 251, 45 )
end
end
end
end
end
end
end
addEventHandler ( "onColShapeHit", g_base_col, hit )