Solved How to stop my hack when hotkey is pressed

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat
Status
Not open for further replies.

rushil

Newbie
Full Member
Mar 21, 2015
9
82
0
Hey . I have been creating teamESP hacks in a game .But recently they have patched teamESP hack. So when someone use teamesp they cannot kill their opponent because teamESP is on. So now i want to create the same hack but when i use the left mouse button to shoot the hack automatically stops so i can kill and when i let go of left mouse button it starts back . i am stuck at this part, Can anyone help me ? This is an IMG of my hack. .



C++:
#include <windows.h>

bool TeamESP = false;

void __stdcall Main()
{
	while (1)
	{
		if (GetAsyncKeyState(VK_INSERT) & 1)
		{
			if (TeamESP = !TeamESP)
			{
				TeamESP = true;
			}
			else
			{
				TeamESP = false;
			}

		}

		if (TeamESP == true)
		{
			*(BYTE*)0x00000000 = 01;
                        *(BYTE*)0x00000000 = 01;
		}
		else if (TeamESP == false)
		{
			*(BYTE*)0x00000000 = 01;
                        *(BYTE*)0x00000000 = 01;
		}
	}
}
 

Lovelace

Jr.Coder
Full Member
Nobleman
Oct 23, 2015
83
938
5
:indifferent::spoon:

C++:
#include <windows.h>
 
bool TeamESP = false;
   
void __stdcall Main()
{
    while (1)
    {
		if (GetAsyncKeyState(VK_INSERT))
		{
			TeamESP = !TeamESP;
			Sleep(300);
		}
       
		if (TeamESP && !GetAsyncKeyState(VK_LBUTTON))
		{
			// enable
		}
		else
		{
			// disable
		}
    }
}
 

Rake

Cesspool Admin
Administrator
Jan 21, 2014
12,074
78,998
2,371
C++:
#include <windows.h>
 
bool TeamESP = false;
 
void __stdcall Main()
{
    while (1)
    {

		if (!(GetAsyncKeyState(VK_LBUTTON) & 1))
		{
			if (GetAsyncKeyState(VK_INSERT) & 1)
			{
				if (TeamESP = !TeamESP)
				{
					TeamESP = true;
				}
				else
				{
					TeamESP = false;
				}
			}
	 
			if (TeamESP == true)
			{
				*(BYTE*)0x00000000 = 01;
							*(BYTE*)0x00000000 = 01;
			}
			else if (TeamESP == false)
			{
				*(BYTE*)0x00000000 = 01;
							*(BYTE*)0x00000000 = 01;
			}
		}
    }
}
 

rushil

Newbie
Full Member
Mar 21, 2015
9
82
0
Rake;43633 said:
C++:
#include <windows.h>
 
bool TeamESP = false;
 
void __stdcall Main()
{
    while (1)
    {

		if (!(GetAsyncKeyState(VK_LBUTTON) & 1))
		{
			if (GetAsyncKeyState(VK_INSERT) & 1)
			{
				if (TeamESP = !TeamESP)
				{
					TeamESP = true;
				}
				else
				{
					TeamESP = false;
				}
			}
	 
			if (TeamESP == true)
			{
				*(BYTE*)0x00000000 = 01;
							*(BYTE*)0x00000000 = 01;
			}
			else if (TeamESP == false)
			{
				*(BYTE*)0x00000000 = 01;
							*(BYTE*)0x00000000 = 01;
			}
		}
    }
}
Hey i tried but it dont work
 

Lovelace

Jr.Coder
Full Member
Nobleman
Oct 23, 2015
83
938
5
If you don't mind using using sleep between each insert key press...

C++:
#include <windows.h>

bool TeamESP = false;
  
void __stdcall Main()
{
    while (1)
    {
        if (!GetAsyncKeyState(VK_LBUTTON))
        {
            if (GetAsyncKeyState(VK_INSERT))
            {
            	TeamESP = !TeamESP;
            	Sleep(300);
            }
      
            if (TeamESP)
            {
            	// Enable hack when insert is pressed
            }
            else
            {
            	// Disable hack when insert is pressed
            }
        }
    }
}
C++:
GetAsyncKeyState(key) & 1 // This is cancer btw unless you're running this on a 16 bit DOS.
You'll achieve the same thing from this:

C++:
if (TeamESP = !TeamESP)
{
	TeamESP = true;
}
else
{
	TeamESP = false;
}
to this:

C++:
TeamESP = !TeamESP;
 

Lukor

ded
Meme Tier VIP
Fleep Tier Donator
Dec 13, 2013
488
5,353
25
Well...

C++:
if (TeamESP = !TeamESP)
i hate this so much
 

rushil

Newbie
Full Member
Mar 21, 2015
9
82
0
If you don't mind using using sleep between each insert key press...

C++:
#include <windows.h>

bool TeamESP = false;
  
void __stdcall Main()
{
    while (1)
    {
        if (!GetAsyncKeyState(VK_LBUTTON))
        {
            if (GetAsyncKeyState(VK_INSERT))
            {
            	TeamESP = !TeamESP;
            	Sleep(300);
            }
      
            if (TeamESP)
            {
            	// Enable hack when insert is pressed
            }
            else
            {
            	// Disable hack when insert is pressed
            }
        }
    }
}
C++:
GetAsyncKeyState(key) & 1 // This is cancer btw unless you're running this on a 16 bit DOS.
You'll achieve the same thing from this:

C++:
if (TeamESP = !TeamESP)
{
	TeamESP = true;
}
else
{
	TeamESP = false;
}
to this:

C++:
TeamESP = !TeamESP;
Hey . When used your code =, The hack does not off when i press left mouse button
 

rushil

Newbie
Full Member
Mar 21, 2015
9
82
0
:indifferent::spoon:

C++:
#include <windows.h>
 
bool TeamESP = false;
   
void __stdcall Main()
{
    while (1)
    {
		if (GetAsyncKeyState(VK_INSERT))
		{
			TeamESP = !TeamESP;
			Sleep(300);
		}
       
		if (TeamESP && !GetAsyncKeyState(VK_LBUTTON))
		{
			// enable
		}
		else
		{
			// disable
		}
    }
}
thanks it works :)
 
Status
Not open for further replies.
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