Jump to content

مساعدة في كود


Recommended Posts

السلام عليكم ابي مساعدة في كود

الحين مابي اللوحة ذي تفتح الا لو انا في الاسل في جروب معين

---client
bindKey ( "F6" , "down" , function() 
        guiSetVisible ( main, not guiGetVisible ( main ) ) 
        showCursor ( guiGetVisible ( main ) ) 
playSound("open.wav")
 end) 
----------------
--server
addEvent("open", true) 
addEventHandler("open", root, 
function ( ) 
  local accName = getAccountName ( getPlayerAccount ( source ) )
   if isObjectInACLGroup ("user."..accName, aclGetGroup ( "VIP" ) ) then 

end
end
)

وشكرا مقدما  :x:x

Link to comment

تفضل

-- # Client 1

bindKey ( "F6" , "down" , function() 
triggerServerEvent("ifThisAdmin", localPlayer) 
end
)
-- # Server
addEvent ( "ifThisAdmin", true)
addEventHandler( "ifThisAdmin",root,
	function (  )
			local acc = getPlayerAccount ( source )
			if acc and not isGuestAccount ( acc ) then
				if isObjectInACLGroup ( "user."..getAccountName ( acc ), aclGetGroup ( "VIP" ) ) then
					triggerClientEvent ( source, "thisAdminOpenPanel", resourceRoot )
				else
				outputChatBox("يجب ان تكون فيب لتفتح اللوحة",source,125,125,125,true)
				end
			end
		end
)
-- # Client 2
addEvent ( "thisAdminOpenPanel", true )
addEventHandler ( "thisAdminOpenPanel", root,
function ()
guiSetVisible( main, not guiGetVisible( main ) )  
showCursor( guiGetVisible( main ) ) 
playSound("open.wav")
end
 )

 

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