Raised This Month: $32 Target: $400
 8% 

Command count


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
sudzone
Member
Join Date: Jan 2010
Location: Bucharest
Old 05-23-2012 , 15:54   Command count
Reply With Quote #1

Hello everybody, i want add count to a command but i don't know right function... if a player used cmd of 4 time return PLUGIN_HANDLED and to player spawn reset count for command

My method reset and count to everybody not to a single player in part.
Please help me thanks
sudzone is offline
Send a message via Yahoo to sudzone
<VeCo>
Veteran Member
Join Date: Jul 2009
Location: Bulgaria
Old 05-23-2012 , 16:34   Re: Command count
Reply With Quote #2

You just need to make an array, instead of a normal variable:
PHP Code:
new user_cmdtries[33
And then increase the value with:
PHP Code:
user_cmdtries[id]++ 
And reset it on spawn with:
PHP Code:
user_cmdtries[id] = 
__________________
<VeCo> is offline
sudzone
Member
Join Date: Jan 2010
Location: Bucharest
Old 05-23-2012 , 17:03   Re: Command count
Reply With Quote #3

Thank you xD
sudzone is offline
Send a message via Yahoo to sudzone
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 10:23.


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