Results 1 to 11 of 11
  1. #1
    jonnyHS's Avatar
    Join Date
    May 2013
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    1
    My Mood
    Pensive

    Angry Help PointerWrite (Pointers lvls4 with 4 and 5 offsets) Pointers & Offsets

    Good evening, today I come to this forum looking for a solution to my big problem: A PounterWrite module for Visual Studio 2012.

    I have tried already with 3 different modules up and go crazy :-(. Investigating've seen that all or most people use the Visual Studio 2010 Express or Full, to see me download the Express and still not work for me.

    Here is one of the modules that I use:

    Code:
    VB.NET Module 
    'Author : Cless 
    'How to use Read/Write Pointer 
    'Example Read 
    '       Me.Text = ReadPointerInteger(Game exe name, &HPointer,&HOffset).ToString() 
    ' 
    '       Me.Text = ReadPointerInteger("gta_sa", &HB71A38,&H540).ToString() 
    '       Or 
    '       Me.Text = ReadPointerInteger("gta_sa", &HB71A38,&H540,&H544).ToString() 
    'Example Write 
    '       WritePointerInteger(Game exe name,&HPointer,Value,&HOffset) 
    ' 
    '       WritePointerInteger("gta_sa",&HB71A38,1000,&H540) 
    '       Or 
    '       WritePointerInteger("gta_sa",&HB71A38,1000,&H540, &H544) 
    
    Module Trainer 
        Private Declare Function ReadMemoryByte Lib "kernel32" Alias "ReadProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Byte, Optional ByVal Size As Integer = 2, Optional ByRef Bytes As Integer = 0) As Byte 
        Private Declare Function ReadMemoryInteger Lib "kernel32" Alias "ReadProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Integer, Optional ByVal Size As Integer = 4, Optional ByRef Bytes As Integer = 0) As Integer 
        Private Declare Function ReadMemoryFloat Lib "kernel32" Alias "ReadProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Single, Optional ByVal Size As Integer = 4, Optional ByRef Bytes As Integer = 0) As Single 
        Private Declare Function ReadMemoryDouble Lib "kernel32" Alias "ReadProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Double, Optional ByVal Size As Integer = 8, Optional ByRef Bytes As Integer = 0) As Double 
    
        Private Declare Function WriteMemoryByte Lib "kernel32" Alias "WriteProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Byte, Optional ByVal Size As Integer = 2, Optional ByRef Bytes As Integer = 0) As Byte 
        Private Declare Function WriteMemoryInteger Lib "kernel32" Alias "WriteProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Integer, Optional ByVal Size As Integer = 4, Optional ByRef Bytes As Integer = 0) As Integer 
        Private Declare Function WriteMemoryFloat Lib "kernel32" Alias "WriteProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Single, Optional ByVal Size As Integer = 2, Optional ByRef Bytes As Integer = 0) As Single 
        Private Declare Function WriteMemoryDouble Lib "kernel32" Alias "WriteProcessMemory" (ByVal Handle As Integer, ByVal Address As Integer, ByRef Value As Double, Optional ByVal Size As Integer = 2, Optional ByRef Bytes As Integer = 0) As Double 
    
        Public Function ReadByte(ByVal EXENAME As String, ByVal Address As Integer) As Byte 
            Dim Value As Byte 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    ReadMemoryByte(Handle, Address, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadInteger(ByVal EXENAME As String, ByVal Address As Integer) As Integer 
            Dim Value As Integer 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    ReadMemoryInteger(Handle, Address, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadFloat(ByVal EXENAME As String, ByVal Address As Integer) As Single 
            Dim Value As Single 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    ReadMemoryFloat(Handle, Address, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadDouble(ByVal EXENAME As String, ByVal Address As Integer) As Double 
            Dim Value As Double 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    ReadMemoryByte(Handle, Address, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadPointerByte(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Byte 
            Dim Value As Byte 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    ReadMemoryByte(Handle, Pointer, Value) 
                End If 
            Else 
                MsgBox("can't find process") 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadPointerInteger(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer() ) As Integer 
            Dim Value As Integer 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    ReadMemoryInteger(Handle, Pointer, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadPointerFloat(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Single 
            Dim Value As Single 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    ReadMemoryFloat(Handle, Pointer, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Function ReadPointerDouble(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Double 
            Dim Value As Double 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    ReadMemoryDouble(Handle, Pointer, Value) 
                End If 
            End If 
            Return Value 
        End Function 
    
        Public Sub WriteByte(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Byte) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    WriteMemoryByte(Handle, Address, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WriteInteger(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Integer) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    WriteMemoryInteger(Handle, Address, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WriteFloat(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Single) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    WriteMemoryFloat(Handle, Address, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WriteDouble(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Double) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    WriteMemoryDouble(Handle, Address, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WritePointerByte(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal Value As Byte, ByVal ParamArray Offset As Integer()) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    WriteMemoryByte(Handle, Pointer, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WritePointerInteger(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal Value As Integer, ByVal ParamArray Offset As Integer()) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    WriteMemoryInteger(Handle, Pointer, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WritePointerFloat(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal Value As Single, ByVal ParamArray Offset As Integer()) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    WriteMemoryFloat(Handle, Pointer, Value) 
                End If 
            End If 
        End Sub 
    
        Public Sub WritePointerDouble(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal Value As Double, ByVal ParamArray Offset As Integer()) 
            If Process.GetProcessesByName(EXENAME).Length <> 0 Then 
                Dim Handle As Integer = Process.GetProcessesByName(EXENAME)(0).Handle 
                If Handle <> 0 Then 
                    For Each I As Integer In Offset 
                        ReadMemoryInteger(Handle, Pointer, Pointer) 
                        Pointer += I 
                    Next 
                    WriteMemoryDouble(Handle, Pointer, Value) 
                End If 
            End If 
        End Sub 
    End Module
    And to write in memory:

    Code:
    WritePointerInteger("proceso",&HBaseaddress,Valor,&HOffset1, &HOffset2, &HOffset3, &HOffset4)
    But only wroks with pointers lvl1 :l

    ---------------------------------------------------------------------------------------------------------------------------------------------

    I tried reading the memory and adding the offsets to the base address with this module, but still dont working

    Code:

    Code:
    Dim Adress As Integer = ReadPointerInteger("SpiderSolitaire", &H942B8)
            Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H10)
            Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H7C)
            Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &HC)
            Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H40)
            WritePointerInteger("SpiderSolitaire", Adress + &H74, 50000)
    And

    [CODE] Dim Address As Integer = ReadPointerInteger ("SpiderSolitaire", & )
    Adress = ReadPointerInteger ("SpiderSolitaire", & Adress + & H10)
    Adress = ReadPointerInteger ("SpiderSolitaire", &Adress + & H7C )
    Adress = ReadPointerInteger ("SpiderSolitaire", & Adress + & HC)
    Adress = ReadPointerInteger ("SpiderSolitaire", & Adress + & H40)
    WritePointerInteger ("SpiderSolitaire" Adress + & H74, 50000) [/ CODE]

    ----------------------------------------------------------------------------------------------------------------------------

    2

    Try with the module Read / WriteMerobo found in many videos throughout the network

    to write in memory:

    Code:
    WriteDMAInteger("SpiderSolitaire", &H4942B8, Offsets:={&H10, &H7C, &HC, &H40, &H74}, Value:="50000000" Level:=5, nsize:=4)
    ----------------------------------------------------------------------------------------------------------------------------
    3

    Try a module which I found here is this:

    Its Called Memory:

    Code:
    'Memory hacking module, don't change anything here
    Imports System.Runtime.InteropServices
    Imports System.Diagnostics
    Imports System****
    
    Module Memory
    
        <DllImport("kernel32.dll")> _
        Public Function ReadProcessMemory(ByVal hProcess As IntPtr, ByVal lpBaseAddress As IntPtr, <[In](), Out()> ByVal buffer As Byte(), ByVal size As UInt32, ByRef lpNumberOfBytesRead As IntPtr) As Int32
        End Function
    
        <DllImport("kernel32.dll")> _
        Public Function WriteProcessMemory(ByVal hProcess As IntPtr, ByVal lpBaseAddress As IntPtr, <[In](), Out()> ByVal buffer As Byte(), ByVal size As UInt32, ByRef lpNumberOfBytesWritten As IntPtr) As Int32
        End Function
    
        Public Function WriteInt32(ByVal P As Process, ByVal memAdr As Int32, ByVal value As Integer) As Boolean
            Return WriteBytes(P, memAdr, BitConverter.GetBytes(value), 4)
        End Function
    
        Public Function ReadInt32(ByVal P As Process, ByVal memAdr As Int32) As Integer
            Return BitConverter.ToInt32(ReadBytes(P, memAdr, 4), 0)
        End Function
    
        Public Function WriteShort(ByVal P As Process, ByVal memAdr As Int32, ByVal value As Short) As Boolean
            Return WriteBytes(P, memAdr, BitConverter.GetBytes(value), 2)
        End Function
    
        Public Function ReadShort(ByVal P As Process, ByVal memAdr As Int32) As Short
            Return BitConverter.ToInt16(ReadBytes(P, memAdr, 2), 0)
        End Function
    
        Public Function WriteFloat(ByVal P As Process, ByVal memAdr As Int32, ByVal value As Single) As Boolean
            Return WriteBytes(P, memAdr, BitConverter.GetBytes(value), 4)
        End Function
    
        Public Function ReadFloat(ByVal P As Process, ByVal memAdr As Int32) As Single
            Return BitConverter.ToSingle(ReadBytes(P, memAdr, 4), 0)
        End Function
    
        Public Function WriteByte(ByVal P As Process, ByVal memAdr As Int32, ByVal value As Byte) As Boolean
            Return WriteBytes(P, memAdr, BitConverter.GetBytes(value), 1)
        End Function
    
        Public Function ReadByte(ByVal P As Process, ByVal memAdr As Int32) As Byte
            Return BitConverter.ToString(ReadBytes(P, memAdr, 1), 0)
        End Function
    
        Private Function ReadBytes(ByVal P As Process, ByVal memAdr As Long, ByVal bytesToRead As UInteger) As Byte()
            Dim ptrBytesRead As IntPtr
            Dim buffer As Byte() = New Byte(bytesToRead - 1) {}
            ReadProcessMemory(P.Handle, New IntPtr(memAdr), buffer, bytesToRead, ptrBytesRead)
            Return buffer
        End Function
    
        Public Function WriteBytes(ByVal P As Process, ByVal memAdr As Long, ByVal bytes As Byte(), ByVal length As UInteger) As Boolean
            Dim bytesWritten As IntPtr
            Dim result As Integer = WriteProcessMemory(P.Handle, New IntPtr(memAdr), bytes, length, bytesWritten)
            Return result <> 0
        End Function
    
        Public Function StrToByteArray(ByVal str As String) As Byte() 'Function to write Unicode text into the memory. Use it with the WriteBytes function like in the example:  WriteBytes(p, Adr2 + &H0, StrToByteArray(TEXT), StrToByteArray(TEXT).Length)
            Dim encoding As New System.Text.UnicodeEncoding()         'You may have to overwrite the string with 00 Bytes first to avoid a combination of the original and the new string as result, like if the new text is "One" and the old is "Blablabla"
            Return encoding.GetBytes(str)                             'after changing it would be "Oneblabla" and not "One" if you don't overwrite the old string. To overwrite it use this in the code BEFORE you overwrite it with the new text:
        End Function                                                  'WriteBytes(p, Adr1 + &H0, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, 24). Write two 0s for every letter of the old text, replace the 24 with the amount of 0s and don't forget to replace the &H0 with the last offset of your pointer.
    
    End Module
    With this:

    Code:
    'Function for giving the program access to change values in the RAM
    Module modTTInitializeProc
        Public Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As IntPtr
        Public Declare Function GetWindowThreadProcessId Lib "user32" (ByVal hwnd As IntPtr, ByRef lpdwProcessId As Integer) As Integer
        Public Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Integer, ByVal bInheritHandle As Boolean, ByVal dwProcessId As Integer) As IntPtr
        Public Declare Function CloseHandle Lib "kernel32" Alias "CloseHandle" (ByVal hObject As IntPtr) As Boolean
    
        Private PROCESS_ALL_ACCESS As Integer = &H1F0FFF
    
        Public pstrClassName As String
    
        Public Function InitProc(ByVal strClassName As String) As IntPtr
            'Obtain the window handle by the window class
            Dim hWnd As IntPtr = FindWindow(strClassName, vbNullString)
            If hWnd = Nothing Then
                Form1.HotkeyTimer.Stop()
                Form1.RefreshTimer.Stop()
                MessageBox.Show("Game window not found in the specified process! Closing...", "Error", MessageBoxButtons.OK, MessageBoxIcon.Warning)
                Application.Exit()
            Else 'If there is a handle
                Dim pID As Integer
                'Obtain the process id
                GetWindowThreadProcessId(hWnd, pID)
                'Obtain the handle of the process
                Dim intTemp As IntPtr
                intTemp = OpenProcess(PROCESS_ALL_ACCESS, False, pID)
                InitProc = intTemp
            End If
        End Function
    End Module
    (All the credits of these modules to ccman32)

    In form1:

    Code:
    'Variables
        Dim ProcessName As String = "Emuclient"
        Dim WindowClass As String = "S4 Client" 'If you wanna hack another game than AVA you have to replace this string with the window class name of your game
        'You can use google to find out how you can get the window class for the game you wanna hack with this trainer
        'The easiest way to get the window class is by using WinSpy++ (Spy++)
        Dim p As Process = Nothing
        Dim RealName As String
        Dim Xpos As Integer
        Dim Ypos As Integer
        Dim NewPoint As New System.Drawing.Point
        Dim Panel1MouseDown As Boolean = False 'This variable was made to avoid bugs if the window gets moved while pressing the hotkey for setting it to center screen.
    For inject or Write:

    Code:
     Try
                Dim Adr1 As Int32 = Memory.ReadInt32(p, &HB328B0) 'Address
                Adr1 = Memory.ReadInt32(p, Adr1 + &H210) 'Offset1
                Adr1 = Memory.ReadInt32(p, Adr1 + &H8) 'Offset2 (Add more offsets if needed)
                Adr1 = Memory.ReadInt32(p, Adr1 + &H138) 'Offset1
    
    
                'ATTENTION: The last offset MUST be added in the writing part (in this example the last offset is &H123)
                'Replace the value (999) with what you want to change it to and the method (WriteInt32) with the method for the value type of the value you wanna change.
                WriteInt32(p, Adr1 + &H90, 1167867904)
    
            Catch ex As Exception 'If something failed
                MessageBox.Show("Writing to memory failed: " & vbCrLf & ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error)
            End Try
    ----------------------------------------------------------------------------------------------------------------------------

    Anything works for me, Somebody can help me? (Am using Visual Studio 2012 Full)
    Last edited by jonnyHS; 10-07-2013 at 04:48 PM.

  2. #2
    abuckau907's Avatar
    Join Date
    Dec 2012
    Gender
    male
    Location
    other side of the wire
    Posts
    1,342
    Reputation
    162
    Thanks
    239
    My Mood
    Cold
    Not to push my own code, but I wrote a tut about it at

    https://www.mpgh.net/forum/33-visual-...ing-part1.html
    and
    https://www.mpgh.net/forum/33-visual-...ory-part*****ml
    ^^at the end of part 2 is a copy-paste friendly version of all the code.

    Or, do you have a specific question (or error?) other than "I need a memory library" ..there are several available here at mpgh. Check pages 1-100, they're there, I promise.

    edit: Your title says "level 4/5 pointers", is that the problem? It's not as pretty a syntax as C++, but it would look like
    Code:
    Dim level1 as IntPtr = MemoryReadPointer(_address_)
    Dim level2 as IntPtr = MemoryReadPointer(level1)
    Dim level3 as IntPtr = MemoryReadPointer(level2)
    Dim level4 as IntPtr = MemoryReadPointer(level3)
    Or if you have offsets (which you likely do)
    Code:
    Dim level1 as IntPtr = MemoryReadPointer(_address_)
    Dim level2 as IntPtr = MemoryReadPointer(level1 + offset1)
    Dim level3 as IntPtr = MemoryReadPointer(level2 + offset2)
    Dim level4 as IntPtr = MemoryReadPointer(level3 + offset3)
    Last edited by abuckau907; 10-07-2013 at 08:21 PM. Reason: s
    'Some things that can be counted, don't matter. And some things that matter, can't be counted' - A.E.
    --
     

    My posts have some inaccuracies/are wrong/wrong keyword(s) used.
    They're (maybe) pretty close, and I hope they helped you, not created confusion. Take with grain of salt.

    -if you give rep, please leave a comment, else it means less.

  3. #3
    jonnyHS's Avatar
    Join Date
    May 2013
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    1
    My Mood
    Pensive
    Quote Originally Posted by abuckau907 View Post
    Not to push my own code, but I wrote a tut about it at



    Or, do you have a specific question (or error?) other than "I need a memory library" ..there are several available here at mpgh. Check pages 1-100, they're there, I promise.

    edit: Your title says "level 4/5 pointers", is that the problem? It's not as pretty a syntax as C++, but it would look like
    Code:
    Dim level1 as IntPtr = MemoryReadPointer(_address_)
    Dim level2 as IntPtr = MemoryReadPointer(level1)
    Dim level3 as IntPtr = MemoryReadPointer(level2)
    Dim level4 as IntPtr = MemoryReadPointer(level3)
    Or if you have offsets (which you likely do)
    Code:
    Dim level1 as IntPtr = MemoryReadPointer(_address_)
    Dim level2 as IntPtr = MemoryReadPointer(level1 + offset1)
    Dim level3 as IntPtr = MemoryReadPointer(level2 + offset2)
    Dim level4 as IntPtr = MemoryReadPointer(level3 + offset3)
    So, thats for read, but i want to write at the pointer.

    I dont have any error, the problem is that i only can write in pointers with only 1offsets :l
    Last edited by jonnyHS; 10-07-2013 at 08:29 PM.

  4. #4
    abuckau907's Avatar
    Join Date
    Dec 2012
    Gender
    male
    Location
    other side of the wire
    Posts
    1,342
    Reputation
    162
    Thanks
    239
    My Mood
    Cold
    that's just reading the levels until you find the final location. Once you have that address, call a write function on it.

    ?

    edit: I've seen someone post code on here recently (last 6 months?) about doing this exact same thing.

    Basically it's a MemoryRead** function, and 2 of the parameters are 1) number of levels 2) array of offsets

    Code:
    Public Function WriteIntPtrList(Byval address As Intptr, Byval levels as Int32, Byval offsets() as Int32) As boolean
    Dim tmpAddr as IntPtr
    For i As Int32 = 0 to levels - 1
    tmpAddr = MemoryReadPointers(tmpAddr) + offset(i)
    Next i
    WriteInt(tmpAddr,4200) '' write 4200 as new value 
    End Function
    ^^something like that.

    Do you have a specific question...you said you tried to do it like i showed (like your 3rd or 4th code box...the one that's malformatted and isn't actually displaying as a code box), you said it "didn't work", but didn't say why. Compile errors, invalid results? Did you check and make sure the first pointer was ever read correctly? Then the 2nd, etc. ?

    edit:

    Code:
    Public Function ReadPointerList(Byval startAddr as IntPtr, Byval levels as Int32, Byval offsets() as Int32) as IntPtr
    Dim rtnAddr as IntPtr = startAddr
    
    For ii as Int32 = 0 to levels -1
    rtnAddr = MemoryReadPointers(rtnAddr) + offsets(ii)
    Next ii
    
    Return rtnAddr
    End Function
    ^^ something like that would read n number of pointers, and return the final address. Would be used like

    Code:
    Dim offsets() As Int32 = (&H34, &H612, &H91AB, &HABAB, &HAB12)
    Dim finalAddr As IntPtr = ReadPointerList(&H123456,5,offsets) '' use offsets.Length instead of hardcoded 5
    
    WriteInteger(finalAddr, theNewValue)
    Last edited by abuckau907; 10-07-2013 at 08:51 PM.
    'Some things that can be counted, don't matter. And some things that matter, can't be counted' - A.E.
    --
     

    My posts have some inaccuracies/are wrong/wrong keyword(s) used.
    They're (maybe) pretty close, and I hope they helped you, not created confusion. Take with grain of salt.

    -if you give rep, please leave a comment, else it means less.

  5. #5
    jonnyHS's Avatar
    Join Date
    May 2013
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    1
    My Mood
    Pensive
    Quote Originally Posted by abuckau907 View Post
    that's just reading the levels until you find the final location. Once you have that address, call a write function on it.

    ?

    edit: I've seen someone post code on here recently (last 6 months?) about doing this exact same thing.

    Basically it's a MemoryRead** function, and 2 of the parameters are 1) number of levels 2) array of offsets

    Code:
    Public Function WriteIntPtrList(Byval address As Intptr, Byval levels as Int32, Byval offsets() as Int32) As boolean
    
    ..
    End Function
    ^^something like that.

    Do you have a specific question...you said you tried to do it like i showed (like your 3rd or 4th code box...the one that's malformatted and isn't actually displaying as a code box), you said it "didn't work", but didn't say why. Compile errors, invalid results? Did you check and make sure the first pointer was ever read correctly? Then the 2nd, etc. ?
    Compile errors: NO
    invalid results: NO

    i was testing reading pointers for see what happend (first module)

    Label1.text = ReadPointerInteger("SpiderSolitaire", &H942B8, &H10) it works but when i add the second pointer it didn`t work like this:

    Label1.text = ReadPointerInteger("SpiderSolitaire", &H942B8, &H10, &Hc)

    When i try to do write it like this:

    Dim Adress As Integer = ReadPointerInteger("SpiderSolitaire", &H942B8)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H10)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H7C)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &HC)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H40)
    WritePointerInteger("SpiderSolitaire", Adress + &H74, 50000)

    The pointer go down

    Sooo what will happend is i do it like this:


    Dim Adress As Integer = ReadPointerInteger("SpiderSolitaire", &H942B8)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H10)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H7C)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &HC)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H40)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H74)

    And then i write the pointer WritePointerInteger("SpiderSolitaire", Adress, 50000)

    It didn`t work

    I speak spanish, so it will be hard comunicate.

    Code:
    Public Function WriteIntPtrList(Byval address As Intptr, Byval levels as Int32, Byval offsets() as Int32) As boolean
    Dim tmpAddr as IntPtr
    For i As Int32 = 0 to levels - 1
    tmpAddr = MemoryReadPointers(tmpAddr) + offset(i)
    Next i
    WriteInt(tmpAddr,4200) '' write 4200 as new value 
    End Function
    Wich module are u using for this?
    Last edited by jonnyHS; 10-07-2013 at 08:49 PM.

  6. #6
    abuckau907's Avatar
    Join Date
    Dec 2012
    Gender
    male
    Location
    other side of the wire
    Posts
    1,342
    Reputation
    162
    Thanks
    239
    My Mood
    Cold
    And then i write the pointer WritePointerInteger("SpiderSolitaire", Adress, 50000)

    It didn`t work
    But is Adress correct? == 0x61CE2F, or whatever. ??

    --
    just pseudo-code. I wasn't sure which module You were using. Which one?

    edit: I'm not giving you copy-paste code. You understand it and can copy it, or you don't. No c+p. : /

    edit:
    Dim Adress As Integer = ReadPointerInteger("SpiderSolitaire", &H942B8)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H10)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H7C)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &HC)
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 + &H40)
    WritePointerInteger("SpiderSolitaire", Adress + &H74, 50000)

    The pointer go down
    Are you sure Adress + &H74 IS the correct address? Set a break point on the WritePointerInteger line, and check.
    Last edited by abuckau907; 10-07-2013 at 08:58 PM.
    'Some things that can be counted, don't matter. And some things that matter, can't be counted' - A.E.
    --
     

    My posts have some inaccuracies/are wrong/wrong keyword(s) used.
    They're (maybe) pretty close, and I hope they helped you, not created confusion. Take with grain of salt.

    -if you give rep, please leave a comment, else it means less.

  7. #7
    jonnyHS's Avatar
    Join Date
    May 2013
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    1
    My Mood
    Pensive
    "Dim offsets() As Int32 = (&H34, &H612, &H91AB, &HABAB, &HAB12)
    Dim finalAddr As IntPtr = ReadPointerList(&H123456,5,offsets) '' use offsets.Length instead of hardcoded 5

    WriteInteger(finalAddr, theNewValue)"

    I think this will be the best way i will try to start now, thanks

  8. #8
    abuckau907's Avatar
    Join Date
    Dec 2012
    Gender
    male
    Location
    other side of the wire
    Posts
    1,342
    Reputation
    162
    Thanks
    239
    My Mood
    Cold
    It will be cleaner code in the end : )

    If you need help you can add me on skype, username is same one here for mpgh. Good luck.
    Last edited by abuckau907; 10-07-2013 at 09:01 PM.
    'Some things that can be counted, don't matter. And some things that matter, can't be counted' - A.E.
    --
     

    My posts have some inaccuracies/are wrong/wrong keyword(s) used.
    They're (maybe) pretty close, and I hope they helped you, not created confusion. Take with grain of salt.

    -if you give rep, please leave a comment, else it means less.

  9. #9
    jonnyHS's Avatar
    Join Date
    May 2013
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    1
    My Mood
    Pensive
    Ithink that this:

    "Dim Adress As Integer = ReadPointerInteger("SpiderSolitaire", &H942B8)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H10)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H7C)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &HC)
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H40)
    Button1.Text = Adress"ç

    Is the same that u try to teach me but why always is 0?

    PD: the value is: 1778084346

    I`ll continue tomorrow i want to sleep
    Last edited by jonnyHS; 10-07-2013 at 09:35 PM.

  10. #10
    abuckau907's Avatar
    Join Date
    Dec 2012
    Gender
    male
    Location
    other side of the wire
    Posts
    1,342
    Reputation
    162
    Thanks
    239
    My Mood
    Cold
    Quote Originally Posted by jonnyHS View Post
    Code:
    Dim Adress As Integer = ReadPointerInteger("SpiderSolitaire", &H942B8)
                    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H10)
                    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H7C)
                    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &HC)
                    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H40)
                    Button1.Text = Adress"ç
    Is the same that u try to teach me but why always is 0?
    PD: the value is: 1778084346
    What is 0? The final value of 'Adress' ? Does it get a correct value the first 4 times? Check : )

    Code:
    Dim Adress As Integer 
    
    Adress = ReadPointerInteger("SpiderSolitaire", &H942B8 )
    If Adress = 0 Then MessageBox.Show("No Puede [read address 0x942B8]")
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H10)
    If Adress = 0 Then MessageBox.Show("No Puede [read address ptr1 + &H10: " & (Adress+&H10).ToString("X") & " ]")
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H7C)
    If Adress = 0 Then MessageBox.Show("No Puede [read address ptr2 + &H7C: " & (Adress+&H7C).ToString("X") & " ]")
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &HC)
    If Adress = 0 Then MessageBox.Show("No Puede [read address ptr3 + &HC: " & (Adress+&HC).ToString("X") & " ]")
    Adress = ReadPointerInteger("SpiderSolitaire", Adress + &H40)
    If Adress = 0 Then MessageBox.Show("No Puede [read address ptr4 + &H40: " & (Adress+&H10).ToString("X") & " ]")
    Button1.Text = "0x" &  Adress.ToString("X")  '// .ToString("X") == format as hex number. Not base 10.  1778084346 == 0x69FB69FA
    Gl, see you tomorrow.
    -----
    edit:
    I can't test this, because I'm too lazy to copy your code into a new project..but this should be close to working:
    Code:
    Public Function ReadPointerList(Byval processName As String, Byval baseAddress As Integer, ByVal levels As Integer, ByVal offsets() As Integer) As Integer
    Dim rtnPtr as Integer = 0
    rtnPtr = ReadPointerInteger(processName, baseAddress)
    
    For xx As Int32 = 0 To levels -1
      rtnPtr = ReadPointerInteger(processName, rtnPtr+ offsets(xx))
    Next xx
    
    Return rtnPtr
    End Function
     

    Code:
    Public Function ReadPointerList(Byval processName As String, Byval baseAddress As Integer, ByVal levels As Integer, ByVal offsets() As Integer) As Integer
    
    If offsets.Length <> levels Then Throw New Exception("ReadPointerList Not enough offsets in list.  offsets.Length() != 'levels' . Silly Programmer :p")
    
    If (levels = 0) Or (offsets.Length = 0) Then
      ''not actually reading list of pointers. Just a single read. Why would the programmer call this function then :p
      Return ReadPointerInteger(processName ,baseAddress)
    Else
      Dim rtnPtr as Integer = 0
      rtnPtr = ReadPointerInteger(processName ,baseAddress)
        For xx As Int32 = 0 To levels -1
        rtnPtr = ReadPointerInteger(processName ,rtnPtr+ offsets(xx))
        Next xx
    Return rtnPtr
    End Function

    to be used as:
    Code:
    Private Const PROCESS_NAME As String = "SpiderSolitaire" '// Don't type it 20 times..you will misspell it eventually : )
    Private Const BASE_ADDRESS As Integer = &H942B8
    Private Const NEW_SCORE As Integer = 50000
    ..
    
    Dim offsetList() As Integer = {&H10, &H7C, &HC, &H40}
    Dim finalAddr As Integer = ReadPointerList(PROCESS_NAME, BASE_ADDRESS, offsetList.Length, offsetList)
    
    If finalAddr <> 0 Then
      WritePointerInteger(PROCESS_NAME, finalAddr, NEW_SCORE) '// function should be named, simply, WriteInteger()..same thing for ReadInteger..
    MessageBox.Show("SUCCESS! Score = " & NEW_SCORE.ToString() & " ?")
    Else
      MessageBox.Show("FAIL! Unable to ReadPointerList() for 0x" & BASE_ADDRESS.ToString("X"))
    End If
    Last edited by abuckau907; 10-08-2013 at 01:57 AM.
    'Some things that can be counted, don't matter. And some things that matter, can't be counted' - A.E.
    --
     

    My posts have some inaccuracies/are wrong/wrong keyword(s) used.
    They're (maybe) pretty close, and I hope they helped you, not created confusion. Take with grain of salt.

    -if you give rep, please leave a comment, else it means less.

  11. #11
    jonnyHS's Avatar
    Join Date
    May 2013
    Gender
    male
    Posts
    46
    Reputation
    10
    Thanks
    1
    My Mood
    Pensive
    To make life easier I use the translator.

    Well let's start with the first code:
    Code:
    Code:
    Dim Address As Integer = ReadPointerInteger ( "Spider Solitaire ", & HB142B8 ) Address = ReadPointerInteger ( " SpiderSolitaire " Adress + & H10 ) Address = ReadPointerInteger ( " SpiderSolitaire " Adress + & H70 )
    To answer your question of "What is 0 ? The end value of ' Address '? Does it get a correct value the first 4 times ? Check: ) " 0 = Value (not the correct) To verify that everything is properly well have been separated one by one to see that happens. The program with the module I'm using ( I'm using the first module ) can read the first part :
    Code:
    Dim Address As Integer = ReadPointerInteger ( " SpiderSolitaire ", & HB142B8 ) Address = ReadPointerInteger ( " SpiderSolitaire " Adress + & H10 )
    but to add another one :
    Dim Address As Integer = ReadPointerInteger ( " SpiderSolitaire ", & HB142B8 ) Address = ReadPointerInteger ( " SpiderSolitaire " Adress + & H10 ) Address = ReadPointerInteger ( " SpiderSolitaire " Adress + & H70 )
    is useless : L

    Your code:

    Code:
    Dim Address As Integer
    Adress = ReadPointerInteger ( " SpiderSolitaire ", & H942B8 )
    If Address = 0 Then MessageBox.Show ( " You can not [read address 0x942B8 ]" )
    Adress = ReadPointerInteger ( " SpiderSolitaire " Adress + & H10 )
    If Address = 0 Then MessageBox.Show ( " You can not [read address ptr1 + & H10 :" & ( Address + & H10 ) . ToString ( " X ") & " ]" )
    Adress = ReadPointerInteger ( " SpiderSolitaire " Adress + & H7C )
    If Address = 0 Then MessageBox.Show ( " You can not [read ptr2 + & H7C address :" & ( + & H7C Adress ) . ToString ( " X ") & " ]" )
    Adress = ReadPointerInteger ( " SpiderSolitaire " Adress + & HC )
    If Address = 0 Then MessageBox.Show ( " You can not [read address ptr3 + & HC :" & ( Address + & HC ) . ToString ( " X ") & " ]" )
    Adress = ReadPointerInteger ( " SpiderSolitaire " Adress + & H40 )
    If Address = 0 Then MessageBox.Show ( " You can not [read address ptr4 + & H40 :" & ( Address + & H10 ) . ToString ( " X ") & " ]" )
    Button1.Text = "0x " & Adress.ToString ( " X " ) '/ / . ToString ( " X ") == format as hex number. Not base 10. 0x69FB69FA == 1778084346
    also pass the same , while trying to read the second offset ERROR



    Code:
    PROCESS_NAME Private Const As String = " SpiderSolitaire " '/ / Do not type it 20 times .. Eventually you will misspell it : )
    Base_address Private Const As Integer = & H942B8
    Private Const As Integer = 50000 NEW_SCORE
    ..
    
    Dim offsetList () As Integer = {& H10, & H7C , & HC , & H40 }
    FinalAddr Dim As Integer = ReadPointerList ( PROCESS_NAME , base_address , offsetList.Length , offsetList )
    
    If finalAddr < > 0 Then
    **WritePointerInteger ( PROCESS_NAME , finalAddr , NEW_SCORE ) '/ / function Should be named , simply , WriteInteger ( ) .. same thing for ReadInteger ..
    MessageBox.Show ( "SUCCESS ! Score = " & NEW_SCORE.ToString ( ) & " ? " )
    else
    **MessageBox.Show ( "FAIL ! Unable to ReadPointerList ( ) for 0x " & BASE_ADDRESS.ToString ( " X " ) )
    End If
    Dont work :L

    PD: wich module do u think that i have to use?
    Last edited by jonnyHS; 10-08-2013 at 05:30 PM.

Similar Threads

  1. [Patched] 999-1500 exp farm with pointers by Tech and RedSpot
    By hardypro in forum Alliance of Valiant Arms (AVA) Hacks & Cheats
    Replies: 175
    Last Post: 07-24-2012, 08:55 AM
  2. no spread and player pointer and addylogger
    By norto in forum WarRock Hack Source Code
    Replies: 21
    Last Post: 03-10-2011, 12:39 PM
  3. [HELP] How do i find Local Player Pointer?
    By klofee in forum Combat Arms Hack Coding / Programming / Source Code
    Replies: 6
    Last Post: 09-20-2010, 04:44 PM
  4. [SOLVED] Some help with and kick menu!
    By Xgenzor in forum Call of Duty Modern Warfare 2 GSC Modding Help/Discussion
    Replies: 2
    Last Post: 09-11-2010, 11:16 AM
  5. [HELP PLEASE] CDetours and Device Pointer?
    By hgmf8124 in forum Combat Arms Hack Coding / Programming / Source Code
    Replies: 33
    Last Post: 08-16-2010, 09:18 AM

Tags for this Thread