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 


[ASM] Call lua on write?

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
pox911
Grandmaster Cheater
Reputation: 28

Joined: 29 Nov 2008
Posts: 918

PostPosted: Thu May 02, 2013 10:54 pm    Post subject: [ASM] Call lua on write? Reply with quote

I'm toying with a basic idea, i want to call a lua each time this one section of code writes. It doesnt seem to want to do that though. It will execute the lua when i activate the script but thats it. I currently have it setup where i replaced code with a jump to new memory where it has the original code plus a lua call. Is this not the correct way to do it or am i lover looking something?
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

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

PostPosted: Fri May 03, 2013 12:58 am    Post subject: Reply with quote

How do you call the lua code?
_________________
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
pox911
Grandmaster Cheater
Reputation: 28

Joined: 29 Nov 2008
Posts: 918

PostPosted: Fri May 03, 2013 7:41 am    Post subject: Reply with quote

here is an example of what ime doing

[enable]
alloc()
aob()

symboljunk here

Aob:
start:
jmp newmem
return:

newmem:
luacall()
original code
jump return

[disable]
etc
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 471

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

PostPosted: Fri May 03, 2013 8:00 am    Post subject: Reply with quote

that won't work no.
luacall is a preprocessor, not an assemble command

what you could try is run a timer that checks if a certain byte is set by your assembler code, and if so, execute some code in lua and then set that byte to 0.
And let your assembler code set that byte and wait till it's 0

_________________
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
pox911
Grandmaster Cheater
Reputation: 28

Joined: 29 Nov 2008
Posts: 918

PostPosted: Fri May 03, 2013 11:20 am    Post subject: Reply with quote

an if changed would probalby work better. Basicly what i was doing was i got the code for borderlands 2 that would write every time i picked up a weapon. A timer that just checks if the inventory count has changed would do the same effect of what i was trying to do in asm Razz.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking 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