Home
Help
Search
Login
Register
Attract-Mode Support Forum
»
Attract-Mode Support
»
Scripting
»
iteration of files in directory?
« previous
next »
Print
Pages: [
1
]
Author
Topic: iteration of files in directory? (Read 18446 times)
liquid8d
Global Moderator
Sr. Member
Posts: 442
iteration of files in directory?
«
on:
December 05, 2014, 11:15:17 AM »
Is there a way to iterate through files in a directory?
I know you can use FeConfigDirectory to access specific files in there, but is there a way to get a list of files dynamically and load them with do_nut/load_module?
Logged
raygun
Administrator
Sr. Member
Posts: 393
Re: iteration of files in directory?
«
Reply #1 on:
December 06, 2014, 03:52:47 PM »
there is... the audiomode plugin reads a directory to find the audio files to play... you could do something similar to dynamically find a bunch of script files.
https://github.com/mickelson/attract/blob/master/config/plugins/AudioMode.nut
see the load_playlist function.
Logged
Print
Pages: [
1
]
« previous
next »
Attract-Mode Support Forum
»
Attract-Mode Support
»
Scripting
»
iteration of files in directory?