- This wiki is out of date, use the continuation of this wiki instead
Glob
From FenixWiki
Revision as of 09:02, 22 April 2007 by 63.138.247.2 (Talk)
Contents |
Definition
INT glob ( <STRING directory> )
Gets a single filename from the directory specified and keeps returning new ones on subsequent calls until it can't find any more.
Parameters
STRING directory | - The folder in which you want to look, as well as any simple requirements for filenames such as extensions. |
Returns
STRING : Returns the filename of the found file, or an empty string if it couldn't find anything.
Example
BEGIN LOOP string1=GLOB("levels\*.tul"); //looks for a file in the relative folder "levels" that has the file extension "tul". IF (string1<>"") alllevels[z]=string1; z++; ELSE numberlevels=z; BREAK; END END END