ExplodeString

Last Updated2011-07-25
Created At2011-07-25

Breaks a string into pieces and stores each piece into an array of buffers.

stock int ExplodeString(const char[] text, const char[] split, char[][] buffers, int maxStrings, int maxStringLength, bool copyRemainder = false)

Parameters

const char[] text
The string to split.
const char[] split
The string to use as a split delimiter.
char[][] buffers
An array of string buffers (2D array).
int maxStrings
Number of string buffers (first dimension size).
int maxStringLength
Maximum length of each string buffer.
bool copyRemainder
False (default) discard excess pieces, true to ignore delimiters after last piece.

Return Value

int Number of strings retrieved.