Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Keypress Static Address Question

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
MikeNoey
Advanced Cheater
Reputation: 0

Joined: 08 Jun 2018
Posts: 64

PostPosted: Tue May 21, 2019 11:07 pm    Post subject: Keypress Static Address Question Reply with quote

Hi guys. I've found the address for keystates in a game I'm writing an automation script for. This address was all the way down at the bottom of the CE results and in my experience those addresses are unique to each PC.

For example if I used the address for pressing "W key" and write a script for that it works fine on the computer I found that address on but if I try running that script on another computer it doesn't work. It's a green address so I cant pointer scan for it. If someone could tell me how to get around this I'd appreciate it.

edit: It uses Dinput8.dll. I did some research and it looks like it gets scan codes directly from the hardware which is why it doesn't work on a different computer. Still wondering if there is a solution to this though.


Or if there is a way to bypass pressing a key all together. For example pressing Space makes my character Jump. Is there a way to make my character jump without pressing a key. If someone can tell me what I should be googling to achieve that I'd appreciate it too
Back to top
View user's profile Send private message
TheyCallMeTim13
Wiki Contributor
Reputation: 51

Joined: 24 Feb 2017
Posts: 976
Location: Pluto

PostPosted: Wed May 22, 2019 5:04 am    Post subject: Reply with quote

Not sure what you're doing, but it might be better to write a Lua script for that. Then you can use "doKeyPress".
https://wiki.cheatengine.org/index.php?title=Lua:doKeyPress
https://wiki.cheatengine.org/index.php?title=Lua#Input_devices

_________________
Back to top
View user's profile Send private message Visit poster's website
MikeNoey
Advanced Cheater
Reputation: 0

Joined: 08 Jun 2018
Posts: 64

PostPosted: Wed May 22, 2019 9:07 am    Post subject: Reply with quote

Hey Tim. No I've tried doKeyPress and KeyDown etc. None of those work with this game.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites