Solved Wrong Output

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

simonpaa

Jr.Coder
Silenced
Oct 2, 2013
55
708
0
C++:
int main(int argc, char **argv)
{	
         for (int i = 0; i < 64; i++)
	{	
	std::cout << "Waiting for csgo.exe.";

	searching->FindCSGO("Counter-Strike: Global Offensive");

	p.ClientDLL = (DWORD)find.GetModule("client.dll");	
	p.EngineDLL = (DWORD)find.GetModule("engine.dll");
	Sleep(100);

	l._user = read<DWORD>(p.ClientDLL + m_dwLocalPlayer); 
	l.Health = read<int>(l._user + m_iHealth);
	l.team = read<int>(l._user + m_iTeamNum);

        e[i]._user = read<DWORD>(p.ClientDLL + m_dwEntityList + ( i * m_loop));
	e[i].Health = read<int>(e[i]._user + m_iHealth);
	e[i].team = read<int>(e[i]._user + m_iTeamNum);

        std::cout << l.Health << endl;
        std::cout << l.team << endl;	
	std::cout << e[i].Health << endl;
	std::cout << e[i].team << endl;


	
	cin.get();
	return 0;
	}
C++:
struct Local {
        DWORD _user;   
		int Health;
		int team;	
};
Local l;

struct Entity {
        DWORD _user;   
		int Health;
		int team;	
};
Entity e[64];


When im printing the output it prints same health and team on Local and Entity. What have i done wrong ? :)
Also updated for the news offsets and addresses.
+ Post something i can use not arrogant answers :*
 
Last edited:

GAFO666

Hacker
Meme Tier VIP
Aug 19, 2012
520
3,188
23
well, it can only be either
C++:
e[i]._user = read<DWORD>(p.ClientDLL + m_dwEntityList + ( i * m_loop));
or
C++:
DWORD ent_temp = read<DWORD>(p.ClientDLL + m_dwEntityList);		
e[i]._user = read<DWORD>(ent_temp + ( i * m_loop));
Cant it ? Maybe try to print out the adress of "p.ClientDLL + m_dwEntityList" and check it manualy, you need to debug step by step then

since here:
C++:
l._user = read<DWORD>(p.ClientDLL + m_dwLocalPlayer);
l.Health = read<int>(l._user + m_iHealth);
l.team = read<int>(l._user + m_iTeamNum);
you read out first "p.ClientDLL + m_dwLocalPlayer" and then you read the result + offset :)

thatswhy i tend to

C++:
DWORD ent_temp = read<DWORD>(p.ClientDLL + m_dwEntityList);		
e[i]._user = read<DWORD>(ent_temp + ( i * m_loop));
So the entitybase is might wrong or something -


edit;
just in case , might do a check if the entity is even valid

C++:
if(!ent_temp)
return;
C++:
if (!e[i]._user)
    continue;
there might be some external functions/tools to check if a pointer is valid
 
Last edited:

GAFO666

Hacker
Meme Tier VIP
Aug 19, 2012
520
3,188
23
First of all, pls dont call out the bases within a loop.

C++:
int main(int argc, char **argv)
{  
	std::cout << "Waiting for csgo.exe."; 
	searching->FindCSGO("Counter-Strike: Global Offensive");
 
        p.ClientDLL = (DWORD)find.GetModule("client.dll"); 
        p.EngineDLL = (DWORD)find.GetModule("engine.dll");
	
	
	l._user = read<DWORD>(p.ClientDLL + m_dwLocalPlayer);
        l.Health = read<int>(l._user + m_iHealth);
        l.team = read<int>(l._user + m_iTeamNum);
	
        DWORD ent_temp = read<DWORD>(p.ClientDLL + m_dwEntityList);
    for (int i = 0; i < 64; i++)
    {   
				
                e[i]._user = read<DWORD>(ent_temp + ( i * m_loop));
		
		e[i].Health = read<int>(e[i]._user + m_iHealth);
		e[i].team = read<int>(e[i]._user + m_iTeamNum);
 
                //std::cout << "local health: " << l.Health << endl;
                //std::cout << "local team: " << l.team << endl;   
		std::cout << "enity[" << i << "] health: " << e[i].Health << endl;
		std::cout << "enity[" << i << "] team: " << e[i].team << endl;
	}
 
     
	cin.get();
	return 0;
}

However I assume that you need to read out the entity external in two stages, depense how the reading works tho
C++:
DWORD ent_temp = read<DWORD>(p.ClientDLL + m_dwEntityList);		
e[i]._user = read<DWORD>(ent_temp + ( i * m_loop));
- I only work internal and never did something external -
- So it might be wrong. -
 
Last edited:

simonpaa

Jr.Coder
Silenced
Oct 2, 2013
55
708
0
I manage to solved the problem by doing :

C++:
DWORD ent_temp = read<DWORD>(p.ClientDLL + m_dwEntityList);
to:
C++:
DWORD ent_temp = (p.ClientDLL + m_dwEntityList);

also

C++:
for (int i = 0; i < 64; i++)
to

C++:
for (int i = 1; i < 64; i++)
But srlsly thx for trying helping me man +rep :)!
 
Last edited:

GAFO666

Hacker
Meme Tier VIP
Aug 19, 2012
520
3,188
23
I manage to solved the problem by doing :

DWORD ent_temp = read<DWORD>(p.ClientDLL + m_dwEntityList);

to:
DWORD ent_temp = (p.ClientDLL + m_dwEntityList);


But srlsly thx for trying helping me man +rep :)!
aaaah , then the casting to dword missed before reading (or at least some brackets .. xD ) :) alright then

C++:
e[i]._user = read<DWORD>((DWORD)(p.ClientDLL + m_dwEntityList) + ( i * m_loop));
 
Last edited:

mambda

headass
Escobar Tier VIP
Trump Tier Donator
Jun 25, 2014
2,298
37,938
269
nah it wasnt a dword cast its because he was reading the entList at the first index rather than just adding the addresses together, common mistake for csgo the first few times around really
 
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