plugins/include/string.inc
changeset 631 76dc2aa558e5
parent 621 5a0f5014aac1
child 634 85108309e453
     1.1 --- a/plugins/include/string.inc	Fri Mar 16 18:19:26 2007 +0000
     1.2 +++ b/plugins/include/string.inc	Fri Mar 16 20:10:13 2007 +0000
     1.3 @@ -23,7 +23,7 @@
     1.4   * and maximum length should have the null terminator INCLUDED in the length.  This means 
     1.5   * that this is valid: StrCopy(string, sizeof(string), ...)
     1.6   */
     1.7 -
     1.8 + 
     1.9  /**
    1.10   * Calculates the length of a string.
    1.11   *
    1.12 @@ -159,3 +159,17 @@
    1.13   * @return				Number of cells written to buffer.
    1.14   */
    1.15  native FloatToString(Float:num, String:str[], maxlength);
    1.16 +
    1.17 +/**
    1.18 + * Finds the first "argument" in a string; either a set of space
    1.19 + * terminated characters, or a fully quoted string.  After the 
    1.20 + * argument is found, whitespace is read until the next portion
    1.21 + * of the string is reached.  If nothing remains, -1 is returned.
    1.22 + * Otherwise, the index to the first character is returned.
    1.23 + *
    1.24 + * @param source		Source input string.
    1.25 + * @param arg			Stores argument read from string.
    1.26 + * @param argLen		Maximum length of argument buffer.
    1.27 + * @return				Index to next piece of string, or -1 if none.
    1.28 + */
    1.29 +native StrBreak(const String:source[], String:arg[], argLen);
    1.30 \ No newline at end of file