View previous topic :: View next topic |
Author |
Message |
elshabory Newbie cheater
Reputation: 0
Joined: 02 Mar 2011 Posts: 20
|
Posted: Sun May 29, 2011 10:39 pm Post subject: how can i read text from process with readprocessmemory |
|
|
hi all
how can i read text from running game process with readprocessmemory ??
just read it
i want an example in vb6 or in delphi please
say i want to display the sentence " you are good "
and say that value is a green address 40124C
of my process that named test
i read so many tuts in writeprocessmemory
but readprocessmemory are rare specialy in showing text value
so in few words
i want an example for readprocessmemory to get text value in known address
game name = test
text length is 12 char
address 40124c static
please help me if you can
|
|
Back to top |
|
 |
reload01 Advanced Cheater
Reputation: 0
Joined: 22 Oct 2006 Posts: 96
|
Posted: Mon May 30, 2011 2:27 am Post subject: |
|
|
Hello, you want to do is very simple. Basically, you have to do is call and specify the size ReadProcessMemory address and data recovery. In your case, the text of the address in your location, and placing 12 + 1 (NUL termination character) in size. You should know that the field size may vary, so you want to find the maximum length of string can becomes call ReadProcessMemory with maximum length and iterate until found NUL character. Good Luck and excellent problem
|
|
Back to top |
|
 |
elshabory Newbie cheater
Reputation: 0
Joined: 02 Mar 2011 Posts: 20
|
Posted: Tue May 31, 2011 7:12 am Post subject: |
|
|
OK
THANKS FOR REPLAY
THE CHEAT ENGINE FOLDER CONTAINS A FILE NAMED Tutorial.EXE
IN THE GREAN ADDRESS 4727AC IT HAVE A WORD
THAT WORD IS "WELCOME"
CAN YOU OR ANY ONE GIVE ME AN EXAMPLE FOR DISPLAY THIS WORD
IN TEXTBOX OR IN LABEL OR IN WHATEVER CONTROL ??
BY USING READPROCESSMEMORY
IN VB OR DELPHI PLEASE
Description: |
|
 Download |
Filename: |
Tutorial.CT |
Filesize: |
93 Bytes |
Downloaded: |
805 Time(s) |
|
|
Back to top |
|
 |
Krähne Expert Cheater
Reputation: 0
Joined: 06 Jun 2010 Posts: 108 Location: Inside of my Kernel
|
Posted: Tue May 31, 2011 1:18 pm Post subject: |
|
|
elshabory wrote: | OK
THANKS FOR REPLAY
THE CHEAT ENGINE FOLDER CONTAINS A FILE NAMED Tutorial.EXE
IN THE GREAN ADDRESS 4727AC IT HAVE A WORD
THAT WORD IS "WELCOME"
CAN YOU OR ANY ONE GIVE ME AN EXAMPLE FOR DISPLAY THIS WORD
IN TEXTBOX OR IN LABEL OR IN WHATEVER CONTROL ??
BY USING READPROCESSMEMORY
IN VB OR DELPHI PLEASE |
VB6 or .NET?
_________________
Excuse me if you don't understand what I just said, but "english" isn't my native language. |
|
Back to top |
|
 |
elshabory Newbie cheater
Reputation: 0
Joined: 02 Mar 2011 Posts: 20
|
Posted: Tue May 31, 2011 2:24 pm Post subject: |
|
|
vb6 or delphi please
|
|
Back to top |
|
 |
Krähne Expert Cheater
Reputation: 0
Joined: 06 Jun 2010 Posts: 108 Location: Inside of my Kernel
|
Posted: Tue May 31, 2011 6:21 pm Post subject: |
|
|
elshabory wrote: | vb6 or delphi please |
VB6:
Well, declare the API ReadProcessMemory, blah blah... and convert the buffer that returns ReadProcessMemory.
Code: | Public Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (Destination As Any, Source As Any, ByVal Length As Long)
Function ByteArrayToString(bytes As String, Length As Long) As String
Dim retValStr As String
retValStr = String(Length - 1, Chr$(0))
CopyMemory ByVal StrPtr(retValStr), ByVal bytes, Length * 2
ByteArrayToString = retValStr
End Function |
Hope it help you.
_________________
Excuse me if you don't understand what I just said, but "english" isn't my native language. |
|
Back to top |
|
 |
extra Newbie cheater
Reputation: 0
Joined: 29 May 2011 Posts: 10
|
Posted: Tue May 31, 2011 10:23 pm Post subject: |
|
|
Krähne wrote: | elshabory wrote: | vb6 or delphi please |
VB6:
Well, declare the API ReadProcessMemory, blah blah... and convert the buffer that returns ReadProcessMemory.
Code: | Public Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (Destination As Any, Source As Any, ByVal Length As Long)
Function ByteArrayToString(bytes As String, Length As Long) As String
Dim retValStr As String
retValStr = String(Length - 1, Chr$(0))
CopyMemory ByVal StrPtr(retValStr), ByVal bytes, Length * 2
ByteArrayToString = retValStr
End Function |
Hope it help you. |
you know ?? in most cases the problem is in the decleration blah blah
this function failes at most cases with the wrong decleration
so please give us full stuf master
|
|
Back to top |
|
 |
elshabory Newbie cheater
Reputation: 0
Joined: 02 Mar 2011 Posts: 20
|
Posted: Fri Jun 03, 2011 11:58 pm Post subject: |
|
|
any idea ??
this function alwayes fail when reading text
i need a working example
|
|
Back to top |
|
 |
Pingo Grandmaster Cheater
Reputation: 8
Joined: 12 Jul 2007 Posts: 571
|
Posted: Tue Jun 07, 2011 5:38 am Post subject: |
|
|
Heres a simple code you can try to convert. Not complete so you can convert it easier. It'l still work though.
Code: | public string ReadAscii(string ProcName, int pAddress, int pSize)
{
System.Diagnostics.Process[] P = System.Diagnostics.Process.GetProcessesByName(ProcName);
byte[] buffer = new byte[pSize * 2];
try
{
if (ReadProcessMemory((int)P[0].Handle, pAddress, buffer, pSize * 2, 0))
return System.Text.Encoding.ASCII.GetString(buffer);
}
catch { return ""; }
return "";
} |
And for Unicode string
change
Code: | return System.Text.Encoding.ASCII.GetString(buffer); |
to
Code: | return System.Text.Encoding.Unicode.GetString(buffer); |
_________________
|
|
Back to top |
|
 |
|