Jump to content

CEF and ACL


Skream

Recommended Posts

I'm trying to run my login in lua but all I get is a black screen so I wonder to know if I have to do anything on ACL mod

just in case this is my LUA code

-- rio-login config
loginConfig = {
	['url'] = 'http://mta/rio-login/html/login.html'
}

screenW, screenH = guiGetScreenSize()
cefBrowser = guiGetBrowser(guiCreateBrowser(0, 0, screenW, screenH, true, true))

addEventHandler('onClientBrowserCreated', cefBrowser,
	function()
		loadBrowserURL(cefBrowser, loginConfig['url'])
		showCursor(true)
		fadeCamera(false)
	end
)

addEventHandler('rio_onClientLogin', root,
	function()
		setBrowserRenderingPaused(cefBrowser, true)
		guiSetVisible(cefBrowser, false)
	end
)

addEvent('rio_onClientAttemptLogin', true)
addEventHandler('rio_onClientAttemptLogin', root,
	function(username, password)
		triggerServerEvent('tryLogin' root, username, password)
	end 
)

addEvent('rio_onClientAttemptRegister', true)
addEventHandler('rio_onClientAttemptRegister', root,
	function(username, email, password)
		triggerServerEvent('tryRegister' root, username, email, password)
	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...