TinTin++ Mud Client Manual  
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
Foreach
space
Syntax: #foreach {list} {variable} {commands}
space
The foreach command works like a simplified loop. Each word in the list will be stored in the variable at execution time and can be used in the commands part.
space
Items in the provided list must either be separated by using semi-colons, or by encasing them in braces.
space
Example: #foreach {Bob;Jim;Tom} {name} {say Hello $name!}
Example: #foreach {{Bob}{Jim}{Tom}} {name} {say Hello $name!}
Both equal: say Hello Bob!;say Hello Jim!;say Hello Tom!
space
To loop through all items in a list (or a nested variable) using the foreach command use $<list>[%*].
space
Example: #foreach {$variable[%*]} {name} {say Hello $name!}