View Single Post
  #48  
Old 02-05-2014, 11:45 AM
Torankusu Torankusu is offline
Elite Member
Torankusu's Avatar
Join Date: Jun 2001
Posts: 10,065
Torankusu is a jewel in the roughTorankusu is a jewel in the rough
Quote:
Originally Posted by iDigzy View Post
Ahh, thanks for the reply anyways .

Would anyone be able to explain tokenizing to me/link me to anything on it please?
obj.tokenize([delimiters]) - splits the string into an array wherever the delimiters occur

Example:
Player chats: "This is an example"

PHP Code:
player.chat.tokenize(" "); //uses spaces as separator 
Can access tokens like this:
tokenscount (will yield 4)
tokens[0] will reference the first token (the word "this").
Similarly,
tokens[2] will reference the word "an".
__________________
Quote:
Originally posted by Spark910
Think befreo you type.
Reply With Quote