Bot Stop Read MemoryAddress
Hello bot stoping read correctly value on all address always = 0
Someone can look it ? is VS 2013 Full Source.
Link:
http://speedy.sh/MNyR9/MaCrOsoft.zip
Example
ReadInt32(Tibia.Handle, adrZPos + Base - 400000) // Return 0
Now all function and declaration:
Public Function ReadBytes(Handle As IntPtr, Address As Int64, BytesToRead As UInteger) As Byte()
Dim ptrBytesRead As IntPtr
' Declare a buffer, this is the no mans land in which the information travels to get from the memory address to our programs memory.
Dim buffer As Byte() = New Byte(BytesToRead - 1) {}
' Call to the windows function to get the information.
ReadProcessMemory(Handle, New IntPtr(Address), buffer, BytesToRead, ptrBytesRead)
' The result of this function will be the contents of buffer. Any information which was stored at the memory address passed in, is now in the buffer.
Return buffer
End Function
Public Function ReadInt32(Handle As IntPtr, Address As Long) As Integer
Return BitConverter.ToInt32(ReadBytes(Handle, Address, 4), 0)
End Function
Public Declare Function ReadProcessMemory Lib "kernel32.dll" (hProcess As IntPtr, lpBaseAddress As IntPtr, buffer As Byte(), size As UInt32, ByRef lpNumberOfBytesRead As IntPtr) As Int32
Public adrZPos As UInt32 = &HAD1040
Dim TibiaProcess As Process() = Process.GetProcessesByName("Tibia")
Tibia = TibiaProcess(0)
Base = Hex(Tibia.MainModule.BaseAddress.ToInt32())