Abrimos el Visual studio y le damos a New Proyect, en el cual pones un nombre:
[You must be registered and logged in to see this image.]
Se abrirá una pantalla Click en Next->Seleccionas la opción (Aplicación Consola)->y descheckeas(No debe estar checked) el checbox de Emcabezados Precompliado.->Finalizar.
Ahora quedara asi:
[You must be registered and logged in to see this image.]
Ahora arriba de stdafx.h ponemos:
Ahora abajo de stdafx.h ponemos:
Nos quedaría asi:
Ahora Añadimos un Titulo a nuestra consola:
ahora añadimos las variables, en este caso yo usare solo 2 ustede pueden usar mas:
Añadimos un mensaje a nuestra consola y un retorno de valores:
El cin sirve para obtener el valor ingresado por teclado a la consola :3455ñ:
Ahora añadimos a nuestro código,lo ponemos arriba del main:
A nuestro código le agregamos esas funciones:
Ahora añadimos un sleep, un open process;
un write processmemory para escribir la address:
Ahora después del cambio de valores ponemos:
El código completo seria:
Ahora vas a propiedades->Vinculador->ARchivo de manifiesto->Pones RequieredAdministrador:
[You must be registered and logged in to see this image.]
Presionas F5 para compilarlo, ahora compilalo como reléase, publícalo, y Done!!
[You must be registered and logged in to see this link.]: Seyer
[You must be registered and logged in to see this link.]: no está permitido el uso de colores en comentarios y/o títulos.
[You must be registered and logged in to see this image.]
Se abrirá una pantalla Click en Next->Seleccionas la opción (Aplicación Consola)->y descheckeas(No debe estar checked) el checbox de Emcabezados Precompliado.->Finalizar.
Ahora quedara asi:
[You must be registered and logged in to see this image.]
Ahora arriba de stdafx.h ponemos:
- Code:
#include <Windows.h>
#include <TlHelp32.h>
#include <Psapi.h>
#include <iostream>
#include <string>
#include <Shlwapi.h>
#pragma comment(lib, "Shlwapi")
Ahora abajo de stdafx.h ponemos:
- Code:
using namespace std;
Nos quedaría asi:
- Code:
#include <Windows.h>
#include <TlHelp32.h>
#include <Psapi.h>
#include <iostream>
#include <string>
#include <Shlwapi.h>
#include "stdafx.h"
#pragma comment(lib, "Shlwapi")
using namespace std;
int _tmain(int argc, _TCHAR* argv[])
{
return 0;
}
Ahora Añadimos un Titulo a nuestra consola:
- Code:
int _tmain(int argc, _TCHAR* argv[])
{
SetConsoleTitleA("My titulo de mi consola");
return 0;
}
ahora añadimos las variables, en este caso yo usare solo 2 ustede pueden usar mas:
- Code:
int sp,Speed;
Añadimos un mensaje a nuestra consola y un retorno de valores:
- Code:
#include <Windows.h>
#include <TlHelp32.h>
#include <Psapi.h>
#include <iostream>
#include <string>
#include <Shlwapi.h>
#include "stdafx.h"
#pragma comment(lib, "Shlwapi")
using namespace std;
int Sp,Speed;
int _tmain(int argc, _TCHAR* argv[])
{
SetConsoleTitleA("My titulo de mi consola");
cout<<"Sp=> 1(True)/0(False)"<<"\n";
cin>>Sp;
cout<<"Speed=> 1(True)/0(False)"<<"\n";
cin>>Speed;
return 0;
}
El cin sirve para obtener el valor ingresado por teclado a la consola :3455ñ:
Ahora añadimos a nuestro código,lo ponemos arriba del main:
- Code:
DWORD HS4LProcessPid(WCHAR* ProcessName)
{
HANDLE hSnapShot;
hSnapShot=CreateToolhelp32Snapshot (TH32CS_SNAPALL,NULL);
PROCESSENTRY32 pEntry;
pEntry.dwSize =sizeof(pEntry);
Process32First (hSnapShot,&pEntry);
while(TRUE)
{
BOOL hRes=Process32Next (hSnapShot,&pEntry);
if(StrCmpW(pEntry.szExeFile,ProcessName) == 0)
{
return pEntry.th32ProcessID;
}
if(hRes==FALSE)
break;
}
return FALSE;
}
BOOL HS4LProcessExist(WCHAR* ProcessName)
{
HANDLE hSnapShot;
hSnapShot=CreateToolhelp32Snapshot (TH32CS_SNAPALL,NULL);
PROCESSENTRY32 pEntry;
pEntry.dwSize =sizeof(pEntry);
Process32First (hSnapShot,&pEntry);
while(TRUE)
{
BOOL hRes=Process32Next (hSnapShot,&pEntry);
if(StrCmpW(pEntry.szExeFile,ProcessName) == 0)
{
return TRUE;
}
if(hRes==FALSE)
break;
}
return FALSE;
}
void HS4LWaitProcess(WCHAR* ProcessName)
{
while(HS4LProcessExist(ProcessName) != TRUE){Sleep(500);};
}
A nuestro código le agregamos esas funciones:
- Code:
#include <Windows.h>
#include <TlHelp32.h>
#include <Psapi.h>
#include <iostream>
#include <string>
#include <Shlwapi.h>
#include "stdafx.h"
#pragma comment(lib, "Shlwapi")
using namespace std;
int Sp,Speed;
DWORD HS4LProcessPid(WCHAR* ProcessName)
{
HANDLE hSnapShot;
hSnapShot=CreateToolhelp32Snapshot (TH32CS_SNAPALL,NULL);
PROCESSENTRY32 pEntry;
pEntry.dwSize =sizeof(pEntry);
Process32First (hSnapShot,&pEntry);
while(TRUE)
{
BOOL hRes=Process32Next (hSnapShot,&pEntry);
if(StrCmpW(pEntry.szExeFile,ProcessName) == 0)
{
return pEntry.th32ProcessID;
}
if(hRes==FALSE)
break;
}
return FALSE;
}
BOOL HS4LProcessExist(WCHAR* ProcessName)
{
HANDLE hSnapShot;
hSnapShot=CreateToolhelp32Snapshot (TH32CS_SNAPALL,NULL);
PROCESSENTRY32 pEntry;
pEntry.dwSize =sizeof(pEntry);
Process32First (hSnapShot,&pEntry);
while(TRUE)
{
BOOL hRes=Process32Next (hSnapShot,&pEntry);
if(StrCmpW(pEntry.szExeFile,ProcessName) == 0)
{
return TRUE;
}
if(hRes==FALSE)
break;
}
return FALSE;
}
void HS4LWaitProcess(WCHAR* ProcessName)
{
while(HS4LProcessExist(ProcessName) != TRUE){Sleep(500);};
}
int _tmain(int argc, _TCHAR* argv[])
{
SetConsoleTitleA("My titulo de mi consola");
cout<<"Sp=> 1(True)/0(False)"<<"\n";
cin>>Sp;
cout<<"Speed=> 1(True)/0(False)"<<"\n";
cin>>Speed;
cout<<"Ahora abre S4..."<<"\n";
HS4LWaitProcess(L"S4Client.exe");
return 0;
}
Ahora añadimos un sleep, un open process;
- Code:
Sleep(500);
HANDLE Open = OpenProcess(PROCESS_ALL_ACCESS,false,HS4LProcessPid(L"S4Client.exe"));
un write processmemory para escribir la address:
- Code:
//inf sp
long valuesp = 2348565979;
WriteProcessMemory(Open, (LPVOID*)(DWORD)0x00481E82, &valuesp, sizeof(valuesp), NULL);
//Speed
long valuespeed = 2366073344 ;
WriteProcessMemory(Open, (LPVOID*)(DWORD)0x005DD874, &valuespeed, sizeof(valuespeed), NULL);
Ahora después del cambio de valores ponemos:
- Code:
cout<<"Done!!"<<"\n";
system("pause");
El código completo seria:
- Code:
#include <Windows.h>
#include <TlHelp32.h>
#include <Psapi.h>
#include <iostream>
#include <string>
#include <Shlwapi.h>
#include "stdafx.h"
#pragma comment(lib, "Shlwapi")
using namespace std;
int Sp,Speed;
DWORD HS4LProcessPid(WCHAR* ProcessName)
{
HANDLE hSnapShot;
hSnapShot=CreateToolhelp32Snapshot (TH32CS_SNAPALL,NULL);
PROCESSENTRY32 pEntry;
pEntry.dwSize =sizeof(pEntry);
Process32First (hSnapShot,&pEntry);
while(TRUE)
{
BOOL hRes=Process32Next (hSnapShot,&pEntry);
if(StrCmpW(pEntry.szExeFile,ProcessName) == 0)
{
return pEntry.th32ProcessID;
}
if(hRes==FALSE)
break;
}
return FALSE;
}
BOOL HS4LProcessExist(WCHAR* ProcessName)
{
HANDLE hSnapShot;
hSnapShot=CreateToolhelp32Snapshot (TH32CS_SNAPALL,NULL);
PROCESSENTRY32 pEntry;
pEntry.dwSize =sizeof(pEntry);
Process32First (hSnapShot,&pEntry);
while(TRUE)
{
BOOL hRes=Process32Next (hSnapShot,&pEntry);
if(StrCmpW(pEntry.szExeFile,ProcessName) == 0)
{
return TRUE;
}
if(hRes==FALSE)
break;
}
return FALSE;
}
void HS4LWaitProcess(WCHAR* ProcessName)
{
while(HS4LProcessExist(ProcessName) != TRUE){Sleep(500);};
}
int _tmain(int argc, _TCHAR* argv[])
{
SetConsoleTitleA("My titulo de mi consola");
cout<<"Sp=> 1(True)/0(False)"<<"\n";
cin>>Sp;
cout<<"Speed=> 1(True)/0(False)"<<"\n";
cin>>Speed;
cout<<"Ahora abre S4..."<<"\n";
HS4LWaitProcess(L"S4Client.exe");
Sleep(500);
HANDLE Open = OpenProcess(PROCESS_ALL_ACCESS,false,HS4LProcessPid(L"S4Client.exe"));
//inf sp
long valuesp = 2348565979;
WriteProcessMemory(Open, (LPVOID*)(DWORD)0x00481E82, &valuesp, sizeof(valuesp), NULL);
//Speed
long valuespeed = 2366073344 ;
WriteProcessMemory(Open, (LPVOID*)(DWORD)0x005DD874, &valuespeed, sizeof(valuespeed), NULL);
cout<<"Done!!"<<"\n";
system("pause");
return 0;
}
Ahora vas a propiedades->Vinculador->ARchivo de manifiesto->Pones RequieredAdministrador:
[You must be registered and logged in to see this image.]
Presionas F5 para compilarlo, ahora compilalo como reléase, publícalo, y Done!!
[You must be registered and logged in to see this link.]: Seyer
[You must be registered and logged in to see this link.]: no está permitido el uso de colores en comentarios y/o títulos.