U HAVE TO FOLLOW MY TUT , HOW TO SETUP SDK SUM ENZ.
This is only to learn, The CLEAN SOURCE is outdated, U could use my released source but its a small different!
CREDITS : XTREEMPJE
Adding Addies
now i gonna explain how u add a'n addie.
go to : ///////////////////////////////////////////////// Addies Here!
u will see a'n example :
Code:
#define yourhack_Addie 0x000000
Code:
#define yourhack_Addie 0x259182D #define yourhack_Addie 0x12D8FAC
Lets bool spawn :
Code:
bool spawn = false;
if you add a string you will need to change the [2] to [3] and the {1,0,0} to {1,0,0}
Lets add a spawnstring :
Code:
char spawnstring[20] = {NULL};
were done at this part. take your scrollbutton to the middle.
you will see this in the CH_menu:
Code:
sprintf(chamsstring, "Chams %s",(CH_chams ? "ON" : "OFF"));
just copy it and edit the chamsstring to your spawnstring and the CH_chams to your bool ( spawn ).
Example :
Code:
sprintf(Spawnstring, "Spawn %s",(spawn ? "ON" : "OFF"));
now below the sprintf's u see :
Code:
if(highlight[1]==1) m_pFont_INFO->DrawText(15.0f, 30.0f, textRed, chamsstring); else m_pFont_INFO->DrawText(15.0f,30.0f, textPurple, chamsstring);
Just copy it and paste it again , change the [1] to [2] and the 2x 30's to 40.
Example :
Code:
if(highlight[2]==1) m_pFont_INFO->DrawText(15.0f, 40.0f, textRed, spawnstring); else m_pFont_INFO->DrawText(15.0f,40.0f, textPurple, spawnstring);
scroll a bit down and you will see :
Code:
if(GetAsyncKeyState(VK_UP)&1) { for(int i=0; i < 2; i++) /////add +1 to menu here ,change the 2 { if (highlight[i] == 1) { int a = i-1; if(a < 0) break; else { highlight[a]=1; highlight[i]=0; break; } } } } if(GetAsyncKeyState(VK_DOWN)&1) { for(int i=0; i < 2; i++) //////same here change the 3 to +1 of menu { if (highlight[i] == 1) { int a = i+1; if(a > 1) ////amount in the menu goes here ,change the 2 break; else { highlight[a]=1; highlight[i]=0; break; } } } }
Everytime you add a cheat you need to change the :
Code:
for(int i=0; i < 2; i++) to for(int i=0; i < 3; i++)
and :
Code:
if(a > 1) to if(a > 2)
now scroll down untill u see Activate hacks on/off here.
copy :
Code:
if(highlight[1] == 1 && (GetAsyncKeyState(VK_RIGHT)&1)) CH_Chams = !CH_Chams;
and paste it again + change the CH_chams to your bool ( spawn ) + change the [1] to [2]
Example :
Code:
if(highlight[2] == 1 && (GetAsyncKeyState(VK_RIGHT)&1)) Spawn = !Spawn;
Your menu is done now!, now add the code to make the cheat working
Scroll down untill u see Make the cheat working!
Add :
Code:
;if (tSpawn); { long t=0; unsigned long Protection; VirtualProtect((void*)Spawn_Addie1, sizeof(t), PAGE_READWRITE, &Protection); memcpy((void*)Spawn_Addie1, &t , sizeof(t)); VirtualProtect((void*)Spawn_Addie1, sizeof(t), Protection, 0); VirtualProtect((void*)Spawn_Addie2, sizeof(t), PAGE_READWRITE, &Protection); memcpy((void*)Spawn_Addie2, &t , sizeof(t)); VirtualProtect((void*)Spawn_Addie2, sizeof(t), Protection, 0); }
long = WriteAlong ( memory )
t=0; = the value