mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-10-30 08:01:01 +00:00
Reran autogen
This commit is contained in:
parent
4b84a87c6f
commit
36270e4301
5 changed files with 120 additions and 7 deletions
|
|
@ -52,7 +52,7 @@ in_files = [
|
||||||
"src/game/object_list_processor.h",
|
"src/game/object_list_processor.h",
|
||||||
"src/game/behavior_actions.h",
|
"src/game/behavior_actions.h",
|
||||||
"src/game/mario_misc.h",
|
"src/game/mario_misc.h",
|
||||||
"src/pc/mods/mod_storage.h"
|
"src/pc/mods/mod_storage.h",
|
||||||
"src/pc/utils/misc.h",
|
"src/pc/utils/misc.h",
|
||||||
"src/game/level_update.h"
|
"src/game/level_update.h"
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -5211,6 +5211,11 @@ function vec3f_set_dist_and_angle(from, to, dist, pitch, yaw)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- @return nil
|
||||||
|
function update_all_mario_stars()
|
||||||
|
-- ...
|
||||||
|
end
|
||||||
|
|
||||||
--- @param key string
|
--- @param key string
|
||||||
--- @return string
|
--- @return string
|
||||||
function mod_storage_load(key)
|
function mod_storage_load(key)
|
||||||
|
|
@ -5224,11 +5229,6 @@ function mod_storage_save(key, value)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @return nil
|
|
||||||
function update_all_mario_stars()
|
|
||||||
-- ...
|
|
||||||
end
|
|
||||||
|
|
||||||
--- @param courseNum integer
|
--- @param courseNum integer
|
||||||
--- @param actNum integer
|
--- @param actNum integer
|
||||||
--- @param levelNum integer
|
--- @param levelNum integer
|
||||||
|
|
|
||||||
|
|
@ -7095,10 +7095,72 @@
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
||||||
|
---
|
||||||
|
# functions from misc.h
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
||||||
|
|
||||||
|
## [update_all_mario_stars](#update_all_mario_stars)
|
||||||
|
|
||||||
|
### Lua Example
|
||||||
|
`update_all_mario_stars()`
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
- None
|
||||||
|
|
||||||
|
### Returns
|
||||||
|
- None
|
||||||
|
|
||||||
|
### C Prototype
|
||||||
|
`void update_all_mario_stars(void);`
|
||||||
|
|
||||||
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
|
<br />
|
||||||
|
|
||||||
|
---
|
||||||
|
# functions from mod_storage.h
|
||||||
|
|
||||||
|
<br />
|
||||||
|
|
||||||
|
|
||||||
|
## [mod_storage_load](#mod_storage_load)
|
||||||
|
|
||||||
|
### Lua Example
|
||||||
|
`local stringValue = mod_storage_load(key)`
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
| Field | Type |
|
||||||
|
| ----- | ---- |
|
||||||
|
| key | `string` |
|
||||||
|
|
||||||
|
### Returns
|
||||||
|
- `string`
|
||||||
|
|
||||||
|
### C Prototype
|
||||||
|
`const char *mod_storage_load(const char *key);`
|
||||||
|
|
||||||
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
|
<br />
|
||||||
|
|
||||||
|
## [mod_storage_save](#mod_storage_save)
|
||||||
|
|
||||||
|
### Lua Example
|
||||||
|
`local booleanValue = mod_storage_save(key, value)`
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
| Field | Type |
|
||||||
|
| ----- | ---- |
|
||||||
|
| key | `string` |
|
||||||
|
| value | `string` |
|
||||||
|
|
||||||
|
### Returns
|
||||||
|
- `boolean`
|
||||||
|
|
||||||
|
### C Prototype
|
||||||
|
`bool mod_storage_save(const char *key, const char *value);`
|
||||||
|
|
||||||
[:arrow_up_small:](#)
|
[:arrow_up_small:](#)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1012,6 +1012,14 @@
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
||||||
|
- misc.h
|
||||||
|
- [update_all_mario_stars](functions-3.md#update_all_mario_stars)
|
||||||
|
|
||||||
|
<br />
|
||||||
|
|
||||||
|
- mod_storage.h
|
||||||
|
- [mod_storage_load](functions-3.md#mod_storage_load)
|
||||||
|
- [mod_storage_save](functions-3.md#mod_storage_save)
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -31,9 +31,9 @@
|
||||||
#include "src/game/object_list_processor.h"
|
#include "src/game/object_list_processor.h"
|
||||||
#include "src/game/behavior_actions.h"
|
#include "src/game/behavior_actions.h"
|
||||||
#include "src/game/mario_misc.h"
|
#include "src/game/mario_misc.h"
|
||||||
|
#include "src/pc/mods/mod_storage.h"
|
||||||
#include "src/pc/utils/misc.h"
|
#include "src/pc/utils/misc.h"
|
||||||
#include "src/game/level_update.h"
|
#include "src/game/level_update.h"
|
||||||
#include "src/pc/mods/mod_storage.h"
|
|
||||||
|
|
||||||
|
|
||||||
////////////////////////
|
////////////////////////
|
||||||
|
|
@ -11719,6 +11719,43 @@ int smlua_func_vec3s_to_vec3f(lua_State* L) {
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
////////////
|
||||||
|
// misc.h //
|
||||||
|
////////////
|
||||||
|
|
||||||
|
int smlua_func_update_all_mario_stars(UNUSED lua_State* L) {
|
||||||
|
if(!smlua_functions_valid_param_count(L, 0)) { return 0; }
|
||||||
|
|
||||||
|
|
||||||
|
update_all_mario_stars();
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
///////////////////
|
||||||
|
// mod_storage.h //
|
||||||
|
///////////////////
|
||||||
|
|
||||||
|
int smlua_func_mod_storage_load(lua_State* L) {
|
||||||
|
if(!smlua_functions_valid_param_count(L, 1)) { return 0; }
|
||||||
|
|
||||||
|
const char* key = smlua_to_string(L, 1);
|
||||||
|
if (!gSmLuaConvertSuccess) { LOG_LUA("Failed to convert parameter 1 for function 'mod_storage_load'"); return 0; }
|
||||||
|
|
||||||
|
lua_pushstring(L, mod_storage_load(key));
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int smlua_func_mod_storage_save(lua_State* L) {
|
||||||
|
if(!smlua_functions_valid_param_count(L, 2)) { return 0; }
|
||||||
|
|
||||||
|
const char* key = smlua_to_string(L, 1);
|
||||||
|
if (!gSmLuaConvertSuccess) { LOG_LUA("Failed to convert parameter 1 for function 'mod_storage_save'"); return 0; }
|
||||||
|
const char* value = smlua_to_string(L, 2);
|
||||||
|
if (!gSmLuaConvertSuccess) { LOG_LUA("Failed to convert parameter 2 for function 'mod_storage_save'"); return 0; }
|
||||||
|
|
||||||
|
lua_pushboolean(L, mod_storage_save(key, value));
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
@ -19205,6 +19242,12 @@ void smlua_bind_functions_autogen(void) {
|
||||||
//smlua_bind_function(L, "vec3s_sum", smlua_func_vec3s_sum); <--- UNIMPLEMENTED
|
//smlua_bind_function(L, "vec3s_sum", smlua_func_vec3s_sum); <--- UNIMPLEMENTED
|
||||||
//smlua_bind_function(L, "vec3s_to_vec3f", smlua_func_vec3s_to_vec3f); <--- UNIMPLEMENTED
|
//smlua_bind_function(L, "vec3s_to_vec3f", smlua_func_vec3s_to_vec3f); <--- UNIMPLEMENTED
|
||||||
|
|
||||||
|
// misc.h
|
||||||
|
smlua_bind_function(L, "update_all_mario_stars", smlua_func_update_all_mario_stars);
|
||||||
|
|
||||||
|
// mod_storage.h
|
||||||
|
smlua_bind_function(L, "mod_storage_load", smlua_func_mod_storage_load);
|
||||||
|
smlua_bind_function(L, "mod_storage_save", smlua_func_mod_storage_save);
|
||||||
|
|
||||||
// network_player.h
|
// network_player.h
|
||||||
smlua_bind_function(L, "get_network_player_from_area", smlua_func_get_network_player_from_area);
|
smlua_bind_function(L, "get_network_player_from_area", smlua_func_get_network_player_from_area);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue