I'm trying to get the memdump external processes via delphi
But I'm struggling.
I am programming an anti-hack.
To detect hacks :
(Offset : $0432360; MemDump :($45, $FC, $8B, $40, $14, $8B, $40, $18, $83, $F8, $02, $74, $02, $EB, $0B, $8B, $45, $FC, $8B, $40, $24, $89, $45, $F8, $EB, $12, $8B, $45, $FC, $8B, $58, $14)), //Cheat Engine 6.1
Good people have this function to get the internal memdump:
I would get the memdump an external process via PID
function MemoryDump(Address : DWORD; SizeOfDump : Byte; RepeatX : DWORD):string;
value : Int64;
i,Count : DWORD;
s,vType : string;
if (SizeOfDump in [1,2,4,8]) then
Count := 0;
case (SizeOfDump) of
1: vType := 'Byte';
2: vType := 'Word';
4: vType := 'DWORD';
8: vType := 'Int64';
Result := 'Memory Dump from Address[$'+
IntToHex(Address,8)+']:'#13#10'Dump : array [0..$'+IntToHex(RepeatX,8)+
'] of '+vType+' = '#13#10'('#13#10' ';
s := '';
value := 0;
MoveMemory(@value,Pointer(Address + (SizeOfDump * Count)),SizeOfDump);
s := IntToHex(value,SizeOfDump);
if (Count <> RepeatX-1) then
if ((Count+1) mod 8 = 0) then
Result := Result + '$'+s+', '#13#10' '
Result := Result + '$'+s+', '
Result := Result + '$'+s+#13#10');';
until (Count = RepeatX);
Result := '';
Memo1.Text := MemoryDump($0044EC90,1,50);
But I tried and not worked with ReadProcessMemory
I appreciate everyone's attention!