From d8f936f1df0b07c981a33ea3683bc649a5b6f4d0 Mon Sep 17 00:00:00 2001 From: Nunuhara Cabbage Date: Sun, 8 Jan 2023 11:34:06 -0800 Subject: [PATCH] Implement SystemService.GetGameFolderPath --- src/hll/SystemService.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/hll/SystemService.c b/src/hll/SystemService.c index 0c7810d..099efbb 100644 --- a/src/hll/SystemService.c +++ b/src/hll/SystemService.c @@ -158,7 +158,11 @@ static bool SystemService_GetMouseCursorConfig(int type, int *value) //bool SystemService_RunProgram(struct string *program_file_name, struct string *parameter); //bool SystemService_IsOpenedMutex(struct string *mutex_name); -//void SystemService_GetGameFolderPath(struct string **folder_path); + +void SystemService_GetGameFolderPath(struct string **folder_path) +{ + *folder_path = make_string(config.game_dir, strlen(config.game_dir)); +} static void SystemService_GetTime(int *hour, int *min, int *sec) { @@ -212,7 +216,7 @@ HLL_LIBRARY(SystemService, HLL_EXPORT(GetMouseCursorConfig, SystemService_GetMouseCursorConfig), HLL_TODO_EXPORT(RunProgram, SystemService_RunProgram), HLL_TODO_EXPORT(IsOpenedMutex, SystemService_IsOpenedMutex), - HLL_TODO_EXPORT(GetGameFolderPath, SystemService_GetGameFolderPath), + HLL_EXPORT(GetGameFolderPath, SystemService_GetGameFolderPath), HLL_EXPORT(GetDate, get_date), HLL_EXPORT(GetTime, SystemService_GetTime), HLL_TODO_EXPORT(IsResetOnce, SystemService_IsResetOnce),