2024-03-14 20:35:19 +07:00
|
|
|
function __path_get(path) {
|
|
|
|
INLINE
|
|
|
|
|
2024-05-16 09:26:35 +07:00
|
|
|
if(directory_exists(path)) return path;
|
2024-03-14 20:35:19 +07:00
|
|
|
if(file_exists_empty(path)) return path;
|
2022-12-27 19:30:02 +07:00
|
|
|
|
2024-03-14 20:35:19 +07:00
|
|
|
var local_path = $"{filename_dir(PROJECT.path)}/{path}";
|
2023-12-08 09:50:09 +07:00
|
|
|
if(file_exists_empty(local_path))
|
2022-12-27 19:30:02 +07:00
|
|
|
return local_path;
|
2022-01-13 11:24:03 +07:00
|
|
|
|
2024-05-16 15:37:44 +07:00
|
|
|
return "";
|
2024-03-14 20:35:19 +07:00
|
|
|
}
|
|
|
|
|
|
|
|
function path_get(path) {
|
|
|
|
INLINE
|
|
|
|
|
|
|
|
if(!is_array(path)) return __path_get(path);
|
|
|
|
|
|
|
|
var _res = array_create(array_length(path));
|
|
|
|
for( var i = 0, n = array_length(path); i < n; i++ )
|
|
|
|
_res[i] = __path_get(path[i]);
|
|
|
|
|
|
|
|
return _res;
|
2022-01-13 11:24:03 +07:00
|
|
|
}
|