≡
Products
▼
Support
▼
Company
▼
Forum
Ambiera Forum
Discussions, Help and Support.
Create a new account
,
Search
, or Login:
Create reply in
keycode events
Posted by:
(you are not logged in)
Enter the missing letter in: "Intern?tional"
(you are not logged in)
Text:
[quote][b][/b] wrote: @VP, if you want to emulate keypress then you should have asked that directly, I mean be specific to what you ask for. Yes it it totally possible to simulate or emulate keypress. just like @aiming_bullets mentioned, you can use the recently intorduced [b]ccbEmulateKey(keyCode, pressedDown)[/b] command. You can use it with either on proximity or every few seconds, in the execute javascript action. the usage is very simple and is just one line of code. let say you want to emulate "F" key and you want to emulate the state like when it is press down. then simply in your execute javascript action, either in every few seconds command or anywhere else put this code. [code] ccbEmulateKey(70, true)[/code] you can change the keycode "70" to the keycode that you want to use, for mouse keys keycodes are ( 1 = left mouse button, 2 = right mouse button, 4 = middle mouse button). you can find the javascript keycode here on this website if you don't know which one is for which key. [url]https://www.toptal.com/developers/keycode[/url] If you want to simulate key up event, then change the second parameter "true" to "false" and it will emulate if the key is left up. This will then work as if you pressed that key in your game, and if you game has any behavior like when a key is pressed F, and anything inside that behavior. it will be going to execute that behavior. Hope that helps. let me know if you need a .ccb example file. but that might not work with external things like re-shade and all, the other way around is to use system() command to simulate the keypress, that will actually work with third party integrations but can be quite complex and may require additional libraries or tools. Also, if you ever want to get your queries and answers in realtime then you can always text me on Discord. I remain active there most of the time.[/quote]
Possible Codes
Feature
Code
Link
[url] www.example.com [/url]
Bold
[b]bold text[/b]
Image
[img]http://www.example.com/image.jpg[/img]
Quote
[quote]quoted text[/quote]
Code
[code]source code[/code]
Emoticons
Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact