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 


Lua Variable to Auto Assembler script

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
martiney1337
How do I cheat?
Reputation: 0

Joined: 03 Dec 2017
Posts: 4

PostPosted: Sun Dec 03, 2017 10:37 am    Post subject: Lua Variable to Auto Assembler script Reply with quote

Hey there, i hope you can help me out as im stuck for quite a while now.

I have a auto assembler script like this:

Code:
..
user:
  db 1
healthGen:
  db E8 03

mycode:
 mov rax,[rax+34]
..


And now instead of running
Code:
db E8 03
I want "E8 03" to be the value which i type in getProperty(CETrainer_CEEdit1,"Text")

Im running the AA script using the autoassemble(script) command from lua.


Hope you can help out, thanks.
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 457

Joined: 09 May 2003
Posts: 25262
Location: The netherlands

PostPosted: Sun Dec 03, 2017 1:39 pm    Post subject: Reply with quote

{$lua}
return string.format("dw %x", tonumber(getProperty(CETrainer_CEEdit1,"Text")))
{$asm}

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
martiney1337
How do I cheat?
Reputation: 0

Joined: 03 Dec 2017
Posts: 4

PostPosted: Sun Dec 03, 2017 5:06 pm    Post subject: Reply with quote

Ok thank you, that works great aslong as im doing it while Cheat Engine is running.

As soon as i compile a .exe and close everything and start up the trainer, it wont work anymore (speed etc. still works fine, so its attached to the correct process).

How can i read the fields then?


EDIT: I am actually not getting any outputs anymore when trying

showMessage(getProperty(CETrainer_CEEdit1,"Text")), only when i write it all from scratch, but as soon as i save it and restart everything, it wont work anymore.

EDIT EDIT: NVM, i was stupid, all the trainer changes made me change the form name, it works perfectly, thank you.
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 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