Jump to content

Why access denied on redirectPlayer?


Hiding

Recommended Posts

Hello, I'm wondering why am I still getting this acces denied @ redirectPlayer? 

I added the ACL rigths to the redirectPlayer

function handleClick()
	if not toggle then return end
	
	if isMouseInPosition(sX, sY, width, height) then 
		triggerServerEvent("server", getLocalPlayer())
		outputChatBox("Successfully execute this chatbox, but still got error access denied..")
	end
end
addEventHandler("onClientClick", getRootElement(), handleClick)

addEvent ("server", true)
addEventHandler ("server", getRootElement(), 
	function()
		redirectPlayer (source, ip, port)
	end
)

<acl name="Admin">
	<right name="function.redirectPlayer" access="true"></right>

Image from web acl: https://files.fm/u/7utn3dfyx?ak=6fc15

Link to comment
  • Moderators
17 hours ago, Hiding said:

Hello, I'm wondering why am I still getting this acces denied @ redirectPlayer? 

While the admin acl does have this privilege, that doesn't mean that the resource is a part of it.

Instead of giving admin a right that it already has.
Add the resource to the admin group.

 

<group name="Admin">
  
<!-- <<< --> <object name="resource.FILL_IN_THE_RESOURCE_FOLDER_NAME"></object>

</group>

 

Note:

<group> and <acl> are two different tags.

<group name="Admin">
	<object name=""></object> <!-- user.<accountName> or resource.<resourceName> -->
	<acl name="Admin"></acl> <!-- ACL rights linked to this group -->
</group>

 

<acl name="Admin">
	<right name="" access="false"></right>
</acl>

 

 

  • Like 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...