Raised This Month: $ Target: $400
 0% 

hook_say arg2


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-25-2010 , 10:19   Re: hook_say arg2
Reply With Quote #2

1st you don't need remove_quotes if you retrieve arg 1, you would need it if you would use read_args, but read_argv(1 is just fine because arg 1 is the whole text passed after say and say_team.
Well, if something is written after /command, this is the next characters to /command, you have few ways to check it.

If your command is /raport, if nothing is written later length of arg 1 is 7.

You can do :

PHP Code:
    static chat[192], len;
    
len read_argv(1chatcharsmax(chat)); 
Then if len is < 7 you know that some text is following the chat command.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
 



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 00:18.


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