Solved Help With Code.

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

olsarets7

Newbie
Full Member
Nov 15, 2014
13
92
0
I have made a triggerbot forCS:GO and I have used Fleeps ProcMem.cpp and ProcMem.h to read process memory.

The error is that LocalTeam, EnemyTeam, and EnemyHealth is undefined. I know how to fix it, but i only know 1 way. Whick would make the program read Module client.dll first, when it should read Mem.Process("csgo.exe") first. And i cant put Mem.Process outside a function.

My question is how to make it choose process before trying to read memory.

C++:
#include "ProcMem.h"
ProcMem Mem; //Shortcut

const DWORD playerBase = 0xA6DA34;
const DWORD entityBase = 0xA10324;
const DWORD crosshairOffset = 0x23F8;
/////////////////////////////////////////
const DWORD teamOffset = 0xF0;
const DWORD healthOffset = 0xFC;
const DWORD EntLoopDist = 0x10;

void trigger()

{

	if (LocalTeam != EnemyTeam) {
		mouse_event(MOUSEEVENTF_LEFTDOWN, NULL, NULL, NULL, NULL);
		//Slepp(x ms) For how long to hold down LEFTMOUSEBUTTON
		mouse_event(MOUSEEVENTF_LEFTUP, NULL, NULL, NULL, NULL);
		//Sleep(x ms) For how long to wait before shooting again
	}
	if (EnemyHealth > 0) {
		mouse_event(MOUSEEVENTF_LEFTDOWN, NULL, NULL, NULL, NULL);
		mouse_event(MOUSEEVENTF_LEFTUP, NULL, NULL, NULL, NULL);
	}
	if (LocalTeam != EnemyTeam && EnemyHealth > 0) {
		mouse_event(MOUSEEVENTF_LEFTDOWN, NULL, NULL, NULL, NULL);
		mouse_event(MOUSEEVENTF_LEFTUP, NULL, NULL, NULL, NULL);
	}
}

int main(int argc, char** argv) {
		Mem.Process("csgo.exe");
		DWORD ClientDLL = Mem.Module("client.dll");
		for (;;){
			trigger();
			Sleep(5);

			// our player
			DWORD LocalPlayer = Mem.Read<DWORD>(ClientDLL + playerBase);
			// our player's team, so we can compare it to the player in our crosshair and shoot if its not our own player's team.
			int LocalTeam = Mem.Read<int>(LocalPlayer + teamOffset);
			// our player's crosshair ID, it is used for reading what is in our crosshair
			int CrossHairID = Mem.Read<int>(LocalPlayer + crosshairOffset);

			DWORD EnemyInCH = Mem.Read<DWORD>(ClientDLL + entityBase + ((CrossHairID - 1) * EntLoopDist));
			int EnemyHealth = Mem.Read<int>(EnemyInCH + healthOffset);
			int EnemyTeam = Mem.Read<int>(EnemyInCH + teamOffset);
		}

		return 0;
	}
 

dmo

Coder
Full Member
Nobleman
Nov 8, 2014
145
678
5
You need to get the module address, i think Fleep teach a way to do it in the videos.

BTW, define a object is not a shortcut. xD
 
Last edited:

olsarets7

Newbie
Full Member
Nov 15, 2014
13
92
0
You need to get the module address, i think Fleep teach a way to do it in the videos.

BTW, define a object is not a shortcut. xD
Haha, i know that its not a shortcut. A guy on another hacking forum... made a tutorial on triggerbot for cs:go (source code and everything) Since i couldnt solve the error, I straight up copied and pasted :/
 

dmo

Coder
Full Member
Nobleman
Nov 8, 2014
145
678
5
Haha, i know that its not a shortcut. A guy on another hacking forum... made a tutorial on triggerbot for cs:go (source code and everything) Since i couldnt solve the error, I straight up copied and pasted :/
Send me a PM with the link to see what he is doing, maybe you are missing something from there.
Idk ProcMem.h, but it maybe have a functions to get Module address's.

Otherside, you need to do your own function with CreateToolhelp32Snapshot/Module32First/Module32Next .

That's problem when you copy/paste without knowledge.
You really should see Fleep's videos and learn c++ before.
 
Last edited:

olsarets7

Newbie
Full Member
Nov 15, 2014
13
92
0
Send me a PM with the link to see what he is doing, maybe you are missing something from there.
Idk ProcMem.h, but it maybe have a functions to get Module address's.

Otherside, you need to do your own function with CreateToolhelp32Snapshot/Module32First/Module32Next .

That's problem when you copy/paste without knowledge.
You really should see Fleep's videos and learn c++ before.
okay m8 :)
 

dmo

Coder
Full Member
Nobleman
Nov 8, 2014
145
678
5
Ok, first you need to update the address's..

Second, the Mem.Process is only getting the process ID and not the process memory address. So, if you want to read something that need the exe address it will not work with this function. You can use the module function to do it.]

What he is doing is: Get PID to use RPM getting the processHandle and Get process Address to RPM a offset.

You really need to learn a little of c++ and watch Fleep's videos, this tutorial that you sent is really bad to say the true.
And Fleep's have a tutorial about a trigger bot. If you need help after learn how to do the memory trigger i can help you to do it external.
 

olsarets7

Newbie
Full Member
Nov 15, 2014
13
92
0
Ok, first you need to update the address's..

Second, the Mem.Process is only getting the process ID and not the process memory address. So, if you want to read something that need the exe address it will not work with this function. You can use the module function to do it.]

What he is doing is: Get PID to use RPM getting the processHandle and Get process Address to RPM a offset.

You really need to learn a little of c++ and watch Fleep's videos, this tutorial that you sent is really bad to say the true.
And Fleep's have a tutorial about a trigger bot. If you need help after learn how to do the memory trigger i can help you to do it external.
Ok, thank you for help :)

I watched Fleeps Bhop turorial, and i got stuck when u were supposed to find the "3" in Memory View. By counting bytes. m_iHealth got 0x90. m_iTeamNum got 558... Do you know an easier way? :p Kinda offtopic but, i wondered :)
 
Last edited:

dmo

Coder
Full Member
Nobleman
Nov 8, 2014
145
678
5
Ok, thank you for help :)

I watched Fleeps Bhop turorial, and i got stuck when u were supposed to find the "3" in Memory View. By counting bytes. m_iHealth got 0x90. m_iTeamNum got 558... Do you know an easier way? :p Kinda offtopic but, i wondered :)
If i remember correctly, you need to find the correct address. Like after do everything you have 20~40 address +-, than you open one by one in memory view and count 8 bytes and see if it have 03. First time is annoying, do not stop, keep trying!
 
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