Re: Whos' going to make the MapRusher?
Posted: Wed Jan 19, 2011 6:57 pm
I've only read about 20% of a C++ book...
Try to code a simple Win32 console calculator that can do addition, subtraction, multiplication and division first, that's a good exercise.LBYuan wrote:The book were making me nuts!@@
Btw any exercise for it?
lol i haven siao woralbertng95 wrote:OMG.....tis gonna make me crazy reading those book = =
some part xDGuilt-Gear wrote:I haven't read those C++ books
Does it feel boring/makes you sleepy/eyes tired in the beggining when you first read it?
If I'm not wrong if you take programming in universiti you gonna read all the C++ books rite?SoullessSoul wrote:some part xDGuilt-Gear wrote:I haven't read those C++ books
Does it feel boring/makes you sleepy/eyes tired in the beggining when you first read it?
Code: Select all
bool SSMFOn = false;
void SSMFHotkey()
{
for(;;Sleep(1)){
if (GetAsyncKeyState(VK_F1)) {
if (SSMFOn == false) {
SSMFOn = true;
hSSMF = NewThread(SSMouseFly);
Form1->Label59->Caption = "Enabled";
Form1->Label59->Font->Color = clGreen;
}
if (SSMFOn == true) {
SSMFOn = false;
TerminateThread(hSSMF, 0);
Form1->Label59->Caption = "Disabled";
Form1->Label59->Font->Color = clRed;
}
}
}
}
Raiden wrote:Hey someone help me on this:Is there something wrong on the code??? I can enable it by pressing F1 but not disable it.Code: Select all
bool SSMFOn = false; void SSMFHotkey() { for(;;Sleep(1)){ if (GetAsyncKeyState(VK_F1)) { if (SSMFOn == false) { SSMFOn = true; hSSMF = NewThread(SSMouseFly); Form1->Label59->Caption = "Enabled"; Form1->Label59->Font->Color = clGreen; } if (SSMFOn == true) { SSMFOn = false; TerminateThread(hSSMF, 0); Form1->Label59->Caption = "Disabled"; Form1->Label59->Font->Color = clRed; } } } }
Language: C++ Builder (RAD Studio)
Code: Select all
BOOL SSMFOn = FALSE;
void SSMFHotkey()
{
for(;;Sleep(100))
{
if (GetAsyncKeyState(VK_F1) < 0)
{
if(!SSMFOn)
{
SSMFOn = TRUE;
hSSMF = NewThread(SSMouseFly);
Form1->Label59->Caption = "Enabled";
Form1->Label59->Font->Color = clGreen;
}
else
{
SSMFOn = FALSE;
TerminateThread(hSSMF, 0);
Form1->Label59->Caption = "Disabled";
Form1->Label59->Font->Color = clRed;
}
}
}
}
Thanks. It works. (I`m coding my bot lol)New|Life wrote:Raiden wrote:Hey someone help me on this:Is there something wrong on the code??? I can enable it by pressing F1 but not disable it.Code: Select all
bool SSMFOn = false; void SSMFHotkey() { for(;;Sleep(1)){ if (GetAsyncKeyState(VK_F1)) { if (SSMFOn == false) { SSMFOn = true; hSSMF = NewThread(SSMouseFly); Form1->Label59->Caption = "Enabled"; Form1->Label59->Font->Color = clGreen; } if (SSMFOn == true) { SSMFOn = false; TerminateThread(hSSMF, 0); Form1->Label59->Caption = "Disabled"; Form1->Label59->Font->Color = clRed; } } } }
Language: C++ Builder (RAD Studio)It would be strange that if you can enable it in the first place, logically it can't be enabled because you specified two 'if', the moment it is enabled, it will be disabled in instant.Code: Select all
BOOL SSMFOn = FALSE; void SSMFHotkey() { for(;;Sleep(100)) { if (GetAsyncKeyState(VK_F1) < 0) { if(!SSMFOn) { SSMFOn = TRUE; hSSMF = NewThread(SSMouseFly); Form1->Label59->Caption = "Enabled"; Form1->Label59->Font->Color = clGreen; } else { SSMFOn = FALSE; TerminateThread(hSSMF, 0); Form1->Label59->Caption = "Disabled"; Form1->Label59->Font->Color = clRed; } } } }