Modulo Trainer vb.net gratis

aca les traigo el famoso modulo para crear trainers en vb.net

Imports Microsoft.VisualBasic.CompilerServices
Imports System
Imports System.Diagnostics
Imports System.Runtime.InteropServices

Module TRAINER
    Public Function ReadByte(ByVal EXENAME As String, ByVal Address As Integer) As Byte
        Dim num As Byte = 0
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num1 As Integer = 0
                TRAINER.ReadMemoryByte(handle, Address, num, 2, num1)
            End If
        End If
        Return num
    End Function

    Public Function ReadDouble(ByVal EXENAME As String, ByVal Address As Integer) As Double
        Dim num As Double = 0
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num1 As Byte = CByte(Math.Round(num))
                Dim num2 As Integer = 0
                TRAINER.ReadMemoryByte(handle, Address, num1, 2, num2)
                num = CDbl(num1)
            End If
        End If
        Return num
    End Function

    Public Function ReadFloat(ByVal EXENAME As String, ByVal Address As Integer) As Single
        Dim [single] As Single = 0.0!
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num As Integer = 0
                TRAINER.ReadMemoryFloat(handle, Address, [single], 4, num)
            End If
        End If
        Return [single]
    End Function

    Public Function ReadInteger(ByVal EXENAME As String, ByVal Address As Integer) As Integer
        Dim num As Integer = 0
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num1 As Integer = 0
                TRAINER.ReadMemoryInteger(handle, Address, num, 4, num1)
            End If
        End If
        Return num
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="ReadProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function ReadMemoryByte(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
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="ReadProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function ReadMemoryDouble(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
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="ReadProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function ReadMemoryFloat(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
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="ReadProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function ReadMemoryInteger(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
    End Function

    Public Function ReadPointerByte(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Byte
        Dim num As Byte = 0
        Dim num1 As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num2 As Integer = 0
                While num2 < CInt(numArray.Length)
                    Dim num3 As Integer = numArray(num2)
                    num1 = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num1)
                    Pointer = Pointer + num3
                    num2 = num2 + 1
                End While
                num1 = 0
                TRAINER.ReadMemoryByte(handle, Pointer, num, 2, num1)
            End If
        End If
        Return num
    End Function

    Public Function ReadPointerDouble(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Double
        Dim num As Double = 0
        Dim num1 As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num2 As Integer = 0
                While num2 < CInt(numArray.Length)
                    Dim num3 As Integer = numArray(num2)
                    num1 = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num1)
                    Pointer = Pointer + num3
                    num2 = num2 + 1
                End While
                num1 = 0
                TRAINER.ReadMemoryDouble(handle, Pointer, num, 8, num1)
            End If
        End If
        Return num
    End Function

    Public Function ReadPointerFloat(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Single
        Dim [single] As Single = 0.0!
        Dim num As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num1 As Integer = 0
                While num1 < CInt(numArray.Length)
                    Dim num2 As Integer = numArray(num1)
                    num = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num)
                    Pointer = Pointer + num2
                    num1 = num1 + 1
                End While
                num = 0
                TRAINER.ReadMemoryFloat(handle, Pointer, [single], 4, num)
            End If
        End If
        Return [single]
    End Function

    Public Function ReadPointerInteger(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal ParamArray Offset As Integer()) As Integer
        Dim num As Integer = 0
        Dim num1 As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num2 As Integer = 0
                While num2 < CInt(numArray.Length)
                    Dim num3 As Integer = numArray(num2)
                    num1 = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num1)
                    Pointer = Pointer + num3
                    num2 = num2 + 1
                End While
                num1 = 0
                TRAINER.ReadMemoryInteger(handle, Pointer, num, 4, num1)
            End If
        End If
        Return num
    End Function

    Public Sub WriteByte(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Byte)
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num As Integer = 0
                TRAINER.WriteMemoryByte(handle, Address, Value, 2, num)
            End If
        End If
    End Sub

    Public Sub WriteDouble(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Double)
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num As Integer = 0
                TRAINER.WriteMemoryDouble(handle, Address, Value, 2, num)
            End If
        End If
    End Sub

    Public Sub WriteFloat(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Single)
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num As Integer = 0
                TRAINER.WriteMemoryFloat(handle, Address, Value, 2, num)
            End If
        End If
    End Sub

    Public Sub WriteInteger(ByVal EXENAME As String, ByVal Address As Integer, ByVal Value As Integer)
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim num As Integer = 0
                TRAINER.WriteMemoryInteger(handle, Address, Value, 4, num)
            End If
        End If
    End Sub

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="WriteProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function WriteMemoryByte(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
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="WriteProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function WriteMemoryDouble(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
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="WriteProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function WriteMemoryFloat(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
    End Function

    <DllImport("kernel32", CharSet:=CharSet.Ansi, EntryPoint:="WriteProcessMemory", ExactSpelling:=True, SetLastError:=True)>
    Private Function WriteMemoryInteger(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
    End Function

    Public Sub WritePointerByte(ByVal EXENAME As String, ByVal Pointer As Integer, ByVal Value As Byte, ByVal ParamArray Offset As Integer())
        Dim num As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num1 As Integer = 0
                While num1 < CInt(numArray.Length)
                    Dim num2 As Integer = numArray(num1)
                    num = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num)
                    Pointer = Pointer + num2
                    num1 = num1 + 1
                End While
                num = 0
                TRAINER.WriteMemoryByte(handle, Pointer, Value, 2, num)
            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())
        Dim num As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num1 As Integer = 0
                While num1 < CInt(numArray.Length)
                    Dim num2 As Integer = numArray(num1)
                    num = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num)
                    Pointer = Pointer + num2
                    num1 = num1 + 1
                End While
                num = 0
                TRAINER.WriteMemoryDouble(handle, Pointer, Value, 2, num)
            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())
        Dim num As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num1 As Integer = 0
                While num1 < CInt(numArray.Length)
                    Dim num2 As Integer = numArray(num1)
                    num = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num)
                    Pointer = Pointer + num2
                    num1 = num1 + 1
                End While
                num = 0
                TRAINER.WriteMemoryFloat(handle, Pointer, Value, 2, num)
            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())
        Dim num As Integer
        If (CInt(Process.GetProcessesByName(EXENAME).Length) <> 0) Then
            Dim handle As Integer = CInt(Process.GetProcessesByName(EXENAME)(0).Handle)
            If (handle <> 0) Then
                Dim numArray As Integer() = Offset
                Dim num1 As Integer = 0
                While num1 < CInt(numArray.Length)
                    Dim num2 As Integer = numArray(num1)
                    num = 0
                    TRAINER.ReadMemoryInteger(handle, Pointer, Pointer, 4, num)
                    Pointer = Pointer + num2
                    num1 = num1 + 1
                End While
                num = 0
                TRAINER.WriteMemoryInteger(handle, Pointer, Value, 4, num)
            End If
        End If
    End Sub
End Module
Compartir En Redes Sociales

Deja un comentario