Adjusting the offsets on a multilevel pointer

Memory scanning, code injection, debugger internals and other gamemodding related discussion
Post Reply
headmember
Noobzor
Noobzor
Posts: 6
Joined: Tue Oct 26, 2021 3:46 pm
Reputation: 0

Adjusting the offsets on a multilevel pointer

Post by headmember »

Hi!

I have a problem with adjusting the offsets on a multilevel pointer. Short explanation. Suppose I need a pointer for 2 addresses. I search and find the pointer for the first address. The pointer has only one offset. So I don't need to search for a pointer for the second address, I just adjust the offset of the first address until the address in the address field matches the second address. So I would have the pointer for the second address. But now in another game I have a pointer with 6 offsets. Can someone give me some advice how to adjust the offsets in this case? Is it possible at all in a simple way, or do I have to find a pointer for every single address? It would be great if someone could help me.

bye

User avatar
LeFiXER
LeFixer
LeFixer
Posts: 482
Joined: Wed Mar 24, 2021 9:35 am
Reputation: 243

Re: Adjusting the offsets on a multilevel pointer

Post by LeFiXER »

It really depends, every game is different. If the data struct has an entry which points to another address which contains the data you want then yes. Although, without more information it's hard to give specific help because it's quite a broad question. There seems to be some confusion around pointers for some so I will explain a bit (hopefully). A pointer is an address which points to another address. An address which points to a value is just an address.

A rather crude example. I hope it explains a bit better:

Code: Select all

Address = 0x4000000 
Offset = 0xA
Value of Address(0x40000A) = 0x400010A
In this case, the offset is added to the address to resolve the pointer address. The value of the address is a pointer because it points to another location in memory rather than a value.

Post Reply

Who is online

Users browsing this forum: YandexBot