diff --git a/autogen/lua_definitions/functions.lua b/autogen/lua_definitions/functions.lua index b281c0f3..66ded312 100644 --- a/autogen/lua_definitions/functions.lua +++ b/autogen/lua_definitions/functions.lua @@ -8389,7 +8389,7 @@ function set_window_title(title) end --- @param name string ---- @return integer +--- @return ModelExtendedId function smlua_model_util_get_id(name) -- ... end diff --git a/docs/lua/functions-5.md b/docs/lua/functions-5.md index bcf9bf8f..e6009984 100644 --- a/docs/lua/functions-5.md +++ b/docs/lua/functions-5.md @@ -3034,7 +3034,7 @@ ## [smlua_model_util_get_id](#smlua_model_util_get_id) ### Lua Example -`local integerValue = smlua_model_util_get_id(name)` +`local enumValue = smlua_model_util_get_id(name)` ### Parameters | Field | Type | @@ -3042,10 +3042,10 @@ | name | `string` | ### Returns -- `integer` +[enum ModelExtendedId](constants.md#enum-ModelExtendedId) ### C Prototype -`u32 smlua_model_util_get_id(const char* name);` +`enum ModelExtendedId smlua_model_util_get_id(const char* name);` [:arrow_up_small:](#) diff --git a/src/pc/lua/utils/smlua_model_utils.c b/src/pc/lua/utils/smlua_model_utils.c index 954f5e60..c7fbaa25 100644 --- a/src/pc/lua/utils/smlua_model_utils.c +++ b/src/pc/lua/utils/smlua_model_utils.c @@ -493,7 +493,7 @@ u16 smlua_model_util_load(enum ModelExtendedId extId) { return (u16)id; } -u32 smlua_model_util_get_id(const char* name) { +enum ModelExtendedId smlua_model_util_get_id(const char* name) { // find geolayout const void* asset = dynos_geolayout_get(name); if (asset == NULL) { diff --git a/src/pc/lua/utils/smlua_model_utils.h b/src/pc/lua/utils/smlua_model_utils.h index 14e0b73d..cb6ca1fb 100644 --- a/src/pc/lua/utils/smlua_model_utils.h +++ b/src/pc/lua/utils/smlua_model_utils.h @@ -398,6 +398,6 @@ enum ModelExtendedId { void smlua_model_util_clear(void); void smlua_model_util_store_in_slot(u32 slot, const char* name); u16 smlua_model_util_load(enum ModelExtendedId extId); -u32 smlua_model_util_get_id(const char* name); +enum ModelExtendedId smlua_model_util_get_id(const char* name); #endif