libmem
libmem copied to clipboard
Add "pointer scan"-like feature on README (C++)
Add a function to resolve pointer scans. Example:
lm_address_t GetPointers(lm_address_t start, std::vector<lm_address_t> offsets) {
for (auto offset : offsets) {
start = *(lm_address_t *)(start + offset);
}
return start;
}
Name suggestions:
LM_GetPointerMap
LM_GetDeepPointer
LM_ReadPointerMap
LM_ResolvePointerMap
LM_DerefPointerMap
LM_AccessPointerMap
LM_PointerMap
LM_UnwrapPointer
LM_MapPointer
LM_DeepPointer
Sketch:
lm_void_t *
LM_DeepPointer(lm_address_t base, lm_address_t *offsets, lm_size_t noffsets);
template <typename T>
T *LM_DeepPointer(lm_address_t base, std::vector<lm_address_t> &offsets);
Usage:
int *player_health = LM_DeepPointer<int>(some_addr, { 0xF0, 0xA0, 0xE0 });
TODO: Add LM_DeepPointer example on README, it's very attractive to Cheat Engine users
TODO: Add documentation
Done
The README needs to be changed
First, the C++ Wrapper API should be done: #130