Fescobalt Posted December 9, 2018 Posted December 9, 2018 (edited) Hi! I have a little problem. When I input text inside CEF and press P key on input then open map. Example: role Play (on letter P my map was oppened and I will be unfocussed on browser. How can I block any game world interaction excepting interaction with CEF? I tried use mp.game.controls.disableAllControlActions - but it's didnt working :(( let sceneryCamera = mp.cameras.new('default', new mp.Vector3(-485, 1095.75, 323.85), new mp.Vector3(0, 0, 0), 40); sceneryCamera.pointAtCoord(402.8664, -996.4108, -98.5); //Changes the rotation of the camera to point towards a location sceneryCamera.setActive(true); mp.game.cam.renderScriptCams(true, false, 0, true, false); mp.game.cam.setCamEffect(1); let browser = mp.browsers.new("package://ui/auth/index.html"); mp.gui.cursor.show(false, true); mp.gui.cursor.position = [500, 500]; mp.gui.chat.show(false); mp.game.controls.disableAllControlActions(32); mp.game.controls.enableAllControlActions(28); mp.game.controls.enableAllControlActions(29); Edited December 9, 2018 by Fescobalt update some aspetcs
CMHDev Posted December 9, 2018 Posted December 9, 2018 (edited) let sceneryCamera = mp.cameras.new('default', new mp.Vector3(-485, 1095.75, 323.85), new mp.Vector3(0, 0, 0), 40); sceneryCamera.pointAtCoord(402.8664, -996.4108, -98.5); //Changes the rotation of the camera to point towards a location sceneryCamera.setActive(true); mp.game.cam.renderScriptCams(true, false, 0, true, false); mp.game.cam.setCamEffect(1); let browser = mp.browsers.new("package://ui/auth/index.html"); mp.gui.cursor.show(true); Edited December 9, 2018 by CMHDev mp.gui.cursor.show(true, true); //Disables the players controls and shows the cursor
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now