Raised This Month: $ Target: $400
 0% 

cut arg1 from read_args(allargs,64)


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
splaTTer
Junior Member
Join Date: Jul 2004
Old 07-09-2004 , 22:07   cut arg1 from read_args(allargs,64)
Reply With Quote #1

hi,
i have a command:
amx_dgc <nick> <reason>

and i want to store the reason in a mysql database. at the moment i store <nick> and <reason> cause i don't know how to cut the <nick> from read_args. is there any way to do so?
by the way - <reason> is not only one word and i do not want to use "

thx splaTTer
splaTTer is offline
Ryan
Senior Member
Join Date: May 2004
Location: NH, USA
Old 07-09-2004 , 23:47  
Reply With Quote #2

yep, the parse() function allows you to do so..

Code:
new szArgs[288]; read_args( szArgs, 287 ); new szName[32], szReason[256]; parse( szArgs, szName, 31, szReason, 255 );

be sure to encapsulate each arg in quotes "", or else it may break them up.

Code:
amx_dgc "Ryan" "For being a super 1337 amxx h4x0r!"
Hope this helps
__________________
Warcraft 3: Expansion
Homepage | Downloads | Forums
Ryan is offline
Send a message via AIM to Ryan
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 14:48.


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