Pymem How can I do the same using pymem process id

Viewed 60
from pymem import Pymem
from pymem.ptypes import RemotePointer

pm = Pymem("process")

def getPointerAddress(base, offsets):
        remote_pointer = RemotePointer(pm.process_handle, base)
        for offset in offsets:
            if offset != offsets[-1]:
                remote_pointer = RemotePointer(pm.process_handle, remote_pointer.value + offset)
            else:
                return remote_pointer.value + offset

print(pm.read_int(getPointerAddress(pm.base_address + 0x01D8D9A8, offsets=[0x44, 0x20, 0x2D8])))

"I want to write process id instead of process name in this Pymem('process')"

0 Answers
Related