bueno este es un tutorial que me pidió Momantai.
Primero necesitamos la librerías(OpenProcess&MemoryWrite):
Creamos 2 Checkboxs y un button & un Timer:
Asignamos función a botton1:
Asignamos función al timer:
Codigo completo:
la address &H386938 = 00386938 ;
vBuffer = 10; Es el valor a cambiar.
Application.ExitThread();Es para cerrar automáticamente el trainer
Application.Exit();Es para cerrar automáticamente el trainer
-Tut By @Raon
Aquí esta el proyecto -> Click here to download
Primero necesitamos la librerías(OpenProcess&MemoryWrite):
- Code:
Imports System.Diagnostics
Imports System.IO
Imports System.Runtime.InteropServices
Public Class Form1
'API declarations
Private Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Integer, ByVal bInheritHandle As Integer, ByVal dwProcessId As Integer) As Integer
Private Declare Function WriteProcessMemory Lib "kernel32" Alias "WriteProcessMemory" (ByVal hProcess As Integer, ByVal lpBaseAddress As Integer, ByRef lpBuffer As Long, ByVal nSize As Integer, ByRef lpNumberOfBytesWritten As Integer) As Integer
Const PROCESS_ALL_ACCESS = &H1F0FFF
Creamos 2 Checkboxs y un button & un Timer:
Asignamos función a botton1:
- Code:
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Timer1.Enabled = True
End Sub
Asignamos función al timer:
- Code:
Private Sub Timer1_Tick(sender As Object, e As EventArgs) Handles Timer1.Tick
Dim MyP As Process() = Process.GetProcessesByName("S4Client")
If MyP.Length = 0 Then
Else
System.Threading.Thread.Sleep(700)
Dim hProcess As IntPtr = OpenProcess(PROCESS_ALL_ACCESS, 0, MyP(0).Id)
If hProcess = IntPtr.Zero Then
MessageBox.Show("Failed to open !")
Exit Sub
End If
If (CheckBox1.Checked) Then
Dim vBuffer As Long
vBuffer = 10
WriteProcessMemory(hProcess, &H386938, vBuffer, vBuffer.ToString.Length, 0)
End If
If (CheckBox2.Checked) Then
Dim vBuffer As Long
vBuffer = 10
WriteProcessMemory(hProcess, &H366F68, vBuffer, vBuffer.ToString.Length, 0)
End If
Application.ExitThread()
Application.Exit()
End If
End Sub
Codigo completo:
- Spoiler:
- Code:
Imports System.Diagnostics
Imports System.IO
Imports System.Runtime.InteropServices
Public Class Form1
'API declarations
Private Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Integer, ByVal bInheritHandle As Integer, ByVal dwProcessId As Integer) As Integer
Private Declare Function WriteProcessMemory Lib "kernel32" Alias "WriteProcessMemory" (ByVal hProcess As Integer, ByVal lpBaseAddress As Integer, ByRef lpBuffer As Long, ByVal nSize As Integer, ByRef lpNumberOfBytesWritten As Integer) As Integer
Const PROCESS_ALL_ACCESS = &H1F0FFF
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Load
End Sub
Private Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Button1.Click
Timer1.Enabled = True
End Sub
Private Sub Timer1_Tick(ByVal sender As Object, ByVal e As EventArgs) Handles Timer1.Tick
Dim MyP As Process() = Process.GetProcessesByName("S4Client")
If MyP.Length = 0 Then
Else
System.Threading.Thread.Sleep(1400)
Dim hProcess As IntPtr = OpenProcess(PROCESS_ALL_ACCESS, 0, MyP(0).Id)
If hProcess = IntPtr.Zero Then
MessageBox.Show("Failed to open !")
Exit Sub
End If
If (CheckBox1.Checked) Then
Dim vBuffer As Long
vBuffer = 2348565978
WriteProcessMemory(hProcess, &H52F004, vBuffer, vBuffer.ToString.Length, 0)
End If
If (CheckBox2.Checked) Then
Dim vBuffer As Long
vBuffer = 1970012208
WriteProcessMemory(hProcess, &H13A31B0, vBuffer, vBuffer.ToString.Length, 0)
End If
Application.ExitThread()
Application.Exit()
End If
End Sub
End Class
la address &H386938 = 00386938 ;
vBuffer = 10; Es el valor a cambiar.
Application.ExitThread();Es para cerrar automáticamente el trainer
Application.Exit();Es para cerrar automáticamente el trainer
-Tut By @Raon
Aquí esta el proyecto -> Click here to download