Jump to content

ajuda aviso infinito no console


Recommended Posts

Estou recebendo aviso no console direito de uma função que eu fiz quando o player entra no hit de uma col
 

AVISOS QUE FLOODA O CONSOLE.


         WARNING: Bad argument @ 'getAccountName' [Expected account at argument 1, got boolean]
         ERROR: attempt to concatenate a boolean value

--[[Aviso]] -- isObjectInACLGroup("user."..getAccountName(getPlayerAccount(player)),aclGetGroup("Admin"))

function chePlayergr(player,x,y,z,baseName)
	if isElement(player) then
		cheTimer = setTimer(function(player,baseName)
			if not((getElementData(player,"Group") == getGroupNameFromBaseName(baseName)) or isObjectInACLGroup("user."..getAccountName(getPlayerAccount(player)),aclGetGroup("Admin"))) then 
				if isTimer(cheTimer) then
					killTimer(cheTimer)
				end
				setElementPosition(player,x,y,z+1)
        	end
		end,2000,0,player,baseName)
	end
end

 

Edited by felipebaidoloko
Link to comment
1 hour ago, felipebaidoloko said:

Estou recebendo aviso no console direito de uma função que eu fiz quando o player entra no hit de uma col
 

AVISOS QUE FLOODA O CONSOLE.


         WARNING: Bad argument @ 'getAccountName' [Expected account at argument 1, got boolean]
         ERROR: attempt to concatenate a boolean value


--[[Aviso]] -- isObjectInACLGroup("user."..getAccountName(getPlayerAccount(player)),aclGetGroup("Admin"))

function chePlayergr(player,x,y,z,baseName)
	if isElement(player) then
		cheTimer = setTimer(function(player,baseName)
			if not((getElementData(player,"Group") == getGroupNameFromBaseName(baseName)) or isObjectInACLGroup("user."..getAccountName(getPlayerAccount(player)),aclGetGroup("Admin"))) then 
				if isTimer(cheTimer) then
					killTimer(cheTimer)
				end
				setElementPosition(player,x,y,z+1)
        	end
		end,2000,0,player,baseName)
	end
end

 

function chePlayergr(player,x,y,z,baseName)
	if isElement(player) and getElementType(player) == "player" then
		cheTimer = setTimer(function(player,baseName)
			if not((getElementData(player,"Group") == getGroupNameFromBaseName(baseName)) or isObjectInACLGroup("user."..getAccountName(getPlayerAccount(player)),aclGetGroup("Admin"))) then 
				setElementPosition(player,x,y,z+1)
        	end
		end,2000, 1,player,baseName)
	end
end

EDIT: Não testei!

  • Thanks 1
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...