This site is no longer active, all members have migrated to devotedcheating.com . Thankyou
This site is no longer active, all members have migrated to devotedcheating.com . Thankyou
Would you like to react to this message? Create an account in a few clicks or log in to continue.



 
Actionhacks.netHomeLatest imagesRegisterLog in

 

 Basic 'Block User Input' program.

Go down 
AuthorMessage
Tate
Admin
Admin
Tate


Posts : 208
Reputation : 17
Join date : 2009-09-19
Age : 27

Basic 'Block User Input' program. Empty
PostSubject: Basic 'Block User Input' program.   Basic 'Block User Input' program. EmptyFri Nov 27, 2009 3:19 pm

This program disables the mouse and keyboard's input for 5 seconds.


first type your includes:

Code:
#include <windows.h>
#include <winable.h>
#include <stdio.h>


Next create your main: (ill put comments in)
Code:

int main()
{
Sleep(1000);//pause for 1000 milliseconds (one second), before it blocks input
BlockInput(true);//blocks input
Sleep(5000);//pauses for 5000 milliseconds (5 seconds), before it unblocks input
BlockInput(false);//unblocks input
return 0;//ends program
}

Source Code:

Code:
#include <windows.h>
#include <winable.h>
#include <stdio.h>

int main()
{
Sleep(1000);
BlockInput(true);
Sleep(5000);
BlockInput(false);
return 0;
}





You do NOT need to add
Code:
using namespace std;
for this part of the code, or at least in dev C++.

If you want to add it, that's fine, it will still work. (and you can add console commands, etc.)



This is for educational purposes only.
Back to top Go down
 
Basic 'Block User Input' program.
Back to top 
Page 1 of 1
 Similar topics
-
» Basic password lock.
» Basic fstream -- Saving files.
» Creating a Basic trainer for .exe files
» Very Basic assault cube:: Single Player Hacks

Permissions in this forum:You cannot reply to topics in this forum
 :: Public Section: Coding :: C++ :: Tutorials-
Jump to: