Unable to evaluate offsets with symbols?

Anything Cheat Engine related, bugs, suggestions, helping others, etc..
Post Reply
IcyPurpose99
Expert Cheater
Expert Cheater
Posts: 470
Joined: Fri Mar 03, 2017 6:04 pm
Reputation: 16

Unable to evaluate offsets with symbols?

Post by IcyPurpose99 »

[curArmor+8]*8+08
Source: [Link]
Offsets can be either numbers, or you could end up using a symbol with registered offsets. However, using the latter works first hand, but if you did a restart, and tried it, it would not update. To update it, you would have to open the pointer and hit OK, for it to update.

What gives? Any fixes, advice?

User avatar
koderkrazy
Expert Cheater
Expert Cheater
Posts: 254
Joined: Sun Jun 17, 2018 2:14 pm
Reputation: 190

Re: Unable to evaluate offsets with symbols?

Post by koderkrazy »

Marcus101RR wrote:
Fri Aug 17, 2018 6:47 pm
[curArmor+8]*8+08
Source: [Link]
Offsets can be either numbers, or you could end up using a symbol with registered offsets. However, using the latter works first hand, but if you did a restart, and tried it, it would not update. To update it, you would have to open the pointer and hit OK, for it to update.

What gives? Any fixes, advice?
Unfortunately offsets are parsed only when you press OK on pointer edit box. Rest of the time they remain same(calculated values) in memrec object
There is reinterpret() method on memrec but it's of no use in this context because it picks up only parsed values. If they had exposed offset objects in cheat scripts then we could've set unparsed=true and called reinterpret()...

So, in your code, even if curOffset changes , without game restart, the 'Set Skill' pointer won't change.

I think only workaround is to have one pointer(base+offset) for each cheat, and calculate them in code. I mean there are only 6 cheats there so have 6 calculated pointers for each cheat.

User avatar
koderkrazy
Expert Cheater
Expert Cheater
Posts: 254
Joined: Sun Jun 17, 2018 2:14 pm
Reputation: 190

Re: Unable to evaluate offsets with symbols?

Post by koderkrazy »

God news! I've created a solution for the problem.
Get the attached table and try it on any 32-bit process. Read the table extras for more details.
Update the offset and hit refresh script it updates the calculated pointer :mrgreen:

Add the LUA script from 'Refresh Pointers' in your main cheat script so that when users open your table they run the script.

Here is the update script for ready reference :
Image
This updates pointers in entire table. If you want to update children of particular cheat like 'Current Armor' then iterate over memrec instead of getAddresList.
Attachments
UpdateCalculatedOffsets-solution.CT
Demo table
(5.55 KiB) Downloaded 107 times

Eric
Hall of Famer
Hall of Famer
Posts: 174
Joined: Thu Mar 02, 2017 11:01 pm
Reputation: 90

Re: Unable to evaluate offsets with symbols?

Post by Eric »

you can also rightclick offsets with symbols and choose the way they are updated

Post Reply

Who is online

Users browsing this forum: No registered users