Raised This Month: $ Target: $400
 0% 

How can I turn on and off a function on the best way?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Bos93
Veteran Member
Join Date: Jul 2010
Old 07-20-2014 , 12:21   Re: How can I turn on and off a function on the best way?
Reply With Quote #1

mottzi, you can change g_Noclip to get_user_noclip ;-)
__________________
Bos93 is offline
Send a message via ICQ to Bos93 Send a message via Skype™ to Bos93
Flick3rR
Veteran Member
Join Date: Feb 2014
Location: Bulgaria, Stara Zagora
Old 07-20-2014 , 12:24   Re: How can I turn on and off a function on the best way?
Reply With Quote #2

Quote:
Originally Posted by Bos93 View Post
mottzi, you can change g_Noclip to get_user_noclip ;-)
This is true, but only for the current example, that mottzi gave. It was about the way you can detect and turn on/off the function. And actually, the best way is with bool, because it has only two values, which you can easily reverse in this way. (bool[id] = !bool[id])
__________________
Flick3rR is offline
Send a message via Skype™ to Flick3rR
NikKOo31
Senior Member
Join Date: May 2013
Location: Home
Old 07-20-2014 , 14:59   Re: How can I turn on and off a function on the best way?
Reply With Quote #3

Quote:
Originally Posted by Flick3rR View Post
This is true, but only for the current example, that mottzi gave. It was about the way you can detect and turn on/off the function. And actually, the best way is with bool, because it has only two values, which you can easily reverse in this way. (bool[id] = !bool[id])
PHP Code:
set_user_noclip(id, !get_user_noclip(id)) 
__________________
Hey ^_^
NikKOo31 is offline
Reply



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 13:06.


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