Raised This Month: $29 Target: $400
 7% 

Hold Button


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
JoKeR LauGh
Veteran Member
Join Date: May 2011
Location: Malaysia
Old 06-06-2012 , 02:52   Hold Button
Reply With Quote #1

Hello.

I was thinking is there a way when a player hold a button and do an action. But, how to detect if the player is holding or pressing the button for x second?

Thanks.
__________________
Quote:
Originally Posted by addons_zz View Post
Also, just to not read `the article`, read all you find. Read and read, for ever and ever. Never stop reading.
Why? Because there is not one single universal truth which holds the meaning for everything.
JoKeR LauGh is offline
<VeCo>
Veteran Member
Join Date: Jul 2009
Location: Bulgaria
Old 06-06-2012 , 07:46   Re: Hold Button
Reply With Quote #2

What button?
__________________
<VeCo> is offline
jimaway
Heeeere's Jimmy!
Join Date: Jan 2009
Location: Estonia
Old 06-06-2012 , 08:04   Re: Hold Button
Reply With Quote #3

possible with buttons that have these functions:

Code:
Button Constants 
#define IN_ATTACK		(1<<0)
#define IN_JUMP			(1<<1)
#define IN_DUCK			(1<<2)
#define IN_FORWARD		(1<<3)
#define IN_BACK			(1<<4)
#define IN_USE			(1<<5)
#define IN_CANCEL		(1<<6)
#define IN_LEFT			(1<<7)
#define IN_RIGHT		(1<<8)
#define IN_MOVELEFT		(1<<9)
#define IN_MOVERIGHT		(1<<10)
#define IN_ATTACK2		(1<<11)
#define IN_RUN			(1<<12)
#define IN_RELOAD		(1<<13)
#define IN_ALT1			(1<<14)
#define IN_SCORE		(1<<15)
jimaway is offline
JoKeR LauGh
Veteran Member
Join Date: May 2011
Location: Malaysia
Old 06-06-2012 , 08:30   Re: Hold Button
Reply With Quote #4

Quote:
Originally Posted by <VeCo> View Post
What button?
any button

@jimaway
I know all the button for CS.
__________________
Quote:
Originally Posted by addons_zz View Post
Also, just to not read `the article`, read all you find. Read and read, for ever and ever. Never stop reading.
Why? Because there is not one single universal truth which holds the meaning for everything.
JoKeR LauGh is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 06-06-2012 , 08:35   Re: Hold Button
Reply With Quote #5

It's only possible to hook the buttons listed above.
hleV is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:34.


Powered by vBulletin®
Copyright ©2000 - 2021, vBulletin Solutions, Inc.
Theme made by Freecode