Fescobalt

Opens map when I use CEF. Help pls

Recommended Posts

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 by Fescobalt
update some aspetcs

Share this post


Link to post
Share on other sites
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 by CMHDev
mp.gui.cursor.show(true, true); //Disables the players controls and shows the cursor

Share this post


Link to post
Share on other sites

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.