 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
Dark Byte Site Admin
Reputation: 475
Joined: 09 May 2003 Posts: 26005 Location: The netherlands
|
Posted: Sat Nov 21, 2020 6:03 pm Post subject: |
|
|
| Quote: |
I figured the only way around this sporadic behavior would be forcing the 14byte jump every time.
Question is: how do I force a jump to be a 14byte jump in AA?
Is there a jmp14 command? Razz
|
Don't make the jmp 14 bytes, make the return jump 14 bytes later
e.g.
| Code: |
alloc(bla,1024)
bla:
//something
jmp hookpoint+14
hookpoint:
jmp bla
|
Also, in what case does your jmp turn to a 14 byte jmp? Did you forget to provide the 3th alloc parameter ?
_________________
Tools give you results. Knowledge gives you control.
Like my help? Join me on Patreon so i can keep helping |
|
| Back to top |
|
 |
panraven Grandmaster Cheater
Reputation: 62
Joined: 01 Oct 2008 Posts: 960
|
Posted: Sat Nov 21, 2020 6:43 pm Post subject: |
|
|
My opinion, force long jump has the benefit to emit proper 'nop' instruction, so that the disassemble of the inject point look tidy.
| Quote: | | Also, in what case does your jmp turn to a 14 byte jmp? |
Not sure Csimbi experience, my cases:
1. it happened if multiple mono injection point in same script;
2. more likely in my 32G desktop, less in my 16G laptop;
3. recent mono game, in my case notable in an open world game seems need a lot memory;
4. there is case in above mentioned game, even I make one inject point in one script, it still allocate memory far more than 2G distance, seemly the mono engine reserved a large memory region to its jit's functions.
| Quote: | | Did you forget to provide the 3th alloc parameter ? |
Csimbi's script prefer scan multiple inject point inside an initial script,
it seems ce 'alloc' command within same script only respect the 1st 'alloc''s address hint (3rd parameter).
_________________
- Retarded. |
|
| Back to top |
|
 |
Csimbi I post too much
Reputation: 98
Joined: 14 Jul 2007 Posts: 3428
|
Posted: Sun Nov 22, 2020 3:38 am Post subject: |
|
|
| Dark Byte wrote: |
Don't make the jmp 14 bytes, make the return jump 14 bytes later
|
That's actually a very elegant solution, not sure why I did not think of that, thanks!
| Dark Byte wrote: | | Also, in what case does your jmp turn to a 14 byte jmp? Did you forget to provide the 3th alloc parameter ? |
I have multiple injections in one script and they all go into the same 4k cave (alloc,4k,sig)
Mono generates code on the fly - means some of the code on app startup, while some only after level data is loaded and game started.
If the level is big, I guess it causes new memory to be allocated for the newly generated code at much higher addresses.
This is the table in question. Some users were complaining about crashes. I did not get a crash at all while I played on Windows 7. Now that I upgraded to (and play on) Windows 10, I got the crash too, so I could check what's what.
The crash occurs at aobUnitEfficiencyUpdater return (that's where the 14byte jump occurs randomly).
| panraven wrote: | My opinion, force long jump has the benefit to emit proper 'nop' instruction, so that the disassemble of the inject point look tidy.
|
True, but this is a sacrifce I am willing to make to get a crash-proof script.
| panraven wrote: |
Not sure Csimbi experience, my cases:
1. it happened if multiple mono injection point in same script;
2. more likely in my 32G desktop, less in my 16G laptop;
3. recent mono game, in my case notable in an open world game seems need a lot memory;
4. there is case in above mentioned game, even I make one inject point in one script, it still allocate memory far more than 2G distance, seemly the mono engine reserved a large memory region to its jit's functions. |
1. precisely what I have
2. I am also on 32G RAM, maybe Windows 10 does things differently than Windows 7? I seldom reboot - could also be that memory becomes more fragmented in Win10 than it did on Win7?
3. It's WFTO, there are a good deal of resources to be loaded, yes
4. again, this is precisely it
| panraven wrote: |
Csimbi's script prefer scan multiple inject point inside an initial script,
it seems ce 'alloc' command within same script only respect the 1st 'alloc''s address hint (3rd parameter). |
Spot on
|
|
| Back to top |
|
 |
panraven Grandmaster Cheater
Reputation: 62
Joined: 01 Oct 2008 Posts: 960
|
Posted: Sun Nov 22, 2020 8:46 am Post subject: |
|
|
Oops, sorry, this is not true,
| Quote: |
...
it seems ce 'alloc' command within same script only respect the 1st 'alloc''s address hint (3rd parameter). |
I mixed up alloc with globalalloc.
_________________
- Retarded. |
|
| Back to top |
|
 |
sandsmaster Newbie cheater
Reputation: 1
Joined: 21 Jan 2021 Posts: 24
|
Posted: Sun Aug 08, 2021 2:21 am Post subject: |
|
|
Thanks a lot guys and Dark Byte for the solution.
That took me some time to find.
Thanks again.
_________________
I don't post too much. yet. |
|
| Back to top |
|
 |
|
|
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
|
|