2022-01-13 05:24:03 +01:00
|
|
|
/// @description main directory, parameter
|
|
|
|
#region directory
|
|
|
|
globalvar DIRECTORY;
|
2022-11-21 06:38:44 +01:00
|
|
|
DIRECTORY = environment_get_variable("userprofile") + "\\AppData\\Local\\Pixels_Composer\\";
|
2022-11-22 14:25:39 +01:00
|
|
|
if(!directory_exists(DIRECTORY))
|
|
|
|
directory_create(DIRECTORY);
|
2022-12-21 02:30:23 +01:00
|
|
|
if(!directory_exists(DIRECTORY + "temp"))
|
|
|
|
directory_create(DIRECTORY + "temp");
|
2022-11-22 14:25:39 +01:00
|
|
|
|
2022-01-25 04:05:30 +01:00
|
|
|
log_clear();
|
2022-01-13 05:24:03 +01:00
|
|
|
log_newline();
|
|
|
|
log_message("SESSION", "Begin");
|
|
|
|
log_message("DIRECTORY", DIRECTORY);
|
2022-11-22 14:25:39 +01:00
|
|
|
__init_theme();
|
2022-12-10 05:06:01 +01:00
|
|
|
__initCollection();
|
2022-09-27 06:37:28 +02:00
|
|
|
__initAssets();
|
2022-12-10 05:06:01 +01:00
|
|
|
__initPresets();
|
2022-12-16 09:18:09 +01:00
|
|
|
__initFontFolder();
|
2022-11-22 14:25:39 +01:00
|
|
|
|
|
|
|
PREF_LOAD();
|
|
|
|
loadFonts();
|
|
|
|
loadGraphic(PREF_MAP[? "theme"]);
|
|
|
|
loadColor(PREF_MAP[? "theme"]);
|
|
|
|
|
|
|
|
setPanel();
|
2022-01-13 05:24:03 +01:00
|
|
|
#endregion
|
|
|
|
|
|
|
|
#region parameter
|
|
|
|
alarm[1] = 2;
|
|
|
|
|
|
|
|
if(parameter_count() > 1) {
|
|
|
|
var path = parameter_string(1);
|
|
|
|
path = string_replace_all(path, "\n", "");
|
|
|
|
path = string_replace_all(path, "\"", "");
|
2022-11-21 06:38:44 +01:00
|
|
|
|
2022-01-13 05:24:03 +01:00
|
|
|
if(file_exists(path) && filename_ext(path) == ".pxc") {
|
|
|
|
file_open_parameter = path;
|
|
|
|
alarm[2] = 3;
|
2022-11-21 06:38:44 +01:00
|
|
|
|
|
|
|
directory_set_current_working(DIRECTORY);
|
2022-01-13 05:24:03 +01:00
|
|
|
}
|
|
|
|
}
|
2022-11-22 14:25:39 +01:00
|
|
|
#endregion
|