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 


luacode in 7.6 not working

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
xFLMXWolf
Newbie cheater
Reputation: 0

Joined: 13 Jul 2013
Posts: 14

PostPosted: Mon Mar 31, 2025 4:02 pm    Post subject: luacode in 7.6 not working Reply with quote

The following code works fine in CE 7.5 but in 7.6 it does not print anything.

Anyone know how to fix?

Code:

[ENABLE]

aobscanmodule(INJECT,game.exe,89 48 3C 8B E5 5D C2 04 00 CC CC CC CC CC CC CC CC CC CC 55)
alloc(newmem,$1000)

label(code)
label(return)

registersymbol(INJECT)

newmem:
{$luacode tst=ecx}
print('test')
end
{$asm}

_________________
713242141
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Mon Mar 31, 2025 5:10 pm    Post subject: Reply with quote

remove the end after print

and how do you execute newmem?

_________________
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
xFLMXWolf
Newbie cheater
Reputation: 0

Joined: 13 Jul 2013
Posts: 14

PostPosted: Mon Mar 31, 2025 5:35 pm    Post subject: Reply with quote

Code:

INJECT:
  jmp newmem
return:

_________________
713242141
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Tue Apr 01, 2025 2:52 am    Post subject: Reply with quote

In memoryview->view make sure that kernelmode symbols is disabled

also do a help->check for updates.
Apparently some people still get older versions when they download CE

_________________
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
xFLMXWolf
Newbie cheater
Reputation: 0

Joined: 13 Jul 2013
Posts: 14

PostPosted: Tue Apr 01, 2025 3:58 am    Post subject: Reply with quote

Kernalmode symbols is disabled and help > check for new version says "you are up to date. The latest version is 7.6"
_________________
713242141
Back to top
View user's profile Send private message
xFLMXWolf
Newbie cheater
Reputation: 0

Joined: 13 Jul 2013
Posts: 14

PostPosted: Wed Apr 02, 2025 3:38 am    Post subject: Reply with quote

Looks like it's running into the attached error.

Seems to work if I include:
Code:

loadlibrary(luaclient-x86_64.dll)
luacall(openLuaServer('CELUASERVER'))

CELUA_ServerName:
db 'CELUASERVER',0


So maybe there's a problem with the dll-less luapipe?

Not sure if anyone else is having this issue.

_________________
713242141
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Wed Apr 02, 2025 7:08 pm    Post subject: Reply with quote

is the target an uwp app?
_________________
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
xFLMXWolf
Newbie cheater
Reputation: 0

Joined: 13 Jul 2013
Posts: 14

PostPosted: Thu Apr 03, 2025 2:52 am    Post subject: Reply with quote

No, I've tested a few different apps, including notepad, WinDirStat, and even the CE tutorial. They all behave the same way.
_________________
713242141
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 470

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

PostPosted: Thu Apr 03, 2025 5:41 am    Post subject: Reply with quote

are you using the 64-bit CE client ?
can you check with help->check for new version that you are on the latest version. Sometimes the download will provide an earlier version of 7.6 instead of the latest.

the following script works fine for the 64-bit tutorial: (step 2 button click)
Code:

[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
alloc(newmem,2048,"Tutorial-x86_64.exe"+45D7D)
label(returnhere)
label(originalcode)
label(exit)

newmem: //this is allocated memory, you have read,write,execute access
//place your code here
{$luacode decval=edx}
print("this works")
decval=0
{$asm}

originalcode:
sub [rbx+000007F8],edx

exit:
jmp returnhere

"Tutorial-x86_64.exe"+45D7D:
jmp newmem
nop
returnhere:
 
 
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
dealloc(newmem)
"Tutorial-x86_64.exe"+45D7D:
db 29 93 F8 07 00 00
//sub [rbx+000007F8],edx


can you try that one ?

_________________
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
xFLMXWolf
Newbie cheater
Reputation: 0

Joined: 13 Jul 2013
Posts: 14

PostPosted: Fri Apr 04, 2025 3:38 am    Post subject: Reply with quote

I think I've figured it out.

Definitely using the latest version and the x86_64-SSE4-AVX2 exe

Your code worked fine, but it was still not working for me when I used AOB Injection.

It seems to be because the AOB Injection template adds a description to the top of the script:
Code:

{ Game   : Tutorial-x86_64.exe
  Version:
  Date   : 2025-04-04
  Author : xflmxwolf

  This script does blah blah blah
}


If I remove this description then it works fine, but if I leave it in then it doesn't. I assume the braces are interfering with the function of {$luacode} somehow.

_________________
713242141
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