Source Code Black Ops 2 nosTEAM Zombies Trainer

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

WoodenFloorBoard

Newbie
Full Member
Jan 4, 2017
13
64
0
Hello! This is the source to a simple trainer I've been working on for Black Ops 2 Zombies, nosTEAM version. I'm releasing the source since I'm too lazy to finish it and maybe some other people might find use out of the source. I'd like to also thank Rake for showing me the hack class and how to make one.

Main.cpp
C++:
#include <Windows.h>
#include <iostream>
#include "Functions.h"

/*Create Teh Hax*/
Hacks Godmode{(void*)pHealth, (PBYTE)"/xFF/x03", (PBYTE)"/x64/x00", false, 2};
Hacks Points{(void*)pPoints, (PBYTE)"/xFF/xFF", (PBYTE)"/x64/x00", false, 2};
Hacks Firerate{(void*)pWepFR, (PBYTE)"/xC9", (PBYTE)"/x00", false, 1};
Hacks Ammo1{(void*)pWepAmmo1, (PBYTE)"/xFF/x03", (PBYTE)"/x01/x00", false, 2};
Hacks Ammo2{(void*)pWepAmmo2, (PBYTE)"/xFF/x03", (PBYTE)"/x01/x00", false, 2};
Hacks Name{(void*)pIGName, (PBYTE)"^5Aye LMAO", 
						   (PBYTE)"Kurwa     ", 
						false, 10};

void Main() {
	printf("Testing..."); //Confirm injection was sucessful.
	Name.Enable();
	Points.Enable();

	while (true) {
		Godmode.Enable();
		Firerate.Enable();
		Ammo1.Enable();
		Ammo2.Enable();

		if (GetAsyncKeyState(VK_SPACE))
			Name.pStatus = !Name.pStatus;
		if (Name.pStatus) {
			Name.Enable();
		}
		else {
			Name.Disable();
		}

		Sleep(25);
	}
}

BOOL APIENTRY DllMain(HINSTANCE hModule, DWORD dwReason, LPVOID lpArgs) {
	switch (dwReason) {
	case DLL_PROCESS_ATTACH:
		AllocConsole();
		AttachConsole(GetProcessId(GetCurrentProcess()));
		freopen("CONOUT$", "w", stdout);
		CreateThread(0, 0, (LPTHREAD_START_ROUTINE)Main, 0, 0, 0);
	case DLL_PROCESS_DETACH:
		break;
	}
	return TRUE;
}

Functions.h
C++:
#include "Classes.h"

/*Addresses*/
int pHealth = 0x21C1568;
int zZombCount = 0x2330388;
int pWepFR = 0x23427EC;
int pWepAmmo1 = 0x2342BCC;
int pWepAmmo2 = 0x2342BD4;
int pWepAmmo3 = 0x2342BD8;
int pWepAmmo4 = 0x2342BDC;
int pWepGrenades = 0x2342BD0;
int pIGName = 0x2347CD4;
int pPoints = 0x2347D68;

Classes.h
C++:
/*Vector Struct*/
struct Vec3 { float x; float y; float z; };

/*Function To Write Bytes*/
void WriteBytes(void* pAddress, void* pBytes, int pSize) {
	DWORD oldProtect;
	VirtualProtect(pAddress, pSize, PAGE_EXECUTE_READWRITE, &oldProtect);
	memcpy(pAddress, pBytes, pSize);
	VirtualProtect(pAddress, pSize, oldProtect, &oldProtect);
}

/*Class To Manage Hacks*/
class Hacks {
public:
	void* pAddress; //Address of where bytes are going to be written to.
	void* pBytesOn; //Bytes to turn on hack.
	void* pBytesOff; //Bytes to turn off hack.
	bool pStatus; //Status of the hack.
	int pSize; //How much bytes are going to be written.

	//Functions for hacks.
	void Enable() {
		WriteBytes(pAddress, (PBYTE)pBytesOn, pSize);
	}

	void Disable() {
		WriteBytes(pAddress, (PBYTE)pBytesOff, pSize);
	}
};

:kappa:
 
Attention! Before you post:

Read the How to Ask Questions Guide
99% of questions are answered in the Beginner's Guide, do it before asking a question.

No Hack Requests. Post in the correct section.  Search the forum first. Read the rules.

How to make a good post:

  • Fill out the form correctly
  • Tell us the game name & coding language
  • Post everything we need to know to help you
  • Ask specific questions, be descriptive
  • Post errors, line numbers & screenshots
  • Post code snippets using code tags
  • If it's a large project, zip it up and attach it

If you do not comply, your post may be deleted.  We want to help, please make a good post and we will do our best to help you.

Community Mods