Attract-Mode Support Forum

Attract-Mode Support => Scripting => Topic started by: zeroid on May 30, 2015, 11:00:21 AM

Title: How do i call the syntax for "folder form start-up application"?
Post by: zeroid on May 30, 2015, 11:00:21 AM
I have come to understand that "$Home" is the directory shortcut to "C:\Users\MyName\".
But what if i wanted to use the directory from Attract-mode?
e.g. "Attract-Mode\layout\" or "Attract-Mode\emulator"...

if this was coded in c# it would be "application.startuppath".
But what is it called in Squirrel?

Thanks in advance.
Title: Re: How do i call the syntax for "folder form start-up application"?
Post by: liquid8d on May 30, 2015, 01:45:39 PM
In squirrel:

FeConfigDirectory + "/path_or_file_in_am_folder"
or
fe.script_dir is a variable for the path to your layout folder if you just need that.
Title: Re: How do i call the syntax for "folder form start-up application"?
Post by: raygun on May 30, 2015, 09:28:17 PM
To add to liquid8d's note, the fe.path_expand() function is there too if you want to get the home or program files path: https://github.com/mickelson/attract/blob/master/Layouts.md#path_expand
Title: Re: How do i call the syntax for "folder form start-up application"?
Post by: zeroid on May 30, 2015, 09:38:37 PM
Thank you very much.
That helps a lot.