View previous topic :: View next topic |
Author |
Message |
gir489 Grandmaster Cheater
Reputation: 14
Joined: 03 Jan 2012 Posts: 840 Location: Maryland, United States
|
Posted: Sun Apr 09, 2023 9:21 am Post subject: AobScan Template header needs modernization |
|
|
When creating an AoBScan code injection script, the header for it will auto populate with some wanting information. Mostly version and author.
Author is taken directly from the Window's user and there is no room for configuration to instead manually supply a replacement, I have to replace my real name with my internet handle each time, it's very annoying and tedious.
Version is always blank, when you could use something reliable like the compile Timestamp variable located in the PE header. I sometimes use the EXE signing date, but only a few companies sign their EXEs, so it's not reliable, whereas the compile sign timestamp is required by Windows PE header.
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Sun Apr 09, 2023 4:09 pm Post subject: |
|
|
Have you looked at using custom templates?
|
|
Back to top |
|
 |
gir489 Grandmaster Cheater
Reputation: 14
Joined: 03 Jan 2012 Posts: 840 Location: Maryland, United States
|
Posted: Tue Apr 11, 2023 11:30 am Post subject: |
|
|
++METHOS wrote: | Have you looked at using custom templates? |
How do I do that?
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Tue Apr 11, 2023 4:34 pm Post subject: |
|
|
Here is one that I have used for years:
https://forum.cheatengine.org/viewtopic.php?t=588038
It saves me a lot of time. Highly recommended.
Just drop the Lua file into your autorun folder. You can edit it to create your own templates.
Description: |
|
Filesize: |
22.64 KB |
Viewed: |
4204 Time(s) |

|
|
|
Back to top |
|
 |
gir489 Grandmaster Cheater
Reputation: 14
Joined: 03 Jan 2012 Posts: 840 Location: Maryland, United States
|
Posted: Wed Apr 12, 2023 6:47 pm Post subject: |
|
|
Thanks a lot, man. This is exactly the control I wanted over the template.
Included is the Lua file I'm using with the 2 features requested.
https://pastebin.com/TNw8iSUP
Description: |
|
Filesize: |
103.35 KB |
Viewed: |
4138 Time(s) |

|
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Wed Apr 12, 2023 7:04 pm Post subject: |
|
|
Yes. Easily my favorite CE extension. I wish mgr.inz.Player was still coming around these days, but life keeps us busy sometimes.
|
|
Back to top |
|
 |
gir489 Grandmaster Cheater
Reputation: 14
Joined: 03 Jan 2012 Posts: 840 Location: Maryland, United States
|
Posted: Thu Apr 13, 2023 8:41 pm Post subject: |
|
|
++METHOS wrote: | Yes. Easily my favorite CE extension. I wish mgr.inz.Player was still coming around these days, but life keeps us busy sometimes. |
The first game I tried to use it on, it fell flat on its face.
I get an error about
Code: | Error:Failure determining what Cyberpunk2077.AK means |
The address I have highlighted is:
Code: | Cyberpunk2077.AK::SoundEngine::StartProfilerCapture+7ED0 - 41 8B 00 - mov eax,[r8] |
I tried giving it all manners of different addresses, but it kept erroring out. The stock AoB Scan Template works fine against the address.
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Thu Apr 13, 2023 8:58 pm Post subject: |
|
|
The extension is a little dated. Maybe someone can update it.
As a workaround, try turning off symbols inside of memory viewer before generating your script.
|
|
Back to top |
|
 |
LeFiXER Grandmaster Cheater Supreme
Reputation: 20
Joined: 02 Sep 2011 Posts: 1066 Location: 0x90
|
Posted: Fri Apr 14, 2023 6:54 am Post subject: |
|
|
gir489 wrote: | ++METHOS wrote: | Yes. Easily my favorite CE extension. I wish mgr.inz.Player was still coming around these days, but life keeps us busy sometimes. |
The first game I tried to use it on, it fell flat on its face.
I get an error about
Code: | Error:Failure determining what Cyberpunk2077.AK means |
The address I have highlighted is:
Code: | Cyberpunk2077.AK::SoundEngine::StartProfilerCapture+7ED0 - 41 8B 00 - mov eax,[r8] |
I tried giving it all manners of different addresses, but it kept erroring out. The stock AoB Scan Template works fine against the address. |
This is to do with the pattern used to match the address since the injection address is pulled from the information within the large comment block at the bottom of the scripts. The current code stops at the first colon and because there are two consecutive colons twice in the example provided, it can't capture the text after that.
On line 347 of your Pastebin code change this:
Code: |
local injectAddress = newScript:match('INJECTING HERE %-%-%-%-%-%-%-%-%-%-\r\n(.-):')
local injectAddressNum = getAddress(injectAddress)
|
To:
Code: |
local injectAddress = newScript:match('INJECTING HERE %-%-%-%-%-%-%-%-%-%-\r\n(.-):') or newScript:match('%-%-%-%-%-%-%-%-%-%-\n(.-)%s')
local injectAddressNum = getAddress(injectAddress)
|
The new pattern captures any text after the hyphens and newline char, but before the space. This is the example:
Code: |
// ---------- INJECTING HERE ----------
Cyberpunk2077.AK::SoundEngine::StartProfilerCapture+7ED0 - 41 8B 00 - mov eax,[r8]
// ---------- DONE INJECTING ----------
//The new pattern captures this text:
Cyberpunk2077.AK::SoundEngine::StartProfilerCapture+7ED0
|
Hopefully that will resolve your problem.
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Fri Apr 14, 2023 11:11 am Post subject: |
|
|
It would be great if we can get this issue resolved. When checking against a different target, the problem persists when symbols are turned on.
The symbol addressing can vary greatly. Any way to fix?
Thanks.
Description: |
|
Filesize: |
2.67 KB |
Viewed: |
3947 Time(s) |

|
Description: |
|
Filesize: |
1.26 KB |
Viewed: |
3947 Time(s) |

|
|
|
Back to top |
|
 |
gir489 Grandmaster Cheater
Reputation: 14
Joined: 03 Jan 2012 Posts: 840 Location: Maryland, United States
|
Posted: Fri Apr 14, 2023 6:56 pm Post subject: |
|
|
LeFiXER wrote: | This is to do with the pattern used to match the address since the injection address is pulled from the information within the large comment block at the bottom of the scripts. The current code stops at the first colon and because there are two consecutive colons twice in the example provided, it can't capture the text after that.
On line 347 of your Pastebin code change this:
Code: |
local injectAddress = newScript:match('INJECTING HERE %-%-%-%-%-%-%-%-%-%-\r\n(.-):')
local injectAddressNum = getAddress(injectAddress)
|
To:
Code: |
local injectAddress = newScript:match('INJECTING HERE %-%-%-%-%-%-%-%-%-%-\r\n(.-):') or newScript:match('%-%-%-%-%-%-%-%-%-%-\n(.-)%s')
local injectAddressNum = getAddress(injectAddress)
|
The new pattern captures any text after the hyphens and newline char, but before the space. This is the example:
Code: |
// ---------- INJECTING HERE ----------
Cyberpunk2077.AK::SoundEngine::StartProfilerCapture+7ED0 - 41 8B 00 - mov eax,[r8]
// ---------- DONE INJECTING ----------
//The new pattern captures this text:
Cyberpunk2077.AK::SoundEngine::StartProfilerCapture+7ED0
|
Hopefully that will resolve your problem. |
The script just silently does nothing, it's still not resolved.
I figured out how to fix it.
Code: | local injectAddress = newScript:match('INJECTING HERE %-%-%-%-%-%-%-%-%-%-\r\n(.-):%s') |
It will return anything between the new line and the colon and stop at the first space.
|
|
Back to top |
|
 |
LeFiXER Grandmaster Cheater Supreme
Reputation: 20
Joined: 02 Sep 2011 Posts: 1066 Location: 0x90
|
Posted: Sat Apr 15, 2023 5:34 am Post subject: |
|
|
++METHOS wrote: | It would be great if we can get this issue resolved. When checking against a different target, the problem persists when symbols are turned on.
The symbol addressing can vary greatly. Any way to fix?
Thanks. |
Do you have some examples?
gir489 wrote: |
The script just silently does nothing, it's still not resolved.
I figured out how to fix it.
Code: | local injectAddress = newScript:match('INJECTING HERE %-%-%-%-%-%-%-%-%-%-\r\n(.-):%s') |
It will return anything between the new line and the colon and stop at the first space. |
That's interesting. When I inserted '\r' into the pattern it yielded no results. But it pretty much is the same functionality, capture the text between '\n' and the first space after the hyphens. At least that's resolved.
|
|
Back to top |
|
 |
gir489 Grandmaster Cheater
Reputation: 14
Joined: 03 Jan 2012 Posts: 840 Location: Maryland, United States
|
Posted: Sat Apr 15, 2023 3:32 pm Post subject: |
|
|
LeFiXER wrote: |
That's interesting. When I inserted '\r' into the pattern it yielded no results. But it pretty much is the same functionality, capture the text between '\n' and the first space after the hyphens. At least that's resolved. |
What's funny is after I fixed it, I realized I stripped the script that requires injectAddress. I didn't even need to fix it.
|
|
Back to top |
|
 |
LeFiXER Grandmaster Cheater Supreme
Reputation: 20
Joined: 02 Sep 2011 Posts: 1066 Location: 0x90
|
Posted: Sat Apr 15, 2023 3:51 pm Post subject: |
|
|
gir489 wrote: |
What's funny is after I fixed it, I realized I stripped the script that requires injectAddress. I didn't even need to fix it.  |
Nevermind eh. What's important is you have the functionality you need.
|
|
Back to top |
|
 |
++METHOS I post too much
Reputation: 92
Joined: 29 Oct 2010 Posts: 4197
|
Posted: Sat Apr 15, 2023 4:01 pm Post subject: |
|
|
LeFiXER wrote: | Do you have some examples? |
-I have posted one example in my previous post. However, it seems that it can be anything, really. Here are some random examples, from the same module:
Code: | 7FF651E582D0 - sdhdship.`anonymous namespace'::strconv_attribute_t<0,1,1,1>()
7FF651E5D590 - sdhdship.UFG::qList<Illusion::StateBlock,Illusion::StateBlock,1,0>::~qList<Illusion::StateBlock,Illusion::StateBlock,1,0>()
7FF651E6AD30 - sdhdship.hkSmallArray<hkpEntityListener * __ptr64>::~hkSmallArray<hkpEntityListener * __ptr64>()
7FF653160293 - sdhdship.`UFG::`dynamic initializer for 'aHardcodedLeaderboardData'''::`1'::dtor$631()
7FF6532FC070 - sdhdship.`dynamic initializer for 'gDirectGameSliceId''()
7FF65341CA68 - sdhdship.Symbol_EnableDLC01CollectibleIndicators$initializer$
7FF653422298 - sdhdship.UFG::TargetingSystemPedBaseComponent::_TypeIDesc$initializer$ |
As previously mentioned, turning off symbols in memory viewer eliminates this issue. However, this solution is not ideal. By default, CE can generate an AA script, regardless. But when trying to generate a script using the custom template extension, errors occur and nothing is generated unless symbols are turned off.
Thanks.
|
|
Back to top |
|
 |
|