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 


I2CETLogger weird error

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

Joined: 29 Jan 2022
Posts: 4

PostPosted: Sat Jan 29, 2022 2:41 am    Post subject: I2CETLogger weird error Reply with quote

hello
i was updating theycallmetim13 Metro Exodus table, i updated offsets, aobscans and so on.

now before i continue to explain you should know that theycallmetim13 is using his i2ctable helpers so that .CEA files can be used as external script files.

and after i updated everything i tried the scripts individually and they work great, now when i use theycallmetim13's I2CETableCEA.autoAssembleFile command in a script it also works, everything gets injected correctly and everything is fine. however, whenever i try to disable a script, the I2CETLogger throws this error.

Code:


I2CETLogger::CETlog - ERROR: autoAssembleFile:
Syntax error in file: "CoordHook.CEA"
Error in line 83 (dealloc(memCoordHook)) :This instruction can't be compiled



CoordHook here as an example.

Code:


{$STRICT}

define(address, PhysX3_x64.dll+118364)
define(bytes, F3 0F 10 40 10)

////
//// ------------------------------ ENABLE ------------------------------
[ENABLE]
// aobScanModule(aobCoordHook, PhysX3_x64.dll, F30F10500CF30F1155xxF30F104010)
i2aobScanModule(aobCoordHook, PhysX3_x64.dll, F30F10500CF30F1155xxF30F104010)
define(injCoordHook, aobCoordHook+A)
// assert(injCoordHook, bytes)
i2assert(injCoordHook, bytes)
registerSymbol(injCoordHook)

alloc(memCoordHook, 0x400, injCoordHook)

label(ptrCoordHook)
registerSymbol(ptrCoordHook)

label(n_code)
label(o_code)
label(exit)
label(return)

memCoordHook:
   ptrCoordHook:
      dq 0
   align 10 CC
   n_code:
       mov [ptrCoordHook],rax
   o_code:
      movss xmm0,[rax+10]
   exit:
      jmp return


////
//// ---------- Injection Point ----------
injCoordHook:
   jmp n_code
   return:

{$lua}
I2CETeleporter.CoordPointerSymbol = 'ptrCoordHook'
I2CETeleporter.Xoffset = 0x10
I2CETeleporter.Yoffset = 0x14
I2CETeleporter.Zoffset = 0x18
-- I2CETeleporter.WaypointPointerSymbol = ''
-- I2CETeleporter.WayXoffset = 0x
-- I2CETeleporter.WayYoffset = 0x
-- I2CETeleporter.WayZoffset = 0x
-- I2CETeleporter.WayYaddOnRead = 0
{$asm}

////
//// ------------------------------ DISABLE ------------------------------
[DISABLE]
////
//// ---------- Injection Point ----------
injCoordHook:
   db bytes

unregisterSymbol(injCoordHook)

unregisterSymbol(ptrCoordHook)

dealloc(memCoordHook)



and i am executing it by

Code:


{$lua}
if syntaxcheck then return end
I2CETableCEA.autoAssembleFile('CoordHook.CEA', memrec)
------------------------------ ENABLE ------------------------------
[ENABLE]
------------------------------ DISABLE ------------------------------
[DISABLE]



now i have no idea why thats happening, i mean dealloc is a standard instruction, i made sure that i am using assembly and not lua.
so i have no idea whats going on.

i am using cheat engine 7.4 by the way.

i tried looking up this error here and on the fearlessrevolution site and couldn't get the answer i'm looking for.

hopefully someone can help.

i'd like to apologize for any forum etiquette mistakes i made as this is my first post here ever.

and i'd like to thank you in advance for your help.


Last edited by NightOwlScripter on Sat Jan 29, 2022 12:58 pm; edited 1 time in total
Back to top
View user's profile Send private message
LeFiXER
Grandmaster Cheater Supreme
Reputation: 20

Joined: 02 Sep 2011
Posts: 1055
Location: 0x90

PostPosted: Sat Jan 29, 2022 8:47 am    Post subject: Reply with quote

Firstly, please format your code correctly. You should also remove unnecessary comments for legibility especially when the formatting is poor. I apologise if you take offence to this, but someone had to tell you.

NightOwlScripter wrote:
hello
i was updating theycallmetim13 Metro Exodus table, i updated offsets, aobscans and so on.

now before i continue to explain you should know that theycallmetim13 is using his i2ctable helpers so that .CEA files can be used as external script files.

and after i updated everything i tried the scripts individually and they work great, now when i use theycallmetim13's I2CETableCEA.autoAssembleFile command in a script it also works, everything gets injected correctly and everything is fine. however, whenever i try to disable a script, the I2CETLogger throws this error.

Code:

I2CETLogger::CETlog - ERROR: autoAssembleFile:
Syntax error in file: "CoordHook.CEA"
Error in line 83 (dealloc(memCoordHook)) :This instruction can't be compiled



CoordHook here as an example.

Code:

{$STRICT}
define(address, PhysX3_x64.dll+118364)
define(bytes, F3 0F 10 40 10)

[ENABLE]

// aobScanModule(aobCoordHook, PhysX3_x64.dll, F30F10500CF30F1155xxF30F104010)
i2aobScanModule(aobCoordHook, PhysX3_x64.dll, F30F10500CF30F1155xxF30F104010)
define(injCoordHook, aobCoordHook+A)
// assert(injCoordHook, bytes)
i2assert(injCoordHook, bytes)
registerSymbol(injCoordHook)

alloc(memCoordHook, 0x400, injCoordHook)

label(ptrCoordHook)
registerSymbol(ptrCoordHook)

label(n_code)
label(o_code)
label(exit)
label(return)

memCoordHook:

ptrCoordHook:
  dq 0

align 10 CC
n_code:
  mov [ptrCoordHook],rax

o_code:
  movss xmm0,[rax+10]

exit:
  jmp return


injCoordHook:
  jmp n_code

return:

{$lua}
I2CETeleporter.CoordPointerSymbol = 'ptrCoordHook'
I2CETeleporter.Xoffset = 0x10
I2CETeleporter.Yoffset = 0x14
I2CETeleporter.Zoffset = 0x18
-- I2CETeleporter.WaypointPointerSymbol = ''
-- I2CETeleporter.WayXoffset = 0x
-- I2CETeleporter.WayYoffset = 0x
-- I2CETeleporter.WayZoffset = 0x
-- I2CETeleporter.WayYaddOnRead = 0

{$asm}
[DISABLE]

injCoordHook:
  db bytes

unregisterSymbol(injCoordHook)
unregisterSymbol(ptrCoordHook)

dealloc(memCoordHook)



Secondly, unregisterSymbol is the Lua function, AutoAssembler is all lowercase: unregistersymbol.
See: CELua.txt/unregisterSymbol

NightOwlScripter wrote:

and i am executing it by

Code:

{$lua}
if syntaxcheck then return end
I2CETableCEA.autoAssembleFile('CoordHook.CEA', memrec)   
[ENABLE]

[DISABLE]


This:
Code:

I2CETableCEA.autoAssembleFile('CoordHook.CEA', memrec)   

is outside of the enable section.

NightOwlScripter wrote:

now i have no idea why thats happening, i mean dealloc is a standard instruction, i made sure that i am using assembly and not lua.
so i have no idea whats going on.

i am using cheat engine 7.4 by the way.

i tried looking up this error here and on the fearlessrevolution site and couldn't get the answer i'm looking for.

hopefully someone can help.

i'd like to apologize for any forum etiquette mistakes i made as this is my first post here ever.

and i'd like to thank you in advance for your help.


It could very well be that you have misplaced the code as previously mentioned. See how that goes.
Back to top
View user's profile Send private message
NightOwlScripter
How do I cheat?
Reputation: 0

Joined: 29 Jan 2022
Posts: 4

PostPosted: Sat Jan 29, 2022 10:19 am    Post subject: Reply with quote

First of all i thank you LeFiXER for replying and no offense taken.

i knew my post looked horrible and i knew i'd make mistakes, i thank you again for reorganizing my post as you didn't have to and i learned (hopefully) how to do it right.

now as for unregisterSymbol being lua and not assembly, i know that but theycallmetim13 i believe coded his table templates, helpers and his cheat table lua scripts templates in a way in which both work (uppercase and lowercase "S"), i tried the scripts individually and they work fine (no problems in enabling or disabling)

what i mean by trying them individually is: when i make a script in cheat engine with the code i posted it works fine (it enables and disables, unregisters symbols and deallocs memory correctly), now when i use lua to "call" a .CEA file which have the same code, it enables without a problem but when i try to disable it for some reason it thinks that dealloc() is a wrong syntax and throws an error.

as for this being outside the enable section:

Code:
I2CETableCEA.autoAssembleFile('CoordHook.CEA', memrec)


i didn't change that from theycallmetim13's table, i just copied it over, and it is injecting so there is no problem there. the problem is disabling the script which then an error gets thrown.

by the way i should have mentioned before that in this cheat table there is a lua cheat table script which i also got from theycallmetim13's templates and also in the table i added his table helpers which i got also from his post on the fearlessrevolution here:


fearlessrevolution com/viewtopic.php?t=9881


hopefully my post is better this time and i apologize if it wasn't. Razz
Back to top
View user's profile Send private message
ParkourPenguin
I post too much
Reputation: 140

Joined: 06 Jul 2014
Posts: 4289

PostPosted: Sat Jan 29, 2022 12:29 pm    Post subject: Reply with quote

LeFiXER wrote:
Secondly, unregisterSymbol is the Lua function, AutoAssembler is all lowercase: unregistersymbol
Most identifiers in AA code are case-insensitive. e.g. this code assembles fine:
Code:
[enAbLe]
GLObaLalLOC(Foo,4096)
LABel(bar)
ReGistErSYMboL(Bar)

foO+100:
bar:
[DisABlE]
UNRegIstERsYMboL(BaR)
Symbols used in label(...) declarations are the only place where I've seen case matter. (I haven't looked much, however)

Your picture doesn't match the code you wrote. It says the line "dealloc(memDeltaMulHook)" is a problem, but that doesn't exist in the code you posted.

And don't disable BBCode in your posts. Code tags make code more readable.

_________________
I don't know where I'm going, but I'll figure it out when I get there.
Back to top
View user's profile Send private message
NightOwlScripter
How do I cheat?
Reputation: 0

Joined: 29 Jan 2022
Posts: 4

PostPosted: Sat Jan 29, 2022 12:55 pm    Post subject: Reply with quote

oh i apologize i posted another error from another script but from the same table.
here is a pic of the error related to the code before.

i deleted the one in my original post to avoid confusion.



I2CETLogger Error.jpg
 Description:
 Filesize:  27.64 KB
 Viewed:  1652 Time(s)

I2CETLogger Error.jpg




Last edited by NightOwlScripter on Sat Jan 29, 2022 1:48 pm; edited 1 time in total
Back to top
View user's profile Send private message
LeFiXER
Grandmaster Cheater Supreme
Reputation: 20

Joined: 02 Sep 2011
Posts: 1055
Location: 0x90

PostPosted: Sat Jan 29, 2022 1:00 pm    Post subject: Reply with quote

ParkourPenguin wrote:
]Most identifiers in AA code are case-insensitive. e.g. this code assembles fine:
Code:
[enAbLe]
GLObaLalLOC(Foo,4096)
LABel(bar)
ReGistErSYMboL(Bar)

foO+100:
bar:
[DisABlE]
UNRegIstERsYMboL(BaR)
Symbols used in label(...) declarations are the only place where I've seen case matter. (I haven't looked much, however)


To be honest, I've never tried case-insensitivity before; however, that is good to know. I assumed it was the same for Auto Assembler because Lua is case-sensitive. Nevertheless, thank you for sharing your knowledge. Smile
Back to top
View user's profile Send private message
NightOwlScripter
How do I cheat?
Reputation: 0

Joined: 29 Jan 2022
Posts: 4

PostPosted: Sat Jan 29, 2022 8:55 pm    Post subject: Reply with quote

Hello

So an update to my problem, i installed an older version of cheat engine (7.2 to be exact) and i got no problems whatsoever.

everything enables and disables correctly.

so i guess then maybe something happened in the new updates of cheat engine that is causing the error.

thanks to all who replied and please if someone has a suggestion on how to fix this problem for cheat engine 7.4 it would be greatly appreciated if you shared it.
Back to top
View user's profile Send private message
TheyCallMeTim13
Wiki Contributor
Reputation: 50

Joined: 24 Feb 2017
Posts: 976
Location: Pluto

PostPosted: Sat Jan 29, 2022 9:41 pm    Post subject: Reply with quote

Yeah it's something in the autoAssembleCheck function, technically the script could disable but when the syntax is checked it fails since that function doesn't take any disableInfo like the autoAssmeble function. I have reported it on github and it's already been fixed for the next release of CE. So yeah you can't use CE 7.3 or 7.4 with that module.
_________________
Back to top
View user's profile Send private message Visit poster's website
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