The_HydroX Posted July 13, 2017 Posted July 13, 2017 (edited) Hey guys, ragemp has cef, so lets use it! ( useable @ 0.2 ) (it's my Code, so my leader has nothing to say :P) 1. // // [ The_HydroX | Nick | 2017 ] // let devWindow = { browser: mp.browsers.new('package://[YOUR CLIENT PACKAGE]/index.html'), keyCode: 0x7B, // F12 windowOpen: false } I define a new object, named devWindow. the browser window will be spawned when we call mp.browsers.new('package://devLog/index.html') 2. I want to change the visibility of the Frame / cef / whatEver. // keyDown mp.keys.bind(devWindow.keyCode, true, function(){ if (!devWindow.windowOpen) { devWindow.browser.execute('showWindow();'); devWindow.windowOpen = !devWindow.windowOpen; } else { devWindow.browser.execute('hideWindow();'); devWindow.windowOpen = !devWindow.windowOpen; } }); i do this with keyBinding. 3. you can execute functions they are defined @ the index.html like: function showWindow() { $('.devWindow').show(); } function hideWindow() { $('.devWindow').hide(); } yes, its very simple. sry for my englisch ^^ GreetZ from Dresden The_HydroX Edited July 13, 2017 by The_HydroX available @ 0.2 - sry 3
Jim0 Posted July 13, 2017 Posted July 13, 2017 Please can you specify the files, where i have to put this code ?
The_HydroX Posted July 13, 2017 Author Posted July 13, 2017 (edited) yes, of course. or you use this : [Offline] Ps. for you GreetZ The_HydroX Edited January 3, 2019 by The_HydroX
ragempdev Posted July 13, 2017 Posted July 13, 2017 I'd suggest you try to use "browser.active = toggle".
The_HydroX Posted July 13, 2017 Author Posted July 13, 2017 vor 1 Stunde schrieb ragempdev: I'd suggest you try to use "browser.active = toggle". oh. will try it asap
notorious_nils Posted June 9, 2018 Posted June 9, 2018 i am about to change from gtmp to rage its a simple tutorial which shows basics pretty good greatings back from Dresden
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