From 58de87d1c1c82b969bfc0b79f7fe95765655cc91 Mon Sep 17 00:00:00 2001 From: John S <138552829+Multi-Volt@users.noreply.github.com> Date: Sat, 7 Dec 2024 16:06:27 -0500 Subject: [PATCH] Documentation of area.h and characters.h (#548) * Documentation of characters.h Documenting characters.h * Add documentation to Area.h * Redo autogen for new descriptions --- autogen/lua_definitions/functions.lua | 8 + docs/lua/functions-2.md | 4 +- docs/lua/functions-3.md | 277 +- docs/lua/functions-4.md | 4956 +------------------ docs/lua/functions-5.md | 6542 ++++++++++++++++++------- docs/lua/functions-6.md | 1851 +++++++ docs/lua/functions.md | 672 +-- src/game/area.h | 10 + src/game/characters.h | 31 +- 9 files changed, 7215 insertions(+), 7136 deletions(-) create mode 100644 docs/lua/functions-6.md diff --git a/autogen/lua_definitions/functions.lua b/autogen/lua_definitions/functions.lua index 4812d866a..5ab102ac1 100644 --- a/autogen/lua_definitions/functions.lua +++ b/autogen/lua_definitions/functions.lua @@ -2,12 +2,14 @@ --- @param id integer --- @return ObjectWarpNode +--- Finds a warp node in the current area by its ID. The warp node must exist in the list of warp nodes for the current area. Useful for locating a specific warp point in the level, such as teleportation zones or connections to other areas. function area_get_warp_node(id) -- ... end --- @param o Object --- @return ObjectWarpNode +--- Finds a warp node in the current area using parameters from the provided object. The object's behavior parameters are used to determine the warp node ID. Useful for associating an object (like a door or warp pipe) with its corresponding warp node in the area. function area_get_warp_node_from_params(o) -- ... end @@ -3007,18 +3009,21 @@ end --- @param m MarioState --- @param characterAnim CharacterAnimID --- @return integer +--- Gets the animation ID to use for a specific character and animation combination. The ID is based on `characterAnim` and the character currently controlled by Mario (`m`). Useful for determining which animation to play for actions like walking, jumping, or idle states function get_character_anim(m, characterAnim) -- ... end --- @param m MarioState --- @return number +--- Calculates the animation offset for Mario's current animation. The offset is determined by the type of animation being played (e.g., hand, feet, or torso movement). Useful for smoothly syncing Mario's model height or positional adjustments during animations function get_character_anim_offset(m) -- ... end --- @param m MarioState --- @param characterSound CharacterSound +--- Plays a character-specific sound based on the given `characterSound` value. The sound is tied to Mario's current state (`m`). Useful for triggering sound effects for actions like jumping or interacting with the environment function play_character_sound(m, characterSound) -- ... end @@ -3026,6 +3031,7 @@ end --- @param m MarioState --- @param characterSound CharacterSound --- @param flags integer +--- Plays a character-specific sound only if certain flags are not set. This ensures that sounds are not repeated unnecessarily. The sound is based on `characterSound`, and the flags are checked using `flags`. Useful for avoiding duplicate sound effects in rapid succession or conditional actions function play_character_sound_if_no_flag(m, characterSound, flags) -- ... end @@ -3033,11 +3039,13 @@ end --- @param m MarioState --- @param characterSound CharacterSound --- @param offset integer +--- Plays a character-specific sound with an additional `offset`, allowing variations or delays in the sound effect. Uses Mario's current state (`m`). Useful for adding dynamic sound effects or syncing sounds to specific animations or events function play_character_sound_offset(m, characterSound, offset) -- ... end --- @param m MarioState +--- Updates Mario's current animation offset. This adjusts Mario's position based on the calculated offset to ensure animations appear smooth and natural. Useful for keeping Mario's animations visually aligned, particularly when transitioning between animations function update_character_anim_offset(m) -- ... end diff --git a/docs/lua/functions-2.md b/docs/lua/functions-2.md index a0b6a61e1..fad7d1aa8 100644 --- a/docs/lua/functions-2.md +++ b/docs/lua/functions-2.md @@ -2,7 +2,7 @@ --- -[< prev](functions.md) | [1](functions.md) | 2 | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [next >](functions-3.md)] +[< prev](functions.md) | [1](functions.md) | 2 | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-3.md)] --- @@ -10572,5 +10572,5 @@
--- -[< prev](functions.md) | [1](functions.md) | 2 | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [next >](functions-3.md)] +[< prev](functions.md) | [1](functions.md) | 2 | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-3.md)] diff --git a/docs/lua/functions-3.md b/docs/lua/functions-3.md index 6212573b7..7c894d7bf 100644 --- a/docs/lua/functions-3.md +++ b/docs/lua/functions-3.md @@ -2,7 +2,7 @@ --- -[< prev](functions-2.md) | [1](functions.md) | [2](functions-2.md) | 3 | [4](functions-4.md) | [5](functions-5.md) | [next >](functions-4.md)] +[< prev](functions-2.md) | [1](functions.md) | [2](functions-2.md) | 3 | [4](functions-4.md) | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-4.md)] --- @@ -1918,6 +1918,9 @@ ## [get_character_anim](#get_character_anim) +### Description +Gets the animation ID to use for a specific character and animation combination. The ID is based on `characterAnim` and the character currently controlled by Mario (`m`). Useful for determining which animation to play for actions like walking, jumping, or idle states + ### Lua Example `local integerValue = get_character_anim(m, characterAnim)` @@ -1939,6 +1942,9 @@ ## [get_character_anim_offset](#get_character_anim_offset) +### Description +Calculates the animation offset for Mario's current animation. The offset is determined by the type of animation being played (e.g., hand, feet, or torso movement). Useful for smoothly syncing Mario's model height or positional adjustments during animations + ### Lua Example `local numberValue = get_character_anim_offset(m)` @@ -1959,6 +1965,9 @@ ## [play_character_sound](#play_character_sound) +### Description +Plays a character-specific sound based on the given `characterSound` value. The sound is tied to Mario's current state (`m`). Useful for triggering sound effects for actions like jumping or interacting with the environment + ### Lua Example `play_character_sound(m, characterSound)` @@ -1980,6 +1989,9 @@ ## [play_character_sound_if_no_flag](#play_character_sound_if_no_flag) +### Description +Plays a character-specific sound only if certain flags are not set. This ensures that sounds are not repeated unnecessarily. The sound is based on `characterSound`, and the flags are checked using `flags`. Useful for avoiding duplicate sound effects in rapid succession or conditional actions + ### Lua Example `play_character_sound_if_no_flag(m, characterSound, flags)` @@ -2002,6 +2014,9 @@ ## [play_character_sound_offset](#play_character_sound_offset) +### Description +Plays a character-specific sound with an additional `offset`, allowing variations or delays in the sound effect. Uses Mario's current state (`m`). Useful for adding dynamic sound effects or syncing sounds to specific animations or events + ### Lua Example `play_character_sound_offset(m, characterSound, offset)` @@ -2024,6 +2039,9 @@ ## [update_character_anim_offset](#update_character_anim_offset) +### Description +Updates Mario's current animation offset. This adjusts Mario's position based on the calculated offset to ensure animations appear smooth and natural. Useful for keeping Mario's animations visually aligned, particularly when transitioning between animations + ### Lua Example `update_character_anim_offset(m)` @@ -8394,263 +8412,8 @@ [:arrow_up_small:](#) -
- ---- -# functions from mario_step.h - -
- - -## [get_additive_y_vel_for_jumps](#get_additive_y_vel_for_jumps) - -### Lua Example -`local numberValue = get_additive_y_vel_for_jumps()` - -### Parameters -- None - -### Returns -- `number` - -### C Prototype -`f32 get_additive_y_vel_for_jumps(void);` - -[:arrow_up_small:](#) - -
- -## [init_bully_collision_data](#init_bully_collision_data) - -### Lua Example -`init_bully_collision_data(data, posX, posZ, forwardVel, yaw, conversionRatio, radius)` - -### Parameters -| Field | Type | -| ----- | ---- | -| data | [BullyCollisionData](structs.md#BullyCollisionData) | -| posX | `number` | -| posZ | `number` | -| forwardVel | `number` | -| yaw | `integer` | -| conversionRatio | `number` | -| radius | `number` | - -### Returns -- None - -### C Prototype -`void init_bully_collision_data(struct BullyCollisionData *data, f32 posX, f32 posZ, f32 forwardVel, s16 yaw, f32 conversionRatio, f32 radius);` - -[:arrow_up_small:](#) - -
- -## [mario_bonk_reflection](#mario_bonk_reflection) - -### Lua Example -`mario_bonk_reflection(arg0, arg1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | -| arg1 | `integer` | - -### Returns -- None - -### C Prototype -`void mario_bonk_reflection(struct MarioState *, u32);` - -[:arrow_up_small:](#) - -
- -## [mario_push_off_steep_floor](#mario_push_off_steep_floor) - -### Lua Example -`local integerValue = mario_push_off_steep_floor(arg0, arg1, arg2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | -| arg1 | `integer` | -| arg2 | `integer` | - -### Returns -- `integer` - -### C Prototype -`u32 mario_push_off_steep_floor(struct MarioState *, u32, u32);` - -[:arrow_up_small:](#) - -
- -## [mario_update_moving_sand](#mario_update_moving_sand) - -### Lua Example -`local integerValue = mario_update_moving_sand(arg0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | - -### Returns -- `integer` - -### C Prototype -`u32 mario_update_moving_sand(struct MarioState *);` - -[:arrow_up_small:](#) - -
- -## [mario_update_quicksand](#mario_update_quicksand) - -### Lua Example -`local integerValue = mario_update_quicksand(arg0, arg1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | -| arg1 | `number` | - -### Returns -- `integer` - -### C Prototype -`u32 mario_update_quicksand(struct MarioState *, f32);` - -[:arrow_up_small:](#) - -
- -## [mario_update_windy_ground](#mario_update_windy_ground) - -### Lua Example -`local integerValue = mario_update_windy_ground(arg0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | - -### Returns -- `integer` - -### C Prototype -`u32 mario_update_windy_ground(struct MarioState *);` - -[:arrow_up_small:](#) - -
- -## [perform_air_step](#perform_air_step) - -### Lua Example -`local integerValue = perform_air_step(arg0, arg1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | -| arg1 | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 perform_air_step(struct MarioState *, u32);` - -[:arrow_up_small:](#) - -
- -## [perform_ground_step](#perform_ground_step) - -### Lua Example -`local integerValue = perform_ground_step(arg0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | - -### Returns -- `integer` - -### C Prototype -`s32 perform_ground_step(struct MarioState *);` - -[:arrow_up_small:](#) - -
- -## [set_vel_from_pitch_and_yaw](#set_vel_from_pitch_and_yaw) - -### Lua Example -`set_vel_from_pitch_and_yaw(m)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | - -### Returns -- None - -### C Prototype -`void set_vel_from_pitch_and_yaw(struct MarioState* m);` - -[:arrow_up_small:](#) - -
- -## [stationary_ground_step](#stationary_ground_step) - -### Lua Example -`local integerValue = stationary_ground_step(arg0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | - -### Returns -- `integer` - -### C Prototype -`s32 stationary_ground_step(struct MarioState *);` - -[:arrow_up_small:](#) - -
- -## [stop_and_set_height_to_floor](#stop_and_set_height_to_floor) - -### Lua Example -`stop_and_set_height_to_floor(arg0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| arg0 | [MarioState](structs.md#MarioState) | - -### Returns -- None - -### C Prototype -`void stop_and_set_height_to_floor(struct MarioState *);` - -[:arrow_up_small:](#) -
--- -[< prev](functions-2.md) | [1](functions.md) | [2](functions-2.md) | 3 | [4](functions-4.md) | [5](functions-5.md) | [next >](functions-4.md)] +[< prev](functions-2.md) | [1](functions.md) | [2](functions-2.md) | 3 | [4](functions-4.md) | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-4.md)] diff --git a/docs/lua/functions-4.md b/docs/lua/functions-4.md index 1ba964acc..876ad6c66 100644 --- a/docs/lua/functions-4.md +++ b/docs/lua/functions-4.md @@ -2,9 +2,264 @@ --- -[< prev](functions-3.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | 4 | [5](functions-5.md) | [next >](functions-5.md)] +[< prev](functions-3.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | 4 | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-5.md)] +--- +# functions from mario_step.h + +
+ + +## [get_additive_y_vel_for_jumps](#get_additive_y_vel_for_jumps) + +### Lua Example +`local numberValue = get_additive_y_vel_for_jumps()` + +### Parameters +- None + +### Returns +- `number` + +### C Prototype +`f32 get_additive_y_vel_for_jumps(void);` + +[:arrow_up_small:](#) + +
+ +## [init_bully_collision_data](#init_bully_collision_data) + +### Lua Example +`init_bully_collision_data(data, posX, posZ, forwardVel, yaw, conversionRatio, radius)` + +### Parameters +| Field | Type | +| ----- | ---- | +| data | [BullyCollisionData](structs.md#BullyCollisionData) | +| posX | `number` | +| posZ | `number` | +| forwardVel | `number` | +| yaw | `integer` | +| conversionRatio | `number` | +| radius | `number` | + +### Returns +- None + +### C Prototype +`void init_bully_collision_data(struct BullyCollisionData *data, f32 posX, f32 posZ, f32 forwardVel, s16 yaw, f32 conversionRatio, f32 radius);` + +[:arrow_up_small:](#) + +
+ +## [mario_bonk_reflection](#mario_bonk_reflection) + +### Lua Example +`mario_bonk_reflection(arg0, arg1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | +| arg1 | `integer` | + +### Returns +- None + +### C Prototype +`void mario_bonk_reflection(struct MarioState *, u32);` + +[:arrow_up_small:](#) + +
+ +## [mario_push_off_steep_floor](#mario_push_off_steep_floor) + +### Lua Example +`local integerValue = mario_push_off_steep_floor(arg0, arg1, arg2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | +| arg1 | `integer` | +| arg2 | `integer` | + +### Returns +- `integer` + +### C Prototype +`u32 mario_push_off_steep_floor(struct MarioState *, u32, u32);` + +[:arrow_up_small:](#) + +
+ +## [mario_update_moving_sand](#mario_update_moving_sand) + +### Lua Example +`local integerValue = mario_update_moving_sand(arg0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | + +### Returns +- `integer` + +### C Prototype +`u32 mario_update_moving_sand(struct MarioState *);` + +[:arrow_up_small:](#) + +
+ +## [mario_update_quicksand](#mario_update_quicksand) + +### Lua Example +`local integerValue = mario_update_quicksand(arg0, arg1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | +| arg1 | `number` | + +### Returns +- `integer` + +### C Prototype +`u32 mario_update_quicksand(struct MarioState *, f32);` + +[:arrow_up_small:](#) + +
+ +## [mario_update_windy_ground](#mario_update_windy_ground) + +### Lua Example +`local integerValue = mario_update_windy_ground(arg0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | + +### Returns +- `integer` + +### C Prototype +`u32 mario_update_windy_ground(struct MarioState *);` + +[:arrow_up_small:](#) + +
+ +## [perform_air_step](#perform_air_step) + +### Lua Example +`local integerValue = perform_air_step(arg0, arg1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | +| arg1 | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 perform_air_step(struct MarioState *, u32);` + +[:arrow_up_small:](#) + +
+ +## [perform_ground_step](#perform_ground_step) + +### Lua Example +`local integerValue = perform_ground_step(arg0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | + +### Returns +- `integer` + +### C Prototype +`s32 perform_ground_step(struct MarioState *);` + +[:arrow_up_small:](#) + +
+ +## [set_vel_from_pitch_and_yaw](#set_vel_from_pitch_and_yaw) + +### Lua Example +`set_vel_from_pitch_and_yaw(m)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | + +### Returns +- None + +### C Prototype +`void set_vel_from_pitch_and_yaw(struct MarioState* m);` + +[:arrow_up_small:](#) + +
+ +## [stationary_ground_step](#stationary_ground_step) + +### Lua Example +`local integerValue = stationary_ground_step(arg0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | + +### Returns +- `integer` + +### C Prototype +`s32 stationary_ground_step(struct MarioState *);` + +[:arrow_up_small:](#) + +
+ +## [stop_and_set_height_to_floor](#stop_and_set_height_to_floor) + +### Lua Example +`stop_and_set_height_to_floor(arg0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| arg0 | [MarioState](structs.md#MarioState) | + +### Returns +- None + +### C Prototype +`void stop_and_set_height_to_floor(struct MarioState *);` + +[:arrow_up_small:](#) + +
+ --- # functions from math_util.h @@ -3564,4705 +3819,8 @@ Converts a 3D signed-integer vector `a` (vec3s) into a 3D floating-point vector [:arrow_up_small:](#) -
- ---- -# functions from object_helpers.c - -
- - -## [abs_angle_diff](#abs_angle_diff) - -### Lua Example -`local integerValue = abs_angle_diff(x0, x1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x0 | `integer` | -| x1 | `integer` | - -### Returns -- `integer` - -### C Prototype -`s16 abs_angle_diff(s16 x0, s16 x1);` - -[:arrow_up_small:](#) - -
- -## [apply_drag_to_value](#apply_drag_to_value) - -### Lua Example -`apply_drag_to_value(value, dragStrength)` - -### Parameters -| Field | Type | -| ----- | ---- | -| value | `Pointer` <`number`> | -| dragStrength | `number` | - -### Returns -- None - -### C Prototype -`void apply_drag_to_value(f32 *value, f32 dragStrength);` - -[:arrow_up_small:](#) - -
- -## [approach_f32_signed](#approach_f32_signed) - -### Lua Example -`local integerValue = approach_f32_signed(value, target, increment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| value | `Pointer` <`number`> | -| target | `number` | -| increment | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 approach_f32_signed(f32 *value, f32 target, f32 increment);` - -[:arrow_up_small:](#) - -
- -## [approach_f32_symmetric](#approach_f32_symmetric) - -### Lua Example -`local numberValue = approach_f32_symmetric(value, target, increment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| value | `number` | -| target | `number` | -| increment | `number` | - -### Returns -- `number` - -### C Prototype -`f32 approach_f32_symmetric(f32 value, f32 target, f32 increment);` - -[:arrow_up_small:](#) - -
- -## [approach_s16_symmetric](#approach_s16_symmetric) - -### Lua Example -`local integerValue = approach_s16_symmetric(value, target, increment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| value | `integer` | -| target | `integer` | -| increment | `integer` | - -### Returns -- `integer` - -### C Prototype -`s16 approach_s16_symmetric(s16 value, s16 target, s16 increment);` - -[:arrow_up_small:](#) - -
- -## [bhv_dust_smoke_loop](#bhv_dust_smoke_loop) - -### Lua Example -`bhv_dust_smoke_loop()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void bhv_dust_smoke_loop(void);` - -[:arrow_up_small:](#) - -
- -## [bhv_init_room](#bhv_init_room) - -### Lua Example -`bhv_init_room()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void bhv_init_room(void);` - -[:arrow_up_small:](#) - -
- -## [bit_shift_left](#bit_shift_left) - -### Lua Example -`local integerValue = bit_shift_left(a0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 bit_shift_left(s32 a0);` - -[:arrow_up_small:](#) - -
- -## [chain_segment_init](#chain_segment_init) - -### Lua Example -`chain_segment_init(segment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| segment | [ChainSegment](structs.md#ChainSegment) | - -### Returns -- None - -### C Prototype -`void chain_segment_init(struct ChainSegment *segment);` - -[:arrow_up_small:](#) - -
- -## [clear_move_flag](#clear_move_flag) - -### Lua Example -`local integerValue = clear_move_flag(bitSet, flag)` - -### Parameters -| Field | Type | -| ----- | ---- | -| bitSet | `Pointer` <`integer`> | -| flag | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 clear_move_flag(u32 *bitSet, s32 flag);` - -[:arrow_up_small:](#) - -
- -## [clear_time_stop_flags](#clear_time_stop_flags) - -### Lua Example -`clear_time_stop_flags(flags)` - -### Parameters -| Field | Type | -| ----- | ---- | -| flags | `integer` | - -### Returns -- None - -### C Prototype -`void clear_time_stop_flags(s32 flags);` - -[:arrow_up_small:](#) - -
- -## [count_objects_with_behavior](#count_objects_with_behavior) - -### Lua Example -`local integerValue = count_objects_with_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- `integer` - -### C Prototype -`s32 count_objects_with_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [count_unimportant_objects](#count_unimportant_objects) - -### Lua Example -`local integerValue = count_unimportant_objects()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 count_unimportant_objects(void);` - -[:arrow_up_small:](#) - -
- -## [create_transformation_from_matrices](#create_transformation_from_matrices) - -### Lua Example -`create_transformation_from_matrices(a0, a1, a2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `Mat4` | -| a1 | `Mat4` | -| a2 | `Mat4` | - -### Returns -- None - -### C Prototype -`void create_transformation_from_matrices(Mat4 a0, Mat4 a1, Mat4 a2);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_abs_y_dist_to_home](#cur_obj_abs_y_dist_to_home) - -### Lua Example -`local numberValue = cur_obj_abs_y_dist_to_home()` - -### Parameters -- None - -### Returns -- `number` - -### C Prototype -`f32 cur_obj_abs_y_dist_to_home(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_advance_looping_anim](#cur_obj_advance_looping_anim) - -### Lua Example -`local integerValue = cur_obj_advance_looping_anim()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_advance_looping_anim(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_align_gfx_with_floor](#cur_obj_align_gfx_with_floor) - -### Lua Example -`cur_obj_align_gfx_with_floor()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_align_gfx_with_floor(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_angle_to_home](#cur_obj_angle_to_home) - -### Lua Example -`local integerValue = cur_obj_angle_to_home()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s16 cur_obj_angle_to_home(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_apply_drag_xz](#cur_obj_apply_drag_xz) - -### Lua Example -`cur_obj_apply_drag_xz(dragStrength)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dragStrength | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_apply_drag_xz(f32 dragStrength);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_become_intangible](#cur_obj_become_intangible) - -### Lua Example -`cur_obj_become_intangible()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_become_intangible(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_become_tangible](#cur_obj_become_tangible) - -### Lua Example -`cur_obj_become_tangible()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_become_tangible(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_can_mario_activate_textbox](#cur_obj_can_mario_activate_textbox) - -### Lua Example -`local integerValue = cur_obj_can_mario_activate_textbox(m, radius, height, unused)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | -| radius | `number` | -| height | `number` | -| unused | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_can_mario_activate_textbox(struct MarioState* m, f32 radius, f32 height, UNUSED s32 unused);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_can_mario_activate_textbox_2](#cur_obj_can_mario_activate_textbox_2) - -### Lua Example -`local integerValue = cur_obj_can_mario_activate_textbox_2(m, radius, height)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | -| radius | `number` | -| height | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_can_mario_activate_textbox_2(struct MarioState* m, f32 radius, f32 height);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_change_action](#cur_obj_change_action) - -### Lua Example -`cur_obj_change_action(action)` - -### Parameters -| Field | Type | -| ----- | ---- | -| action | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_change_action(s32 action);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_anim_frame](#cur_obj_check_anim_frame) - -### Lua Example -`local integerValue = cur_obj_check_anim_frame(frame)` - -### Parameters -| Field | Type | -| ----- | ---- | -| frame | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_anim_frame(s32 frame);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_anim_frame_in_range](#cur_obj_check_anim_frame_in_range) - -### Lua Example -`local integerValue = cur_obj_check_anim_frame_in_range(startFrame, rangeLength)` - -### Parameters -| Field | Type | -| ----- | ---- | -| startFrame | `integer` | -| rangeLength | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_anim_frame_in_range(s32 startFrame, s32 rangeLength);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_frame_prior_current_frame](#cur_obj_check_frame_prior_current_frame) - -### Lua Example -`local integerValue = cur_obj_check_frame_prior_current_frame(a0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `Pointer` <`integer`> | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_frame_prior_current_frame(s16 *a0);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_grabbed_mario](#cur_obj_check_grabbed_mario) - -### Lua Example -`local integerValue = cur_obj_check_grabbed_mario()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_grabbed_mario(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_if_at_animation_end](#cur_obj_check_if_at_animation_end) - -### Lua Example -`local integerValue = cur_obj_check_if_at_animation_end()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_if_at_animation_end(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_if_near_animation_end](#cur_obj_check_if_near_animation_end) - -### Lua Example -`local integerValue = cur_obj_check_if_near_animation_end()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_if_near_animation_end(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_check_interacted](#cur_obj_check_interacted) - -### Lua Example -`local integerValue = cur_obj_check_interacted()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_check_interacted(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_clear_interact_status_flag](#cur_obj_clear_interact_status_flag) - -### Lua Example -`local integerValue = cur_obj_clear_interact_status_flag(flag)` - -### Parameters -| Field | Type | -| ----- | ---- | -| flag | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_clear_interact_status_flag(s32 flag);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_compute_vel_xz](#cur_obj_compute_vel_xz) - -### Lua Example -`cur_obj_compute_vel_xz()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_compute_vel_xz(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_count_objects_with_behavior](#cur_obj_count_objects_with_behavior) - -### Lua Example -`local integerValue = cur_obj_count_objects_with_behavior(behavior, dist)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | -| dist | `number` | - -### Returns -- `integer` - -### C Prototype -`u16 cur_obj_count_objects_with_behavior(const BehaviorScript* behavior, f32 dist);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_detect_steep_floor](#cur_obj_detect_steep_floor) - -### Lua Example -`local integerValue = cur_obj_detect_steep_floor(steepAngleDegrees)` - -### Parameters -| Field | Type | -| ----- | ---- | -| steepAngleDegrees | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_detect_steep_floor(s16 steepAngleDegrees);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_disable](#cur_obj_disable) - -### Lua Example -`cur_obj_disable()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_disable(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_disable_rendering](#cur_obj_disable_rendering) - -### Lua Example -`cur_obj_disable_rendering()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_disable_rendering(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_disable_rendering_and_become_intangible](#cur_obj_disable_rendering_and_become_intangible) - -### Lua Example -`cur_obj_disable_rendering_and_become_intangible(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void cur_obj_disable_rendering_and_become_intangible(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_dist_to_nearest_object_with_behavior](#cur_obj_dist_to_nearest_object_with_behavior) - -### Lua Example -`local numberValue = cur_obj_dist_to_nearest_object_with_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- `number` - -### C Prototype -`f32 cur_obj_dist_to_nearest_object_with_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_enable_rendering](#cur_obj_enable_rendering) - -### Lua Example -`cur_obj_enable_rendering()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_enable_rendering(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_enable_rendering_2](#cur_obj_enable_rendering_2) - -### Lua Example -`cur_obj_enable_rendering_2()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_enable_rendering_2(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_enable_rendering_and_become_tangible](#cur_obj_enable_rendering_and_become_tangible) - -### Lua Example -`cur_obj_enable_rendering_and_become_tangible(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void cur_obj_enable_rendering_and_become_tangible(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_enable_rendering_if_mario_in_room](#cur_obj_enable_rendering_if_mario_in_room) - -### Lua Example -`cur_obj_enable_rendering_if_mario_in_room()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_enable_rendering_if_mario_in_room(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_end_dialog](#cur_obj_end_dialog) - -### Lua Example -`cur_obj_end_dialog(m, dialogFlags, dialogResult)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | -| dialogFlags | `integer` | -| dialogResult | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_end_dialog(struct MarioState* m, s32 dialogFlags, s32 dialogResult);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_extend_animation_if_at_end](#cur_obj_extend_animation_if_at_end) - -### Lua Example -`cur_obj_extend_animation_if_at_end()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_extend_animation_if_at_end(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_find_nearby_held_actor](#cur_obj_find_nearby_held_actor) - -### Lua Example -`local ObjectValue = cur_obj_find_nearby_held_actor(behavior, maxDist)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | -| maxDist | `number` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *cur_obj_find_nearby_held_actor(const BehaviorScript *behavior, f32 maxDist);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_find_nearest_object_with_behavior](#cur_obj_find_nearest_object_with_behavior) - -### Lua Example -`local ObjectValue = cur_obj_find_nearest_object_with_behavior(behavior, dist)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | -| dist | `Pointer` <`number`> | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *cur_obj_find_nearest_object_with_behavior(const BehaviorScript *behavior, f32 *dist);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_find_nearest_pole](#cur_obj_find_nearest_pole) - -### Lua Example -`local ObjectValue = cur_obj_find_nearest_pole()` - -### Parameters -- None - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object* cur_obj_find_nearest_pole(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_follow_path](#cur_obj_follow_path) - -### Lua Example -`local integerValue = cur_obj_follow_path(unusedArg)` - -### Parameters -| Field | Type | -| ----- | ---- | -| unusedArg | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_follow_path(UNUSED s32 unusedArg);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_forward_vel_approach_upward](#cur_obj_forward_vel_approach_upward) - -### Lua Example -`cur_obj_forward_vel_approach_upward(target, increment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| target | `number` | -| increment | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_forward_vel_approach_upward(f32 target, f32 increment);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_get_dropped](#cur_obj_get_dropped) - -### Lua Example -`cur_obj_get_dropped()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_get_dropped(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_get_thrown_or_placed](#cur_obj_get_thrown_or_placed) - -### Lua Example -`cur_obj_get_thrown_or_placed(forwardVel, velY, thrownAction)` - -### Parameters -| Field | Type | -| ----- | ---- | -| forwardVel | `number` | -| velY | `number` | -| thrownAction | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_get_thrown_or_placed(f32 forwardVel, f32 velY, s32 thrownAction);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_has_behavior](#cur_obj_has_behavior) - -### Lua Example -`local integerValue = cur_obj_has_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_has_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_has_model](#cur_obj_has_model) - -### Lua Example -`local integerValue = cur_obj_has_model(modelID)` - -### Parameters -| Field | Type | -| ----- | ---- | -| modelID | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_has_model(u16 modelID);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_hide](#cur_obj_hide) - -### Lua Example -`cur_obj_hide()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_hide(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_hide_if_mario_far_away_y](#cur_obj_hide_if_mario_far_away_y) - -### Lua Example -`local integerValue = cur_obj_hide_if_mario_far_away_y(distY)` - -### Parameters -| Field | Type | -| ----- | ---- | -| distY | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_hide_if_mario_far_away_y(f32 distY);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_if_hit_wall_bounce_away](#cur_obj_if_hit_wall_bounce_away) - -### Lua Example -`cur_obj_if_hit_wall_bounce_away()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_if_hit_wall_bounce_away(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_init_animation](#cur_obj_init_animation) - -### Lua Example -`cur_obj_init_animation(animIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animIndex | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_init_animation(s32 animIndex);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_init_animation_and_anim_frame](#cur_obj_init_animation_and_anim_frame) - -### Lua Example -`cur_obj_init_animation_and_anim_frame(animIndex, animFrame)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animIndex | `integer` | -| animFrame | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_init_animation_and_anim_frame(s32 animIndex, s32 animFrame);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_init_animation_and_check_if_near_end](#cur_obj_init_animation_and_check_if_near_end) - -### Lua Example -`local integerValue = cur_obj_init_animation_and_check_if_near_end(animIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animIndex | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_init_animation_and_check_if_near_end(s32 animIndex);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_init_animation_and_extend_if_at_end](#cur_obj_init_animation_and_extend_if_at_end) - -### Lua Example -`cur_obj_init_animation_and_extend_if_at_end(animIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animIndex | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_init_animation_and_extend_if_at_end(s32 animIndex);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_init_animation_with_accel_and_sound](#cur_obj_init_animation_with_accel_and_sound) - -### Lua Example -`cur_obj_init_animation_with_accel_and_sound(animIndex, accel)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animIndex | `integer` | -| accel | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_init_animation_with_accel_and_sound(s32 animIndex, f32 accel);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_init_animation_with_sound](#cur_obj_init_animation_with_sound) - -### Lua Example -`cur_obj_init_animation_with_sound(animIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animIndex | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_init_animation_with_sound(s32 animIndex);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_is_any_player_on_platform](#cur_obj_is_any_player_on_platform) - -### Lua Example -`local integerValue = cur_obj_is_any_player_on_platform()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_is_any_player_on_platform(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_is_mario_ground_pounding_platform](#cur_obj_is_mario_ground_pounding_platform) - -### Lua Example -`local integerValue = cur_obj_is_mario_ground_pounding_platform()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_is_mario_ground_pounding_platform(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_is_mario_on_platform](#cur_obj_is_mario_on_platform) - -### Lua Example -`local integerValue = cur_obj_is_mario_on_platform()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_is_mario_on_platform(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_lateral_dist_from_mario_to_home](#cur_obj_lateral_dist_from_mario_to_home) - -### Lua Example -`local numberValue = cur_obj_lateral_dist_from_mario_to_home()` - -### Parameters -- None - -### Returns -- `number` - -### C Prototype -`f32 cur_obj_lateral_dist_from_mario_to_home(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_lateral_dist_from_obj_to_home](#cur_obj_lateral_dist_from_obj_to_home) - -### Lua Example -`local numberValue = cur_obj_lateral_dist_from_obj_to_home(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- `number` - -### C Prototype -`f32 cur_obj_lateral_dist_from_obj_to_home(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_lateral_dist_to_home](#cur_obj_lateral_dist_to_home) - -### Lua Example -`local numberValue = cur_obj_lateral_dist_to_home()` - -### Parameters -- None - -### Returns -- `number` - -### C Prototype -`f32 cur_obj_lateral_dist_to_home(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_mario_far_away](#cur_obj_mario_far_away) - -### Lua Example -`local integerValue = cur_obj_mario_far_away()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_mario_far_away(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_after_thrown_or_dropped](#cur_obj_move_after_thrown_or_dropped) - -### Lua Example -`cur_obj_move_after_thrown_or_dropped(forwardVel, velY)` - -### Parameters -| Field | Type | -| ----- | ---- | -| forwardVel | `number` | -| velY | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_move_after_thrown_or_dropped(f32 forwardVel, f32 velY);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_standard](#cur_obj_move_standard) - -### Lua Example -`cur_obj_move_standard(steepSlopeAngleDegrees)` - -### Parameters -| Field | Type | -| ----- | ---- | -| steepSlopeAngleDegrees | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_move_standard(s16 steepSlopeAngleDegrees);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_up_and_down](#cur_obj_move_up_and_down) - -### Lua Example -`local integerValue = cur_obj_move_up_and_down(a0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_move_up_and_down(s32 a0);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_update_ground_air_flags](#cur_obj_move_update_ground_air_flags) - -### Lua Example -`cur_obj_move_update_ground_air_flags(gravity, bounciness)` - -### Parameters -| Field | Type | -| ----- | ---- | -| gravity | `number` | -| bounciness | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_move_update_ground_air_flags(UNUSED f32 gravity, f32 bounciness);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_update_underwater_flags](#cur_obj_move_update_underwater_flags) - -### Lua Example -`cur_obj_move_update_underwater_flags()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_move_update_underwater_flags(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_using_fvel_and_gravity](#cur_obj_move_using_fvel_and_gravity) - -### Lua Example -`cur_obj_move_using_fvel_and_gravity()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_move_using_fvel_and_gravity(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_using_vel](#cur_obj_move_using_vel) - -### Lua Example -`cur_obj_move_using_vel()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_move_using_vel(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_using_vel_and_gravity](#cur_obj_move_using_vel_and_gravity) - -### Lua Example -`cur_obj_move_using_vel_and_gravity()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_move_using_vel_and_gravity(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_xz](#cur_obj_move_xz) - -### Lua Example -`local integerValue = cur_obj_move_xz(steepSlopeNormalY, careAboutEdgesAndSteepSlopes)` - -### Parameters -| Field | Type | -| ----- | ---- | -| steepSlopeNormalY | `number` | -| careAboutEdgesAndSteepSlopes | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_move_xz(f32 steepSlopeNormalY, s32 careAboutEdgesAndSteepSlopes);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_xz_using_fvel_and_yaw](#cur_obj_move_xz_using_fvel_and_yaw) - -### Lua Example -`cur_obj_move_xz_using_fvel_and_yaw()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_move_xz_using_fvel_and_yaw(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_y](#cur_obj_move_y) - -### Lua Example -`cur_obj_move_y(gravity, bounciness, buoyancy)` - -### Parameters -| Field | Type | -| ----- | ---- | -| gravity | `number` | -| bounciness | `number` | -| buoyancy | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_move_y(f32 gravity, f32 bounciness, f32 buoyancy);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_y_and_get_water_level](#cur_obj_move_y_and_get_water_level) - -### Lua Example -`local numberValue = cur_obj_move_y_and_get_water_level(gravity, buoyancy)` - -### Parameters -| Field | Type | -| ----- | ---- | -| gravity | `number` | -| buoyancy | `number` | - -### Returns -- `number` - -### C Prototype -`f32 cur_obj_move_y_and_get_water_level(f32 gravity, f32 buoyancy);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_move_y_with_terminal_vel](#cur_obj_move_y_with_terminal_vel) - -### Lua Example -`cur_obj_move_y_with_terminal_vel()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_move_y_with_terminal_vel(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_nearest_object_with_behavior](#cur_obj_nearest_object_with_behavior) - -### Lua Example -`local ObjectValue = cur_obj_nearest_object_with_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *cur_obj_nearest_object_with_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_outside_home_rectangle](#cur_obj_outside_home_rectangle) - -### Lua Example -`local integerValue = cur_obj_outside_home_rectangle(minX, maxX, minZ, maxZ)` - -### Parameters -| Field | Type | -| ----- | ---- | -| minX | `number` | -| maxX | `number` | -| minZ | `number` | -| maxZ | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_outside_home_rectangle(f32 minX, f32 maxX, f32 minZ, f32 maxZ);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_outside_home_square](#cur_obj_outside_home_square) - -### Lua Example -`local integerValue = cur_obj_outside_home_square(halfLength)` - -### Parameters -| Field | Type | -| ----- | ---- | -| halfLength | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_outside_home_square(f32 halfLength);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_push_mario_away](#cur_obj_push_mario_away) - -### Lua Example -`cur_obj_push_mario_away(radius)` - -### Parameters -| Field | Type | -| ----- | ---- | -| radius | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_push_mario_away(f32 radius);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_push_mario_away_from_cylinder](#cur_obj_push_mario_away_from_cylinder) - -### Lua Example -`cur_obj_push_mario_away_from_cylinder(radius, extentY)` - -### Parameters -| Field | Type | -| ----- | ---- | -| radius | `number` | -| extentY | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_push_mario_away_from_cylinder(f32 radius, f32 extentY);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_reflect_move_angle_off_wall](#cur_obj_reflect_move_angle_off_wall) - -### Lua Example -`local integerValue = cur_obj_reflect_move_angle_off_wall()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s16 cur_obj_reflect_move_angle_off_wall(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_reset_timer_and_subaction](#cur_obj_reset_timer_and_subaction) - -### Lua Example -`cur_obj_reset_timer_and_subaction()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_reset_timer_and_subaction(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_resolve_wall_collisions](#cur_obj_resolve_wall_collisions) - -### Lua Example -`local integerValue = cur_obj_resolve_wall_collisions()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_resolve_wall_collisions(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_reverse_animation](#cur_obj_reverse_animation) - -### Lua Example -`cur_obj_reverse_animation()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_reverse_animation(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_rotate_face_angle_using_vel](#cur_obj_rotate_face_angle_using_vel) - -### Lua Example -`cur_obj_rotate_face_angle_using_vel()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_rotate_face_angle_using_vel(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_rotate_move_angle_using_vel](#cur_obj_rotate_move_angle_using_vel) - -### Lua Example -`cur_obj_rotate_move_angle_using_vel()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_rotate_move_angle_using_vel(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_rotate_yaw_toward](#cur_obj_rotate_yaw_toward) - -### Lua Example -`local integerValue = cur_obj_rotate_yaw_toward(target, increment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| target | `integer` | -| increment | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_rotate_yaw_toward(s16 target, s16 increment);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_scale](#cur_obj_scale) - -### Lua Example -`cur_obj_scale(scale)` - -### Parameters -| Field | Type | -| ----- | ---- | -| scale | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_scale(f32 scale);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_scale_over_time](#cur_obj_scale_over_time) - -### Lua Example -`cur_obj_scale_over_time(a0, a1, sp10, sp14)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `integer` | -| a1 | `integer` | -| sp10 | `number` | -| sp14 | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_scale_over_time(s32 a0, s32 a1, f32 sp10, f32 sp14);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_behavior](#cur_obj_set_behavior) - -### Lua Example -`cur_obj_set_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- None - -### C Prototype -`void cur_obj_set_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_billboard_if_vanilla_cam](#cur_obj_set_billboard_if_vanilla_cam) - -### Lua Example -`cur_obj_set_billboard_if_vanilla_cam()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_billboard_if_vanilla_cam(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_face_angle_to_move_angle](#cur_obj_set_face_angle_to_move_angle) - -### Lua Example -`cur_obj_set_face_angle_to_move_angle()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_face_angle_to_move_angle(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_hitbox_and_die_if_attacked](#cur_obj_set_hitbox_and_die_if_attacked) - -### Lua Example -`local integerValue = cur_obj_set_hitbox_and_die_if_attacked(hitbox, deathSound, noLootCoins)` - -### Parameters -| Field | Type | -| ----- | ---- | -| hitbox | [ObjectHitbox](structs.md#ObjectHitbox) | -| deathSound | `integer` | -| noLootCoins | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_set_hitbox_and_die_if_attacked(struct ObjectHitbox *hitbox, s32 deathSound, s32 noLootCoins);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_hitbox_radius_and_height](#cur_obj_set_hitbox_radius_and_height) - -### Lua Example -`cur_obj_set_hitbox_radius_and_height(radius, height)` - -### Parameters -| Field | Type | -| ----- | ---- | -| radius | `number` | -| height | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_set_hitbox_radius_and_height(f32 radius, f32 height);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_home_once](#cur_obj_set_home_once) - -### Lua Example -`cur_obj_set_home_once()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_home_once(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_hurtbox_radius_and_height](#cur_obj_set_hurtbox_radius_and_height) - -### Lua Example -`cur_obj_set_hurtbox_radius_and_height(radius, height)` - -### Parameters -| Field | Type | -| ----- | ---- | -| radius | `number` | -| height | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_set_hurtbox_radius_and_height(f32 radius, f32 height);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_pos_relative](#cur_obj_set_pos_relative) - -### Lua Example -`cur_obj_set_pos_relative(other, dleft, dy, dforward)` - -### Parameters -| Field | Type | -| ----- | ---- | -| other | [Object](structs.md#Object) | -| dleft | `number` | -| dy | `number` | -| dforward | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_set_pos_relative(struct Object *other, f32 dleft, f32 dy, f32 dforward);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_pos_relative_to_parent](#cur_obj_set_pos_relative_to_parent) - -### Lua Example -`cur_obj_set_pos_relative_to_parent(dleft, dy, dforward)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dleft | `number` | -| dy | `number` | -| dforward | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_set_pos_relative_to_parent(f32 dleft, f32 dy, f32 dforward);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_pos_to_home](#cur_obj_set_pos_to_home) - -### Lua Example -`cur_obj_set_pos_to_home()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_pos_to_home(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_pos_to_home_and_stop](#cur_obj_set_pos_to_home_and_stop) - -### Lua Example -`cur_obj_set_pos_to_home_and_stop()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_pos_to_home_and_stop(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_pos_to_home_with_debug](#cur_obj_set_pos_to_home_with_debug) - -### Lua Example -`cur_obj_set_pos_to_home_with_debug()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_pos_to_home_with_debug(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_pos_via_transform](#cur_obj_set_pos_via_transform) - -### Lua Example -`cur_obj_set_pos_via_transform()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_set_pos_via_transform(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_vel_from_mario_vel](#cur_obj_set_vel_from_mario_vel) - -### Lua Example -`cur_obj_set_vel_from_mario_vel(m, f12, f14)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | -| f12 | `number` | -| f14 | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_set_vel_from_mario_vel(struct MarioState* m, f32 f12, f32 f14);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_set_y_vel_and_animation](#cur_obj_set_y_vel_and_animation) - -### Lua Example -`cur_obj_set_y_vel_and_animation(sp18, sp1C)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp18 | `number` | -| sp1C | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_set_y_vel_and_animation(f32 sp18, s32 sp1C);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_shake_screen](#cur_obj_shake_screen) - -### Lua Example -`cur_obj_shake_screen(shake)` - -### Parameters -| Field | Type | -| ----- | ---- | -| shake | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_shake_screen(s32 shake);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_shake_y](#cur_obj_shake_y) - -### Lua Example -`cur_obj_shake_y(amount)` - -### Parameters -| Field | Type | -| ----- | ---- | -| amount | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_shake_y(f32 amount);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_shake_y_until](#cur_obj_shake_y_until) - -### Lua Example -`local integerValue = cur_obj_shake_y_until(cycles, amount)` - -### Parameters -| Field | Type | -| ----- | ---- | -| cycles | `integer` | -| amount | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_shake_y_until(s32 cycles, s32 amount);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_spawn_loot_blue_coin](#cur_obj_spawn_loot_blue_coin) - -### Lua Example -`cur_obj_spawn_loot_blue_coin()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_spawn_loot_blue_coin(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_spawn_loot_coin_at_mario_pos](#cur_obj_spawn_loot_coin_at_mario_pos) - -### Lua Example -`cur_obj_spawn_loot_coin_at_mario_pos(m)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | - -### Returns -- None - -### C Prototype -`void cur_obj_spawn_loot_coin_at_mario_pos(struct MarioState* m);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_spawn_particles](#cur_obj_spawn_particles) - -### Lua Example -`cur_obj_spawn_particles(info)` - -### Parameters -| Field | Type | -| ----- | ---- | -| info | [SpawnParticlesInfo](structs.md#SpawnParticlesInfo) | - -### Returns -- None - -### C Prototype -`void cur_obj_spawn_particles(struct SpawnParticlesInfo *info);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_spawn_star_at_y_offset](#cur_obj_spawn_star_at_y_offset) - -### Lua Example -`cur_obj_spawn_star_at_y_offset(targetX, targetY, targetZ, offsetY)` - -### Parameters -| Field | Type | -| ----- | ---- | -| targetX | `number` | -| targetY | `number` | -| targetZ | `number` | -| offsetY | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_spawn_star_at_y_offset(f32 targetX, f32 targetY, f32 targetZ, f32 offsetY);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_start_cam_event](#cur_obj_start_cam_event) - -### Lua Example -`cur_obj_start_cam_event(obj, cameraEvent)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| cameraEvent | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_start_cam_event(UNUSED struct Object *obj, s32 cameraEvent);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_unhide](#cur_obj_unhide) - -### Lua Example -`cur_obj_unhide()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_unhide(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_unrender_and_reset_state](#cur_obj_unrender_and_reset_state) - -### Lua Example -`cur_obj_unrender_and_reset_state(sp18, sp1C)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp18 | `integer` | -| sp1C | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_unrender_and_reset_state(s32 sp18, s32 sp1C);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_unused_init_on_floor](#cur_obj_unused_init_on_floor) - -### Lua Example -`cur_obj_unused_init_on_floor()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_unused_init_on_floor(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_unused_play_footstep_sound](#cur_obj_unused_play_footstep_sound) - -### Lua Example -`cur_obj_unused_play_footstep_sound(animFrame1, animFrame2, sound)` - -### Parameters -| Field | Type | -| ----- | ---- | -| animFrame1 | `integer` | -| animFrame2 | `integer` | -| sound | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_unused_play_footstep_sound(s32 animFrame1, s32 animFrame2, s32 sound);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_unused_resolve_wall_collisions](#cur_obj_unused_resolve_wall_collisions) - -### Lua Example -`cur_obj_unused_resolve_wall_collisions(offsetY, radius)` - -### Parameters -| Field | Type | -| ----- | ---- | -| offsetY | `number` | -| radius | `number` | - -### Returns -- None - -### C Prototype -`void cur_obj_unused_resolve_wall_collisions(f32 offsetY, f32 radius);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_update_floor](#cur_obj_update_floor) - -### Lua Example -`cur_obj_update_floor()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_update_floor(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_update_floor_and_resolve_wall_collisions](#cur_obj_update_floor_and_resolve_wall_collisions) - -### Lua Example -`cur_obj_update_floor_and_resolve_wall_collisions(steepSlopeDegrees)` - -### Parameters -| Field | Type | -| ----- | ---- | -| steepSlopeDegrees | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_update_floor_and_resolve_wall_collisions(s16 steepSlopeDegrees);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_update_floor_and_walls](#cur_obj_update_floor_and_walls) - -### Lua Example -`cur_obj_update_floor_and_walls()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_update_floor_and_walls(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_update_floor_height](#cur_obj_update_floor_height) - -### Lua Example -`cur_obj_update_floor_height()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void cur_obj_update_floor_height(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_update_floor_height_and_get_floor](#cur_obj_update_floor_height_and_get_floor) - -### Lua Example -`local SurfaceValue = cur_obj_update_floor_height_and_get_floor()` - -### Parameters -- None - -### Returns -[Surface](structs.md#Surface) - -### C Prototype -`struct Surface *cur_obj_update_floor_height_and_get_floor(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_wait_then_blink](#cur_obj_wait_then_blink) - -### Lua Example -`local integerValue = cur_obj_wait_then_blink(timeUntilBlinking, numBlinks)` - -### Parameters -| Field | Type | -| ----- | ---- | -| timeUntilBlinking | `integer` | -| numBlinks | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_wait_then_blink(s32 timeUntilBlinking, s32 numBlinks);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_was_attacked_or_ground_pounded](#cur_obj_was_attacked_or_ground_pounded) - -### Lua Example -`local integerValue = cur_obj_was_attacked_or_ground_pounded()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_was_attacked_or_ground_pounded(void);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_within_12k_bounds](#cur_obj_within_12k_bounds) - -### Lua Example -`local integerValue = cur_obj_within_12k_bounds()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 cur_obj_within_12k_bounds(void);` - -[:arrow_up_small:](#) - -
- -## [disable_time_stop](#disable_time_stop) - -### Lua Example -`disable_time_stop()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void disable_time_stop(void);` - -[:arrow_up_small:](#) - -
- -## [disable_time_stop_including_mario](#disable_time_stop_including_mario) - -### Lua Example -`disable_time_stop_including_mario()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void disable_time_stop_including_mario(void);` - -[:arrow_up_small:](#) - -
- -## [dist_between_object_and_point](#dist_between_object_and_point) - -### Lua Example -`local numberValue = dist_between_object_and_point(obj, pointX, pointY, pointZ)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| pointX | `number` | -| pointY | `number` | -| pointZ | `number` | - -### Returns -- `number` - -### C Prototype -`f32 dist_between_object_and_point(struct Object *obj, f32 pointX, f32 pointY, f32 pointZ);` - -[:arrow_up_small:](#) - -
- -## [dist_between_objects](#dist_between_objects) - -### Lua Example -`local numberValue = dist_between_objects(obj1, obj2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj1 | [Object](structs.md#Object) | -| obj2 | [Object](structs.md#Object) | - -### Returns -- `number` - -### C Prototype -`f32 dist_between_objects(struct Object *obj1, struct Object *obj2);` - -[:arrow_up_small:](#) - -
- -## [enable_time_stop](#enable_time_stop) - -### Lua Example -`enable_time_stop()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void enable_time_stop(void);` - -[:arrow_up_small:](#) - -
- -## [enable_time_stop_if_alone](#enable_time_stop_if_alone) - -### Lua Example -`enable_time_stop_if_alone()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void enable_time_stop_if_alone(void);` - -[:arrow_up_small:](#) - -
- -## [enable_time_stop_including_mario](#enable_time_stop_including_mario) - -### Lua Example -`enable_time_stop_including_mario()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void enable_time_stop_including_mario(void);` - -[:arrow_up_small:](#) - -
- -## [find_object_with_behavior](#find_object_with_behavior) - -### Lua Example -`local ObjectValue = find_object_with_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *find_object_with_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [find_unimportant_object](#find_unimportant_object) - -### Lua Example -`local ObjectValue = find_unimportant_object()` - -### Parameters -- None - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *find_unimportant_object(void);` - -[:arrow_up_small:](#) - -
- -## [geo_offset_klepto_debug](#geo_offset_klepto_debug) - -### Lua Example -`local integerValue = geo_offset_klepto_debug(callContext, a1, sp8)` - -### Parameters -| Field | Type | -| ----- | ---- | -| callContext | `integer` | -| a1 | [GraphNode](structs.md#GraphNode) | -| sp8 | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 geo_offset_klepto_debug(s32 callContext, struct GraphNode *a1, UNUSED s32 sp8);` - -[:arrow_up_small:](#) - -
- -## [get_object_list_from_behavior](#get_object_list_from_behavior) - -### Lua Example -`local integerValue = get_object_list_from_behavior(behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- `integer` - -### C Prototype -`u32 get_object_list_from_behavior(const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [get_trajectory_length](#get_trajectory_length) - -### Lua Example -`local integerValue = get_trajectory_length(trajectory)` - -### Parameters -| Field | Type | -| ----- | ---- | -| trajectory | `Pointer` <`Trajectory`> | - -### Returns -- `integer` - -### C Prototype -`s32 get_trajectory_length(Trajectory* trajectory);` - -[:arrow_up_small:](#) - -
- -## [increment_velocity_toward_range](#increment_velocity_toward_range) - -### Lua Example -`local numberValue = increment_velocity_toward_range(value, center, zeroThreshold, increment)` - -### Parameters -| Field | Type | -| ----- | ---- | -| value | `number` | -| center | `number` | -| zeroThreshold | `number` | -| increment | `number` | - -### Returns -- `number` - -### C Prototype -`f32 increment_velocity_toward_range(f32 value, f32 center, f32 zeroThreshold, f32 increment);` - -[:arrow_up_small:](#) - -
- -## [is_item_in_array](#is_item_in_array) - -### Lua Example -`local integerValue = is_item_in_array(item, array)` - -### Parameters -| Field | Type | -| ----- | ---- | -| item | `integer` | -| array | `Pointer` <`integer`> | - -### Returns -- `integer` - -### C Prototype -`s32 is_item_in_array(s8 item, s8 *array);` - -[:arrow_up_small:](#) - -
- -## [is_mario_moving_fast_or_in_air](#is_mario_moving_fast_or_in_air) - -### Lua Example -`local integerValue = is_mario_moving_fast_or_in_air(speedThreshold)` - -### Parameters -| Field | Type | -| ----- | ---- | -| speedThreshold | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 is_mario_moving_fast_or_in_air(s32 speedThreshold);` - -[:arrow_up_small:](#) - -
- -## [lateral_dist_between_objects](#lateral_dist_between_objects) - -### Lua Example -`local numberValue = lateral_dist_between_objects(obj1, obj2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj1 | [Object](structs.md#Object) | -| obj2 | [Object](structs.md#Object) | - -### Returns -- `number` - -### C Prototype -`f32 lateral_dist_between_objects(struct Object *obj1, struct Object *obj2);` - -[:arrow_up_small:](#) - -
- -## [linear_mtxf_mul_vec3f](#linear_mtxf_mul_vec3f) - -### Lua Example -`linear_mtxf_mul_vec3f(m, dst, v)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | `Mat4` | -| dst | [Vec3f](structs.md#Vec3f) | -| v | [Vec3f](structs.md#Vec3f) | - -### Returns -- None - -### C Prototype -`void linear_mtxf_mul_vec3f(Mat4 m, Vec3f dst, Vec3f v);` - -[:arrow_up_small:](#) - -
- -## [linear_mtxf_transpose_mul_vec3f](#linear_mtxf_transpose_mul_vec3f) - -### Lua Example -`linear_mtxf_transpose_mul_vec3f(m, dst, v)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | `Mat4` | -| dst | [Vec3f](structs.md#Vec3f) | -| v | [Vec3f](structs.md#Vec3f) | - -### Returns -- None - -### C Prototype -`void linear_mtxf_transpose_mul_vec3f(Mat4 m, Vec3f dst, Vec3f v);` - -[:arrow_up_small:](#) - -
- -## [mario_is_dive_sliding](#mario_is_dive_sliding) - -### Lua Example -`local integerValue = mario_is_dive_sliding(m)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | - -### Returns -- `integer` - -### C Prototype -`s32 mario_is_dive_sliding(struct MarioState* m);` - -[:arrow_up_small:](#) - -
- -## [mario_is_in_air_action](#mario_is_in_air_action) - -### Lua Example -`local integerValue = mario_is_in_air_action(m)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | - -### Returns -- `integer` - -### C Prototype -`s32 mario_is_in_air_action(struct MarioState* m);` - -[:arrow_up_small:](#) - -
- -## [mario_is_within_rectangle](#mario_is_within_rectangle) - -### Lua Example -`local integerValue = mario_is_within_rectangle(minX, maxX, minZ, maxZ)` - -### Parameters -| Field | Type | -| ----- | ---- | -| minX | `integer` | -| maxX | `integer` | -| minZ | `integer` | -| maxZ | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 mario_is_within_rectangle(s16 minX, s16 maxX, s16 minZ, s16 maxZ);` - -[:arrow_up_small:](#) - -
- -## [mario_set_flag](#mario_set_flag) - -### Lua Example -`mario_set_flag(flag)` - -### Parameters -| Field | Type | -| ----- | ---- | -| flag | `integer` | - -### Returns -- None - -### C Prototype -`void mario_set_flag(s32 flag);` - -[:arrow_up_small:](#) - -
- -## [obj_angle_to_object](#obj_angle_to_object) - -### Lua Example -`local integerValue = obj_angle_to_object(obj1, obj2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj1 | [Object](structs.md#Object) | -| obj2 | [Object](structs.md#Object) | - -### Returns -- `integer` - -### C Prototype -`s16 obj_angle_to_object(struct Object *obj1, struct Object *obj2);` - -[:arrow_up_small:](#) - -
- -## [obj_angle_to_point](#obj_angle_to_point) - -### Lua Example -`local integerValue = obj_angle_to_point(obj, pointX, pointZ)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| pointX | `number` | -| pointZ | `number` | - -### Returns -- `integer` - -### C Prototype -`s16 obj_angle_to_point(struct Object *obj, f32 pointX, f32 pointZ);` - -[:arrow_up_small:](#) - -
- -## [obj_apply_scale_to_matrix](#obj_apply_scale_to_matrix) - -### Lua Example -`obj_apply_scale_to_matrix(obj, dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| dst | `Mat4` | -| src | `Mat4` | - -### Returns -- None - -### C Prototype -`void obj_apply_scale_to_matrix(struct Object *obj, Mat4 dst, Mat4 src);` - -[:arrow_up_small:](#) - -
- -## [obj_apply_scale_to_transform](#obj_apply_scale_to_transform) - -### Lua Example -`obj_apply_scale_to_transform(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_apply_scale_to_transform(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_attack_collided_from_other_object](#obj_attack_collided_from_other_object) - -### Lua Example -`local integerValue = obj_attack_collided_from_other_object(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- `integer` - -### C Prototype -`s32 obj_attack_collided_from_other_object(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_become_tangible](#obj_become_tangible) - -### Lua Example -`obj_become_tangible(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_become_tangible(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_build_relative_transform](#obj_build_relative_transform) - -### Lua Example -`obj_build_relative_transform(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_build_relative_transform(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_build_transform_from_pos_and_angle](#obj_build_transform_from_pos_and_angle) - -### Lua Example -`obj_build_transform_from_pos_and_angle(obj, posIndex, angleIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| posIndex | `integer` | -| angleIndex | `integer` | - -### Returns -- None - -### C Prototype -`void obj_build_transform_from_pos_and_angle(struct Object *obj, s16 posIndex, s16 angleIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_build_transform_relative_to_parent](#obj_build_transform_relative_to_parent) - -### Lua Example -`obj_build_transform_relative_to_parent(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_build_transform_relative_to_parent(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_build_vel_from_transform](#obj_build_vel_from_transform) - -### Lua Example -`obj_build_vel_from_transform(a0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_build_vel_from_transform(struct Object *a0);` - -[:arrow_up_small:](#) - -
- -## [obj_check_if_collided_with_object](#obj_check_if_collided_with_object) - -### Lua Example -`local integerValue = obj_check_if_collided_with_object(obj1, obj2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj1 | [Object](structs.md#Object) | -| obj2 | [Object](structs.md#Object) | - -### Returns -- `integer` - -### C Prototype -`s32 obj_check_if_collided_with_object(struct Object *obj1, struct Object *obj2);` - -[:arrow_up_small:](#) - -
- -## [obj_copy_angle](#obj_copy_angle) - -### Lua Example -`obj_copy_angle(dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dst | [Object](structs.md#Object) | -| src | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_copy_angle(struct Object *dst, struct Object *src);` - -[:arrow_up_small:](#) - -
- -## [obj_copy_behavior_params](#obj_copy_behavior_params) - -### Lua Example -`obj_copy_behavior_params(dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dst | [Object](structs.md#Object) | -| src | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_copy_behavior_params(struct Object *dst, struct Object *src);` - -[:arrow_up_small:](#) - -
- -## [obj_copy_graph_y_offset](#obj_copy_graph_y_offset) - -### Lua Example -`obj_copy_graph_y_offset(dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dst | [Object](structs.md#Object) | -| src | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_copy_graph_y_offset(struct Object *dst, struct Object *src);` - -[:arrow_up_small:](#) - -
- -## [obj_copy_pos](#obj_copy_pos) - -### Lua Example -`obj_copy_pos(dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dst | [Object](structs.md#Object) | -| src | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_copy_pos(struct Object *dst, struct Object *src);` - -[:arrow_up_small:](#) - -
- -## [obj_copy_pos_and_angle](#obj_copy_pos_and_angle) - -### Lua Example -`obj_copy_pos_and_angle(dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dst | [Object](structs.md#Object) | -| src | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_copy_pos_and_angle(struct Object *dst, struct Object *src);` - -[:arrow_up_small:](#) - -
- -## [obj_copy_scale](#obj_copy_scale) - -### Lua Example -`obj_copy_scale(dst, src)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dst | [Object](structs.md#Object) | -| src | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_copy_scale(struct Object *dst, struct Object *src);` - -[:arrow_up_small:](#) - -
- -## [obj_create_transform_from_self](#obj_create_transform_from_self) - -### Lua Example -`obj_create_transform_from_self(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_create_transform_from_self(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_explode_and_spawn_coins](#obj_explode_and_spawn_coins) - -### Lua Example -`obj_explode_and_spawn_coins(sp18, sp1C)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp18 | `number` | -| sp1C | `integer` | - -### Returns -- None - -### C Prototype -`void obj_explode_and_spawn_coins(f32 sp18, s32 sp1C);` - -[:arrow_up_small:](#) - -
- -## [obj_has_behavior](#obj_has_behavior) - -### Lua Example -`local integerValue = obj_has_behavior(obj, behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- `integer` - -### C Prototype -`s32 obj_has_behavior(struct Object *obj, const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [obj_init_animation](#obj_init_animation) - -### Lua Example -`obj_init_animation(obj, animIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| animIndex | `integer` | - -### Returns -- None - -### C Prototype -`void obj_init_animation(struct Object *obj, s32 animIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_init_animation_with_accel_and_sound](#obj_init_animation_with_accel_and_sound) - -### Lua Example -`obj_init_animation_with_accel_and_sound(obj, animIndex, accel)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| animIndex | `integer` | -| accel | `number` | - -### Returns -- None - -### C Prototype -`void obj_init_animation_with_accel_and_sound(struct Object *obj, s32 animIndex, f32 accel);` - -[:arrow_up_small:](#) - -
- -## [obj_init_animation_with_sound](#obj_init_animation_with_sound) - -### Lua Example -`obj_init_animation_with_sound(obj, animations, animIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| animations | [AnimationTable](structs.md#AnimationTable) | -| animIndex | `integer` | - -### Returns -- None - -### C Prototype -`void obj_init_animation_with_sound(struct Object *obj, const struct AnimationTable* animations, s32 animIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_is_hidden](#obj_is_hidden) - -### Lua Example -`local integerValue = obj_is_hidden(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- `integer` - -### C Prototype -`s32 obj_is_hidden(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_mark_for_deletion](#obj_mark_for_deletion) - -### Lua Example -`obj_mark_for_deletion(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_mark_for_deletion(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_pitch_to_object](#obj_pitch_to_object) - -### Lua Example -`local integerValue = obj_pitch_to_object(obj, target)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| target | [Object](structs.md#Object) | - -### Returns -- `integer` - -### C Prototype -`s16 obj_pitch_to_object(struct Object* obj, struct Object* target);` - -[:arrow_up_small:](#) - -
- -## [obj_scale](#obj_scale) - -### Lua Example -`obj_scale(obj, scale)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| scale | `number` | - -### Returns -- None - -### C Prototype -`void obj_scale(struct Object *obj, f32 scale);` - -[:arrow_up_small:](#) - -
- -## [obj_scale_random](#obj_scale_random) - -### Lua Example -`obj_scale_random(obj, rangeLength, minScale)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| rangeLength | `number` | -| minScale | `number` | - -### Returns -- None - -### C Prototype -`void obj_scale_random(struct Object *obj, f32 rangeLength, f32 minScale);` - -[:arrow_up_small:](#) - -
- -## [obj_scale_xyz](#obj_scale_xyz) - -### Lua Example -`obj_scale_xyz(obj, xScale, yScale, zScale)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| xScale | `number` | -| yScale | `number` | -| zScale | `number` | - -### Returns -- None - -### C Prototype -`void obj_scale_xyz(struct Object *obj, f32 xScale, f32 yScale, f32 zScale);` - -[:arrow_up_small:](#) - -
- -## [obj_set_angle](#obj_set_angle) - -### Lua Example -`obj_set_angle(obj, pitch, yaw, roll)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| pitch | `integer` | -| yaw | `integer` | -| roll | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` - -[:arrow_up_small:](#) - -
- -## [obj_set_behavior](#obj_set_behavior) - -### Lua Example -`obj_set_behavior(obj, behavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| behavior | `Pointer` <`BehaviorScript`> | - -### Returns -- None - -### C Prototype -`void obj_set_behavior(struct Object *obj, const BehaviorScript *behavior);` - -[:arrow_up_small:](#) - -
- -## [obj_set_billboard](#obj_set_billboard) - -### Lua Example -`obj_set_billboard(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_set_billboard(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_set_cylboard](#obj_set_cylboard) - -### Lua Example -`obj_set_cylboard(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_set_cylboard(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_set_face_angle](#obj_set_face_angle) - -### Lua Example -`obj_set_face_angle(obj, pitch, yaw, roll)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| pitch | `integer` | -| yaw | `integer` | -| roll | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_face_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` - -[:arrow_up_small:](#) - -
- -## [obj_set_face_angle_to_move_angle](#obj_set_face_angle_to_move_angle) - -### Lua Example -`obj_set_face_angle_to_move_angle(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_set_face_angle_to_move_angle(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_set_gfx_angle](#obj_set_gfx_angle) - -### Lua Example -`obj_set_gfx_angle(obj, pitch, yaw, roll)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| pitch | `integer` | -| yaw | `integer` | -| roll | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_gfx_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` - -[:arrow_up_small:](#) - -
- -## [obj_set_gfx_pos](#obj_set_gfx_pos) - -### Lua Example -`obj_set_gfx_pos(obj, x, y, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| x | `number` | -| y | `number` | -| z | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_gfx_pos(struct Object *obj, f32 x, f32 y, f32 z);` - -[:arrow_up_small:](#) - -
- -## [obj_set_gfx_pos_at_obj_pos](#obj_set_gfx_pos_at_obj_pos) - -### Lua Example -`obj_set_gfx_pos_at_obj_pos(obj1, obj2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj1 | [Object](structs.md#Object) | -| obj2 | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_set_gfx_pos_at_obj_pos(struct Object *obj1, struct Object *obj2);` - -[:arrow_up_small:](#) - -
- -## [obj_set_gfx_pos_from_pos](#obj_set_gfx_pos_from_pos) - -### Lua Example -`obj_set_gfx_pos_from_pos(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_set_gfx_pos_from_pos(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_set_gfx_scale](#obj_set_gfx_scale) - -### Lua Example -`obj_set_gfx_scale(obj, x, y, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| x | `number` | -| y | `number` | -| z | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_gfx_scale(struct Object *obj, f32 x, f32 y, f32 z);` - -[:arrow_up_small:](#) - -
- -## [obj_set_held_state](#obj_set_held_state) - -### Lua Example -`obj_set_held_state(obj, heldBehavior)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| heldBehavior | `Pointer` <`BehaviorScript`> | - -### Returns -- None - -### C Prototype -`void obj_set_held_state(struct Object *obj, const BehaviorScript *heldBehavior);` - -[:arrow_up_small:](#) - -
- -## [obj_set_hitbox](#obj_set_hitbox) - -### Lua Example -`obj_set_hitbox(obj, hitbox)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| hitbox | [ObjectHitbox](structs.md#ObjectHitbox) | - -### Returns -- None - -### C Prototype -`void obj_set_hitbox(struct Object *obj, struct ObjectHitbox *hitbox);` - -[:arrow_up_small:](#) - -
- -## [obj_set_hitbox_radius_and_height](#obj_set_hitbox_radius_and_height) - -### Lua Example -`obj_set_hitbox_radius_and_height(o, radius, height)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| radius | `number` | -| height | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_hitbox_radius_and_height(struct Object *o, f32 radius, f32 height);` - -[:arrow_up_small:](#) - -
- -## [obj_set_hurtbox_radius_and_height](#obj_set_hurtbox_radius_and_height) - -### Lua Example -`obj_set_hurtbox_radius_and_height(o, radius, height)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| radius | `number` | -| height | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_hurtbox_radius_and_height(struct Object *o, f32 radius, f32 height);` - -[:arrow_up_small:](#) - -
- -## [obj_set_move_angle](#obj_set_move_angle) - -### Lua Example -`obj_set_move_angle(obj, pitch, yaw, roll)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| pitch | `integer` | -| yaw | `integer` | -| roll | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_move_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` - -[:arrow_up_small:](#) - -
- -## [obj_set_parent_relative_pos](#obj_set_parent_relative_pos) - -### Lua Example -`obj_set_parent_relative_pos(obj, relX, relY, relZ)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| relX | `integer` | -| relY | `integer` | -| relZ | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_parent_relative_pos(struct Object *obj, s16 relX, s16 relY, s16 relZ);` - -[:arrow_up_small:](#) - -
- -## [obj_set_pos](#obj_set_pos) - -### Lua Example -`obj_set_pos(obj, x, y, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| x | `integer` | -| y | `integer` | -| z | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_pos(struct Object *obj, s16 x, s16 y, s16 z);` - -[:arrow_up_small:](#) - -
- -## [obj_set_pos_relative](#obj_set_pos_relative) - -### Lua Example -`obj_set_pos_relative(obj, other, dleft, dy, dforward)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| other | [Object](structs.md#Object) | -| dleft | `number` | -| dy | `number` | -| dforward | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_pos_relative(struct Object *obj, struct Object *other, f32 dleft, f32 dy, f32 dforward);` - -[:arrow_up_small:](#) - -
- -## [obj_set_throw_matrix_from_transform](#obj_set_throw_matrix_from_transform) - -### Lua Example -`obj_set_throw_matrix_from_transform(obj)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_set_throw_matrix_from_transform(struct Object *obj);` - -[:arrow_up_small:](#) - -
- -## [obj_spawn_loot_blue_coins](#obj_spawn_loot_blue_coins) - -### Lua Example -`obj_spawn_loot_blue_coins(obj, numCoins, sp28, posJitter)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| numCoins | `integer` | -| sp28 | `number` | -| posJitter | `integer` | - -### Returns -- None - -### C Prototype -`void obj_spawn_loot_blue_coins(struct Object *obj, s32 numCoins, f32 sp28, s16 posJitter);` - -[:arrow_up_small:](#) - -
- -## [obj_spawn_loot_coins](#obj_spawn_loot_coins) - -### Lua Example -`obj_spawn_loot_coins(obj, numCoins, sp30, coinBehavior, posJitter, model)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| numCoins | `integer` | -| sp30 | `number` | -| coinBehavior | `Pointer` <`BehaviorScript`> | -| posJitter | `integer` | -| model | `integer` | - -### Returns -- None - -### C Prototype -`void obj_spawn_loot_coins(struct Object *obj, s32 numCoins, f32 sp30, const BehaviorScript *coinBehavior, s16 posJitter, s16 model);` - -[:arrow_up_small:](#) - -
- -## [obj_spawn_loot_yellow_coins](#obj_spawn_loot_yellow_coins) - -### Lua Example -`obj_spawn_loot_yellow_coins(obj, numCoins, sp28)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| numCoins | `integer` | -| sp28 | `number` | - -### Returns -- None - -### C Prototype -`void obj_spawn_loot_yellow_coins(struct Object *obj, s32 numCoins, f32 sp28);` - -[:arrow_up_small:](#) - -
- -## [obj_translate_local](#obj_translate_local) - -### Lua Example -`obj_translate_local(obj, posIndex, localTranslateIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| posIndex | `integer` | -| localTranslateIndex | `integer` | - -### Returns -- None - -### C Prototype -`void obj_translate_local(struct Object *obj, s16 posIndex, s16 localTranslateIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_translate_xyz_random](#obj_translate_xyz_random) - -### Lua Example -`obj_translate_xyz_random(obj, rangeLength)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| rangeLength | `number` | - -### Returns -- None - -### C Prototype -`void obj_translate_xyz_random(struct Object *obj, f32 rangeLength);` - -[:arrow_up_small:](#) - -
- -## [obj_translate_xz_random](#obj_translate_xz_random) - -### Lua Example -`obj_translate_xz_random(obj, rangeLength)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| rangeLength | `number` | - -### Returns -- None - -### C Prototype -`void obj_translate_xz_random(struct Object *obj, f32 rangeLength);` - -[:arrow_up_small:](#) - -
- -## [obj_turn_toward_object](#obj_turn_toward_object) - -### Lua Example -`local integerValue = obj_turn_toward_object(obj, target, angleIndex, turnAmount)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| target | [Object](structs.md#Object) | -| angleIndex | `integer` | -| turnAmount | `integer` | - -### Returns -- `integer` - -### C Prototype -`s16 obj_turn_toward_object(struct Object *obj, struct Object *target, s16 angleIndex, s16 turnAmount);` - -[:arrow_up_small:](#) - -
- -## [obj_update_pos_from_parent_transformation](#obj_update_pos_from_parent_transformation) - -### Lua Example -`obj_update_pos_from_parent_transformation(a0, a1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `Mat4` | -| a1 | [Object](structs.md#Object) | - -### Returns -- None - -### C Prototype -`void obj_update_pos_from_parent_transformation(Mat4 a0, struct Object *a1);` - -[:arrow_up_small:](#) - -
- -## [player_performed_grab_escape_action](#player_performed_grab_escape_action) - -### Lua Example -`local integerValue = player_performed_grab_escape_action()` - -### Parameters -- None - -### Returns -- `integer` - -### C Prototype -`s32 player_performed_grab_escape_action(void);` - -[:arrow_up_small:](#) - -
- -## [random_f32_around_zero](#random_f32_around_zero) - -### Lua Example -`local numberValue = random_f32_around_zero(diameter)` - -### Parameters -| Field | Type | -| ----- | ---- | -| diameter | `number` | - -### Returns -- `number` - -### C Prototype -`f32 random_f32_around_zero(f32 diameter);` - -[:arrow_up_small:](#) - -
- -## [set_mario_interact_hoot_if_in_range](#set_mario_interact_hoot_if_in_range) - -### Lua Example -`set_mario_interact_hoot_if_in_range(sp0, sp4, sp8)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp0 | `integer` | -| sp4 | `integer` | -| sp8 | `number` | - -### Returns -- None - -### C Prototype -`void set_mario_interact_hoot_if_in_range(UNUSED s32 sp0, UNUSED s32 sp4, f32 sp8);` - -[:arrow_up_small:](#) - -
- -## [set_room_override](#set_room_override) - -### Lua Example -`set_room_override(room)` - -### Parameters -| Field | Type | -| ----- | ---- | -| room | `integer` | - -### Returns -- None - -### C Prototype -`void set_room_override(s16 room);` - -[:arrow_up_small:](#) - -
- -## [set_time_stop_flags](#set_time_stop_flags) - -### Lua Example -`set_time_stop_flags(flags)` - -### Parameters -| Field | Type | -| ----- | ---- | -| flags | `integer` | - -### Returns -- None - -### C Prototype -`void set_time_stop_flags(s32 flags);` - -[:arrow_up_small:](#) - -
- -## [set_time_stop_flags_if_alone](#set_time_stop_flags_if_alone) - -### Lua Example -`set_time_stop_flags_if_alone(flags)` - -### Parameters -| Field | Type | -| ----- | ---- | -| flags | `integer` | - -### Returns -- None - -### C Prototype -`void set_time_stop_flags_if_alone(s32 flags);` - -[:arrow_up_small:](#) - -
- -## [signum_positive](#signum_positive) - -### Lua Example -`local integerValue = signum_positive(x)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 signum_positive(s32 x);` - -[:arrow_up_small:](#) - -
- -## [spawn_base_star_with_no_lvl_exit](#spawn_base_star_with_no_lvl_exit) - -### Lua Example -`spawn_base_star_with_no_lvl_exit()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void spawn_base_star_with_no_lvl_exit(void);` - -[:arrow_up_small:](#) - -
- -## [spawn_mist_particles](#spawn_mist_particles) - -### Lua Example -`spawn_mist_particles()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void spawn_mist_particles(void);` - -[:arrow_up_small:](#) - -
- -## [spawn_mist_particles_with_sound](#spawn_mist_particles_with_sound) - -### Lua Example -`spawn_mist_particles_with_sound(sp18)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp18 | `integer` | - -### Returns -- None - -### C Prototype -`void spawn_mist_particles_with_sound(u32 sp18);` - -[:arrow_up_small:](#) - -
- -## [spawn_star_with_no_lvl_exit](#spawn_star_with_no_lvl_exit) - -### Lua Example -`local ObjectValue = spawn_star_with_no_lvl_exit(sp20, sp24)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp20 | `integer` | -| sp24 | `integer` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *spawn_star_with_no_lvl_exit(s32 sp20, s32 sp24);` - -[:arrow_up_small:](#) - -
- -## [spawn_water_droplet](#spawn_water_droplet) - -### Lua Example -`local ObjectValue = spawn_water_droplet(parent, params)` - -### Parameters -| Field | Type | -| ----- | ---- | -| parent | [Object](structs.md#Object) | -| params | [WaterDropletParams](structs.md#WaterDropletParams) | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *spawn_water_droplet(struct Object *parent, struct WaterDropletParams *params);` - -[:arrow_up_small:](#) - -
- -## [stub_obj_helpers_3](#stub_obj_helpers_3) - -### Lua Example -`stub_obj_helpers_3(sp0, sp4)` - -### Parameters -| Field | Type | -| ----- | ---- | -| sp0 | `integer` | -| sp4 | `integer` | - -### Returns -- None - -### C Prototype -`void stub_obj_helpers_3(UNUSED s32 sp0, UNUSED s32 sp4);` - -[:arrow_up_small:](#) - -
- -## [stub_obj_helpers_4](#stub_obj_helpers_4) - -### Lua Example -`stub_obj_helpers_4()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void stub_obj_helpers_4(void);` - -[:arrow_up_small:](#) - -
- ---- -# functions from object_list_processor.h - -
- - -## [set_object_respawn_info_bits](#set_object_respawn_info_bits) - -### Lua Example -`set_object_respawn_info_bits(obj, bits)` - -### Parameters -| Field | Type | -| ----- | ---- | -| obj | [Object](structs.md#Object) | -| bits | `integer` | - -### Returns -- None - -### C Prototype -`void set_object_respawn_info_bits(struct Object *obj, u8 bits);` - -[:arrow_up_small:](#) - -
- ---- -# functions from rumble_init.c - -
- - -## [queue_rumble_data](#queue_rumble_data) - -### Lua Example -`queue_rumble_data(a0, a1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a0 | `integer` | -| a1 | `integer` | - -### Returns -- None - -### C Prototype -`void queue_rumble_data(s16 a0, s16 a1);` - -[:arrow_up_small:](#) - -
- -## [queue_rumble_data_mario](#queue_rumble_data_mario) - -### Lua Example -`queue_rumble_data_mario(m, a0, a1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | -| a0 | `integer` | -| a1 | `integer` | - -### Returns -- None - -### C Prototype -`void queue_rumble_data_mario(struct MarioState* m, s16 a0, s16 a1);` - -[:arrow_up_small:](#) - -
- -## [queue_rumble_data_object](#queue_rumble_data_object) - -### Lua Example -`queue_rumble_data_object(object, a0, a1)` - -### Parameters -| Field | Type | -| ----- | ---- | -| object | [Object](structs.md#Object) | -| a0 | `integer` | -| a1 | `integer` | - -### Returns -- None - -### C Prototype -`void queue_rumble_data_object(struct Object* object, s16 a0, s16 a1);` - -[:arrow_up_small:](#) - -
- -## [reset_rumble_timers](#reset_rumble_timers) - -### Lua Example -`reset_rumble_timers(m)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | - -### Returns -- None - -### C Prototype -`void reset_rumble_timers(struct MarioState* m);` - -[:arrow_up_small:](#) - -
- -## [reset_rumble_timers_2](#reset_rumble_timers_2) - -### Lua Example -`reset_rumble_timers_2(m, a0)` - -### Parameters -| Field | Type | -| ----- | ---- | -| m | [MarioState](structs.md#MarioState) | -| a0 | `integer` | - -### Returns -- None - -### C Prototype -`void reset_rumble_timers_2(struct MarioState* m, s32 a0);` - -[:arrow_up_small:](#) -
--- -[< prev](functions-3.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | 4 | [5](functions-5.md) | [next >](functions-5.md)] +[< prev](functions-3.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | 4 | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-5.md)] diff --git a/docs/lua/functions-5.md b/docs/lua/functions-5.md index 249f70592..a90c768ea 100644 --- a/docs/lua/functions-5.md +++ b/docs/lua/functions-5.md @@ -2,9 +2,4706 @@ --- -[< prev](functions-4.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | 5] +[< prev](functions-4.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | 5 | [6](functions-6.md) | [next >](functions-6.md)] +--- +# functions from object_helpers.c + +
+ + +## [abs_angle_diff](#abs_angle_diff) + +### Lua Example +`local integerValue = abs_angle_diff(x0, x1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x0 | `integer` | +| x1 | `integer` | + +### Returns +- `integer` + +### C Prototype +`s16 abs_angle_diff(s16 x0, s16 x1);` + +[:arrow_up_small:](#) + +
+ +## [apply_drag_to_value](#apply_drag_to_value) + +### Lua Example +`apply_drag_to_value(value, dragStrength)` + +### Parameters +| Field | Type | +| ----- | ---- | +| value | `Pointer` <`number`> | +| dragStrength | `number` | + +### Returns +- None + +### C Prototype +`void apply_drag_to_value(f32 *value, f32 dragStrength);` + +[:arrow_up_small:](#) + +
+ +## [approach_f32_signed](#approach_f32_signed) + +### Lua Example +`local integerValue = approach_f32_signed(value, target, increment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| value | `Pointer` <`number`> | +| target | `number` | +| increment | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 approach_f32_signed(f32 *value, f32 target, f32 increment);` + +[:arrow_up_small:](#) + +
+ +## [approach_f32_symmetric](#approach_f32_symmetric) + +### Lua Example +`local numberValue = approach_f32_symmetric(value, target, increment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| value | `number` | +| target | `number` | +| increment | `number` | + +### Returns +- `number` + +### C Prototype +`f32 approach_f32_symmetric(f32 value, f32 target, f32 increment);` + +[:arrow_up_small:](#) + +
+ +## [approach_s16_symmetric](#approach_s16_symmetric) + +### Lua Example +`local integerValue = approach_s16_symmetric(value, target, increment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| value | `integer` | +| target | `integer` | +| increment | `integer` | + +### Returns +- `integer` + +### C Prototype +`s16 approach_s16_symmetric(s16 value, s16 target, s16 increment);` + +[:arrow_up_small:](#) + +
+ +## [bhv_dust_smoke_loop](#bhv_dust_smoke_loop) + +### Lua Example +`bhv_dust_smoke_loop()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void bhv_dust_smoke_loop(void);` + +[:arrow_up_small:](#) + +
+ +## [bhv_init_room](#bhv_init_room) + +### Lua Example +`bhv_init_room()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void bhv_init_room(void);` + +[:arrow_up_small:](#) + +
+ +## [bit_shift_left](#bit_shift_left) + +### Lua Example +`local integerValue = bit_shift_left(a0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 bit_shift_left(s32 a0);` + +[:arrow_up_small:](#) + +
+ +## [chain_segment_init](#chain_segment_init) + +### Lua Example +`chain_segment_init(segment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| segment | [ChainSegment](structs.md#ChainSegment) | + +### Returns +- None + +### C Prototype +`void chain_segment_init(struct ChainSegment *segment);` + +[:arrow_up_small:](#) + +
+ +## [clear_move_flag](#clear_move_flag) + +### Lua Example +`local integerValue = clear_move_flag(bitSet, flag)` + +### Parameters +| Field | Type | +| ----- | ---- | +| bitSet | `Pointer` <`integer`> | +| flag | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 clear_move_flag(u32 *bitSet, s32 flag);` + +[:arrow_up_small:](#) + +
+ +## [clear_time_stop_flags](#clear_time_stop_flags) + +### Lua Example +`clear_time_stop_flags(flags)` + +### Parameters +| Field | Type | +| ----- | ---- | +| flags | `integer` | + +### Returns +- None + +### C Prototype +`void clear_time_stop_flags(s32 flags);` + +[:arrow_up_small:](#) + +
+ +## [count_objects_with_behavior](#count_objects_with_behavior) + +### Lua Example +`local integerValue = count_objects_with_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- `integer` + +### C Prototype +`s32 count_objects_with_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [count_unimportant_objects](#count_unimportant_objects) + +### Lua Example +`local integerValue = count_unimportant_objects()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 count_unimportant_objects(void);` + +[:arrow_up_small:](#) + +
+ +## [create_transformation_from_matrices](#create_transformation_from_matrices) + +### Lua Example +`create_transformation_from_matrices(a0, a1, a2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `Mat4` | +| a1 | `Mat4` | +| a2 | `Mat4` | + +### Returns +- None + +### C Prototype +`void create_transformation_from_matrices(Mat4 a0, Mat4 a1, Mat4 a2);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_abs_y_dist_to_home](#cur_obj_abs_y_dist_to_home) + +### Lua Example +`local numberValue = cur_obj_abs_y_dist_to_home()` + +### Parameters +- None + +### Returns +- `number` + +### C Prototype +`f32 cur_obj_abs_y_dist_to_home(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_advance_looping_anim](#cur_obj_advance_looping_anim) + +### Lua Example +`local integerValue = cur_obj_advance_looping_anim()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_advance_looping_anim(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_align_gfx_with_floor](#cur_obj_align_gfx_with_floor) + +### Lua Example +`cur_obj_align_gfx_with_floor()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_align_gfx_with_floor(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_angle_to_home](#cur_obj_angle_to_home) + +### Lua Example +`local integerValue = cur_obj_angle_to_home()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s16 cur_obj_angle_to_home(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_apply_drag_xz](#cur_obj_apply_drag_xz) + +### Lua Example +`cur_obj_apply_drag_xz(dragStrength)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dragStrength | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_apply_drag_xz(f32 dragStrength);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_become_intangible](#cur_obj_become_intangible) + +### Lua Example +`cur_obj_become_intangible()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_become_intangible(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_become_tangible](#cur_obj_become_tangible) + +### Lua Example +`cur_obj_become_tangible()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_become_tangible(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_can_mario_activate_textbox](#cur_obj_can_mario_activate_textbox) + +### Lua Example +`local integerValue = cur_obj_can_mario_activate_textbox(m, radius, height, unused)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | +| radius | `number` | +| height | `number` | +| unused | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_can_mario_activate_textbox(struct MarioState* m, f32 radius, f32 height, UNUSED s32 unused);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_can_mario_activate_textbox_2](#cur_obj_can_mario_activate_textbox_2) + +### Lua Example +`local integerValue = cur_obj_can_mario_activate_textbox_2(m, radius, height)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | +| radius | `number` | +| height | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_can_mario_activate_textbox_2(struct MarioState* m, f32 radius, f32 height);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_change_action](#cur_obj_change_action) + +### Lua Example +`cur_obj_change_action(action)` + +### Parameters +| Field | Type | +| ----- | ---- | +| action | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_change_action(s32 action);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_anim_frame](#cur_obj_check_anim_frame) + +### Lua Example +`local integerValue = cur_obj_check_anim_frame(frame)` + +### Parameters +| Field | Type | +| ----- | ---- | +| frame | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_anim_frame(s32 frame);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_anim_frame_in_range](#cur_obj_check_anim_frame_in_range) + +### Lua Example +`local integerValue = cur_obj_check_anim_frame_in_range(startFrame, rangeLength)` + +### Parameters +| Field | Type | +| ----- | ---- | +| startFrame | `integer` | +| rangeLength | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_anim_frame_in_range(s32 startFrame, s32 rangeLength);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_frame_prior_current_frame](#cur_obj_check_frame_prior_current_frame) + +### Lua Example +`local integerValue = cur_obj_check_frame_prior_current_frame(a0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `Pointer` <`integer`> | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_frame_prior_current_frame(s16 *a0);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_grabbed_mario](#cur_obj_check_grabbed_mario) + +### Lua Example +`local integerValue = cur_obj_check_grabbed_mario()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_grabbed_mario(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_if_at_animation_end](#cur_obj_check_if_at_animation_end) + +### Lua Example +`local integerValue = cur_obj_check_if_at_animation_end()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_if_at_animation_end(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_if_near_animation_end](#cur_obj_check_if_near_animation_end) + +### Lua Example +`local integerValue = cur_obj_check_if_near_animation_end()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_if_near_animation_end(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_check_interacted](#cur_obj_check_interacted) + +### Lua Example +`local integerValue = cur_obj_check_interacted()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_check_interacted(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_clear_interact_status_flag](#cur_obj_clear_interact_status_flag) + +### Lua Example +`local integerValue = cur_obj_clear_interact_status_flag(flag)` + +### Parameters +| Field | Type | +| ----- | ---- | +| flag | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_clear_interact_status_flag(s32 flag);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_compute_vel_xz](#cur_obj_compute_vel_xz) + +### Lua Example +`cur_obj_compute_vel_xz()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_compute_vel_xz(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_count_objects_with_behavior](#cur_obj_count_objects_with_behavior) + +### Lua Example +`local integerValue = cur_obj_count_objects_with_behavior(behavior, dist)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | +| dist | `number` | + +### Returns +- `integer` + +### C Prototype +`u16 cur_obj_count_objects_with_behavior(const BehaviorScript* behavior, f32 dist);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_detect_steep_floor](#cur_obj_detect_steep_floor) + +### Lua Example +`local integerValue = cur_obj_detect_steep_floor(steepAngleDegrees)` + +### Parameters +| Field | Type | +| ----- | ---- | +| steepAngleDegrees | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_detect_steep_floor(s16 steepAngleDegrees);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_disable](#cur_obj_disable) + +### Lua Example +`cur_obj_disable()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_disable(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_disable_rendering](#cur_obj_disable_rendering) + +### Lua Example +`cur_obj_disable_rendering()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_disable_rendering(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_disable_rendering_and_become_intangible](#cur_obj_disable_rendering_and_become_intangible) + +### Lua Example +`cur_obj_disable_rendering_and_become_intangible(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void cur_obj_disable_rendering_and_become_intangible(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_dist_to_nearest_object_with_behavior](#cur_obj_dist_to_nearest_object_with_behavior) + +### Lua Example +`local numberValue = cur_obj_dist_to_nearest_object_with_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- `number` + +### C Prototype +`f32 cur_obj_dist_to_nearest_object_with_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_enable_rendering](#cur_obj_enable_rendering) + +### Lua Example +`cur_obj_enable_rendering()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_enable_rendering(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_enable_rendering_2](#cur_obj_enable_rendering_2) + +### Lua Example +`cur_obj_enable_rendering_2()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_enable_rendering_2(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_enable_rendering_and_become_tangible](#cur_obj_enable_rendering_and_become_tangible) + +### Lua Example +`cur_obj_enable_rendering_and_become_tangible(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void cur_obj_enable_rendering_and_become_tangible(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_enable_rendering_if_mario_in_room](#cur_obj_enable_rendering_if_mario_in_room) + +### Lua Example +`cur_obj_enable_rendering_if_mario_in_room()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_enable_rendering_if_mario_in_room(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_end_dialog](#cur_obj_end_dialog) + +### Lua Example +`cur_obj_end_dialog(m, dialogFlags, dialogResult)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | +| dialogFlags | `integer` | +| dialogResult | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_end_dialog(struct MarioState* m, s32 dialogFlags, s32 dialogResult);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_extend_animation_if_at_end](#cur_obj_extend_animation_if_at_end) + +### Lua Example +`cur_obj_extend_animation_if_at_end()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_extend_animation_if_at_end(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_find_nearby_held_actor](#cur_obj_find_nearby_held_actor) + +### Lua Example +`local ObjectValue = cur_obj_find_nearby_held_actor(behavior, maxDist)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | +| maxDist | `number` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *cur_obj_find_nearby_held_actor(const BehaviorScript *behavior, f32 maxDist);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_find_nearest_object_with_behavior](#cur_obj_find_nearest_object_with_behavior) + +### Lua Example +`local ObjectValue = cur_obj_find_nearest_object_with_behavior(behavior, dist)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | +| dist | `Pointer` <`number`> | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *cur_obj_find_nearest_object_with_behavior(const BehaviorScript *behavior, f32 *dist);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_find_nearest_pole](#cur_obj_find_nearest_pole) + +### Lua Example +`local ObjectValue = cur_obj_find_nearest_pole()` + +### Parameters +- None + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object* cur_obj_find_nearest_pole(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_follow_path](#cur_obj_follow_path) + +### Lua Example +`local integerValue = cur_obj_follow_path(unusedArg)` + +### Parameters +| Field | Type | +| ----- | ---- | +| unusedArg | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_follow_path(UNUSED s32 unusedArg);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_forward_vel_approach_upward](#cur_obj_forward_vel_approach_upward) + +### Lua Example +`cur_obj_forward_vel_approach_upward(target, increment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| target | `number` | +| increment | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_forward_vel_approach_upward(f32 target, f32 increment);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_get_dropped](#cur_obj_get_dropped) + +### Lua Example +`cur_obj_get_dropped()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_get_dropped(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_get_thrown_or_placed](#cur_obj_get_thrown_or_placed) + +### Lua Example +`cur_obj_get_thrown_or_placed(forwardVel, velY, thrownAction)` + +### Parameters +| Field | Type | +| ----- | ---- | +| forwardVel | `number` | +| velY | `number` | +| thrownAction | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_get_thrown_or_placed(f32 forwardVel, f32 velY, s32 thrownAction);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_has_behavior](#cur_obj_has_behavior) + +### Lua Example +`local integerValue = cur_obj_has_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_has_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_has_model](#cur_obj_has_model) + +### Lua Example +`local integerValue = cur_obj_has_model(modelID)` + +### Parameters +| Field | Type | +| ----- | ---- | +| modelID | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_has_model(u16 modelID);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_hide](#cur_obj_hide) + +### Lua Example +`cur_obj_hide()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_hide(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_hide_if_mario_far_away_y](#cur_obj_hide_if_mario_far_away_y) + +### Lua Example +`local integerValue = cur_obj_hide_if_mario_far_away_y(distY)` + +### Parameters +| Field | Type | +| ----- | ---- | +| distY | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_hide_if_mario_far_away_y(f32 distY);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_if_hit_wall_bounce_away](#cur_obj_if_hit_wall_bounce_away) + +### Lua Example +`cur_obj_if_hit_wall_bounce_away()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_if_hit_wall_bounce_away(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_init_animation](#cur_obj_init_animation) + +### Lua Example +`cur_obj_init_animation(animIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animIndex | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_init_animation(s32 animIndex);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_init_animation_and_anim_frame](#cur_obj_init_animation_and_anim_frame) + +### Lua Example +`cur_obj_init_animation_and_anim_frame(animIndex, animFrame)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animIndex | `integer` | +| animFrame | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_init_animation_and_anim_frame(s32 animIndex, s32 animFrame);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_init_animation_and_check_if_near_end](#cur_obj_init_animation_and_check_if_near_end) + +### Lua Example +`local integerValue = cur_obj_init_animation_and_check_if_near_end(animIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animIndex | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_init_animation_and_check_if_near_end(s32 animIndex);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_init_animation_and_extend_if_at_end](#cur_obj_init_animation_and_extend_if_at_end) + +### Lua Example +`cur_obj_init_animation_and_extend_if_at_end(animIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animIndex | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_init_animation_and_extend_if_at_end(s32 animIndex);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_init_animation_with_accel_and_sound](#cur_obj_init_animation_with_accel_and_sound) + +### Lua Example +`cur_obj_init_animation_with_accel_and_sound(animIndex, accel)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animIndex | `integer` | +| accel | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_init_animation_with_accel_and_sound(s32 animIndex, f32 accel);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_init_animation_with_sound](#cur_obj_init_animation_with_sound) + +### Lua Example +`cur_obj_init_animation_with_sound(animIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animIndex | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_init_animation_with_sound(s32 animIndex);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_is_any_player_on_platform](#cur_obj_is_any_player_on_platform) + +### Lua Example +`local integerValue = cur_obj_is_any_player_on_platform()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_is_any_player_on_platform(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_is_mario_ground_pounding_platform](#cur_obj_is_mario_ground_pounding_platform) + +### Lua Example +`local integerValue = cur_obj_is_mario_ground_pounding_platform()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_is_mario_ground_pounding_platform(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_is_mario_on_platform](#cur_obj_is_mario_on_platform) + +### Lua Example +`local integerValue = cur_obj_is_mario_on_platform()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_is_mario_on_platform(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_lateral_dist_from_mario_to_home](#cur_obj_lateral_dist_from_mario_to_home) + +### Lua Example +`local numberValue = cur_obj_lateral_dist_from_mario_to_home()` + +### Parameters +- None + +### Returns +- `number` + +### C Prototype +`f32 cur_obj_lateral_dist_from_mario_to_home(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_lateral_dist_from_obj_to_home](#cur_obj_lateral_dist_from_obj_to_home) + +### Lua Example +`local numberValue = cur_obj_lateral_dist_from_obj_to_home(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- `number` + +### C Prototype +`f32 cur_obj_lateral_dist_from_obj_to_home(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_lateral_dist_to_home](#cur_obj_lateral_dist_to_home) + +### Lua Example +`local numberValue = cur_obj_lateral_dist_to_home()` + +### Parameters +- None + +### Returns +- `number` + +### C Prototype +`f32 cur_obj_lateral_dist_to_home(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_mario_far_away](#cur_obj_mario_far_away) + +### Lua Example +`local integerValue = cur_obj_mario_far_away()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_mario_far_away(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_after_thrown_or_dropped](#cur_obj_move_after_thrown_or_dropped) + +### Lua Example +`cur_obj_move_after_thrown_or_dropped(forwardVel, velY)` + +### Parameters +| Field | Type | +| ----- | ---- | +| forwardVel | `number` | +| velY | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_move_after_thrown_or_dropped(f32 forwardVel, f32 velY);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_standard](#cur_obj_move_standard) + +### Lua Example +`cur_obj_move_standard(steepSlopeAngleDegrees)` + +### Parameters +| Field | Type | +| ----- | ---- | +| steepSlopeAngleDegrees | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_move_standard(s16 steepSlopeAngleDegrees);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_up_and_down](#cur_obj_move_up_and_down) + +### Lua Example +`local integerValue = cur_obj_move_up_and_down(a0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_move_up_and_down(s32 a0);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_update_ground_air_flags](#cur_obj_move_update_ground_air_flags) + +### Lua Example +`cur_obj_move_update_ground_air_flags(gravity, bounciness)` + +### Parameters +| Field | Type | +| ----- | ---- | +| gravity | `number` | +| bounciness | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_move_update_ground_air_flags(UNUSED f32 gravity, f32 bounciness);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_update_underwater_flags](#cur_obj_move_update_underwater_flags) + +### Lua Example +`cur_obj_move_update_underwater_flags()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_move_update_underwater_flags(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_using_fvel_and_gravity](#cur_obj_move_using_fvel_and_gravity) + +### Lua Example +`cur_obj_move_using_fvel_and_gravity()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_move_using_fvel_and_gravity(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_using_vel](#cur_obj_move_using_vel) + +### Lua Example +`cur_obj_move_using_vel()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_move_using_vel(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_using_vel_and_gravity](#cur_obj_move_using_vel_and_gravity) + +### Lua Example +`cur_obj_move_using_vel_and_gravity()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_move_using_vel_and_gravity(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_xz](#cur_obj_move_xz) + +### Lua Example +`local integerValue = cur_obj_move_xz(steepSlopeNormalY, careAboutEdgesAndSteepSlopes)` + +### Parameters +| Field | Type | +| ----- | ---- | +| steepSlopeNormalY | `number` | +| careAboutEdgesAndSteepSlopes | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_move_xz(f32 steepSlopeNormalY, s32 careAboutEdgesAndSteepSlopes);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_xz_using_fvel_and_yaw](#cur_obj_move_xz_using_fvel_and_yaw) + +### Lua Example +`cur_obj_move_xz_using_fvel_and_yaw()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_move_xz_using_fvel_and_yaw(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_y](#cur_obj_move_y) + +### Lua Example +`cur_obj_move_y(gravity, bounciness, buoyancy)` + +### Parameters +| Field | Type | +| ----- | ---- | +| gravity | `number` | +| bounciness | `number` | +| buoyancy | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_move_y(f32 gravity, f32 bounciness, f32 buoyancy);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_y_and_get_water_level](#cur_obj_move_y_and_get_water_level) + +### Lua Example +`local numberValue = cur_obj_move_y_and_get_water_level(gravity, buoyancy)` + +### Parameters +| Field | Type | +| ----- | ---- | +| gravity | `number` | +| buoyancy | `number` | + +### Returns +- `number` + +### C Prototype +`f32 cur_obj_move_y_and_get_water_level(f32 gravity, f32 buoyancy);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_move_y_with_terminal_vel](#cur_obj_move_y_with_terminal_vel) + +### Lua Example +`cur_obj_move_y_with_terminal_vel()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_move_y_with_terminal_vel(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_nearest_object_with_behavior](#cur_obj_nearest_object_with_behavior) + +### Lua Example +`local ObjectValue = cur_obj_nearest_object_with_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *cur_obj_nearest_object_with_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_outside_home_rectangle](#cur_obj_outside_home_rectangle) + +### Lua Example +`local integerValue = cur_obj_outside_home_rectangle(minX, maxX, minZ, maxZ)` + +### Parameters +| Field | Type | +| ----- | ---- | +| minX | `number` | +| maxX | `number` | +| minZ | `number` | +| maxZ | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_outside_home_rectangle(f32 minX, f32 maxX, f32 minZ, f32 maxZ);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_outside_home_square](#cur_obj_outside_home_square) + +### Lua Example +`local integerValue = cur_obj_outside_home_square(halfLength)` + +### Parameters +| Field | Type | +| ----- | ---- | +| halfLength | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_outside_home_square(f32 halfLength);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_push_mario_away](#cur_obj_push_mario_away) + +### Lua Example +`cur_obj_push_mario_away(radius)` + +### Parameters +| Field | Type | +| ----- | ---- | +| radius | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_push_mario_away(f32 radius);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_push_mario_away_from_cylinder](#cur_obj_push_mario_away_from_cylinder) + +### Lua Example +`cur_obj_push_mario_away_from_cylinder(radius, extentY)` + +### Parameters +| Field | Type | +| ----- | ---- | +| radius | `number` | +| extentY | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_push_mario_away_from_cylinder(f32 radius, f32 extentY);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_reflect_move_angle_off_wall](#cur_obj_reflect_move_angle_off_wall) + +### Lua Example +`local integerValue = cur_obj_reflect_move_angle_off_wall()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s16 cur_obj_reflect_move_angle_off_wall(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_reset_timer_and_subaction](#cur_obj_reset_timer_and_subaction) + +### Lua Example +`cur_obj_reset_timer_and_subaction()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_reset_timer_and_subaction(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_resolve_wall_collisions](#cur_obj_resolve_wall_collisions) + +### Lua Example +`local integerValue = cur_obj_resolve_wall_collisions()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_resolve_wall_collisions(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_reverse_animation](#cur_obj_reverse_animation) + +### Lua Example +`cur_obj_reverse_animation()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_reverse_animation(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_rotate_face_angle_using_vel](#cur_obj_rotate_face_angle_using_vel) + +### Lua Example +`cur_obj_rotate_face_angle_using_vel()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_rotate_face_angle_using_vel(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_rotate_move_angle_using_vel](#cur_obj_rotate_move_angle_using_vel) + +### Lua Example +`cur_obj_rotate_move_angle_using_vel()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_rotate_move_angle_using_vel(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_rotate_yaw_toward](#cur_obj_rotate_yaw_toward) + +### Lua Example +`local integerValue = cur_obj_rotate_yaw_toward(target, increment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| target | `integer` | +| increment | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_rotate_yaw_toward(s16 target, s16 increment);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_scale](#cur_obj_scale) + +### Lua Example +`cur_obj_scale(scale)` + +### Parameters +| Field | Type | +| ----- | ---- | +| scale | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_scale(f32 scale);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_scale_over_time](#cur_obj_scale_over_time) + +### Lua Example +`cur_obj_scale_over_time(a0, a1, sp10, sp14)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `integer` | +| a1 | `integer` | +| sp10 | `number` | +| sp14 | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_scale_over_time(s32 a0, s32 a1, f32 sp10, f32 sp14);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_behavior](#cur_obj_set_behavior) + +### Lua Example +`cur_obj_set_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- None + +### C Prototype +`void cur_obj_set_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_billboard_if_vanilla_cam](#cur_obj_set_billboard_if_vanilla_cam) + +### Lua Example +`cur_obj_set_billboard_if_vanilla_cam()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_billboard_if_vanilla_cam(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_face_angle_to_move_angle](#cur_obj_set_face_angle_to_move_angle) + +### Lua Example +`cur_obj_set_face_angle_to_move_angle()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_face_angle_to_move_angle(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_hitbox_and_die_if_attacked](#cur_obj_set_hitbox_and_die_if_attacked) + +### Lua Example +`local integerValue = cur_obj_set_hitbox_and_die_if_attacked(hitbox, deathSound, noLootCoins)` + +### Parameters +| Field | Type | +| ----- | ---- | +| hitbox | [ObjectHitbox](structs.md#ObjectHitbox) | +| deathSound | `integer` | +| noLootCoins | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_set_hitbox_and_die_if_attacked(struct ObjectHitbox *hitbox, s32 deathSound, s32 noLootCoins);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_hitbox_radius_and_height](#cur_obj_set_hitbox_radius_and_height) + +### Lua Example +`cur_obj_set_hitbox_radius_and_height(radius, height)` + +### Parameters +| Field | Type | +| ----- | ---- | +| radius | `number` | +| height | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_set_hitbox_radius_and_height(f32 radius, f32 height);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_home_once](#cur_obj_set_home_once) + +### Lua Example +`cur_obj_set_home_once()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_home_once(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_hurtbox_radius_and_height](#cur_obj_set_hurtbox_radius_and_height) + +### Lua Example +`cur_obj_set_hurtbox_radius_and_height(radius, height)` + +### Parameters +| Field | Type | +| ----- | ---- | +| radius | `number` | +| height | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_set_hurtbox_radius_and_height(f32 radius, f32 height);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_pos_relative](#cur_obj_set_pos_relative) + +### Lua Example +`cur_obj_set_pos_relative(other, dleft, dy, dforward)` + +### Parameters +| Field | Type | +| ----- | ---- | +| other | [Object](structs.md#Object) | +| dleft | `number` | +| dy | `number` | +| dforward | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_set_pos_relative(struct Object *other, f32 dleft, f32 dy, f32 dforward);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_pos_relative_to_parent](#cur_obj_set_pos_relative_to_parent) + +### Lua Example +`cur_obj_set_pos_relative_to_parent(dleft, dy, dforward)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dleft | `number` | +| dy | `number` | +| dforward | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_set_pos_relative_to_parent(f32 dleft, f32 dy, f32 dforward);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_pos_to_home](#cur_obj_set_pos_to_home) + +### Lua Example +`cur_obj_set_pos_to_home()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_pos_to_home(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_pos_to_home_and_stop](#cur_obj_set_pos_to_home_and_stop) + +### Lua Example +`cur_obj_set_pos_to_home_and_stop()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_pos_to_home_and_stop(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_pos_to_home_with_debug](#cur_obj_set_pos_to_home_with_debug) + +### Lua Example +`cur_obj_set_pos_to_home_with_debug()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_pos_to_home_with_debug(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_pos_via_transform](#cur_obj_set_pos_via_transform) + +### Lua Example +`cur_obj_set_pos_via_transform()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_set_pos_via_transform(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_vel_from_mario_vel](#cur_obj_set_vel_from_mario_vel) + +### Lua Example +`cur_obj_set_vel_from_mario_vel(m, f12, f14)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | +| f12 | `number` | +| f14 | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_set_vel_from_mario_vel(struct MarioState* m, f32 f12, f32 f14);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_set_y_vel_and_animation](#cur_obj_set_y_vel_and_animation) + +### Lua Example +`cur_obj_set_y_vel_and_animation(sp18, sp1C)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp18 | `number` | +| sp1C | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_set_y_vel_and_animation(f32 sp18, s32 sp1C);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_shake_screen](#cur_obj_shake_screen) + +### Lua Example +`cur_obj_shake_screen(shake)` + +### Parameters +| Field | Type | +| ----- | ---- | +| shake | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_shake_screen(s32 shake);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_shake_y](#cur_obj_shake_y) + +### Lua Example +`cur_obj_shake_y(amount)` + +### Parameters +| Field | Type | +| ----- | ---- | +| amount | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_shake_y(f32 amount);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_shake_y_until](#cur_obj_shake_y_until) + +### Lua Example +`local integerValue = cur_obj_shake_y_until(cycles, amount)` + +### Parameters +| Field | Type | +| ----- | ---- | +| cycles | `integer` | +| amount | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_shake_y_until(s32 cycles, s32 amount);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_spawn_loot_blue_coin](#cur_obj_spawn_loot_blue_coin) + +### Lua Example +`cur_obj_spawn_loot_blue_coin()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_spawn_loot_blue_coin(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_spawn_loot_coin_at_mario_pos](#cur_obj_spawn_loot_coin_at_mario_pos) + +### Lua Example +`cur_obj_spawn_loot_coin_at_mario_pos(m)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | + +### Returns +- None + +### C Prototype +`void cur_obj_spawn_loot_coin_at_mario_pos(struct MarioState* m);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_spawn_particles](#cur_obj_spawn_particles) + +### Lua Example +`cur_obj_spawn_particles(info)` + +### Parameters +| Field | Type | +| ----- | ---- | +| info | [SpawnParticlesInfo](structs.md#SpawnParticlesInfo) | + +### Returns +- None + +### C Prototype +`void cur_obj_spawn_particles(struct SpawnParticlesInfo *info);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_spawn_star_at_y_offset](#cur_obj_spawn_star_at_y_offset) + +### Lua Example +`cur_obj_spawn_star_at_y_offset(targetX, targetY, targetZ, offsetY)` + +### Parameters +| Field | Type | +| ----- | ---- | +| targetX | `number` | +| targetY | `number` | +| targetZ | `number` | +| offsetY | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_spawn_star_at_y_offset(f32 targetX, f32 targetY, f32 targetZ, f32 offsetY);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_start_cam_event](#cur_obj_start_cam_event) + +### Lua Example +`cur_obj_start_cam_event(obj, cameraEvent)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| cameraEvent | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_start_cam_event(UNUSED struct Object *obj, s32 cameraEvent);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_unhide](#cur_obj_unhide) + +### Lua Example +`cur_obj_unhide()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_unhide(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_unrender_and_reset_state](#cur_obj_unrender_and_reset_state) + +### Lua Example +`cur_obj_unrender_and_reset_state(sp18, sp1C)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp18 | `integer` | +| sp1C | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_unrender_and_reset_state(s32 sp18, s32 sp1C);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_unused_init_on_floor](#cur_obj_unused_init_on_floor) + +### Lua Example +`cur_obj_unused_init_on_floor()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_unused_init_on_floor(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_unused_play_footstep_sound](#cur_obj_unused_play_footstep_sound) + +### Lua Example +`cur_obj_unused_play_footstep_sound(animFrame1, animFrame2, sound)` + +### Parameters +| Field | Type | +| ----- | ---- | +| animFrame1 | `integer` | +| animFrame2 | `integer` | +| sound | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_unused_play_footstep_sound(s32 animFrame1, s32 animFrame2, s32 sound);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_unused_resolve_wall_collisions](#cur_obj_unused_resolve_wall_collisions) + +### Lua Example +`cur_obj_unused_resolve_wall_collisions(offsetY, radius)` + +### Parameters +| Field | Type | +| ----- | ---- | +| offsetY | `number` | +| radius | `number` | + +### Returns +- None + +### C Prototype +`void cur_obj_unused_resolve_wall_collisions(f32 offsetY, f32 radius);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_update_floor](#cur_obj_update_floor) + +### Lua Example +`cur_obj_update_floor()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_update_floor(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_update_floor_and_resolve_wall_collisions](#cur_obj_update_floor_and_resolve_wall_collisions) + +### Lua Example +`cur_obj_update_floor_and_resolve_wall_collisions(steepSlopeDegrees)` + +### Parameters +| Field | Type | +| ----- | ---- | +| steepSlopeDegrees | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_update_floor_and_resolve_wall_collisions(s16 steepSlopeDegrees);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_update_floor_and_walls](#cur_obj_update_floor_and_walls) + +### Lua Example +`cur_obj_update_floor_and_walls()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_update_floor_and_walls(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_update_floor_height](#cur_obj_update_floor_height) + +### Lua Example +`cur_obj_update_floor_height()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void cur_obj_update_floor_height(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_update_floor_height_and_get_floor](#cur_obj_update_floor_height_and_get_floor) + +### Lua Example +`local SurfaceValue = cur_obj_update_floor_height_and_get_floor()` + +### Parameters +- None + +### Returns +[Surface](structs.md#Surface) + +### C Prototype +`struct Surface *cur_obj_update_floor_height_and_get_floor(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_wait_then_blink](#cur_obj_wait_then_blink) + +### Lua Example +`local integerValue = cur_obj_wait_then_blink(timeUntilBlinking, numBlinks)` + +### Parameters +| Field | Type | +| ----- | ---- | +| timeUntilBlinking | `integer` | +| numBlinks | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_wait_then_blink(s32 timeUntilBlinking, s32 numBlinks);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_was_attacked_or_ground_pounded](#cur_obj_was_attacked_or_ground_pounded) + +### Lua Example +`local integerValue = cur_obj_was_attacked_or_ground_pounded()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_was_attacked_or_ground_pounded(void);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_within_12k_bounds](#cur_obj_within_12k_bounds) + +### Lua Example +`local integerValue = cur_obj_within_12k_bounds()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 cur_obj_within_12k_bounds(void);` + +[:arrow_up_small:](#) + +
+ +## [disable_time_stop](#disable_time_stop) + +### Lua Example +`disable_time_stop()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void disable_time_stop(void);` + +[:arrow_up_small:](#) + +
+ +## [disable_time_stop_including_mario](#disable_time_stop_including_mario) + +### Lua Example +`disable_time_stop_including_mario()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void disable_time_stop_including_mario(void);` + +[:arrow_up_small:](#) + +
+ +## [dist_between_object_and_point](#dist_between_object_and_point) + +### Lua Example +`local numberValue = dist_between_object_and_point(obj, pointX, pointY, pointZ)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| pointX | `number` | +| pointY | `number` | +| pointZ | `number` | + +### Returns +- `number` + +### C Prototype +`f32 dist_between_object_and_point(struct Object *obj, f32 pointX, f32 pointY, f32 pointZ);` + +[:arrow_up_small:](#) + +
+ +## [dist_between_objects](#dist_between_objects) + +### Lua Example +`local numberValue = dist_between_objects(obj1, obj2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj1 | [Object](structs.md#Object) | +| obj2 | [Object](structs.md#Object) | + +### Returns +- `number` + +### C Prototype +`f32 dist_between_objects(struct Object *obj1, struct Object *obj2);` + +[:arrow_up_small:](#) + +
+ +## [enable_time_stop](#enable_time_stop) + +### Lua Example +`enable_time_stop()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void enable_time_stop(void);` + +[:arrow_up_small:](#) + +
+ +## [enable_time_stop_if_alone](#enable_time_stop_if_alone) + +### Lua Example +`enable_time_stop_if_alone()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void enable_time_stop_if_alone(void);` + +[:arrow_up_small:](#) + +
+ +## [enable_time_stop_including_mario](#enable_time_stop_including_mario) + +### Lua Example +`enable_time_stop_including_mario()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void enable_time_stop_including_mario(void);` + +[:arrow_up_small:](#) + +
+ +## [find_object_with_behavior](#find_object_with_behavior) + +### Lua Example +`local ObjectValue = find_object_with_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *find_object_with_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [find_unimportant_object](#find_unimportant_object) + +### Lua Example +`local ObjectValue = find_unimportant_object()` + +### Parameters +- None + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *find_unimportant_object(void);` + +[:arrow_up_small:](#) + +
+ +## [geo_offset_klepto_debug](#geo_offset_klepto_debug) + +### Lua Example +`local integerValue = geo_offset_klepto_debug(callContext, a1, sp8)` + +### Parameters +| Field | Type | +| ----- | ---- | +| callContext | `integer` | +| a1 | [GraphNode](structs.md#GraphNode) | +| sp8 | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 geo_offset_klepto_debug(s32 callContext, struct GraphNode *a1, UNUSED s32 sp8);` + +[:arrow_up_small:](#) + +
+ +## [get_object_list_from_behavior](#get_object_list_from_behavior) + +### Lua Example +`local integerValue = get_object_list_from_behavior(behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- `integer` + +### C Prototype +`u32 get_object_list_from_behavior(const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [get_trajectory_length](#get_trajectory_length) + +### Lua Example +`local integerValue = get_trajectory_length(trajectory)` + +### Parameters +| Field | Type | +| ----- | ---- | +| trajectory | `Pointer` <`Trajectory`> | + +### Returns +- `integer` + +### C Prototype +`s32 get_trajectory_length(Trajectory* trajectory);` + +[:arrow_up_small:](#) + +
+ +## [increment_velocity_toward_range](#increment_velocity_toward_range) + +### Lua Example +`local numberValue = increment_velocity_toward_range(value, center, zeroThreshold, increment)` + +### Parameters +| Field | Type | +| ----- | ---- | +| value | `number` | +| center | `number` | +| zeroThreshold | `number` | +| increment | `number` | + +### Returns +- `number` + +### C Prototype +`f32 increment_velocity_toward_range(f32 value, f32 center, f32 zeroThreshold, f32 increment);` + +[:arrow_up_small:](#) + +
+ +## [is_item_in_array](#is_item_in_array) + +### Lua Example +`local integerValue = is_item_in_array(item, array)` + +### Parameters +| Field | Type | +| ----- | ---- | +| item | `integer` | +| array | `Pointer` <`integer`> | + +### Returns +- `integer` + +### C Prototype +`s32 is_item_in_array(s8 item, s8 *array);` + +[:arrow_up_small:](#) + +
+ +## [is_mario_moving_fast_or_in_air](#is_mario_moving_fast_or_in_air) + +### Lua Example +`local integerValue = is_mario_moving_fast_or_in_air(speedThreshold)` + +### Parameters +| Field | Type | +| ----- | ---- | +| speedThreshold | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 is_mario_moving_fast_or_in_air(s32 speedThreshold);` + +[:arrow_up_small:](#) + +
+ +## [lateral_dist_between_objects](#lateral_dist_between_objects) + +### Lua Example +`local numberValue = lateral_dist_between_objects(obj1, obj2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj1 | [Object](structs.md#Object) | +| obj2 | [Object](structs.md#Object) | + +### Returns +- `number` + +### C Prototype +`f32 lateral_dist_between_objects(struct Object *obj1, struct Object *obj2);` + +[:arrow_up_small:](#) + +
+ +## [linear_mtxf_mul_vec3f](#linear_mtxf_mul_vec3f) + +### Lua Example +`linear_mtxf_mul_vec3f(m, dst, v)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | `Mat4` | +| dst | [Vec3f](structs.md#Vec3f) | +| v | [Vec3f](structs.md#Vec3f) | + +### Returns +- None + +### C Prototype +`void linear_mtxf_mul_vec3f(Mat4 m, Vec3f dst, Vec3f v);` + +[:arrow_up_small:](#) + +
+ +## [linear_mtxf_transpose_mul_vec3f](#linear_mtxf_transpose_mul_vec3f) + +### Lua Example +`linear_mtxf_transpose_mul_vec3f(m, dst, v)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | `Mat4` | +| dst | [Vec3f](structs.md#Vec3f) | +| v | [Vec3f](structs.md#Vec3f) | + +### Returns +- None + +### C Prototype +`void linear_mtxf_transpose_mul_vec3f(Mat4 m, Vec3f dst, Vec3f v);` + +[:arrow_up_small:](#) + +
+ +## [mario_is_dive_sliding](#mario_is_dive_sliding) + +### Lua Example +`local integerValue = mario_is_dive_sliding(m)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | + +### Returns +- `integer` + +### C Prototype +`s32 mario_is_dive_sliding(struct MarioState* m);` + +[:arrow_up_small:](#) + +
+ +## [mario_is_in_air_action](#mario_is_in_air_action) + +### Lua Example +`local integerValue = mario_is_in_air_action(m)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | + +### Returns +- `integer` + +### C Prototype +`s32 mario_is_in_air_action(struct MarioState* m);` + +[:arrow_up_small:](#) + +
+ +## [mario_is_within_rectangle](#mario_is_within_rectangle) + +### Lua Example +`local integerValue = mario_is_within_rectangle(minX, maxX, minZ, maxZ)` + +### Parameters +| Field | Type | +| ----- | ---- | +| minX | `integer` | +| maxX | `integer` | +| minZ | `integer` | +| maxZ | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 mario_is_within_rectangle(s16 minX, s16 maxX, s16 minZ, s16 maxZ);` + +[:arrow_up_small:](#) + +
+ +## [mario_set_flag](#mario_set_flag) + +### Lua Example +`mario_set_flag(flag)` + +### Parameters +| Field | Type | +| ----- | ---- | +| flag | `integer` | + +### Returns +- None + +### C Prototype +`void mario_set_flag(s32 flag);` + +[:arrow_up_small:](#) + +
+ +## [obj_angle_to_object](#obj_angle_to_object) + +### Lua Example +`local integerValue = obj_angle_to_object(obj1, obj2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj1 | [Object](structs.md#Object) | +| obj2 | [Object](structs.md#Object) | + +### Returns +- `integer` + +### C Prototype +`s16 obj_angle_to_object(struct Object *obj1, struct Object *obj2);` + +[:arrow_up_small:](#) + +
+ +## [obj_angle_to_point](#obj_angle_to_point) + +### Lua Example +`local integerValue = obj_angle_to_point(obj, pointX, pointZ)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| pointX | `number` | +| pointZ | `number` | + +### Returns +- `integer` + +### C Prototype +`s16 obj_angle_to_point(struct Object *obj, f32 pointX, f32 pointZ);` + +[:arrow_up_small:](#) + +
+ +## [obj_apply_scale_to_matrix](#obj_apply_scale_to_matrix) + +### Lua Example +`obj_apply_scale_to_matrix(obj, dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| dst | `Mat4` | +| src | `Mat4` | + +### Returns +- None + +### C Prototype +`void obj_apply_scale_to_matrix(struct Object *obj, Mat4 dst, Mat4 src);` + +[:arrow_up_small:](#) + +
+ +## [obj_apply_scale_to_transform](#obj_apply_scale_to_transform) + +### Lua Example +`obj_apply_scale_to_transform(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_apply_scale_to_transform(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_attack_collided_from_other_object](#obj_attack_collided_from_other_object) + +### Lua Example +`local integerValue = obj_attack_collided_from_other_object(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- `integer` + +### C Prototype +`s32 obj_attack_collided_from_other_object(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_become_tangible](#obj_become_tangible) + +### Lua Example +`obj_become_tangible(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_become_tangible(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_build_relative_transform](#obj_build_relative_transform) + +### Lua Example +`obj_build_relative_transform(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_build_relative_transform(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_build_transform_from_pos_and_angle](#obj_build_transform_from_pos_and_angle) + +### Lua Example +`obj_build_transform_from_pos_and_angle(obj, posIndex, angleIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| posIndex | `integer` | +| angleIndex | `integer` | + +### Returns +- None + +### C Prototype +`void obj_build_transform_from_pos_and_angle(struct Object *obj, s16 posIndex, s16 angleIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_build_transform_relative_to_parent](#obj_build_transform_relative_to_parent) + +### Lua Example +`obj_build_transform_relative_to_parent(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_build_transform_relative_to_parent(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_build_vel_from_transform](#obj_build_vel_from_transform) + +### Lua Example +`obj_build_vel_from_transform(a0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_build_vel_from_transform(struct Object *a0);` + +[:arrow_up_small:](#) + +
+ +## [obj_check_if_collided_with_object](#obj_check_if_collided_with_object) + +### Lua Example +`local integerValue = obj_check_if_collided_with_object(obj1, obj2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj1 | [Object](structs.md#Object) | +| obj2 | [Object](structs.md#Object) | + +### Returns +- `integer` + +### C Prototype +`s32 obj_check_if_collided_with_object(struct Object *obj1, struct Object *obj2);` + +[:arrow_up_small:](#) + +
+ +## [obj_copy_angle](#obj_copy_angle) + +### Lua Example +`obj_copy_angle(dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dst | [Object](structs.md#Object) | +| src | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_copy_angle(struct Object *dst, struct Object *src);` + +[:arrow_up_small:](#) + +
+ +## [obj_copy_behavior_params](#obj_copy_behavior_params) + +### Lua Example +`obj_copy_behavior_params(dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dst | [Object](structs.md#Object) | +| src | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_copy_behavior_params(struct Object *dst, struct Object *src);` + +[:arrow_up_small:](#) + +
+ +## [obj_copy_graph_y_offset](#obj_copy_graph_y_offset) + +### Lua Example +`obj_copy_graph_y_offset(dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dst | [Object](structs.md#Object) | +| src | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_copy_graph_y_offset(struct Object *dst, struct Object *src);` + +[:arrow_up_small:](#) + +
+ +## [obj_copy_pos](#obj_copy_pos) + +### Lua Example +`obj_copy_pos(dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dst | [Object](structs.md#Object) | +| src | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_copy_pos(struct Object *dst, struct Object *src);` + +[:arrow_up_small:](#) + +
+ +## [obj_copy_pos_and_angle](#obj_copy_pos_and_angle) + +### Lua Example +`obj_copy_pos_and_angle(dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dst | [Object](structs.md#Object) | +| src | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_copy_pos_and_angle(struct Object *dst, struct Object *src);` + +[:arrow_up_small:](#) + +
+ +## [obj_copy_scale](#obj_copy_scale) + +### Lua Example +`obj_copy_scale(dst, src)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dst | [Object](structs.md#Object) | +| src | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_copy_scale(struct Object *dst, struct Object *src);` + +[:arrow_up_small:](#) + +
+ +## [obj_create_transform_from_self](#obj_create_transform_from_self) + +### Lua Example +`obj_create_transform_from_self(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_create_transform_from_self(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_explode_and_spawn_coins](#obj_explode_and_spawn_coins) + +### Lua Example +`obj_explode_and_spawn_coins(sp18, sp1C)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp18 | `number` | +| sp1C | `integer` | + +### Returns +- None + +### C Prototype +`void obj_explode_and_spawn_coins(f32 sp18, s32 sp1C);` + +[:arrow_up_small:](#) + +
+ +## [obj_has_behavior](#obj_has_behavior) + +### Lua Example +`local integerValue = obj_has_behavior(obj, behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- `integer` + +### C Prototype +`s32 obj_has_behavior(struct Object *obj, const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [obj_init_animation](#obj_init_animation) + +### Lua Example +`obj_init_animation(obj, animIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| animIndex | `integer` | + +### Returns +- None + +### C Prototype +`void obj_init_animation(struct Object *obj, s32 animIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_init_animation_with_accel_and_sound](#obj_init_animation_with_accel_and_sound) + +### Lua Example +`obj_init_animation_with_accel_and_sound(obj, animIndex, accel)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| animIndex | `integer` | +| accel | `number` | + +### Returns +- None + +### C Prototype +`void obj_init_animation_with_accel_and_sound(struct Object *obj, s32 animIndex, f32 accel);` + +[:arrow_up_small:](#) + +
+ +## [obj_init_animation_with_sound](#obj_init_animation_with_sound) + +### Lua Example +`obj_init_animation_with_sound(obj, animations, animIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| animations | [AnimationTable](structs.md#AnimationTable) | +| animIndex | `integer` | + +### Returns +- None + +### C Prototype +`void obj_init_animation_with_sound(struct Object *obj, const struct AnimationTable* animations, s32 animIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_hidden](#obj_is_hidden) + +### Lua Example +`local integerValue = obj_is_hidden(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- `integer` + +### C Prototype +`s32 obj_is_hidden(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_mark_for_deletion](#obj_mark_for_deletion) + +### Lua Example +`obj_mark_for_deletion(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_mark_for_deletion(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_pitch_to_object](#obj_pitch_to_object) + +### Lua Example +`local integerValue = obj_pitch_to_object(obj, target)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| target | [Object](structs.md#Object) | + +### Returns +- `integer` + +### C Prototype +`s16 obj_pitch_to_object(struct Object* obj, struct Object* target);` + +[:arrow_up_small:](#) + +
+ +## [obj_scale](#obj_scale) + +### Lua Example +`obj_scale(obj, scale)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| scale | `number` | + +### Returns +- None + +### C Prototype +`void obj_scale(struct Object *obj, f32 scale);` + +[:arrow_up_small:](#) + +
+ +## [obj_scale_random](#obj_scale_random) + +### Lua Example +`obj_scale_random(obj, rangeLength, minScale)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| rangeLength | `number` | +| minScale | `number` | + +### Returns +- None + +### C Prototype +`void obj_scale_random(struct Object *obj, f32 rangeLength, f32 minScale);` + +[:arrow_up_small:](#) + +
+ +## [obj_scale_xyz](#obj_scale_xyz) + +### Lua Example +`obj_scale_xyz(obj, xScale, yScale, zScale)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| xScale | `number` | +| yScale | `number` | +| zScale | `number` | + +### Returns +- None + +### C Prototype +`void obj_scale_xyz(struct Object *obj, f32 xScale, f32 yScale, f32 zScale);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_angle](#obj_set_angle) + +### Lua Example +`obj_set_angle(obj, pitch, yaw, roll)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| pitch | `integer` | +| yaw | `integer` | +| roll | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_behavior](#obj_set_behavior) + +### Lua Example +`obj_set_behavior(obj, behavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| behavior | `Pointer` <`BehaviorScript`> | + +### Returns +- None + +### C Prototype +`void obj_set_behavior(struct Object *obj, const BehaviorScript *behavior);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_billboard](#obj_set_billboard) + +### Lua Example +`obj_set_billboard(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_set_billboard(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_cylboard](#obj_set_cylboard) + +### Lua Example +`obj_set_cylboard(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_set_cylboard(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_face_angle](#obj_set_face_angle) + +### Lua Example +`obj_set_face_angle(obj, pitch, yaw, roll)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| pitch | `integer` | +| yaw | `integer` | +| roll | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_face_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_face_angle_to_move_angle](#obj_set_face_angle_to_move_angle) + +### Lua Example +`obj_set_face_angle_to_move_angle(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_set_face_angle_to_move_angle(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_gfx_angle](#obj_set_gfx_angle) + +### Lua Example +`obj_set_gfx_angle(obj, pitch, yaw, roll)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| pitch | `integer` | +| yaw | `integer` | +| roll | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_gfx_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_gfx_pos](#obj_set_gfx_pos) + +### Lua Example +`obj_set_gfx_pos(obj, x, y, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| x | `number` | +| y | `number` | +| z | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_gfx_pos(struct Object *obj, f32 x, f32 y, f32 z);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_gfx_pos_at_obj_pos](#obj_set_gfx_pos_at_obj_pos) + +### Lua Example +`obj_set_gfx_pos_at_obj_pos(obj1, obj2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj1 | [Object](structs.md#Object) | +| obj2 | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_set_gfx_pos_at_obj_pos(struct Object *obj1, struct Object *obj2);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_gfx_pos_from_pos](#obj_set_gfx_pos_from_pos) + +### Lua Example +`obj_set_gfx_pos_from_pos(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_set_gfx_pos_from_pos(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_gfx_scale](#obj_set_gfx_scale) + +### Lua Example +`obj_set_gfx_scale(obj, x, y, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| x | `number` | +| y | `number` | +| z | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_gfx_scale(struct Object *obj, f32 x, f32 y, f32 z);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_held_state](#obj_set_held_state) + +### Lua Example +`obj_set_held_state(obj, heldBehavior)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| heldBehavior | `Pointer` <`BehaviorScript`> | + +### Returns +- None + +### C Prototype +`void obj_set_held_state(struct Object *obj, const BehaviorScript *heldBehavior);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_hitbox](#obj_set_hitbox) + +### Lua Example +`obj_set_hitbox(obj, hitbox)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| hitbox | [ObjectHitbox](structs.md#ObjectHitbox) | + +### Returns +- None + +### C Prototype +`void obj_set_hitbox(struct Object *obj, struct ObjectHitbox *hitbox);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_hitbox_radius_and_height](#obj_set_hitbox_radius_and_height) + +### Lua Example +`obj_set_hitbox_radius_and_height(o, radius, height)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| radius | `number` | +| height | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_hitbox_radius_and_height(struct Object *o, f32 radius, f32 height);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_hurtbox_radius_and_height](#obj_set_hurtbox_radius_and_height) + +### Lua Example +`obj_set_hurtbox_radius_and_height(o, radius, height)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| radius | `number` | +| height | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_hurtbox_radius_and_height(struct Object *o, f32 radius, f32 height);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_move_angle](#obj_set_move_angle) + +### Lua Example +`obj_set_move_angle(obj, pitch, yaw, roll)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| pitch | `integer` | +| yaw | `integer` | +| roll | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_move_angle(struct Object *obj, s16 pitch, s16 yaw, s16 roll);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_parent_relative_pos](#obj_set_parent_relative_pos) + +### Lua Example +`obj_set_parent_relative_pos(obj, relX, relY, relZ)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| relX | `integer` | +| relY | `integer` | +| relZ | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_parent_relative_pos(struct Object *obj, s16 relX, s16 relY, s16 relZ);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_pos](#obj_set_pos) + +### Lua Example +`obj_set_pos(obj, x, y, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| x | `integer` | +| y | `integer` | +| z | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_pos(struct Object *obj, s16 x, s16 y, s16 z);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_pos_relative](#obj_set_pos_relative) + +### Lua Example +`obj_set_pos_relative(obj, other, dleft, dy, dforward)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| other | [Object](structs.md#Object) | +| dleft | `number` | +| dy | `number` | +| dforward | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_pos_relative(struct Object *obj, struct Object *other, f32 dleft, f32 dy, f32 dforward);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_throw_matrix_from_transform](#obj_set_throw_matrix_from_transform) + +### Lua Example +`obj_set_throw_matrix_from_transform(obj)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_set_throw_matrix_from_transform(struct Object *obj);` + +[:arrow_up_small:](#) + +
+ +## [obj_spawn_loot_blue_coins](#obj_spawn_loot_blue_coins) + +### Lua Example +`obj_spawn_loot_blue_coins(obj, numCoins, sp28, posJitter)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| numCoins | `integer` | +| sp28 | `number` | +| posJitter | `integer` | + +### Returns +- None + +### C Prototype +`void obj_spawn_loot_blue_coins(struct Object *obj, s32 numCoins, f32 sp28, s16 posJitter);` + +[:arrow_up_small:](#) + +
+ +## [obj_spawn_loot_coins](#obj_spawn_loot_coins) + +### Lua Example +`obj_spawn_loot_coins(obj, numCoins, sp30, coinBehavior, posJitter, model)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| numCoins | `integer` | +| sp30 | `number` | +| coinBehavior | `Pointer` <`BehaviorScript`> | +| posJitter | `integer` | +| model | `integer` | + +### Returns +- None + +### C Prototype +`void obj_spawn_loot_coins(struct Object *obj, s32 numCoins, f32 sp30, const BehaviorScript *coinBehavior, s16 posJitter, s16 model);` + +[:arrow_up_small:](#) + +
+ +## [obj_spawn_loot_yellow_coins](#obj_spawn_loot_yellow_coins) + +### Lua Example +`obj_spawn_loot_yellow_coins(obj, numCoins, sp28)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| numCoins | `integer` | +| sp28 | `number` | + +### Returns +- None + +### C Prototype +`void obj_spawn_loot_yellow_coins(struct Object *obj, s32 numCoins, f32 sp28);` + +[:arrow_up_small:](#) + +
+ +## [obj_translate_local](#obj_translate_local) + +### Lua Example +`obj_translate_local(obj, posIndex, localTranslateIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| posIndex | `integer` | +| localTranslateIndex | `integer` | + +### Returns +- None + +### C Prototype +`void obj_translate_local(struct Object *obj, s16 posIndex, s16 localTranslateIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_translate_xyz_random](#obj_translate_xyz_random) + +### Lua Example +`obj_translate_xyz_random(obj, rangeLength)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| rangeLength | `number` | + +### Returns +- None + +### C Prototype +`void obj_translate_xyz_random(struct Object *obj, f32 rangeLength);` + +[:arrow_up_small:](#) + +
+ +## [obj_translate_xz_random](#obj_translate_xz_random) + +### Lua Example +`obj_translate_xz_random(obj, rangeLength)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| rangeLength | `number` | + +### Returns +- None + +### C Prototype +`void obj_translate_xz_random(struct Object *obj, f32 rangeLength);` + +[:arrow_up_small:](#) + +
+ +## [obj_turn_toward_object](#obj_turn_toward_object) + +### Lua Example +`local integerValue = obj_turn_toward_object(obj, target, angleIndex, turnAmount)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| target | [Object](structs.md#Object) | +| angleIndex | `integer` | +| turnAmount | `integer` | + +### Returns +- `integer` + +### C Prototype +`s16 obj_turn_toward_object(struct Object *obj, struct Object *target, s16 angleIndex, s16 turnAmount);` + +[:arrow_up_small:](#) + +
+ +## [obj_update_pos_from_parent_transformation](#obj_update_pos_from_parent_transformation) + +### Lua Example +`obj_update_pos_from_parent_transformation(a0, a1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `Mat4` | +| a1 | [Object](structs.md#Object) | + +### Returns +- None + +### C Prototype +`void obj_update_pos_from_parent_transformation(Mat4 a0, struct Object *a1);` + +[:arrow_up_small:](#) + +
+ +## [player_performed_grab_escape_action](#player_performed_grab_escape_action) + +### Lua Example +`local integerValue = player_performed_grab_escape_action()` + +### Parameters +- None + +### Returns +- `integer` + +### C Prototype +`s32 player_performed_grab_escape_action(void);` + +[:arrow_up_small:](#) + +
+ +## [random_f32_around_zero](#random_f32_around_zero) + +### Lua Example +`local numberValue = random_f32_around_zero(diameter)` + +### Parameters +| Field | Type | +| ----- | ---- | +| diameter | `number` | + +### Returns +- `number` + +### C Prototype +`f32 random_f32_around_zero(f32 diameter);` + +[:arrow_up_small:](#) + +
+ +## [set_mario_interact_hoot_if_in_range](#set_mario_interact_hoot_if_in_range) + +### Lua Example +`set_mario_interact_hoot_if_in_range(sp0, sp4, sp8)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp0 | `integer` | +| sp4 | `integer` | +| sp8 | `number` | + +### Returns +- None + +### C Prototype +`void set_mario_interact_hoot_if_in_range(UNUSED s32 sp0, UNUSED s32 sp4, f32 sp8);` + +[:arrow_up_small:](#) + +
+ +## [set_room_override](#set_room_override) + +### Lua Example +`set_room_override(room)` + +### Parameters +| Field | Type | +| ----- | ---- | +| room | `integer` | + +### Returns +- None + +### C Prototype +`void set_room_override(s16 room);` + +[:arrow_up_small:](#) + +
+ +## [set_time_stop_flags](#set_time_stop_flags) + +### Lua Example +`set_time_stop_flags(flags)` + +### Parameters +| Field | Type | +| ----- | ---- | +| flags | `integer` | + +### Returns +- None + +### C Prototype +`void set_time_stop_flags(s32 flags);` + +[:arrow_up_small:](#) + +
+ +## [set_time_stop_flags_if_alone](#set_time_stop_flags_if_alone) + +### Lua Example +`set_time_stop_flags_if_alone(flags)` + +### Parameters +| Field | Type | +| ----- | ---- | +| flags | `integer` | + +### Returns +- None + +### C Prototype +`void set_time_stop_flags_if_alone(s32 flags);` + +[:arrow_up_small:](#) + +
+ +## [signum_positive](#signum_positive) + +### Lua Example +`local integerValue = signum_positive(x)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 signum_positive(s32 x);` + +[:arrow_up_small:](#) + +
+ +## [spawn_base_star_with_no_lvl_exit](#spawn_base_star_with_no_lvl_exit) + +### Lua Example +`spawn_base_star_with_no_lvl_exit()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void spawn_base_star_with_no_lvl_exit(void);` + +[:arrow_up_small:](#) + +
+ +## [spawn_mist_particles](#spawn_mist_particles) + +### Lua Example +`spawn_mist_particles()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void spawn_mist_particles(void);` + +[:arrow_up_small:](#) + +
+ +## [spawn_mist_particles_with_sound](#spawn_mist_particles_with_sound) + +### Lua Example +`spawn_mist_particles_with_sound(sp18)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp18 | `integer` | + +### Returns +- None + +### C Prototype +`void spawn_mist_particles_with_sound(u32 sp18);` + +[:arrow_up_small:](#) + +
+ +## [spawn_star_with_no_lvl_exit](#spawn_star_with_no_lvl_exit) + +### Lua Example +`local ObjectValue = spawn_star_with_no_lvl_exit(sp20, sp24)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp20 | `integer` | +| sp24 | `integer` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *spawn_star_with_no_lvl_exit(s32 sp20, s32 sp24);` + +[:arrow_up_small:](#) + +
+ +## [spawn_water_droplet](#spawn_water_droplet) + +### Lua Example +`local ObjectValue = spawn_water_droplet(parent, params)` + +### Parameters +| Field | Type | +| ----- | ---- | +| parent | [Object](structs.md#Object) | +| params | [WaterDropletParams](structs.md#WaterDropletParams) | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *spawn_water_droplet(struct Object *parent, struct WaterDropletParams *params);` + +[:arrow_up_small:](#) + +
+ +## [stub_obj_helpers_3](#stub_obj_helpers_3) + +### Lua Example +`stub_obj_helpers_3(sp0, sp4)` + +### Parameters +| Field | Type | +| ----- | ---- | +| sp0 | `integer` | +| sp4 | `integer` | + +### Returns +- None + +### C Prototype +`void stub_obj_helpers_3(UNUSED s32 sp0, UNUSED s32 sp4);` + +[:arrow_up_small:](#) + +
+ +## [stub_obj_helpers_4](#stub_obj_helpers_4) + +### Lua Example +`stub_obj_helpers_4()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void stub_obj_helpers_4(void);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from object_list_processor.h + +
+ + +## [set_object_respawn_info_bits](#set_object_respawn_info_bits) + +### Lua Example +`set_object_respawn_info_bits(obj, bits)` + +### Parameters +| Field | Type | +| ----- | ---- | +| obj | [Object](structs.md#Object) | +| bits | `integer` | + +### Returns +- None + +### C Prototype +`void set_object_respawn_info_bits(struct Object *obj, u8 bits);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from rumble_init.c + +
+ + +## [queue_rumble_data](#queue_rumble_data) + +### Lua Example +`queue_rumble_data(a0, a1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a0 | `integer` | +| a1 | `integer` | + +### Returns +- None + +### C Prototype +`void queue_rumble_data(s16 a0, s16 a1);` + +[:arrow_up_small:](#) + +
+ +## [queue_rumble_data_mario](#queue_rumble_data_mario) + +### Lua Example +`queue_rumble_data_mario(m, a0, a1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | +| a0 | `integer` | +| a1 | `integer` | + +### Returns +- None + +### C Prototype +`void queue_rumble_data_mario(struct MarioState* m, s16 a0, s16 a1);` + +[:arrow_up_small:](#) + +
+ +## [queue_rumble_data_object](#queue_rumble_data_object) + +### Lua Example +`queue_rumble_data_object(object, a0, a1)` + +### Parameters +| Field | Type | +| ----- | ---- | +| object | [Object](structs.md#Object) | +| a0 | `integer` | +| a1 | `integer` | + +### Returns +- None + +### C Prototype +`void queue_rumble_data_object(struct Object* object, s16 a0, s16 a1);` + +[:arrow_up_small:](#) + +
+ +## [reset_rumble_timers](#reset_rumble_timers) + +### Lua Example +`reset_rumble_timers(m)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | + +### Returns +- None + +### C Prototype +`void reset_rumble_timers(struct MarioState* m);` + +[:arrow_up_small:](#) + +
+ +## [reset_rumble_timers_2](#reset_rumble_timers_2) + +### Lua Example +`reset_rumble_timers_2(m, a0)` + +### Parameters +| Field | Type | +| ----- | ---- | +| m | [MarioState](structs.md#MarioState) | +| a0 | `integer` | + +### Returns +- None + +### C Prototype +`void reset_rumble_timers_2(struct MarioState* m, s32 a0);` + +[:arrow_up_small:](#) + +
+ --- # functions from save_file.h @@ -4366,1848 +9063,7 @@ Sets the window title to a custom title [:arrow_up_small:](#)
- ---- -# functions from smlua_obj_utils.h - -
- - -## [get_temp_object_hitbox](#get_temp_object_hitbox) - -### Lua Example -`local ObjectHitboxValue = get_temp_object_hitbox()` - -### Parameters -- None - -### Returns -[ObjectHitbox](structs.md#ObjectHitbox) - -### C Prototype -`struct ObjectHitbox* get_temp_object_hitbox(void);` - -[:arrow_up_small:](#) - -
- -## [get_trajectory](#get_trajectory) - -### Lua Example -`local PointerValue = get_trajectory(name)` - -### Parameters -| Field | Type | -| ----- | ---- | -| name | `string` | - -### Returns -- `Pointer` <`Trajectory`> - -### C Prototype -`Trajectory* get_trajectory(const char* name);` - -[:arrow_up_small:](#) - -
- -## [obj_check_hitbox_overlap](#obj_check_hitbox_overlap) - -### Lua Example -`local booleanValue = obj_check_hitbox_overlap(o1, o2)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o1 | [Object](structs.md#Object) | -| o2 | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_check_hitbox_overlap(struct Object *o1, struct Object *o2);` - -[:arrow_up_small:](#) - -
- -## [obj_check_overlap_with_hitbox_params](#obj_check_overlap_with_hitbox_params) - -### Lua Example -`local booleanValue = obj_check_overlap_with_hitbox_params(o, x, y, z, h, r, d)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| x | `number` | -| y | `number` | -| z | `number` | -| h | `number` | -| r | `number` | -| d | `number` | - -### Returns -- `boolean` - -### C Prototype -`bool obj_check_overlap_with_hitbox_params(struct Object *o, f32 x, f32 y, f32 z, f32 h, f32 r, f32 d);` - -[:arrow_up_small:](#) - -
- -## [obj_count_objects_with_behavior_id](#obj_count_objects_with_behavior_id) - -### Lua Example -`local integerValue = obj_count_objects_with_behavior_id(behaviorId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | - -### Returns -- `integer` - -### C Prototype -`s32 obj_count_objects_with_behavior_id(enum BehaviorId behaviorId);` - -[:arrow_up_small:](#) - -
- -## [obj_get_collided_object](#obj_get_collided_object) - -### Lua Example -`local ObjectValue = obj_get_collided_object(o, index)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| index | `integer` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_collided_object(struct Object *o, s16 index);` - -[:arrow_up_small:](#) - -
- -## [obj_get_field_f32](#obj_get_field_f32) - -### Lua Example -`local numberValue = obj_get_field_f32(o, fieldIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | - -### Returns -- `number` - -### C Prototype -`f32 obj_get_field_f32(struct Object *o, s32 fieldIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_get_field_s16](#obj_get_field_s16) - -### Lua Example -`local integerValue = obj_get_field_s16(o, fieldIndex, fieldSubIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| fieldSubIndex | `integer` | - -### Returns -- `integer` - -### C Prototype -`s16 obj_get_field_s16(struct Object *o, s32 fieldIndex, s32 fieldSubIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_get_field_s32](#obj_get_field_s32) - -### Lua Example -`local integerValue = obj_get_field_s32(o, fieldIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 obj_get_field_s32(struct Object *o, s32 fieldIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_get_field_u32](#obj_get_field_u32) - -### Lua Example -`local integerValue = obj_get_field_u32(o, fieldIndex)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | - -### Returns -- `integer` - -### C Prototype -`u32 obj_get_field_u32(struct Object *o, s32 fieldIndex);` - -[:arrow_up_small:](#) - -
- -## [obj_get_first](#obj_get_first) - -### Lua Example -`local ObjectValue = obj_get_first(objList)` - -### Parameters -| Field | Type | -| ----- | ---- | -| objList | [enum ObjectList](constants.md#enum-ObjectList) | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_first(enum ObjectList objList);` - -[:arrow_up_small:](#) - -
- -## [obj_get_first_with_behavior_id](#obj_get_first_with_behavior_id) - -### Lua Example -`local ObjectValue = obj_get_first_with_behavior_id(behaviorId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_first_with_behavior_id(enum BehaviorId behaviorId);` - -[:arrow_up_small:](#) - -
- -## [obj_get_first_with_behavior_id_and_field_f32](#obj_get_first_with_behavior_id_and_field_f32) - -### Lua Example -`local ObjectValue = obj_get_first_with_behavior_id_and_field_f32(behaviorId, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | -| fieldIndex | `integer` | -| value | `number` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_first_with_behavior_id_and_field_f32(enum BehaviorId behaviorId, s32 fieldIndex, f32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_get_first_with_behavior_id_and_field_s32](#obj_get_first_with_behavior_id_and_field_s32) - -### Lua Example -`local ObjectValue = obj_get_first_with_behavior_id_and_field_s32(behaviorId, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | -| fieldIndex | `integer` | -| value | `integer` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_first_with_behavior_id_and_field_s32(enum BehaviorId behaviorId, s32 fieldIndex, s32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_get_nearest_object_with_behavior_id](#obj_get_nearest_object_with_behavior_id) - -### Lua Example -`local ObjectValue = obj_get_nearest_object_with_behavior_id(o, behaviorId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_nearest_object_with_behavior_id(struct Object *o, enum BehaviorId behaviorId);` - -[:arrow_up_small:](#) - -
- -## [obj_get_next](#obj_get_next) - -### Lua Example -`local ObjectValue = obj_get_next(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_next(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_get_next_with_same_behavior_id](#obj_get_next_with_same_behavior_id) - -### Lua Example -`local ObjectValue = obj_get_next_with_same_behavior_id(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_next_with_same_behavior_id(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_get_next_with_same_behavior_id_and_field_f32](#obj_get_next_with_same_behavior_id_and_field_f32) - -### Lua Example -`local ObjectValue = obj_get_next_with_same_behavior_id_and_field_f32(o, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| value | `number` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_next_with_same_behavior_id_and_field_f32(struct Object *o, s32 fieldIndex, f32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_get_next_with_same_behavior_id_and_field_s32](#obj_get_next_with_same_behavior_id_and_field_s32) - -### Lua Example -`local ObjectValue = obj_get_next_with_same_behavior_id_and_field_s32(o, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| value | `integer` | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object *obj_get_next_with_same_behavior_id_and_field_s32(struct Object *o, s32 fieldIndex, s32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_get_temp_spawn_particles_info](#obj_get_temp_spawn_particles_info) - -### Lua Example -`local SpawnParticlesInfoValue = obj_get_temp_spawn_particles_info(modelId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | - -### Returns -[SpawnParticlesInfo](structs.md#SpawnParticlesInfo) - -### C Prototype -`struct SpawnParticlesInfo* obj_get_temp_spawn_particles_info(enum ModelExtendedId modelId);` - -[:arrow_up_small:](#) - -
- -## [obj_has_behavior_id](#obj_has_behavior_id) - -### Lua Example -`local integerValue = obj_has_behavior_id(o, behaviorId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | - -### Returns -- `integer` - -### C Prototype -`s32 obj_has_behavior_id(struct Object *o, enum BehaviorId behaviorId);` - -[:arrow_up_small:](#) - -
- -## [obj_has_model_extended](#obj_has_model_extended) - -### Lua Example -`local integerValue = obj_has_model_extended(o, modelId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | - -### Returns -- `integer` - -### C Prototype -`s32 obj_has_model_extended(struct Object *o, enum ModelExtendedId modelId);` - -[:arrow_up_small:](#) - -
- -## [obj_is_attackable](#obj_is_attackable) - -### Lua Example -`local booleanValue = obj_is_attackable(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_attackable(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_breakable_object](#obj_is_breakable_object) - -### Lua Example -`local booleanValue = obj_is_breakable_object(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_breakable_object(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_bully](#obj_is_bully) - -### Lua Example -`local booleanValue = obj_is_bully(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_bully(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_coin](#obj_is_coin) - -### Lua Example -`local booleanValue = obj_is_coin(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_coin(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_exclamation_box](#obj_is_exclamation_box) - -### Lua Example -`local booleanValue = obj_is_exclamation_box(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_exclamation_box(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_grabbable](#obj_is_grabbable) - -### Lua Example -`local booleanValue = obj_is_grabbable(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_grabbable(struct Object *o) ;` - -[:arrow_up_small:](#) - -
- -## [obj_is_mushroom_1up](#obj_is_mushroom_1up) - -### Lua Example -`local booleanValue = obj_is_mushroom_1up(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_mushroom_1up(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_secret](#obj_is_secret) - -### Lua Example -`local booleanValue = obj_is_secret(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_secret(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_is_valid_for_interaction](#obj_is_valid_for_interaction) - -### Lua Example -`local booleanValue = obj_is_valid_for_interaction(o)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | - -### Returns -- `boolean` - -### C Prototype -`bool obj_is_valid_for_interaction(struct Object *o);` - -[:arrow_up_small:](#) - -
- -## [obj_move_xyz](#obj_move_xyz) - -### Lua Example -`obj_move_xyz(o, dx, dy, dz)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| dx | `number` | -| dy | `number` | -| dz | `number` | - -### Returns -- None - -### C Prototype -`void obj_move_xyz(struct Object *o, f32 dx, f32 dy, f32 dz);` - -[:arrow_up_small:](#) - -
- -## [obj_set_field_f32](#obj_set_field_f32) - -### Lua Example -`obj_set_field_f32(o, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| value | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_field_f32(struct Object *o, s32 fieldIndex, f32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_set_field_s16](#obj_set_field_s16) - -### Lua Example -`obj_set_field_s16(o, fieldIndex, fieldSubIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| fieldSubIndex | `integer` | -| value | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_field_s16(struct Object *o, s32 fieldIndex, s32 fieldSubIndex, s16 value);` - -[:arrow_up_small:](#) - -
- -## [obj_set_field_s32](#obj_set_field_s32) - -### Lua Example -`obj_set_field_s32(o, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| value | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_field_s32(struct Object *o, s32 fieldIndex, s32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_set_field_u32](#obj_set_field_u32) - -### Lua Example -`obj_set_field_u32(o, fieldIndex, value)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| fieldIndex | `integer` | -| value | `integer` | - -### Returns -- None - -### C Prototype -`void obj_set_field_u32(struct Object *o, s32 fieldIndex, u32 value);` - -[:arrow_up_small:](#) - -
- -## [obj_set_model_extended](#obj_set_model_extended) - -### Lua Example -`obj_set_model_extended(o, modelId)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | - -### Returns -- None - -### C Prototype -`void obj_set_model_extended(struct Object *o, enum ModelExtendedId modelId);` - -[:arrow_up_small:](#) - -
- -## [obj_set_vel](#obj_set_vel) - -### Lua Example -`obj_set_vel(o, vx, vy, vz)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| vx | `number` | -| vy | `number` | -| vz | `number` | - -### Returns -- None - -### C Prototype -`void obj_set_vel(struct Object *o, f32 vx, f32 vy, f32 vz);` - -[:arrow_up_small:](#) - -
- -## [set_whirlpools](#set_whirlpools) - -### Lua Example -`set_whirlpools(x, y, z, strength, area, index)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x | `number` | -| y | `number` | -| z | `number` | -| strength | `integer` | -| area | `integer` | -| index | `integer` | - -### Returns -- None - -### C Prototype -`void set_whirlpools(f32 x, f32 y, f32 z, s16 strength, s16 area, s32 index);` - -[:arrow_up_small:](#) - -
- -## [spawn_non_sync_object](#spawn_non_sync_object) - -### Lua Example -`local ObjectValue = spawn_non_sync_object(behaviorId, modelId, x, y, z, objSetupFunction)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | -| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | -| x | `number` | -| y | `number` | -| z | `number` | -| objSetupFunction | `Lua Function` () | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object* spawn_non_sync_object(enum BehaviorId behaviorId, enum ModelExtendedId modelId, f32 x, f32 y, f32 z, LuaFunction objSetupFunction);` - -[:arrow_up_small:](#) - -
- -## [spawn_sync_object](#spawn_sync_object) - -### Lua Example -`local ObjectValue = spawn_sync_object(behaviorId, modelId, x, y, z, objSetupFunction)` - -### Parameters -| Field | Type | -| ----- | ---- | -| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | -| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | -| x | `number` | -| y | `number` | -| z | `number` | -| objSetupFunction | `Lua Function` () | - -### Returns -[Object](structs.md#Object) - -### C Prototype -`struct Object* spawn_sync_object(enum BehaviorId behaviorId, enum ModelExtendedId modelId, f32 x, f32 y, f32 z, LuaFunction objSetupFunction);` - -[:arrow_up_small:](#) - -
- ---- -# functions from smlua_text_utils.h - -
- - -## [smlua_text_utils_act_name_get](#smlua_text_utils_act_name_get) - -### Lua Example -`local stringValue = smlua_text_utils_act_name_get(courseNum, actNum)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| actNum | `integer` | - -### Returns -- `string` - -### C Prototype -`const char* smlua_text_utils_act_name_get(s16 courseNum, u8 actNum);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_act_name_mod_index](#smlua_text_utils_act_name_mod_index) - -### Lua Example -`local integerValue = smlua_text_utils_act_name_mod_index(courseNum, actNum)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| actNum | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 smlua_text_utils_act_name_mod_index(s16 courseNum, u8 actNum);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_act_name_replace](#smlua_text_utils_act_name_replace) - -### Lua Example -`smlua_text_utils_act_name_replace(courseNum, actNum, name)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| actNum | `integer` | -| name | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_act_name_replace(s16 courseNum, u8 actNum, const char* name);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_act_name_reset](#smlua_text_utils_act_name_reset) - -### Lua Example -`smlua_text_utils_act_name_reset(courseNum, actNum)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| actNum | `integer` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_act_name_reset(s16 courseNum, u8 actNum);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_castle_secret_stars_replace](#smlua_text_utils_castle_secret_stars_replace) - -### Lua Example -`smlua_text_utils_castle_secret_stars_replace(name)` - -### Parameters -| Field | Type | -| ----- | ---- | -| name | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_castle_secret_stars_replace(const char* name);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_course_acts_replace](#smlua_text_utils_course_acts_replace) - -### Lua Example -`smlua_text_utils_course_acts_replace(courseNum, courseName, act1, act2, act3, act4, act5, act6)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| courseName | `string` | -| act1 | `string` | -| act2 | `string` | -| act3 | `string` | -| act4 | `string` | -| act5 | `string` | -| act6 | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_course_acts_replace(s16 courseNum, const char* courseName, const char* act1, const char* act2, const char* act3, const char* act4, const char* act5, const char* act6);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_course_name_get](#smlua_text_utils_course_name_get) - -### Lua Example -`local stringValue = smlua_text_utils_course_name_get(courseNum)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | - -### Returns -- `string` - -### C Prototype -`const char* smlua_text_utils_course_name_get(s16 courseNum);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_course_name_mod_index](#smlua_text_utils_course_name_mod_index) - -### Lua Example -`local integerValue = smlua_text_utils_course_name_mod_index(courseNum)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | - -### Returns -- `integer` - -### C Prototype -`s32 smlua_text_utils_course_name_mod_index(s16 courseNum);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_course_name_replace](#smlua_text_utils_course_name_replace) - -### Lua Example -`smlua_text_utils_course_name_replace(courseNum, name)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| name | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_course_name_replace(s16 courseNum, const char* name);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_course_name_reset](#smlua_text_utils_course_name_reset) - -### Lua Example -`smlua_text_utils_course_name_reset(courseNum)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_course_name_reset(s16 courseNum);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_dialog_replace](#smlua_text_utils_dialog_replace) - -### Lua Example -`smlua_text_utils_dialog_replace(dialogId, unused, linesPerBox, leftOffset, width, str)` - -### Parameters -| Field | Type | -| ----- | ---- | -| dialogId | [enum DialogId](constants.md#enum-DialogId) | -| unused | `integer` | -| linesPerBox | `integer` | -| leftOffset | `integer` | -| width | `integer` | -| str | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_dialog_replace(enum DialogId dialogId, u32 unused, s8 linesPerBox, s16 leftOffset, s16 width, const char* str);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_extra_text_replace](#smlua_text_utils_extra_text_replace) - -### Lua Example -`smlua_text_utils_extra_text_replace(index, text)` - -### Parameters -| Field | Type | -| ----- | ---- | -| index | `integer` | -| text | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_extra_text_replace(s16 index, const char* text);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_get_language](#smlua_text_utils_get_language) - -### Lua Example -`local stringValue = smlua_text_utils_get_language()` - -### Parameters -- None - -### Returns -- `string` - -### C Prototype -`const char* smlua_text_utils_get_language(void);` - -[:arrow_up_small:](#) - -
- -## [smlua_text_utils_secret_star_replace](#smlua_text_utils_secret_star_replace) - -### Lua Example -`smlua_text_utils_secret_star_replace(courseNum, courseName)` - -### Parameters -| Field | Type | -| ----- | ---- | -| courseNum | `integer` | -| courseName | `string` | - -### Returns -- None - -### C Prototype -`void smlua_text_utils_secret_star_replace(s16 courseNum, const char* courseName);` - -[:arrow_up_small:](#) - -
- ---- -# functions from sound_init.h - -
- - -## [disable_background_sound](#disable_background_sound) - -### Lua Example -`disable_background_sound()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void disable_background_sound(void);` - -[:arrow_up_small:](#) - -
- -## [enable_background_sound](#enable_background_sound) - -### Lua Example -`enable_background_sound()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void enable_background_sound(void);` - -[:arrow_up_small:](#) - -
- -## [fadeout_cap_music](#fadeout_cap_music) - -### Lua Example -`fadeout_cap_music()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void fadeout_cap_music(void);` - -[:arrow_up_small:](#) - -
- -## [fadeout_level_music](#fadeout_level_music) - -### Lua Example -`fadeout_level_music(fadeTimer)` - -### Parameters -| Field | Type | -| ----- | ---- | -| fadeTimer | `integer` | - -### Returns -- None - -### C Prototype -`void fadeout_level_music(s16 fadeTimer);` - -[:arrow_up_small:](#) - -
- -## [fadeout_music](#fadeout_music) - -### Lua Example -`fadeout_music(fadeOutTime)` - -### Parameters -| Field | Type | -| ----- | ---- | -| fadeOutTime | `integer` | - -### Returns -- None - -### C Prototype -`void fadeout_music(s16 fadeOutTime);` - -[:arrow_up_small:](#) - -
- -## [lower_background_noise](#lower_background_noise) - -### Lua Example -`lower_background_noise(a)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a | `integer` | - -### Returns -- None - -### C Prototype -`void lower_background_noise(s32 a);` - -[:arrow_up_small:](#) - -
- -## [play_cap_music](#play_cap_music) - -### Lua Example -`play_cap_music(seqArgs)` - -### Parameters -| Field | Type | -| ----- | ---- | -| seqArgs | `integer` | - -### Returns -- None - -### C Prototype -`void play_cap_music(u16 seqArgs);` - -[:arrow_up_small:](#) - -
- -## [play_cutscene_music](#play_cutscene_music) - -### Lua Example -`play_cutscene_music(seqArgs)` - -### Parameters -| Field | Type | -| ----- | ---- | -| seqArgs | `integer` | - -### Returns -- None - -### C Prototype -`void play_cutscene_music(u16 seqArgs);` - -[:arrow_up_small:](#) - -
- -## [play_infinite_stairs_music](#play_infinite_stairs_music) - -### Lua Example -`play_infinite_stairs_music()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void play_infinite_stairs_music(void);` - -[:arrow_up_small:](#) - -
- -## [play_menu_sounds](#play_menu_sounds) - -### Lua Example -`play_menu_sounds(soundMenuFlags)` - -### Parameters -| Field | Type | -| ----- | ---- | -| soundMenuFlags | `integer` | - -### Returns -- None - -### C Prototype -`void play_menu_sounds(s16 soundMenuFlags);` - -[:arrow_up_small:](#) - -
- -## [play_painting_eject_sound](#play_painting_eject_sound) - -### Lua Example -`play_painting_eject_sound()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void play_painting_eject_sound(void);` - -[:arrow_up_small:](#) - -
- -## [play_shell_music](#play_shell_music) - -### Lua Example -`play_shell_music()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void play_shell_music(void);` - -[:arrow_up_small:](#) - -
- -## [raise_background_noise](#raise_background_noise) - -### Lua Example -`raise_background_noise(a)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a | `integer` | - -### Returns -- None - -### C Prototype -`void raise_background_noise(s32 a);` - -[:arrow_up_small:](#) - -
- -## [reset_volume](#reset_volume) - -### Lua Example -`reset_volume()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void reset_volume(void);` - -[:arrow_up_small:](#) - -
- -## [set_background_music](#set_background_music) - -### Lua Example -`set_background_music(a, seqArgs, fadeTimer)` - -### Parameters -| Field | Type | -| ----- | ---- | -| a | `integer` | -| seqArgs | `integer` | -| fadeTimer | `integer` | - -### Returns -- None - -### C Prototype -`void set_background_music(u16 a, u16 seqArgs, s16 fadeTimer);` - -[:arrow_up_small:](#) - -
- -## [stop_cap_music](#stop_cap_music) - -### Lua Example -`stop_cap_music()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void stop_cap_music(void);` - -[:arrow_up_small:](#) - -
- -## [stop_shell_music](#stop_shell_music) - -### Lua Example -`stop_shell_music()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void stop_shell_music(void);` - -[:arrow_up_small:](#) - -
- ---- -# functions from spawn_sound.c - -
- - -## [calc_dist_to_volume_range_1](#calc_dist_to_volume_range_1) - -### Lua Example -`local integerValue = calc_dist_to_volume_range_1(distance)` - -### Parameters -| Field | Type | -| ----- | ---- | -| distance | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 calc_dist_to_volume_range_1(f32 distance);` - -[:arrow_up_small:](#) - -
- -## [calc_dist_to_volume_range_2](#calc_dist_to_volume_range_2) - -### Lua Example -`local integerValue = calc_dist_to_volume_range_2(distance)` - -### Parameters -| Field | Type | -| ----- | ---- | -| distance | `number` | - -### Returns -- `integer` - -### C Prototype -`s32 calc_dist_to_volume_range_2(f32 distance);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_play_sound_1](#cur_obj_play_sound_1) - -### Lua Example -`cur_obj_play_sound_1(soundMagic)` - -### Parameters -| Field | Type | -| ----- | ---- | -| soundMagic | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_play_sound_1(s32 soundMagic);` - -[:arrow_up_small:](#) - -
- -## [cur_obj_play_sound_2](#cur_obj_play_sound_2) - -### Lua Example -`cur_obj_play_sound_2(soundMagic)` - -### Parameters -| Field | Type | -| ----- | ---- | -| soundMagic | `integer` | - -### Returns -- None - -### C Prototype -`void cur_obj_play_sound_2(s32 soundMagic);` - -[:arrow_up_small:](#) - -
- -## [exec_anim_sound_state](#exec_anim_sound_state) - -### Lua Example -`exec_anim_sound_state(soundStates, maxSoundStates)` - -### Parameters -| Field | Type | -| ----- | ---- | -| soundStates | [SoundState](structs.md#SoundState) | -| maxSoundStates | `integer` | - -### Returns -- None - -### C Prototype -`void exec_anim_sound_state(struct SoundState *soundStates, u16 maxSoundStates);` - -[:arrow_up_small:](#) - -
- ---- -# functions from surface_collision.h - -
- - -## [find_ceil_height](#find_ceil_height) - -### Lua Example -`local numberValue = find_ceil_height(x, y, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x | `number` | -| y | `number` | -| z | `number` | - -### Returns -- `number` - -### C Prototype -`f32 find_ceil_height(f32 x, f32 y, f32 z);` - -[:arrow_up_small:](#) - -
- -## [find_floor_height](#find_floor_height) - -### Lua Example -`local numberValue = find_floor_height(x, y, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x | `number` | -| y | `number` | -| z | `number` | - -### Returns -- `number` - -### C Prototype -`f32 find_floor_height(f32 x, f32 y, f32 z);` - -[:arrow_up_small:](#) - -
- -## [find_poison_gas_level](#find_poison_gas_level) - -### Lua Example -`local numberValue = find_poison_gas_level(x, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x | `number` | -| z | `number` | - -### Returns -- `number` - -### C Prototype -`f32 find_poison_gas_level(f32 x, f32 z);` - -[:arrow_up_small:](#) - -
- -## [find_wall_collisions](#find_wall_collisions) - -### Lua Example -`local integerValue = find_wall_collisions(colData)` - -### Parameters -| Field | Type | -| ----- | ---- | -| colData | [WallCollisionData](structs.md#WallCollisionData) | - -### Returns -- `integer` - -### C Prototype -`s32 find_wall_collisions(struct WallCollisionData *colData);` - -[:arrow_up_small:](#) - -
- -## [find_water_level](#find_water_level) - -### Lua Example -`local numberValue = find_water_level(x, z)` - -### Parameters -| Field | Type | -| ----- | ---- | -| x | `number` | -| z | `number` | - -### Returns -- `number` - -### C Prototype -`f32 find_water_level(f32 x, f32 z);` - -[:arrow_up_small:](#) - -
- ---- -# functions from surface_load.h - -
- - -## [get_area_terrain_size](#get_area_terrain_size) - -### Lua Example -`local integerValue = get_area_terrain_size(data)` - -### Parameters -| Field | Type | -| ----- | ---- | -| data | `Pointer` <`integer`> | - -### Returns -- `integer` - -### C Prototype -`u32 get_area_terrain_size(s16 *data);` - -[:arrow_up_small:](#) - -
- -## [load_area_terrain](#load_area_terrain) - -### Lua Example -`load_area_terrain(index, data, surfaceRooms, macroObjects)` - -### Parameters -| Field | Type | -| ----- | ---- | -| index | `integer` | -| data | `Pointer` <`integer`> | -| surfaceRooms | `Pointer` <`integer`> | -| macroObjects | `Pointer` <`integer`> | - -### Returns -- None - -### C Prototype -`void load_area_terrain(s16 index, s16 *data, s8 *surfaceRooms, s16 *macroObjects);` - -[:arrow_up_small:](#) - -
- -## [load_object_collision_model](#load_object_collision_model) - -### Lua Example -`load_object_collision_model()` - -### Parameters -- None - -### Returns -- None - -### C Prototype -`void load_object_collision_model(void);` - -[:arrow_up_small:](#) - -
- -## [obj_get_surface_from_index](#obj_get_surface_from_index) - -### Lua Example -`local SurfaceValue = obj_get_surface_from_index(o, index)` - -### Parameters -| Field | Type | -| ----- | ---- | -| o | [Object](structs.md#Object) | -| index | `integer` | - -### Returns -[Surface](structs.md#Surface) - -### C Prototype -`struct Surface *obj_get_surface_from_index(struct Object *o, u32 index);` - -[:arrow_up_small:](#) - -
- -## [surface_has_force](#surface_has_force) - -### Lua Example -`local booleanValue = surface_has_force(surfaceType)` - -### Parameters -| Field | Type | -| ----- | ---- | -| surfaceType | `integer` | - -### Returns -- `boolean` - -### C Prototype -`bool surface_has_force(s16 surfaceType);` - -[:arrow_up_small:](#) - -
- --- -[< prev](functions-4.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | 5] +[< prev](functions-4.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | 5 | [6](functions-6.md) | [next >](functions-6.md)] diff --git a/docs/lua/functions-6.md b/docs/lua/functions-6.md new file mode 100644 index 000000000..1e64bf3b0 --- /dev/null +++ b/docs/lua/functions-6.md @@ -0,0 +1,1851 @@ +## [:rewind: Lua Functions](functions.md) + +--- + +[< prev](functions-5.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | 6] + + +--- +# functions from smlua_obj_utils.h + +
+ + +## [get_temp_object_hitbox](#get_temp_object_hitbox) + +### Lua Example +`local ObjectHitboxValue = get_temp_object_hitbox()` + +### Parameters +- None + +### Returns +[ObjectHitbox](structs.md#ObjectHitbox) + +### C Prototype +`struct ObjectHitbox* get_temp_object_hitbox(void);` + +[:arrow_up_small:](#) + +
+ +## [get_trajectory](#get_trajectory) + +### Lua Example +`local PointerValue = get_trajectory(name)` + +### Parameters +| Field | Type | +| ----- | ---- | +| name | `string` | + +### Returns +- `Pointer` <`Trajectory`> + +### C Prototype +`Trajectory* get_trajectory(const char* name);` + +[:arrow_up_small:](#) + +
+ +## [obj_check_hitbox_overlap](#obj_check_hitbox_overlap) + +### Lua Example +`local booleanValue = obj_check_hitbox_overlap(o1, o2)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o1 | [Object](structs.md#Object) | +| o2 | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_check_hitbox_overlap(struct Object *o1, struct Object *o2);` + +[:arrow_up_small:](#) + +
+ +## [obj_check_overlap_with_hitbox_params](#obj_check_overlap_with_hitbox_params) + +### Lua Example +`local booleanValue = obj_check_overlap_with_hitbox_params(o, x, y, z, h, r, d)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| x | `number` | +| y | `number` | +| z | `number` | +| h | `number` | +| r | `number` | +| d | `number` | + +### Returns +- `boolean` + +### C Prototype +`bool obj_check_overlap_with_hitbox_params(struct Object *o, f32 x, f32 y, f32 z, f32 h, f32 r, f32 d);` + +[:arrow_up_small:](#) + +
+ +## [obj_count_objects_with_behavior_id](#obj_count_objects_with_behavior_id) + +### Lua Example +`local integerValue = obj_count_objects_with_behavior_id(behaviorId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | + +### Returns +- `integer` + +### C Prototype +`s32 obj_count_objects_with_behavior_id(enum BehaviorId behaviorId);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_collided_object](#obj_get_collided_object) + +### Lua Example +`local ObjectValue = obj_get_collided_object(o, index)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| index | `integer` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_collided_object(struct Object *o, s16 index);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_field_f32](#obj_get_field_f32) + +### Lua Example +`local numberValue = obj_get_field_f32(o, fieldIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | + +### Returns +- `number` + +### C Prototype +`f32 obj_get_field_f32(struct Object *o, s32 fieldIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_field_s16](#obj_get_field_s16) + +### Lua Example +`local integerValue = obj_get_field_s16(o, fieldIndex, fieldSubIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| fieldSubIndex | `integer` | + +### Returns +- `integer` + +### C Prototype +`s16 obj_get_field_s16(struct Object *o, s32 fieldIndex, s32 fieldSubIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_field_s32](#obj_get_field_s32) + +### Lua Example +`local integerValue = obj_get_field_s32(o, fieldIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 obj_get_field_s32(struct Object *o, s32 fieldIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_field_u32](#obj_get_field_u32) + +### Lua Example +`local integerValue = obj_get_field_u32(o, fieldIndex)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | + +### Returns +- `integer` + +### C Prototype +`u32 obj_get_field_u32(struct Object *o, s32 fieldIndex);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_first](#obj_get_first) + +### Lua Example +`local ObjectValue = obj_get_first(objList)` + +### Parameters +| Field | Type | +| ----- | ---- | +| objList | [enum ObjectList](constants.md#enum-ObjectList) | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_first(enum ObjectList objList);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_first_with_behavior_id](#obj_get_first_with_behavior_id) + +### Lua Example +`local ObjectValue = obj_get_first_with_behavior_id(behaviorId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_first_with_behavior_id(enum BehaviorId behaviorId);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_first_with_behavior_id_and_field_f32](#obj_get_first_with_behavior_id_and_field_f32) + +### Lua Example +`local ObjectValue = obj_get_first_with_behavior_id_and_field_f32(behaviorId, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | +| fieldIndex | `integer` | +| value | `number` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_first_with_behavior_id_and_field_f32(enum BehaviorId behaviorId, s32 fieldIndex, f32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_first_with_behavior_id_and_field_s32](#obj_get_first_with_behavior_id_and_field_s32) + +### Lua Example +`local ObjectValue = obj_get_first_with_behavior_id_and_field_s32(behaviorId, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | +| fieldIndex | `integer` | +| value | `integer` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_first_with_behavior_id_and_field_s32(enum BehaviorId behaviorId, s32 fieldIndex, s32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_nearest_object_with_behavior_id](#obj_get_nearest_object_with_behavior_id) + +### Lua Example +`local ObjectValue = obj_get_nearest_object_with_behavior_id(o, behaviorId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_nearest_object_with_behavior_id(struct Object *o, enum BehaviorId behaviorId);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_next](#obj_get_next) + +### Lua Example +`local ObjectValue = obj_get_next(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_next(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_next_with_same_behavior_id](#obj_get_next_with_same_behavior_id) + +### Lua Example +`local ObjectValue = obj_get_next_with_same_behavior_id(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_next_with_same_behavior_id(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_next_with_same_behavior_id_and_field_f32](#obj_get_next_with_same_behavior_id_and_field_f32) + +### Lua Example +`local ObjectValue = obj_get_next_with_same_behavior_id_and_field_f32(o, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| value | `number` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_next_with_same_behavior_id_and_field_f32(struct Object *o, s32 fieldIndex, f32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_next_with_same_behavior_id_and_field_s32](#obj_get_next_with_same_behavior_id_and_field_s32) + +### Lua Example +`local ObjectValue = obj_get_next_with_same_behavior_id_and_field_s32(o, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| value | `integer` | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object *obj_get_next_with_same_behavior_id_and_field_s32(struct Object *o, s32 fieldIndex, s32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_temp_spawn_particles_info](#obj_get_temp_spawn_particles_info) + +### Lua Example +`local SpawnParticlesInfoValue = obj_get_temp_spawn_particles_info(modelId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | + +### Returns +[SpawnParticlesInfo](structs.md#SpawnParticlesInfo) + +### C Prototype +`struct SpawnParticlesInfo* obj_get_temp_spawn_particles_info(enum ModelExtendedId modelId);` + +[:arrow_up_small:](#) + +
+ +## [obj_has_behavior_id](#obj_has_behavior_id) + +### Lua Example +`local integerValue = obj_has_behavior_id(o, behaviorId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | + +### Returns +- `integer` + +### C Prototype +`s32 obj_has_behavior_id(struct Object *o, enum BehaviorId behaviorId);` + +[:arrow_up_small:](#) + +
+ +## [obj_has_model_extended](#obj_has_model_extended) + +### Lua Example +`local integerValue = obj_has_model_extended(o, modelId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | + +### Returns +- `integer` + +### C Prototype +`s32 obj_has_model_extended(struct Object *o, enum ModelExtendedId modelId);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_attackable](#obj_is_attackable) + +### Lua Example +`local booleanValue = obj_is_attackable(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_attackable(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_breakable_object](#obj_is_breakable_object) + +### Lua Example +`local booleanValue = obj_is_breakable_object(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_breakable_object(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_bully](#obj_is_bully) + +### Lua Example +`local booleanValue = obj_is_bully(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_bully(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_coin](#obj_is_coin) + +### Lua Example +`local booleanValue = obj_is_coin(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_coin(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_exclamation_box](#obj_is_exclamation_box) + +### Lua Example +`local booleanValue = obj_is_exclamation_box(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_exclamation_box(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_grabbable](#obj_is_grabbable) + +### Lua Example +`local booleanValue = obj_is_grabbable(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_grabbable(struct Object *o) ;` + +[:arrow_up_small:](#) + +
+ +## [obj_is_mushroom_1up](#obj_is_mushroom_1up) + +### Lua Example +`local booleanValue = obj_is_mushroom_1up(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_mushroom_1up(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_secret](#obj_is_secret) + +### Lua Example +`local booleanValue = obj_is_secret(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_secret(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_is_valid_for_interaction](#obj_is_valid_for_interaction) + +### Lua Example +`local booleanValue = obj_is_valid_for_interaction(o)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | + +### Returns +- `boolean` + +### C Prototype +`bool obj_is_valid_for_interaction(struct Object *o);` + +[:arrow_up_small:](#) + +
+ +## [obj_move_xyz](#obj_move_xyz) + +### Lua Example +`obj_move_xyz(o, dx, dy, dz)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| dx | `number` | +| dy | `number` | +| dz | `number` | + +### Returns +- None + +### C Prototype +`void obj_move_xyz(struct Object *o, f32 dx, f32 dy, f32 dz);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_field_f32](#obj_set_field_f32) + +### Lua Example +`obj_set_field_f32(o, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| value | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_field_f32(struct Object *o, s32 fieldIndex, f32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_field_s16](#obj_set_field_s16) + +### Lua Example +`obj_set_field_s16(o, fieldIndex, fieldSubIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| fieldSubIndex | `integer` | +| value | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_field_s16(struct Object *o, s32 fieldIndex, s32 fieldSubIndex, s16 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_field_s32](#obj_set_field_s32) + +### Lua Example +`obj_set_field_s32(o, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| value | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_field_s32(struct Object *o, s32 fieldIndex, s32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_field_u32](#obj_set_field_u32) + +### Lua Example +`obj_set_field_u32(o, fieldIndex, value)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| fieldIndex | `integer` | +| value | `integer` | + +### Returns +- None + +### C Prototype +`void obj_set_field_u32(struct Object *o, s32 fieldIndex, u32 value);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_model_extended](#obj_set_model_extended) + +### Lua Example +`obj_set_model_extended(o, modelId)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | + +### Returns +- None + +### C Prototype +`void obj_set_model_extended(struct Object *o, enum ModelExtendedId modelId);` + +[:arrow_up_small:](#) + +
+ +## [obj_set_vel](#obj_set_vel) + +### Lua Example +`obj_set_vel(o, vx, vy, vz)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| vx | `number` | +| vy | `number` | +| vz | `number` | + +### Returns +- None + +### C Prototype +`void obj_set_vel(struct Object *o, f32 vx, f32 vy, f32 vz);` + +[:arrow_up_small:](#) + +
+ +## [set_whirlpools](#set_whirlpools) + +### Lua Example +`set_whirlpools(x, y, z, strength, area, index)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x | `number` | +| y | `number` | +| z | `number` | +| strength | `integer` | +| area | `integer` | +| index | `integer` | + +### Returns +- None + +### C Prototype +`void set_whirlpools(f32 x, f32 y, f32 z, s16 strength, s16 area, s32 index);` + +[:arrow_up_small:](#) + +
+ +## [spawn_non_sync_object](#spawn_non_sync_object) + +### Lua Example +`local ObjectValue = spawn_non_sync_object(behaviorId, modelId, x, y, z, objSetupFunction)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | +| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | +| x | `number` | +| y | `number` | +| z | `number` | +| objSetupFunction | `Lua Function` () | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object* spawn_non_sync_object(enum BehaviorId behaviorId, enum ModelExtendedId modelId, f32 x, f32 y, f32 z, LuaFunction objSetupFunction);` + +[:arrow_up_small:](#) + +
+ +## [spawn_sync_object](#spawn_sync_object) + +### Lua Example +`local ObjectValue = spawn_sync_object(behaviorId, modelId, x, y, z, objSetupFunction)` + +### Parameters +| Field | Type | +| ----- | ---- | +| behaviorId | [enum BehaviorId](constants.md#enum-BehaviorId) | +| modelId | [enum ModelExtendedId](constants.md#enum-ModelExtendedId) | +| x | `number` | +| y | `number` | +| z | `number` | +| objSetupFunction | `Lua Function` () | + +### Returns +[Object](structs.md#Object) + +### C Prototype +`struct Object* spawn_sync_object(enum BehaviorId behaviorId, enum ModelExtendedId modelId, f32 x, f32 y, f32 z, LuaFunction objSetupFunction);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from smlua_text_utils.h + +
+ + +## [smlua_text_utils_act_name_get](#smlua_text_utils_act_name_get) + +### Lua Example +`local stringValue = smlua_text_utils_act_name_get(courseNum, actNum)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| actNum | `integer` | + +### Returns +- `string` + +### C Prototype +`const char* smlua_text_utils_act_name_get(s16 courseNum, u8 actNum);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_act_name_mod_index](#smlua_text_utils_act_name_mod_index) + +### Lua Example +`local integerValue = smlua_text_utils_act_name_mod_index(courseNum, actNum)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| actNum | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 smlua_text_utils_act_name_mod_index(s16 courseNum, u8 actNum);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_act_name_replace](#smlua_text_utils_act_name_replace) + +### Lua Example +`smlua_text_utils_act_name_replace(courseNum, actNum, name)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| actNum | `integer` | +| name | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_act_name_replace(s16 courseNum, u8 actNum, const char* name);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_act_name_reset](#smlua_text_utils_act_name_reset) + +### Lua Example +`smlua_text_utils_act_name_reset(courseNum, actNum)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| actNum | `integer` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_act_name_reset(s16 courseNum, u8 actNum);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_castle_secret_stars_replace](#smlua_text_utils_castle_secret_stars_replace) + +### Lua Example +`smlua_text_utils_castle_secret_stars_replace(name)` + +### Parameters +| Field | Type | +| ----- | ---- | +| name | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_castle_secret_stars_replace(const char* name);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_course_acts_replace](#smlua_text_utils_course_acts_replace) + +### Lua Example +`smlua_text_utils_course_acts_replace(courseNum, courseName, act1, act2, act3, act4, act5, act6)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| courseName | `string` | +| act1 | `string` | +| act2 | `string` | +| act3 | `string` | +| act4 | `string` | +| act5 | `string` | +| act6 | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_course_acts_replace(s16 courseNum, const char* courseName, const char* act1, const char* act2, const char* act3, const char* act4, const char* act5, const char* act6);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_course_name_get](#smlua_text_utils_course_name_get) + +### Lua Example +`local stringValue = smlua_text_utils_course_name_get(courseNum)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | + +### Returns +- `string` + +### C Prototype +`const char* smlua_text_utils_course_name_get(s16 courseNum);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_course_name_mod_index](#smlua_text_utils_course_name_mod_index) + +### Lua Example +`local integerValue = smlua_text_utils_course_name_mod_index(courseNum)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | + +### Returns +- `integer` + +### C Prototype +`s32 smlua_text_utils_course_name_mod_index(s16 courseNum);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_course_name_replace](#smlua_text_utils_course_name_replace) + +### Lua Example +`smlua_text_utils_course_name_replace(courseNum, name)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| name | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_course_name_replace(s16 courseNum, const char* name);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_course_name_reset](#smlua_text_utils_course_name_reset) + +### Lua Example +`smlua_text_utils_course_name_reset(courseNum)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_course_name_reset(s16 courseNum);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_dialog_replace](#smlua_text_utils_dialog_replace) + +### Lua Example +`smlua_text_utils_dialog_replace(dialogId, unused, linesPerBox, leftOffset, width, str)` + +### Parameters +| Field | Type | +| ----- | ---- | +| dialogId | [enum DialogId](constants.md#enum-DialogId) | +| unused | `integer` | +| linesPerBox | `integer` | +| leftOffset | `integer` | +| width | `integer` | +| str | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_dialog_replace(enum DialogId dialogId, u32 unused, s8 linesPerBox, s16 leftOffset, s16 width, const char* str);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_extra_text_replace](#smlua_text_utils_extra_text_replace) + +### Lua Example +`smlua_text_utils_extra_text_replace(index, text)` + +### Parameters +| Field | Type | +| ----- | ---- | +| index | `integer` | +| text | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_extra_text_replace(s16 index, const char* text);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_get_language](#smlua_text_utils_get_language) + +### Lua Example +`local stringValue = smlua_text_utils_get_language()` + +### Parameters +- None + +### Returns +- `string` + +### C Prototype +`const char* smlua_text_utils_get_language(void);` + +[:arrow_up_small:](#) + +
+ +## [smlua_text_utils_secret_star_replace](#smlua_text_utils_secret_star_replace) + +### Lua Example +`smlua_text_utils_secret_star_replace(courseNum, courseName)` + +### Parameters +| Field | Type | +| ----- | ---- | +| courseNum | `integer` | +| courseName | `string` | + +### Returns +- None + +### C Prototype +`void smlua_text_utils_secret_star_replace(s16 courseNum, const char* courseName);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from sound_init.h + +
+ + +## [disable_background_sound](#disable_background_sound) + +### Lua Example +`disable_background_sound()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void disable_background_sound(void);` + +[:arrow_up_small:](#) + +
+ +## [enable_background_sound](#enable_background_sound) + +### Lua Example +`enable_background_sound()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void enable_background_sound(void);` + +[:arrow_up_small:](#) + +
+ +## [fadeout_cap_music](#fadeout_cap_music) + +### Lua Example +`fadeout_cap_music()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void fadeout_cap_music(void);` + +[:arrow_up_small:](#) + +
+ +## [fadeout_level_music](#fadeout_level_music) + +### Lua Example +`fadeout_level_music(fadeTimer)` + +### Parameters +| Field | Type | +| ----- | ---- | +| fadeTimer | `integer` | + +### Returns +- None + +### C Prototype +`void fadeout_level_music(s16 fadeTimer);` + +[:arrow_up_small:](#) + +
+ +## [fadeout_music](#fadeout_music) + +### Lua Example +`fadeout_music(fadeOutTime)` + +### Parameters +| Field | Type | +| ----- | ---- | +| fadeOutTime | `integer` | + +### Returns +- None + +### C Prototype +`void fadeout_music(s16 fadeOutTime);` + +[:arrow_up_small:](#) + +
+ +## [lower_background_noise](#lower_background_noise) + +### Lua Example +`lower_background_noise(a)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a | `integer` | + +### Returns +- None + +### C Prototype +`void lower_background_noise(s32 a);` + +[:arrow_up_small:](#) + +
+ +## [play_cap_music](#play_cap_music) + +### Lua Example +`play_cap_music(seqArgs)` + +### Parameters +| Field | Type | +| ----- | ---- | +| seqArgs | `integer` | + +### Returns +- None + +### C Prototype +`void play_cap_music(u16 seqArgs);` + +[:arrow_up_small:](#) + +
+ +## [play_cutscene_music](#play_cutscene_music) + +### Lua Example +`play_cutscene_music(seqArgs)` + +### Parameters +| Field | Type | +| ----- | ---- | +| seqArgs | `integer` | + +### Returns +- None + +### C Prototype +`void play_cutscene_music(u16 seqArgs);` + +[:arrow_up_small:](#) + +
+ +## [play_infinite_stairs_music](#play_infinite_stairs_music) + +### Lua Example +`play_infinite_stairs_music()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void play_infinite_stairs_music(void);` + +[:arrow_up_small:](#) + +
+ +## [play_menu_sounds](#play_menu_sounds) + +### Lua Example +`play_menu_sounds(soundMenuFlags)` + +### Parameters +| Field | Type | +| ----- | ---- | +| soundMenuFlags | `integer` | + +### Returns +- None + +### C Prototype +`void play_menu_sounds(s16 soundMenuFlags);` + +[:arrow_up_small:](#) + +
+ +## [play_painting_eject_sound](#play_painting_eject_sound) + +### Lua Example +`play_painting_eject_sound()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void play_painting_eject_sound(void);` + +[:arrow_up_small:](#) + +
+ +## [play_shell_music](#play_shell_music) + +### Lua Example +`play_shell_music()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void play_shell_music(void);` + +[:arrow_up_small:](#) + +
+ +## [raise_background_noise](#raise_background_noise) + +### Lua Example +`raise_background_noise(a)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a | `integer` | + +### Returns +- None + +### C Prototype +`void raise_background_noise(s32 a);` + +[:arrow_up_small:](#) + +
+ +## [reset_volume](#reset_volume) + +### Lua Example +`reset_volume()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void reset_volume(void);` + +[:arrow_up_small:](#) + +
+ +## [set_background_music](#set_background_music) + +### Lua Example +`set_background_music(a, seqArgs, fadeTimer)` + +### Parameters +| Field | Type | +| ----- | ---- | +| a | `integer` | +| seqArgs | `integer` | +| fadeTimer | `integer` | + +### Returns +- None + +### C Prototype +`void set_background_music(u16 a, u16 seqArgs, s16 fadeTimer);` + +[:arrow_up_small:](#) + +
+ +## [stop_cap_music](#stop_cap_music) + +### Lua Example +`stop_cap_music()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void stop_cap_music(void);` + +[:arrow_up_small:](#) + +
+ +## [stop_shell_music](#stop_shell_music) + +### Lua Example +`stop_shell_music()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void stop_shell_music(void);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from spawn_sound.c + +
+ + +## [calc_dist_to_volume_range_1](#calc_dist_to_volume_range_1) + +### Lua Example +`local integerValue = calc_dist_to_volume_range_1(distance)` + +### Parameters +| Field | Type | +| ----- | ---- | +| distance | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 calc_dist_to_volume_range_1(f32 distance);` + +[:arrow_up_small:](#) + +
+ +## [calc_dist_to_volume_range_2](#calc_dist_to_volume_range_2) + +### Lua Example +`local integerValue = calc_dist_to_volume_range_2(distance)` + +### Parameters +| Field | Type | +| ----- | ---- | +| distance | `number` | + +### Returns +- `integer` + +### C Prototype +`s32 calc_dist_to_volume_range_2(f32 distance);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_play_sound_1](#cur_obj_play_sound_1) + +### Lua Example +`cur_obj_play_sound_1(soundMagic)` + +### Parameters +| Field | Type | +| ----- | ---- | +| soundMagic | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_play_sound_1(s32 soundMagic);` + +[:arrow_up_small:](#) + +
+ +## [cur_obj_play_sound_2](#cur_obj_play_sound_2) + +### Lua Example +`cur_obj_play_sound_2(soundMagic)` + +### Parameters +| Field | Type | +| ----- | ---- | +| soundMagic | `integer` | + +### Returns +- None + +### C Prototype +`void cur_obj_play_sound_2(s32 soundMagic);` + +[:arrow_up_small:](#) + +
+ +## [exec_anim_sound_state](#exec_anim_sound_state) + +### Lua Example +`exec_anim_sound_state(soundStates, maxSoundStates)` + +### Parameters +| Field | Type | +| ----- | ---- | +| soundStates | [SoundState](structs.md#SoundState) | +| maxSoundStates | `integer` | + +### Returns +- None + +### C Prototype +`void exec_anim_sound_state(struct SoundState *soundStates, u16 maxSoundStates);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from surface_collision.h + +
+ + +## [find_ceil_height](#find_ceil_height) + +### Lua Example +`local numberValue = find_ceil_height(x, y, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x | `number` | +| y | `number` | +| z | `number` | + +### Returns +- `number` + +### C Prototype +`f32 find_ceil_height(f32 x, f32 y, f32 z);` + +[:arrow_up_small:](#) + +
+ +## [find_floor_height](#find_floor_height) + +### Lua Example +`local numberValue = find_floor_height(x, y, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x | `number` | +| y | `number` | +| z | `number` | + +### Returns +- `number` + +### C Prototype +`f32 find_floor_height(f32 x, f32 y, f32 z);` + +[:arrow_up_small:](#) + +
+ +## [find_poison_gas_level](#find_poison_gas_level) + +### Lua Example +`local numberValue = find_poison_gas_level(x, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x | `number` | +| z | `number` | + +### Returns +- `number` + +### C Prototype +`f32 find_poison_gas_level(f32 x, f32 z);` + +[:arrow_up_small:](#) + +
+ +## [find_wall_collisions](#find_wall_collisions) + +### Lua Example +`local integerValue = find_wall_collisions(colData)` + +### Parameters +| Field | Type | +| ----- | ---- | +| colData | [WallCollisionData](structs.md#WallCollisionData) | + +### Returns +- `integer` + +### C Prototype +`s32 find_wall_collisions(struct WallCollisionData *colData);` + +[:arrow_up_small:](#) + +
+ +## [find_water_level](#find_water_level) + +### Lua Example +`local numberValue = find_water_level(x, z)` + +### Parameters +| Field | Type | +| ----- | ---- | +| x | `number` | +| z | `number` | + +### Returns +- `number` + +### C Prototype +`f32 find_water_level(f32 x, f32 z);` + +[:arrow_up_small:](#) + +
+ +--- +# functions from surface_load.h + +
+ + +## [get_area_terrain_size](#get_area_terrain_size) + +### Lua Example +`local integerValue = get_area_terrain_size(data)` + +### Parameters +| Field | Type | +| ----- | ---- | +| data | `Pointer` <`integer`> | + +### Returns +- `integer` + +### C Prototype +`u32 get_area_terrain_size(s16 *data);` + +[:arrow_up_small:](#) + +
+ +## [load_area_terrain](#load_area_terrain) + +### Lua Example +`load_area_terrain(index, data, surfaceRooms, macroObjects)` + +### Parameters +| Field | Type | +| ----- | ---- | +| index | `integer` | +| data | `Pointer` <`integer`> | +| surfaceRooms | `Pointer` <`integer`> | +| macroObjects | `Pointer` <`integer`> | + +### Returns +- None + +### C Prototype +`void load_area_terrain(s16 index, s16 *data, s8 *surfaceRooms, s16 *macroObjects);` + +[:arrow_up_small:](#) + +
+ +## [load_object_collision_model](#load_object_collision_model) + +### Lua Example +`load_object_collision_model()` + +### Parameters +- None + +### Returns +- None + +### C Prototype +`void load_object_collision_model(void);` + +[:arrow_up_small:](#) + +
+ +## [obj_get_surface_from_index](#obj_get_surface_from_index) + +### Lua Example +`local SurfaceValue = obj_get_surface_from_index(o, index)` + +### Parameters +| Field | Type | +| ----- | ---- | +| o | [Object](structs.md#Object) | +| index | `integer` | + +### Returns +[Surface](structs.md#Surface) + +### C Prototype +`struct Surface *obj_get_surface_from_index(struct Object *o, u32 index);` + +[:arrow_up_small:](#) + +
+ +## [surface_has_force](#surface_has_force) + +### Lua Example +`local booleanValue = surface_has_force(surfaceType)` + +### Parameters +| Field | Type | +| ----- | ---- | +| surfaceType | `integer` | + +### Returns +- `boolean` + +### C Prototype +`bool surface_has_force(s16 surfaceType);` + +[:arrow_up_small:](#) + +
+ +--- + +[< prev](functions-5.md) | [1](functions.md) | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | 6] + diff --git a/docs/lua/functions.md b/docs/lua/functions.md index f4e01fe7b..d7fdcbd0d 100644 --- a/docs/lua/functions.md +++ b/docs/lua/functions.md @@ -2,7 +2,7 @@ --- -1 | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [next >](functions-2.md)] +1 | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-2.md)] --- @@ -1124,18 +1124,18 @@
- mario_step.h - - [get_additive_y_vel_for_jumps](functions-3.md#get_additive_y_vel_for_jumps) - - [init_bully_collision_data](functions-3.md#init_bully_collision_data) - - [mario_bonk_reflection](functions-3.md#mario_bonk_reflection) - - [mario_push_off_steep_floor](functions-3.md#mario_push_off_steep_floor) - - [mario_update_moving_sand](functions-3.md#mario_update_moving_sand) - - [mario_update_quicksand](functions-3.md#mario_update_quicksand) - - [mario_update_windy_ground](functions-3.md#mario_update_windy_ground) - - [perform_air_step](functions-3.md#perform_air_step) - - [perform_ground_step](functions-3.md#perform_ground_step) - - [set_vel_from_pitch_and_yaw](functions-3.md#set_vel_from_pitch_and_yaw) - - [stationary_ground_step](functions-3.md#stationary_ground_step) - - [stop_and_set_height_to_floor](functions-3.md#stop_and_set_height_to_floor) + - [get_additive_y_vel_for_jumps](functions-4.md#get_additive_y_vel_for_jumps) + - [init_bully_collision_data](functions-4.md#init_bully_collision_data) + - [mario_bonk_reflection](functions-4.md#mario_bonk_reflection) + - [mario_push_off_steep_floor](functions-4.md#mario_push_off_steep_floor) + - [mario_update_moving_sand](functions-4.md#mario_update_moving_sand) + - [mario_update_quicksand](functions-4.md#mario_update_quicksand) + - [mario_update_windy_ground](functions-4.md#mario_update_windy_ground) + - [perform_air_step](functions-4.md#perform_air_step) + - [perform_ground_step](functions-4.md#perform_ground_step) + - [set_vel_from_pitch_and_yaw](functions-4.md#set_vel_from_pitch_and_yaw) + - [stationary_ground_step](functions-4.md#stationary_ground_step) + - [stop_and_set_height_to_floor](functions-4.md#stop_and_set_height_to_floor)
@@ -1328,246 +1328,246 @@
- object_helpers.c - - [abs_angle_diff](functions-4.md#abs_angle_diff) - - [apply_drag_to_value](functions-4.md#apply_drag_to_value) - - [approach_f32_signed](functions-4.md#approach_f32_signed) - - [approach_f32_symmetric](functions-4.md#approach_f32_symmetric) - - [approach_s16_symmetric](functions-4.md#approach_s16_symmetric) - - [bhv_dust_smoke_loop](functions-4.md#bhv_dust_smoke_loop) - - [bhv_init_room](functions-4.md#bhv_init_room) - - [bit_shift_left](functions-4.md#bit_shift_left) - - [chain_segment_init](functions-4.md#chain_segment_init) - - [clear_move_flag](functions-4.md#clear_move_flag) - - [clear_time_stop_flags](functions-4.md#clear_time_stop_flags) - - [count_objects_with_behavior](functions-4.md#count_objects_with_behavior) - - [count_unimportant_objects](functions-4.md#count_unimportant_objects) - - [create_transformation_from_matrices](functions-4.md#create_transformation_from_matrices) - - [cur_obj_abs_y_dist_to_home](functions-4.md#cur_obj_abs_y_dist_to_home) - - [cur_obj_advance_looping_anim](functions-4.md#cur_obj_advance_looping_anim) - - [cur_obj_align_gfx_with_floor](functions-4.md#cur_obj_align_gfx_with_floor) - - [cur_obj_angle_to_home](functions-4.md#cur_obj_angle_to_home) - - [cur_obj_apply_drag_xz](functions-4.md#cur_obj_apply_drag_xz) - - [cur_obj_become_intangible](functions-4.md#cur_obj_become_intangible) - - [cur_obj_become_tangible](functions-4.md#cur_obj_become_tangible) - - [cur_obj_can_mario_activate_textbox](functions-4.md#cur_obj_can_mario_activate_textbox) - - [cur_obj_can_mario_activate_textbox_2](functions-4.md#cur_obj_can_mario_activate_textbox_2) - - [cur_obj_change_action](functions-4.md#cur_obj_change_action) - - [cur_obj_check_anim_frame](functions-4.md#cur_obj_check_anim_frame) - - [cur_obj_check_anim_frame_in_range](functions-4.md#cur_obj_check_anim_frame_in_range) - - [cur_obj_check_frame_prior_current_frame](functions-4.md#cur_obj_check_frame_prior_current_frame) - - [cur_obj_check_grabbed_mario](functions-4.md#cur_obj_check_grabbed_mario) - - [cur_obj_check_if_at_animation_end](functions-4.md#cur_obj_check_if_at_animation_end) - - [cur_obj_check_if_near_animation_end](functions-4.md#cur_obj_check_if_near_animation_end) - - [cur_obj_check_interacted](functions-4.md#cur_obj_check_interacted) - - [cur_obj_clear_interact_status_flag](functions-4.md#cur_obj_clear_interact_status_flag) - - [cur_obj_compute_vel_xz](functions-4.md#cur_obj_compute_vel_xz) - - [cur_obj_count_objects_with_behavior](functions-4.md#cur_obj_count_objects_with_behavior) - - [cur_obj_detect_steep_floor](functions-4.md#cur_obj_detect_steep_floor) - - [cur_obj_disable](functions-4.md#cur_obj_disable) - - [cur_obj_disable_rendering](functions-4.md#cur_obj_disable_rendering) - - [cur_obj_disable_rendering_and_become_intangible](functions-4.md#cur_obj_disable_rendering_and_become_intangible) - - [cur_obj_dist_to_nearest_object_with_behavior](functions-4.md#cur_obj_dist_to_nearest_object_with_behavior) - - [cur_obj_enable_rendering](functions-4.md#cur_obj_enable_rendering) - - [cur_obj_enable_rendering_2](functions-4.md#cur_obj_enable_rendering_2) - - [cur_obj_enable_rendering_and_become_tangible](functions-4.md#cur_obj_enable_rendering_and_become_tangible) - - [cur_obj_enable_rendering_if_mario_in_room](functions-4.md#cur_obj_enable_rendering_if_mario_in_room) - - [cur_obj_end_dialog](functions-4.md#cur_obj_end_dialog) - - [cur_obj_extend_animation_if_at_end](functions-4.md#cur_obj_extend_animation_if_at_end) - - [cur_obj_find_nearby_held_actor](functions-4.md#cur_obj_find_nearby_held_actor) - - [cur_obj_find_nearest_object_with_behavior](functions-4.md#cur_obj_find_nearest_object_with_behavior) - - [cur_obj_find_nearest_pole](functions-4.md#cur_obj_find_nearest_pole) - - [cur_obj_follow_path](functions-4.md#cur_obj_follow_path) - - [cur_obj_forward_vel_approach_upward](functions-4.md#cur_obj_forward_vel_approach_upward) - - [cur_obj_get_dropped](functions-4.md#cur_obj_get_dropped) - - [cur_obj_get_thrown_or_placed](functions-4.md#cur_obj_get_thrown_or_placed) - - [cur_obj_has_behavior](functions-4.md#cur_obj_has_behavior) - - [cur_obj_has_model](functions-4.md#cur_obj_has_model) - - [cur_obj_hide](functions-4.md#cur_obj_hide) - - [cur_obj_hide_if_mario_far_away_y](functions-4.md#cur_obj_hide_if_mario_far_away_y) - - [cur_obj_if_hit_wall_bounce_away](functions-4.md#cur_obj_if_hit_wall_bounce_away) - - [cur_obj_init_animation](functions-4.md#cur_obj_init_animation) - - [cur_obj_init_animation_and_anim_frame](functions-4.md#cur_obj_init_animation_and_anim_frame) - - [cur_obj_init_animation_and_check_if_near_end](functions-4.md#cur_obj_init_animation_and_check_if_near_end) - - [cur_obj_init_animation_and_extend_if_at_end](functions-4.md#cur_obj_init_animation_and_extend_if_at_end) - - [cur_obj_init_animation_with_accel_and_sound](functions-4.md#cur_obj_init_animation_with_accel_and_sound) - - [cur_obj_init_animation_with_sound](functions-4.md#cur_obj_init_animation_with_sound) - - [cur_obj_is_any_player_on_platform](functions-4.md#cur_obj_is_any_player_on_platform) - - [cur_obj_is_mario_ground_pounding_platform](functions-4.md#cur_obj_is_mario_ground_pounding_platform) - - [cur_obj_is_mario_on_platform](functions-4.md#cur_obj_is_mario_on_platform) - - [cur_obj_lateral_dist_from_mario_to_home](functions-4.md#cur_obj_lateral_dist_from_mario_to_home) - - [cur_obj_lateral_dist_from_obj_to_home](functions-4.md#cur_obj_lateral_dist_from_obj_to_home) - - [cur_obj_lateral_dist_to_home](functions-4.md#cur_obj_lateral_dist_to_home) - - [cur_obj_mario_far_away](functions-4.md#cur_obj_mario_far_away) - - [cur_obj_move_after_thrown_or_dropped](functions-4.md#cur_obj_move_after_thrown_or_dropped) - - [cur_obj_move_standard](functions-4.md#cur_obj_move_standard) - - [cur_obj_move_up_and_down](functions-4.md#cur_obj_move_up_and_down) - - [cur_obj_move_update_ground_air_flags](functions-4.md#cur_obj_move_update_ground_air_flags) - - [cur_obj_move_update_underwater_flags](functions-4.md#cur_obj_move_update_underwater_flags) - - [cur_obj_move_using_fvel_and_gravity](functions-4.md#cur_obj_move_using_fvel_and_gravity) - - [cur_obj_move_using_vel](functions-4.md#cur_obj_move_using_vel) - - [cur_obj_move_using_vel_and_gravity](functions-4.md#cur_obj_move_using_vel_and_gravity) - - [cur_obj_move_xz](functions-4.md#cur_obj_move_xz) - - [cur_obj_move_xz_using_fvel_and_yaw](functions-4.md#cur_obj_move_xz_using_fvel_and_yaw) - - [cur_obj_move_y](functions-4.md#cur_obj_move_y) - - [cur_obj_move_y_and_get_water_level](functions-4.md#cur_obj_move_y_and_get_water_level) - - [cur_obj_move_y_with_terminal_vel](functions-4.md#cur_obj_move_y_with_terminal_vel) - - [cur_obj_nearest_object_with_behavior](functions-4.md#cur_obj_nearest_object_with_behavior) - - [cur_obj_outside_home_rectangle](functions-4.md#cur_obj_outside_home_rectangle) - - [cur_obj_outside_home_square](functions-4.md#cur_obj_outside_home_square) - - [cur_obj_push_mario_away](functions-4.md#cur_obj_push_mario_away) - - [cur_obj_push_mario_away_from_cylinder](functions-4.md#cur_obj_push_mario_away_from_cylinder) - - [cur_obj_reflect_move_angle_off_wall](functions-4.md#cur_obj_reflect_move_angle_off_wall) - - [cur_obj_reset_timer_and_subaction](functions-4.md#cur_obj_reset_timer_and_subaction) - - [cur_obj_resolve_wall_collisions](functions-4.md#cur_obj_resolve_wall_collisions) - - [cur_obj_reverse_animation](functions-4.md#cur_obj_reverse_animation) - - [cur_obj_rotate_face_angle_using_vel](functions-4.md#cur_obj_rotate_face_angle_using_vel) - - [cur_obj_rotate_move_angle_using_vel](functions-4.md#cur_obj_rotate_move_angle_using_vel) - - [cur_obj_rotate_yaw_toward](functions-4.md#cur_obj_rotate_yaw_toward) - - [cur_obj_scale](functions-4.md#cur_obj_scale) - - [cur_obj_scale_over_time](functions-4.md#cur_obj_scale_over_time) - - [cur_obj_set_behavior](functions-4.md#cur_obj_set_behavior) - - [cur_obj_set_billboard_if_vanilla_cam](functions-4.md#cur_obj_set_billboard_if_vanilla_cam) - - [cur_obj_set_face_angle_to_move_angle](functions-4.md#cur_obj_set_face_angle_to_move_angle) - - [cur_obj_set_hitbox_and_die_if_attacked](functions-4.md#cur_obj_set_hitbox_and_die_if_attacked) - - [cur_obj_set_hitbox_radius_and_height](functions-4.md#cur_obj_set_hitbox_radius_and_height) - - [cur_obj_set_home_once](functions-4.md#cur_obj_set_home_once) - - [cur_obj_set_hurtbox_radius_and_height](functions-4.md#cur_obj_set_hurtbox_radius_and_height) - - [cur_obj_set_pos_relative](functions-4.md#cur_obj_set_pos_relative) - - [cur_obj_set_pos_relative_to_parent](functions-4.md#cur_obj_set_pos_relative_to_parent) - - [cur_obj_set_pos_to_home](functions-4.md#cur_obj_set_pos_to_home) - - [cur_obj_set_pos_to_home_and_stop](functions-4.md#cur_obj_set_pos_to_home_and_stop) - - [cur_obj_set_pos_to_home_with_debug](functions-4.md#cur_obj_set_pos_to_home_with_debug) - - [cur_obj_set_pos_via_transform](functions-4.md#cur_obj_set_pos_via_transform) - - [cur_obj_set_vel_from_mario_vel](functions-4.md#cur_obj_set_vel_from_mario_vel) - - [cur_obj_set_y_vel_and_animation](functions-4.md#cur_obj_set_y_vel_and_animation) - - [cur_obj_shake_screen](functions-4.md#cur_obj_shake_screen) - - [cur_obj_shake_y](functions-4.md#cur_obj_shake_y) - - [cur_obj_shake_y_until](functions-4.md#cur_obj_shake_y_until) - - [cur_obj_spawn_loot_blue_coin](functions-4.md#cur_obj_spawn_loot_blue_coin) - - [cur_obj_spawn_loot_coin_at_mario_pos](functions-4.md#cur_obj_spawn_loot_coin_at_mario_pos) - - [cur_obj_spawn_particles](functions-4.md#cur_obj_spawn_particles) - - [cur_obj_spawn_star_at_y_offset](functions-4.md#cur_obj_spawn_star_at_y_offset) - - [cur_obj_start_cam_event](functions-4.md#cur_obj_start_cam_event) - - [cur_obj_unhide](functions-4.md#cur_obj_unhide) - - [cur_obj_unrender_and_reset_state](functions-4.md#cur_obj_unrender_and_reset_state) - - [cur_obj_unused_init_on_floor](functions-4.md#cur_obj_unused_init_on_floor) - - [cur_obj_unused_play_footstep_sound](functions-4.md#cur_obj_unused_play_footstep_sound) - - [cur_obj_unused_resolve_wall_collisions](functions-4.md#cur_obj_unused_resolve_wall_collisions) - - [cur_obj_update_floor](functions-4.md#cur_obj_update_floor) - - [cur_obj_update_floor_and_resolve_wall_collisions](functions-4.md#cur_obj_update_floor_and_resolve_wall_collisions) - - [cur_obj_update_floor_and_walls](functions-4.md#cur_obj_update_floor_and_walls) - - [cur_obj_update_floor_height](functions-4.md#cur_obj_update_floor_height) - - [cur_obj_update_floor_height_and_get_floor](functions-4.md#cur_obj_update_floor_height_and_get_floor) - - [cur_obj_wait_then_blink](functions-4.md#cur_obj_wait_then_blink) - - [cur_obj_was_attacked_or_ground_pounded](functions-4.md#cur_obj_was_attacked_or_ground_pounded) - - [cur_obj_within_12k_bounds](functions-4.md#cur_obj_within_12k_bounds) - - [disable_time_stop](functions-4.md#disable_time_stop) - - [disable_time_stop_including_mario](functions-4.md#disable_time_stop_including_mario) - - [dist_between_object_and_point](functions-4.md#dist_between_object_and_point) - - [dist_between_objects](functions-4.md#dist_between_objects) - - [enable_time_stop](functions-4.md#enable_time_stop) - - [enable_time_stop_if_alone](functions-4.md#enable_time_stop_if_alone) - - [enable_time_stop_including_mario](functions-4.md#enable_time_stop_including_mario) - - [find_object_with_behavior](functions-4.md#find_object_with_behavior) - - [find_unimportant_object](functions-4.md#find_unimportant_object) - - [geo_offset_klepto_debug](functions-4.md#geo_offset_klepto_debug) - - [get_object_list_from_behavior](functions-4.md#get_object_list_from_behavior) - - [get_trajectory_length](functions-4.md#get_trajectory_length) - - [increment_velocity_toward_range](functions-4.md#increment_velocity_toward_range) - - [is_item_in_array](functions-4.md#is_item_in_array) - - [is_mario_moving_fast_or_in_air](functions-4.md#is_mario_moving_fast_or_in_air) - - [lateral_dist_between_objects](functions-4.md#lateral_dist_between_objects) - - [linear_mtxf_mul_vec3f](functions-4.md#linear_mtxf_mul_vec3f) - - [linear_mtxf_transpose_mul_vec3f](functions-4.md#linear_mtxf_transpose_mul_vec3f) - - [mario_is_dive_sliding](functions-4.md#mario_is_dive_sliding) - - [mario_is_in_air_action](functions-4.md#mario_is_in_air_action) - - [mario_is_within_rectangle](functions-4.md#mario_is_within_rectangle) - - [mario_set_flag](functions-4.md#mario_set_flag) - - [obj_angle_to_object](functions-4.md#obj_angle_to_object) - - [obj_angle_to_point](functions-4.md#obj_angle_to_point) - - [obj_apply_scale_to_matrix](functions-4.md#obj_apply_scale_to_matrix) - - [obj_apply_scale_to_transform](functions-4.md#obj_apply_scale_to_transform) - - [obj_attack_collided_from_other_object](functions-4.md#obj_attack_collided_from_other_object) - - [obj_become_tangible](functions-4.md#obj_become_tangible) - - [obj_build_relative_transform](functions-4.md#obj_build_relative_transform) - - [obj_build_transform_from_pos_and_angle](functions-4.md#obj_build_transform_from_pos_and_angle) - - [obj_build_transform_relative_to_parent](functions-4.md#obj_build_transform_relative_to_parent) - - [obj_build_vel_from_transform](functions-4.md#obj_build_vel_from_transform) - - [obj_check_if_collided_with_object](functions-4.md#obj_check_if_collided_with_object) - - [obj_copy_angle](functions-4.md#obj_copy_angle) - - [obj_copy_behavior_params](functions-4.md#obj_copy_behavior_params) - - [obj_copy_graph_y_offset](functions-4.md#obj_copy_graph_y_offset) - - [obj_copy_pos](functions-4.md#obj_copy_pos) - - [obj_copy_pos_and_angle](functions-4.md#obj_copy_pos_and_angle) - - [obj_copy_scale](functions-4.md#obj_copy_scale) - - [obj_create_transform_from_self](functions-4.md#obj_create_transform_from_self) - - [obj_explode_and_spawn_coins](functions-4.md#obj_explode_and_spawn_coins) - - [obj_has_behavior](functions-4.md#obj_has_behavior) - - [obj_init_animation](functions-4.md#obj_init_animation) - - [obj_init_animation_with_accel_and_sound](functions-4.md#obj_init_animation_with_accel_and_sound) - - [obj_init_animation_with_sound](functions-4.md#obj_init_animation_with_sound) - - [obj_is_hidden](functions-4.md#obj_is_hidden) - - [obj_mark_for_deletion](functions-4.md#obj_mark_for_deletion) - - [obj_pitch_to_object](functions-4.md#obj_pitch_to_object) - - [obj_scale](functions-4.md#obj_scale) - - [obj_scale_random](functions-4.md#obj_scale_random) - - [obj_scale_xyz](functions-4.md#obj_scale_xyz) - - [obj_set_angle](functions-4.md#obj_set_angle) - - [obj_set_behavior](functions-4.md#obj_set_behavior) - - [obj_set_billboard](functions-4.md#obj_set_billboard) - - [obj_set_cylboard](functions-4.md#obj_set_cylboard) - - [obj_set_face_angle](functions-4.md#obj_set_face_angle) - - [obj_set_face_angle_to_move_angle](functions-4.md#obj_set_face_angle_to_move_angle) - - [obj_set_gfx_angle](functions-4.md#obj_set_gfx_angle) - - [obj_set_gfx_pos](functions-4.md#obj_set_gfx_pos) - - [obj_set_gfx_pos_at_obj_pos](functions-4.md#obj_set_gfx_pos_at_obj_pos) - - [obj_set_gfx_pos_from_pos](functions-4.md#obj_set_gfx_pos_from_pos) - - [obj_set_gfx_scale](functions-4.md#obj_set_gfx_scale) - - [obj_set_held_state](functions-4.md#obj_set_held_state) - - [obj_set_hitbox](functions-4.md#obj_set_hitbox) - - [obj_set_hitbox_radius_and_height](functions-4.md#obj_set_hitbox_radius_and_height) - - [obj_set_hurtbox_radius_and_height](functions-4.md#obj_set_hurtbox_radius_and_height) - - [obj_set_move_angle](functions-4.md#obj_set_move_angle) - - [obj_set_parent_relative_pos](functions-4.md#obj_set_parent_relative_pos) - - [obj_set_pos](functions-4.md#obj_set_pos) - - [obj_set_pos_relative](functions-4.md#obj_set_pos_relative) - - [obj_set_throw_matrix_from_transform](functions-4.md#obj_set_throw_matrix_from_transform) - - [obj_spawn_loot_blue_coins](functions-4.md#obj_spawn_loot_blue_coins) - - [obj_spawn_loot_coins](functions-4.md#obj_spawn_loot_coins) - - [obj_spawn_loot_yellow_coins](functions-4.md#obj_spawn_loot_yellow_coins) - - [obj_translate_local](functions-4.md#obj_translate_local) - - [obj_translate_xyz_random](functions-4.md#obj_translate_xyz_random) - - [obj_translate_xz_random](functions-4.md#obj_translate_xz_random) - - [obj_turn_toward_object](functions-4.md#obj_turn_toward_object) - - [obj_update_pos_from_parent_transformation](functions-4.md#obj_update_pos_from_parent_transformation) - - [player_performed_grab_escape_action](functions-4.md#player_performed_grab_escape_action) - - [random_f32_around_zero](functions-4.md#random_f32_around_zero) - - [set_mario_interact_hoot_if_in_range](functions-4.md#set_mario_interact_hoot_if_in_range) - - [set_room_override](functions-4.md#set_room_override) - - [set_time_stop_flags](functions-4.md#set_time_stop_flags) - - [set_time_stop_flags_if_alone](functions-4.md#set_time_stop_flags_if_alone) - - [signum_positive](functions-4.md#signum_positive) - - [spawn_base_star_with_no_lvl_exit](functions-4.md#spawn_base_star_with_no_lvl_exit) - - [spawn_mist_particles](functions-4.md#spawn_mist_particles) - - [spawn_mist_particles_with_sound](functions-4.md#spawn_mist_particles_with_sound) - - [spawn_star_with_no_lvl_exit](functions-4.md#spawn_star_with_no_lvl_exit) - - [spawn_water_droplet](functions-4.md#spawn_water_droplet) - - [stub_obj_helpers_3](functions-4.md#stub_obj_helpers_3) - - [stub_obj_helpers_4](functions-4.md#stub_obj_helpers_4) + - [abs_angle_diff](functions-5.md#abs_angle_diff) + - [apply_drag_to_value](functions-5.md#apply_drag_to_value) + - [approach_f32_signed](functions-5.md#approach_f32_signed) + - [approach_f32_symmetric](functions-5.md#approach_f32_symmetric) + - [approach_s16_symmetric](functions-5.md#approach_s16_symmetric) + - [bhv_dust_smoke_loop](functions-5.md#bhv_dust_smoke_loop) + - [bhv_init_room](functions-5.md#bhv_init_room) + - [bit_shift_left](functions-5.md#bit_shift_left) + - [chain_segment_init](functions-5.md#chain_segment_init) + - [clear_move_flag](functions-5.md#clear_move_flag) + - [clear_time_stop_flags](functions-5.md#clear_time_stop_flags) + - [count_objects_with_behavior](functions-5.md#count_objects_with_behavior) + - [count_unimportant_objects](functions-5.md#count_unimportant_objects) + - [create_transformation_from_matrices](functions-5.md#create_transformation_from_matrices) + - [cur_obj_abs_y_dist_to_home](functions-5.md#cur_obj_abs_y_dist_to_home) + - [cur_obj_advance_looping_anim](functions-5.md#cur_obj_advance_looping_anim) + - [cur_obj_align_gfx_with_floor](functions-5.md#cur_obj_align_gfx_with_floor) + - [cur_obj_angle_to_home](functions-5.md#cur_obj_angle_to_home) + - [cur_obj_apply_drag_xz](functions-5.md#cur_obj_apply_drag_xz) + - [cur_obj_become_intangible](functions-5.md#cur_obj_become_intangible) + - [cur_obj_become_tangible](functions-5.md#cur_obj_become_tangible) + - [cur_obj_can_mario_activate_textbox](functions-5.md#cur_obj_can_mario_activate_textbox) + - [cur_obj_can_mario_activate_textbox_2](functions-5.md#cur_obj_can_mario_activate_textbox_2) + - [cur_obj_change_action](functions-5.md#cur_obj_change_action) + - [cur_obj_check_anim_frame](functions-5.md#cur_obj_check_anim_frame) + - [cur_obj_check_anim_frame_in_range](functions-5.md#cur_obj_check_anim_frame_in_range) + - [cur_obj_check_frame_prior_current_frame](functions-5.md#cur_obj_check_frame_prior_current_frame) + - [cur_obj_check_grabbed_mario](functions-5.md#cur_obj_check_grabbed_mario) + - [cur_obj_check_if_at_animation_end](functions-5.md#cur_obj_check_if_at_animation_end) + - [cur_obj_check_if_near_animation_end](functions-5.md#cur_obj_check_if_near_animation_end) + - [cur_obj_check_interacted](functions-5.md#cur_obj_check_interacted) + - [cur_obj_clear_interact_status_flag](functions-5.md#cur_obj_clear_interact_status_flag) + - [cur_obj_compute_vel_xz](functions-5.md#cur_obj_compute_vel_xz) + - [cur_obj_count_objects_with_behavior](functions-5.md#cur_obj_count_objects_with_behavior) + - [cur_obj_detect_steep_floor](functions-5.md#cur_obj_detect_steep_floor) + - [cur_obj_disable](functions-5.md#cur_obj_disable) + - [cur_obj_disable_rendering](functions-5.md#cur_obj_disable_rendering) + - [cur_obj_disable_rendering_and_become_intangible](functions-5.md#cur_obj_disable_rendering_and_become_intangible) + - [cur_obj_dist_to_nearest_object_with_behavior](functions-5.md#cur_obj_dist_to_nearest_object_with_behavior) + - [cur_obj_enable_rendering](functions-5.md#cur_obj_enable_rendering) + - [cur_obj_enable_rendering_2](functions-5.md#cur_obj_enable_rendering_2) + - [cur_obj_enable_rendering_and_become_tangible](functions-5.md#cur_obj_enable_rendering_and_become_tangible) + - [cur_obj_enable_rendering_if_mario_in_room](functions-5.md#cur_obj_enable_rendering_if_mario_in_room) + - [cur_obj_end_dialog](functions-5.md#cur_obj_end_dialog) + - [cur_obj_extend_animation_if_at_end](functions-5.md#cur_obj_extend_animation_if_at_end) + - [cur_obj_find_nearby_held_actor](functions-5.md#cur_obj_find_nearby_held_actor) + - [cur_obj_find_nearest_object_with_behavior](functions-5.md#cur_obj_find_nearest_object_with_behavior) + - [cur_obj_find_nearest_pole](functions-5.md#cur_obj_find_nearest_pole) + - [cur_obj_follow_path](functions-5.md#cur_obj_follow_path) + - [cur_obj_forward_vel_approach_upward](functions-5.md#cur_obj_forward_vel_approach_upward) + - [cur_obj_get_dropped](functions-5.md#cur_obj_get_dropped) + - [cur_obj_get_thrown_or_placed](functions-5.md#cur_obj_get_thrown_or_placed) + - [cur_obj_has_behavior](functions-5.md#cur_obj_has_behavior) + - [cur_obj_has_model](functions-5.md#cur_obj_has_model) + - [cur_obj_hide](functions-5.md#cur_obj_hide) + - [cur_obj_hide_if_mario_far_away_y](functions-5.md#cur_obj_hide_if_mario_far_away_y) + - [cur_obj_if_hit_wall_bounce_away](functions-5.md#cur_obj_if_hit_wall_bounce_away) + - [cur_obj_init_animation](functions-5.md#cur_obj_init_animation) + - [cur_obj_init_animation_and_anim_frame](functions-5.md#cur_obj_init_animation_and_anim_frame) + - [cur_obj_init_animation_and_check_if_near_end](functions-5.md#cur_obj_init_animation_and_check_if_near_end) + - [cur_obj_init_animation_and_extend_if_at_end](functions-5.md#cur_obj_init_animation_and_extend_if_at_end) + - [cur_obj_init_animation_with_accel_and_sound](functions-5.md#cur_obj_init_animation_with_accel_and_sound) + - [cur_obj_init_animation_with_sound](functions-5.md#cur_obj_init_animation_with_sound) + - [cur_obj_is_any_player_on_platform](functions-5.md#cur_obj_is_any_player_on_platform) + - [cur_obj_is_mario_ground_pounding_platform](functions-5.md#cur_obj_is_mario_ground_pounding_platform) + - [cur_obj_is_mario_on_platform](functions-5.md#cur_obj_is_mario_on_platform) + - [cur_obj_lateral_dist_from_mario_to_home](functions-5.md#cur_obj_lateral_dist_from_mario_to_home) + - [cur_obj_lateral_dist_from_obj_to_home](functions-5.md#cur_obj_lateral_dist_from_obj_to_home) + - [cur_obj_lateral_dist_to_home](functions-5.md#cur_obj_lateral_dist_to_home) + - [cur_obj_mario_far_away](functions-5.md#cur_obj_mario_far_away) + - [cur_obj_move_after_thrown_or_dropped](functions-5.md#cur_obj_move_after_thrown_or_dropped) + - [cur_obj_move_standard](functions-5.md#cur_obj_move_standard) + - [cur_obj_move_up_and_down](functions-5.md#cur_obj_move_up_and_down) + - [cur_obj_move_update_ground_air_flags](functions-5.md#cur_obj_move_update_ground_air_flags) + - [cur_obj_move_update_underwater_flags](functions-5.md#cur_obj_move_update_underwater_flags) + - [cur_obj_move_using_fvel_and_gravity](functions-5.md#cur_obj_move_using_fvel_and_gravity) + - [cur_obj_move_using_vel](functions-5.md#cur_obj_move_using_vel) + - [cur_obj_move_using_vel_and_gravity](functions-5.md#cur_obj_move_using_vel_and_gravity) + - [cur_obj_move_xz](functions-5.md#cur_obj_move_xz) + - [cur_obj_move_xz_using_fvel_and_yaw](functions-5.md#cur_obj_move_xz_using_fvel_and_yaw) + - [cur_obj_move_y](functions-5.md#cur_obj_move_y) + - [cur_obj_move_y_and_get_water_level](functions-5.md#cur_obj_move_y_and_get_water_level) + - [cur_obj_move_y_with_terminal_vel](functions-5.md#cur_obj_move_y_with_terminal_vel) + - [cur_obj_nearest_object_with_behavior](functions-5.md#cur_obj_nearest_object_with_behavior) + - [cur_obj_outside_home_rectangle](functions-5.md#cur_obj_outside_home_rectangle) + - [cur_obj_outside_home_square](functions-5.md#cur_obj_outside_home_square) + - [cur_obj_push_mario_away](functions-5.md#cur_obj_push_mario_away) + - [cur_obj_push_mario_away_from_cylinder](functions-5.md#cur_obj_push_mario_away_from_cylinder) + - [cur_obj_reflect_move_angle_off_wall](functions-5.md#cur_obj_reflect_move_angle_off_wall) + - [cur_obj_reset_timer_and_subaction](functions-5.md#cur_obj_reset_timer_and_subaction) + - [cur_obj_resolve_wall_collisions](functions-5.md#cur_obj_resolve_wall_collisions) + - [cur_obj_reverse_animation](functions-5.md#cur_obj_reverse_animation) + - [cur_obj_rotate_face_angle_using_vel](functions-5.md#cur_obj_rotate_face_angle_using_vel) + - [cur_obj_rotate_move_angle_using_vel](functions-5.md#cur_obj_rotate_move_angle_using_vel) + - [cur_obj_rotate_yaw_toward](functions-5.md#cur_obj_rotate_yaw_toward) + - [cur_obj_scale](functions-5.md#cur_obj_scale) + - [cur_obj_scale_over_time](functions-5.md#cur_obj_scale_over_time) + - [cur_obj_set_behavior](functions-5.md#cur_obj_set_behavior) + - [cur_obj_set_billboard_if_vanilla_cam](functions-5.md#cur_obj_set_billboard_if_vanilla_cam) + - [cur_obj_set_face_angle_to_move_angle](functions-5.md#cur_obj_set_face_angle_to_move_angle) + - [cur_obj_set_hitbox_and_die_if_attacked](functions-5.md#cur_obj_set_hitbox_and_die_if_attacked) + - [cur_obj_set_hitbox_radius_and_height](functions-5.md#cur_obj_set_hitbox_radius_and_height) + - [cur_obj_set_home_once](functions-5.md#cur_obj_set_home_once) + - [cur_obj_set_hurtbox_radius_and_height](functions-5.md#cur_obj_set_hurtbox_radius_and_height) + - [cur_obj_set_pos_relative](functions-5.md#cur_obj_set_pos_relative) + - [cur_obj_set_pos_relative_to_parent](functions-5.md#cur_obj_set_pos_relative_to_parent) + - [cur_obj_set_pos_to_home](functions-5.md#cur_obj_set_pos_to_home) + - [cur_obj_set_pos_to_home_and_stop](functions-5.md#cur_obj_set_pos_to_home_and_stop) + - [cur_obj_set_pos_to_home_with_debug](functions-5.md#cur_obj_set_pos_to_home_with_debug) + - [cur_obj_set_pos_via_transform](functions-5.md#cur_obj_set_pos_via_transform) + - [cur_obj_set_vel_from_mario_vel](functions-5.md#cur_obj_set_vel_from_mario_vel) + - [cur_obj_set_y_vel_and_animation](functions-5.md#cur_obj_set_y_vel_and_animation) + - [cur_obj_shake_screen](functions-5.md#cur_obj_shake_screen) + - [cur_obj_shake_y](functions-5.md#cur_obj_shake_y) + - [cur_obj_shake_y_until](functions-5.md#cur_obj_shake_y_until) + - [cur_obj_spawn_loot_blue_coin](functions-5.md#cur_obj_spawn_loot_blue_coin) + - [cur_obj_spawn_loot_coin_at_mario_pos](functions-5.md#cur_obj_spawn_loot_coin_at_mario_pos) + - [cur_obj_spawn_particles](functions-5.md#cur_obj_spawn_particles) + - [cur_obj_spawn_star_at_y_offset](functions-5.md#cur_obj_spawn_star_at_y_offset) + - [cur_obj_start_cam_event](functions-5.md#cur_obj_start_cam_event) + - [cur_obj_unhide](functions-5.md#cur_obj_unhide) + - [cur_obj_unrender_and_reset_state](functions-5.md#cur_obj_unrender_and_reset_state) + - [cur_obj_unused_init_on_floor](functions-5.md#cur_obj_unused_init_on_floor) + - [cur_obj_unused_play_footstep_sound](functions-5.md#cur_obj_unused_play_footstep_sound) + - [cur_obj_unused_resolve_wall_collisions](functions-5.md#cur_obj_unused_resolve_wall_collisions) + - [cur_obj_update_floor](functions-5.md#cur_obj_update_floor) + - [cur_obj_update_floor_and_resolve_wall_collisions](functions-5.md#cur_obj_update_floor_and_resolve_wall_collisions) + - [cur_obj_update_floor_and_walls](functions-5.md#cur_obj_update_floor_and_walls) + - [cur_obj_update_floor_height](functions-5.md#cur_obj_update_floor_height) + - [cur_obj_update_floor_height_and_get_floor](functions-5.md#cur_obj_update_floor_height_and_get_floor) + - [cur_obj_wait_then_blink](functions-5.md#cur_obj_wait_then_blink) + - [cur_obj_was_attacked_or_ground_pounded](functions-5.md#cur_obj_was_attacked_or_ground_pounded) + - [cur_obj_within_12k_bounds](functions-5.md#cur_obj_within_12k_bounds) + - [disable_time_stop](functions-5.md#disable_time_stop) + - [disable_time_stop_including_mario](functions-5.md#disable_time_stop_including_mario) + - [dist_between_object_and_point](functions-5.md#dist_between_object_and_point) + - [dist_between_objects](functions-5.md#dist_between_objects) + - [enable_time_stop](functions-5.md#enable_time_stop) + - [enable_time_stop_if_alone](functions-5.md#enable_time_stop_if_alone) + - [enable_time_stop_including_mario](functions-5.md#enable_time_stop_including_mario) + - [find_object_with_behavior](functions-5.md#find_object_with_behavior) + - [find_unimportant_object](functions-5.md#find_unimportant_object) + - [geo_offset_klepto_debug](functions-5.md#geo_offset_klepto_debug) + - [get_object_list_from_behavior](functions-5.md#get_object_list_from_behavior) + - [get_trajectory_length](functions-5.md#get_trajectory_length) + - [increment_velocity_toward_range](functions-5.md#increment_velocity_toward_range) + - [is_item_in_array](functions-5.md#is_item_in_array) + - [is_mario_moving_fast_or_in_air](functions-5.md#is_mario_moving_fast_or_in_air) + - [lateral_dist_between_objects](functions-5.md#lateral_dist_between_objects) + - [linear_mtxf_mul_vec3f](functions-5.md#linear_mtxf_mul_vec3f) + - [linear_mtxf_transpose_mul_vec3f](functions-5.md#linear_mtxf_transpose_mul_vec3f) + - [mario_is_dive_sliding](functions-5.md#mario_is_dive_sliding) + - [mario_is_in_air_action](functions-5.md#mario_is_in_air_action) + - [mario_is_within_rectangle](functions-5.md#mario_is_within_rectangle) + - [mario_set_flag](functions-5.md#mario_set_flag) + - [obj_angle_to_object](functions-5.md#obj_angle_to_object) + - [obj_angle_to_point](functions-5.md#obj_angle_to_point) + - [obj_apply_scale_to_matrix](functions-5.md#obj_apply_scale_to_matrix) + - [obj_apply_scale_to_transform](functions-5.md#obj_apply_scale_to_transform) + - [obj_attack_collided_from_other_object](functions-5.md#obj_attack_collided_from_other_object) + - [obj_become_tangible](functions-5.md#obj_become_tangible) + - [obj_build_relative_transform](functions-5.md#obj_build_relative_transform) + - [obj_build_transform_from_pos_and_angle](functions-5.md#obj_build_transform_from_pos_and_angle) + - [obj_build_transform_relative_to_parent](functions-5.md#obj_build_transform_relative_to_parent) + - [obj_build_vel_from_transform](functions-5.md#obj_build_vel_from_transform) + - [obj_check_if_collided_with_object](functions-5.md#obj_check_if_collided_with_object) + - [obj_copy_angle](functions-5.md#obj_copy_angle) + - [obj_copy_behavior_params](functions-5.md#obj_copy_behavior_params) + - [obj_copy_graph_y_offset](functions-5.md#obj_copy_graph_y_offset) + - [obj_copy_pos](functions-5.md#obj_copy_pos) + - [obj_copy_pos_and_angle](functions-5.md#obj_copy_pos_and_angle) + - [obj_copy_scale](functions-5.md#obj_copy_scale) + - [obj_create_transform_from_self](functions-5.md#obj_create_transform_from_self) + - [obj_explode_and_spawn_coins](functions-5.md#obj_explode_and_spawn_coins) + - [obj_has_behavior](functions-5.md#obj_has_behavior) + - [obj_init_animation](functions-5.md#obj_init_animation) + - [obj_init_animation_with_accel_and_sound](functions-5.md#obj_init_animation_with_accel_and_sound) + - [obj_init_animation_with_sound](functions-5.md#obj_init_animation_with_sound) + - [obj_is_hidden](functions-5.md#obj_is_hidden) + - [obj_mark_for_deletion](functions-5.md#obj_mark_for_deletion) + - [obj_pitch_to_object](functions-5.md#obj_pitch_to_object) + - [obj_scale](functions-5.md#obj_scale) + - [obj_scale_random](functions-5.md#obj_scale_random) + - [obj_scale_xyz](functions-5.md#obj_scale_xyz) + - [obj_set_angle](functions-5.md#obj_set_angle) + - [obj_set_behavior](functions-5.md#obj_set_behavior) + - [obj_set_billboard](functions-5.md#obj_set_billboard) + - [obj_set_cylboard](functions-5.md#obj_set_cylboard) + - [obj_set_face_angle](functions-5.md#obj_set_face_angle) + - [obj_set_face_angle_to_move_angle](functions-5.md#obj_set_face_angle_to_move_angle) + - [obj_set_gfx_angle](functions-5.md#obj_set_gfx_angle) + - [obj_set_gfx_pos](functions-5.md#obj_set_gfx_pos) + - [obj_set_gfx_pos_at_obj_pos](functions-5.md#obj_set_gfx_pos_at_obj_pos) + - [obj_set_gfx_pos_from_pos](functions-5.md#obj_set_gfx_pos_from_pos) + - [obj_set_gfx_scale](functions-5.md#obj_set_gfx_scale) + - [obj_set_held_state](functions-5.md#obj_set_held_state) + - [obj_set_hitbox](functions-5.md#obj_set_hitbox) + - [obj_set_hitbox_radius_and_height](functions-5.md#obj_set_hitbox_radius_and_height) + - [obj_set_hurtbox_radius_and_height](functions-5.md#obj_set_hurtbox_radius_and_height) + - [obj_set_move_angle](functions-5.md#obj_set_move_angle) + - [obj_set_parent_relative_pos](functions-5.md#obj_set_parent_relative_pos) + - [obj_set_pos](functions-5.md#obj_set_pos) + - [obj_set_pos_relative](functions-5.md#obj_set_pos_relative) + - [obj_set_throw_matrix_from_transform](functions-5.md#obj_set_throw_matrix_from_transform) + - [obj_spawn_loot_blue_coins](functions-5.md#obj_spawn_loot_blue_coins) + - [obj_spawn_loot_coins](functions-5.md#obj_spawn_loot_coins) + - [obj_spawn_loot_yellow_coins](functions-5.md#obj_spawn_loot_yellow_coins) + - [obj_translate_local](functions-5.md#obj_translate_local) + - [obj_translate_xyz_random](functions-5.md#obj_translate_xyz_random) + - [obj_translate_xz_random](functions-5.md#obj_translate_xz_random) + - [obj_turn_toward_object](functions-5.md#obj_turn_toward_object) + - [obj_update_pos_from_parent_transformation](functions-5.md#obj_update_pos_from_parent_transformation) + - [player_performed_grab_escape_action](functions-5.md#player_performed_grab_escape_action) + - [random_f32_around_zero](functions-5.md#random_f32_around_zero) + - [set_mario_interact_hoot_if_in_range](functions-5.md#set_mario_interact_hoot_if_in_range) + - [set_room_override](functions-5.md#set_room_override) + - [set_time_stop_flags](functions-5.md#set_time_stop_flags) + - [set_time_stop_flags_if_alone](functions-5.md#set_time_stop_flags_if_alone) + - [signum_positive](functions-5.md#signum_positive) + - [spawn_base_star_with_no_lvl_exit](functions-5.md#spawn_base_star_with_no_lvl_exit) + - [spawn_mist_particles](functions-5.md#spawn_mist_particles) + - [spawn_mist_particles_with_sound](functions-5.md#spawn_mist_particles_with_sound) + - [spawn_star_with_no_lvl_exit](functions-5.md#spawn_star_with_no_lvl_exit) + - [spawn_water_droplet](functions-5.md#spawn_water_droplet) + - [stub_obj_helpers_3](functions-5.md#stub_obj_helpers_3) + - [stub_obj_helpers_4](functions-5.md#stub_obj_helpers_4)
- object_list_processor.h - - [set_object_respawn_info_bits](functions-4.md#set_object_respawn_info_bits) + - [set_object_respawn_info_bits](functions-5.md#set_object_respawn_info_bits)
- rumble_init.c - - [queue_rumble_data](functions-4.md#queue_rumble_data) - - [queue_rumble_data_mario](functions-4.md#queue_rumble_data_mario) - - [queue_rumble_data_object](functions-4.md#queue_rumble_data_object) - - [reset_rumble_timers](functions-4.md#reset_rumble_timers) - - [reset_rumble_timers_2](functions-4.md#reset_rumble_timers_2) + - [queue_rumble_data](functions-5.md#queue_rumble_data) + - [queue_rumble_data_mario](functions-5.md#queue_rumble_data_mario) + - [queue_rumble_data_object](functions-5.md#queue_rumble_data_object) + - [reset_rumble_timers](functions-5.md#reset_rumble_timers) + - [reset_rumble_timers_2](functions-5.md#reset_rumble_timers_2)
@@ -1821,113 +1821,113 @@
- smlua_obj_utils.h - - [get_temp_object_hitbox](functions-5.md#get_temp_object_hitbox) - - [get_trajectory](functions-5.md#get_trajectory) - - [obj_check_hitbox_overlap](functions-5.md#obj_check_hitbox_overlap) - - [obj_check_overlap_with_hitbox_params](functions-5.md#obj_check_overlap_with_hitbox_params) - - [obj_count_objects_with_behavior_id](functions-5.md#obj_count_objects_with_behavior_id) - - [obj_get_collided_object](functions-5.md#obj_get_collided_object) - - [obj_get_field_f32](functions-5.md#obj_get_field_f32) - - [obj_get_field_s16](functions-5.md#obj_get_field_s16) - - [obj_get_field_s32](functions-5.md#obj_get_field_s32) - - [obj_get_field_u32](functions-5.md#obj_get_field_u32) - - [obj_get_first](functions-5.md#obj_get_first) - - [obj_get_first_with_behavior_id](functions-5.md#obj_get_first_with_behavior_id) - - [obj_get_first_with_behavior_id_and_field_f32](functions-5.md#obj_get_first_with_behavior_id_and_field_f32) - - [obj_get_first_with_behavior_id_and_field_s32](functions-5.md#obj_get_first_with_behavior_id_and_field_s32) - - [obj_get_nearest_object_with_behavior_id](functions-5.md#obj_get_nearest_object_with_behavior_id) - - [obj_get_next](functions-5.md#obj_get_next) - - [obj_get_next_with_same_behavior_id](functions-5.md#obj_get_next_with_same_behavior_id) - - [obj_get_next_with_same_behavior_id_and_field_f32](functions-5.md#obj_get_next_with_same_behavior_id_and_field_f32) - - [obj_get_next_with_same_behavior_id_and_field_s32](functions-5.md#obj_get_next_with_same_behavior_id_and_field_s32) - - [obj_get_temp_spawn_particles_info](functions-5.md#obj_get_temp_spawn_particles_info) - - [obj_has_behavior_id](functions-5.md#obj_has_behavior_id) - - [obj_has_model_extended](functions-5.md#obj_has_model_extended) - - [obj_is_attackable](functions-5.md#obj_is_attackable) - - [obj_is_breakable_object](functions-5.md#obj_is_breakable_object) - - [obj_is_bully](functions-5.md#obj_is_bully) - - [obj_is_coin](functions-5.md#obj_is_coin) - - [obj_is_exclamation_box](functions-5.md#obj_is_exclamation_box) - - [obj_is_grabbable](functions-5.md#obj_is_grabbable) - - [obj_is_mushroom_1up](functions-5.md#obj_is_mushroom_1up) - - [obj_is_secret](functions-5.md#obj_is_secret) - - [obj_is_valid_for_interaction](functions-5.md#obj_is_valid_for_interaction) - - [obj_move_xyz](functions-5.md#obj_move_xyz) - - [obj_set_field_f32](functions-5.md#obj_set_field_f32) - - [obj_set_field_s16](functions-5.md#obj_set_field_s16) - - [obj_set_field_s32](functions-5.md#obj_set_field_s32) - - [obj_set_field_u32](functions-5.md#obj_set_field_u32) - - [obj_set_model_extended](functions-5.md#obj_set_model_extended) - - [obj_set_vel](functions-5.md#obj_set_vel) - - [set_whirlpools](functions-5.md#set_whirlpools) - - [spawn_non_sync_object](functions-5.md#spawn_non_sync_object) - - [spawn_sync_object](functions-5.md#spawn_sync_object) + - [get_temp_object_hitbox](functions-6.md#get_temp_object_hitbox) + - [get_trajectory](functions-6.md#get_trajectory) + - [obj_check_hitbox_overlap](functions-6.md#obj_check_hitbox_overlap) + - [obj_check_overlap_with_hitbox_params](functions-6.md#obj_check_overlap_with_hitbox_params) + - [obj_count_objects_with_behavior_id](functions-6.md#obj_count_objects_with_behavior_id) + - [obj_get_collided_object](functions-6.md#obj_get_collided_object) + - [obj_get_field_f32](functions-6.md#obj_get_field_f32) + - [obj_get_field_s16](functions-6.md#obj_get_field_s16) + - [obj_get_field_s32](functions-6.md#obj_get_field_s32) + - [obj_get_field_u32](functions-6.md#obj_get_field_u32) + - [obj_get_first](functions-6.md#obj_get_first) + - [obj_get_first_with_behavior_id](functions-6.md#obj_get_first_with_behavior_id) + - [obj_get_first_with_behavior_id_and_field_f32](functions-6.md#obj_get_first_with_behavior_id_and_field_f32) + - [obj_get_first_with_behavior_id_and_field_s32](functions-6.md#obj_get_first_with_behavior_id_and_field_s32) + - [obj_get_nearest_object_with_behavior_id](functions-6.md#obj_get_nearest_object_with_behavior_id) + - [obj_get_next](functions-6.md#obj_get_next) + - [obj_get_next_with_same_behavior_id](functions-6.md#obj_get_next_with_same_behavior_id) + - [obj_get_next_with_same_behavior_id_and_field_f32](functions-6.md#obj_get_next_with_same_behavior_id_and_field_f32) + - [obj_get_next_with_same_behavior_id_and_field_s32](functions-6.md#obj_get_next_with_same_behavior_id_and_field_s32) + - [obj_get_temp_spawn_particles_info](functions-6.md#obj_get_temp_spawn_particles_info) + - [obj_has_behavior_id](functions-6.md#obj_has_behavior_id) + - [obj_has_model_extended](functions-6.md#obj_has_model_extended) + - [obj_is_attackable](functions-6.md#obj_is_attackable) + - [obj_is_breakable_object](functions-6.md#obj_is_breakable_object) + - [obj_is_bully](functions-6.md#obj_is_bully) + - [obj_is_coin](functions-6.md#obj_is_coin) + - [obj_is_exclamation_box](functions-6.md#obj_is_exclamation_box) + - [obj_is_grabbable](functions-6.md#obj_is_grabbable) + - [obj_is_mushroom_1up](functions-6.md#obj_is_mushroom_1up) + - [obj_is_secret](functions-6.md#obj_is_secret) + - [obj_is_valid_for_interaction](functions-6.md#obj_is_valid_for_interaction) + - [obj_move_xyz](functions-6.md#obj_move_xyz) + - [obj_set_field_f32](functions-6.md#obj_set_field_f32) + - [obj_set_field_s16](functions-6.md#obj_set_field_s16) + - [obj_set_field_s32](functions-6.md#obj_set_field_s32) + - [obj_set_field_u32](functions-6.md#obj_set_field_u32) + - [obj_set_model_extended](functions-6.md#obj_set_model_extended) + - [obj_set_vel](functions-6.md#obj_set_vel) + - [set_whirlpools](functions-6.md#set_whirlpools) + - [spawn_non_sync_object](functions-6.md#spawn_non_sync_object) + - [spawn_sync_object](functions-6.md#spawn_sync_object)
- smlua_text_utils.h - - [smlua_text_utils_act_name_get](functions-5.md#smlua_text_utils_act_name_get) - - [smlua_text_utils_act_name_mod_index](functions-5.md#smlua_text_utils_act_name_mod_index) - - [smlua_text_utils_act_name_replace](functions-5.md#smlua_text_utils_act_name_replace) - - [smlua_text_utils_act_name_reset](functions-5.md#smlua_text_utils_act_name_reset) - - [smlua_text_utils_castle_secret_stars_replace](functions-5.md#smlua_text_utils_castle_secret_stars_replace) - - [smlua_text_utils_course_acts_replace](functions-5.md#smlua_text_utils_course_acts_replace) - - [smlua_text_utils_course_name_get](functions-5.md#smlua_text_utils_course_name_get) - - [smlua_text_utils_course_name_mod_index](functions-5.md#smlua_text_utils_course_name_mod_index) - - [smlua_text_utils_course_name_replace](functions-5.md#smlua_text_utils_course_name_replace) - - [smlua_text_utils_course_name_reset](functions-5.md#smlua_text_utils_course_name_reset) - - [smlua_text_utils_dialog_replace](functions-5.md#smlua_text_utils_dialog_replace) - - [smlua_text_utils_extra_text_replace](functions-5.md#smlua_text_utils_extra_text_replace) - - [smlua_text_utils_get_language](functions-5.md#smlua_text_utils_get_language) - - [smlua_text_utils_secret_star_replace](functions-5.md#smlua_text_utils_secret_star_replace) + - [smlua_text_utils_act_name_get](functions-6.md#smlua_text_utils_act_name_get) + - [smlua_text_utils_act_name_mod_index](functions-6.md#smlua_text_utils_act_name_mod_index) + - [smlua_text_utils_act_name_replace](functions-6.md#smlua_text_utils_act_name_replace) + - [smlua_text_utils_act_name_reset](functions-6.md#smlua_text_utils_act_name_reset) + - [smlua_text_utils_castle_secret_stars_replace](functions-6.md#smlua_text_utils_castle_secret_stars_replace) + - [smlua_text_utils_course_acts_replace](functions-6.md#smlua_text_utils_course_acts_replace) + - [smlua_text_utils_course_name_get](functions-6.md#smlua_text_utils_course_name_get) + - [smlua_text_utils_course_name_mod_index](functions-6.md#smlua_text_utils_course_name_mod_index) + - [smlua_text_utils_course_name_replace](functions-6.md#smlua_text_utils_course_name_replace) + - [smlua_text_utils_course_name_reset](functions-6.md#smlua_text_utils_course_name_reset) + - [smlua_text_utils_dialog_replace](functions-6.md#smlua_text_utils_dialog_replace) + - [smlua_text_utils_extra_text_replace](functions-6.md#smlua_text_utils_extra_text_replace) + - [smlua_text_utils_get_language](functions-6.md#smlua_text_utils_get_language) + - [smlua_text_utils_secret_star_replace](functions-6.md#smlua_text_utils_secret_star_replace)
- sound_init.h - - [disable_background_sound](functions-5.md#disable_background_sound) - - [enable_background_sound](functions-5.md#enable_background_sound) - - [fadeout_cap_music](functions-5.md#fadeout_cap_music) - - [fadeout_level_music](functions-5.md#fadeout_level_music) - - [fadeout_music](functions-5.md#fadeout_music) - - [lower_background_noise](functions-5.md#lower_background_noise) - - [play_cap_music](functions-5.md#play_cap_music) - - [play_cutscene_music](functions-5.md#play_cutscene_music) - - [play_infinite_stairs_music](functions-5.md#play_infinite_stairs_music) - - [play_menu_sounds](functions-5.md#play_menu_sounds) - - [play_painting_eject_sound](functions-5.md#play_painting_eject_sound) - - [play_shell_music](functions-5.md#play_shell_music) - - [raise_background_noise](functions-5.md#raise_background_noise) - - [reset_volume](functions-5.md#reset_volume) - - [set_background_music](functions-5.md#set_background_music) - - [stop_cap_music](functions-5.md#stop_cap_music) - - [stop_shell_music](functions-5.md#stop_shell_music) + - [disable_background_sound](functions-6.md#disable_background_sound) + - [enable_background_sound](functions-6.md#enable_background_sound) + - [fadeout_cap_music](functions-6.md#fadeout_cap_music) + - [fadeout_level_music](functions-6.md#fadeout_level_music) + - [fadeout_music](functions-6.md#fadeout_music) + - [lower_background_noise](functions-6.md#lower_background_noise) + - [play_cap_music](functions-6.md#play_cap_music) + - [play_cutscene_music](functions-6.md#play_cutscene_music) + - [play_infinite_stairs_music](functions-6.md#play_infinite_stairs_music) + - [play_menu_sounds](functions-6.md#play_menu_sounds) + - [play_painting_eject_sound](functions-6.md#play_painting_eject_sound) + - [play_shell_music](functions-6.md#play_shell_music) + - [raise_background_noise](functions-6.md#raise_background_noise) + - [reset_volume](functions-6.md#reset_volume) + - [set_background_music](functions-6.md#set_background_music) + - [stop_cap_music](functions-6.md#stop_cap_music) + - [stop_shell_music](functions-6.md#stop_shell_music)
- spawn_sound.c - - [calc_dist_to_volume_range_1](functions-5.md#calc_dist_to_volume_range_1) - - [calc_dist_to_volume_range_2](functions-5.md#calc_dist_to_volume_range_2) - - [cur_obj_play_sound_1](functions-5.md#cur_obj_play_sound_1) - - [cur_obj_play_sound_2](functions-5.md#cur_obj_play_sound_2) - - [exec_anim_sound_state](functions-5.md#exec_anim_sound_state) + - [calc_dist_to_volume_range_1](functions-6.md#calc_dist_to_volume_range_1) + - [calc_dist_to_volume_range_2](functions-6.md#calc_dist_to_volume_range_2) + - [cur_obj_play_sound_1](functions-6.md#cur_obj_play_sound_1) + - [cur_obj_play_sound_2](functions-6.md#cur_obj_play_sound_2) + - [exec_anim_sound_state](functions-6.md#exec_anim_sound_state)
- surface_collision.h - - [find_ceil_height](functions-5.md#find_ceil_height) - - [find_floor_height](functions-5.md#find_floor_height) - - [find_poison_gas_level](functions-5.md#find_poison_gas_level) - - [find_wall_collisions](functions-5.md#find_wall_collisions) - - [find_water_level](functions-5.md#find_water_level) + - [find_ceil_height](functions-6.md#find_ceil_height) + - [find_floor_height](functions-6.md#find_floor_height) + - [find_poison_gas_level](functions-6.md#find_poison_gas_level) + - [find_wall_collisions](functions-6.md#find_wall_collisions) + - [find_water_level](functions-6.md#find_water_level)
- surface_load.h - - [get_area_terrain_size](functions-5.md#get_area_terrain_size) - - [load_area_terrain](functions-5.md#load_area_terrain) - - [load_object_collision_model](functions-5.md#load_object_collision_model) - - [obj_get_surface_from_index](functions-5.md#obj_get_surface_from_index) - - [surface_has_force](functions-5.md#surface_has_force) + - [get_area_terrain_size](functions-6.md#get_area_terrain_size) + - [load_area_terrain](functions-6.md#load_area_terrain) + - [load_object_collision_model](functions-6.md#load_object_collision_model) + - [obj_get_surface_from_index](functions-6.md#obj_get_surface_from_index) + - [surface_has_force](functions-6.md#surface_has_force)
@@ -2423,6 +2423,9 @@ N/A ## [area_get_warp_node](#area_get_warp_node) +### Description +Finds a warp node in the current area by its ID. The warp node must exist in the list of warp nodes for the current area. Useful for locating a specific warp point in the level, such as teleportation zones or connections to other areas. + ### Lua Example `local ObjectWarpNodeValue = area_get_warp_node(id)` @@ -2443,6 +2446,9 @@ N/A ## [area_get_warp_node_from_params](#area_get_warp_node_from_params) +### Description +Finds a warp node in the current area using parameters from the provided object. The object's behavior parameters are used to determine the warp node ID. Useful for associating an object (like a door or warp pipe) with its corresponding warp node in the area. + ### Lua Example `local ObjectWarpNodeValue = area_get_warp_node_from_params(o)` @@ -2462,5 +2468,5 @@ N/A
--- -1 | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [next >](functions-2.md)] +1 | [2](functions-2.md) | [3](functions-3.md) | [4](functions-4.md) | [5](functions-5.md) | [6](functions-6.md) | [next >](functions-2.md)] diff --git a/src/game/area.h b/src/game/area.h index 714405990..77bedd04b 100644 --- a/src/game/area.h +++ b/src/game/area.h @@ -158,8 +158,18 @@ extern u8 gSpawnedStarHiddenCount; void override_viewport_and_clip(Vp *a, Vp *b, u8 c, u8 d, u8 e); void print_intro_text(void); u32 get_mario_spawn_type(struct Object *o); + +/* |description| +Finds a warp node in the current area by its ID. The warp node must exist in the list of warp nodes for the current area. +Useful for locating a specific warp point in the level, such as teleportation zones or connections to other areas. +|descriptionEnd| */ struct ObjectWarpNode *area_get_warp_node(u8 id); struct ObjectWarpNode *area_get_any_warp_node(void); + +/* |description| +Finds a warp node in the current area using parameters from the provided object. The object's behavior parameters are used to determine the warp node ID. +Useful for associating an object (like a door or warp pipe) with its corresponding warp node in the area. +|descriptionEnd| */ struct ObjectWarpNode *area_get_warp_node_from_params(struct Object *o); void clear_areas(void); void clear_area_graph_nodes(void); diff --git a/src/game/characters.h b/src/game/characters.h index d9accb692..229d1b8a4 100644 --- a/src/game/characters.h +++ b/src/game/characters.h @@ -359,12 +359,39 @@ struct MarioState; extern struct Character gCharacters[]; struct Character* get_character(struct MarioState* m); +/* |description| +Plays a character-specific sound based on the given `characterSound` value. The sound is tied to Mario's current state (`m`). +Useful for triggering sound effects for actions like jumping or interacting with the environment +|descriptionEnd| */ void play_character_sound(struct MarioState* m, enum CharacterSound characterSound); + +/* |description| +Plays a character-specific sound with an additional `offset`, allowing variations or delays in the sound effect. Uses Mario's current state (`m`). +Useful for adding dynamic sound effects or syncing sounds to specific animations or events +|descriptionEnd| */ void play_character_sound_offset(struct MarioState* m, enum CharacterSound characterSound, u32 offset); + +/* |description| +Plays a character-specific sound only if certain flags are not set. This ensures that sounds are not repeated unnecessarily. The sound is based on `characterSound`, and the flags are checked using `flags`. +Useful for avoiding duplicate sound effects in rapid succession or conditional actions +|descriptionEnd| */ void play_character_sound_if_no_flag(struct MarioState* m, enum CharacterSound characterSound, u32 flags); +/* |description| +Calculates the animation offset for Mario's current animation. The offset is determined by the type of animation being played (e.g., hand, feet, or torso movement). +Useful for smoothly syncing Mario's model height or positional adjustments during animations +|descriptionEnd| */ f32 get_character_anim_offset(struct MarioState* m); -s32 get_character_anim(struct MarioState* m, enum CharacterAnimID characterAnim); -void update_character_anim_offset(struct MarioState* m); +/* |description| +Gets the animation ID to use for a specific character and animation combination. The ID is based on `characterAnim` and the character currently controlled by Mario (`m`). +Useful for determining which animation to play for actions like walking, jumping, or idle states +|descriptionEnd| */ +s32 get_character_anim(struct MarioState* m, enum CharacterAnimID characterAnim); + +/* |description| +Updates Mario's current animation offset. This adjusts Mario's position based on the calculated offset to ensure animations appear smooth and natural. +Useful for keeping Mario's animations visually aligned, particularly when transitioning between animations +|descriptionEnd| */ +void update_character_anim_offset(struct MarioState* m); #endif // CHARACTERS_H