diff --git a/autogen/convert_functions.py b/autogen/convert_functions.py index 2cb6dcb01..995a3e014 100644 --- a/autogen/convert_functions.py +++ b/autogen/convert_functions.py @@ -1248,6 +1248,10 @@ def doc_function(fname, function): rtype, rlink = translate_type_to_lua(function['type']) param_str = ', '.join([x['identifier'] for x in function['params']]) + if description != "": + s += '\n### Description\n' + s += f'{description}\n' + s += "\n### Lua Example\n" if rtype != None: s += "`local %sValue = %s(%s)`\n" % (rtype.replace('`', '').split(' ')[0], fid, param_str) @@ -1288,10 +1292,6 @@ def doc_function(fname, function): s += '\n### C Prototype\n' s += '`%s`\n' % function['line'].strip() - - if description != "": - s += '\n### Description\n' - s += f'{description}\n' s += '\n[:arrow_up_small:](#)\n\n
\n' diff --git a/docs/lua/functions-4.md b/docs/lua/functions-4.md index 77aa7d4f1..1ba964acc 100644 --- a/docs/lua/functions-4.md +++ b/docs/lua/functions-4.md @@ -13,6 +13,9 @@ ## [anim_spline_init](#anim_spline_init) +### Description +Initializes a spline-based animation for the `MarioState` structure `m` using the provided array of 3D signed-integer vectors `keyFrames`. This sets up the animation so that it can be advanced by polling + ### Lua Example `anim_spline_init(m, keyFrames)` @@ -28,15 +31,15 @@ ### C Prototype `void anim_spline_init(struct MarioState* m, Vec4s *keyFrames);` -### Description -Initializes a spline-based animation for the `MarioState` structure `m` using the provided array of 3D signed-integer vectors `keyFrames`. This sets up the animation so that it can be advanced by polling - [:arrow_up_small:](#)
## [anim_spline_poll](#anim_spline_poll) +### Description +Advances the spline-based animation associated with `m` and stores the current interpolated position in `result`. It returns the animation's status, allowing the caller to determine if the animation is ongoing or has completed + ### Lua Example `local integerValue = anim_spline_poll(m, result)` @@ -52,15 +55,15 @@ Initializes a spline-based animation for the `MarioState` structure `m` using th ### C Prototype `s32 anim_spline_poll(struct MarioState* m, Vec3f result);` -### Description -Advances the spline-based animation associated with `m` and stores the current interpolated position in `result`. It returns the animation's status, allowing the caller to determine if the animation is ongoing or has completed - [:arrow_up_small:](#)
## [approach_f32](#approach_f32) +### Description +Similar to `approach_s32`, but operates on floating-point numbers. It moves `current` toward `target` by increasing it by `inc` if below target, or decreasing it by `dec` if above target, creating a smooth interpolation + ### Lua Example `local numberValue = approach_f32(current, target, inc, dec)` @@ -78,15 +81,15 @@ Advances the spline-based animation associated with `m` and stores the current i ### C Prototype `f32 approach_f32(f32 current, f32 target, f32 inc, f32 dec);` -### Description -Similar to `approach_s32`, but operates on floating-point numbers. It moves `current` toward `target` by increasing it by `inc` if below target, or decreasing it by `dec` if above target, creating a smooth interpolation - [:arrow_up_small:](#)
## [approach_s32](#approach_s32) +### Description +Gradually moves an integer `current` value toward a `target` value, increasing it by `inc` if it is too low, or decreasing it by `dec` if it is too high. This is often used for smooth transitions or animations + ### Lua Example `local integerValue = approach_s32(current, target, inc, dec)` @@ -104,15 +107,15 @@ Similar to `approach_s32`, but operates on floating-point numbers. It moves `cur ### C Prototype `s32 approach_s32(s32 current, s32 target, s32 inc, s32 dec);` -### Description -Gradually moves an integer `current` value toward a `target` value, increasing it by `inc` if it is too low, or decreasing it by `dec` if it is too high. This is often used for smooth transitions or animations - [:arrow_up_small:](#)
## [atan2s](#atan2s) +### Description +Computes the arctangent of y/x and returns the angle as a signed 16-bit integer, typically representing a direction in the SM64 fixed-point angle format. This can be used to find an angle between x and y coordinates + ### Lua Example `local integerValue = atan2s(y, x)` @@ -128,15 +131,15 @@ Gradually moves an integer `current` value toward a `target` value, increasing i ### C Prototype `s16 atan2s(f32 y, f32 x);` -### Description -Computes the arctangent of y/x and returns the angle as a signed 16-bit integer, typically representing a direction in the SM64 fixed-point angle format. This can be used to find an angle between x and y coordinates - [:arrow_up_small:](#)
## [coss](#coss) +### Description +Calculates the cosine of the given angle, where the angle is specified as a signed 16-bit integer representing a fixed-point "SM64 angle". The function returns a floating-point value corresponding to cos(angle) + ### Lua Example `local numberValue = coss(sm64Angle)` @@ -151,15 +154,15 @@ Computes the arctangent of y/x and returns the angle as a signed 16-bit integer, ### C Prototype `f32 coss(s16 sm64Angle);` -### Description -Calculates the cosine of the given angle, where the angle is specified as a signed 16-bit integer representing a fixed-point "SM64 angle". The function returns a floating-point value corresponding to cos(angle) - [:arrow_up_small:](#)
## [find_vector_perpendicular_to_plane](#find_vector_perpendicular_to_plane) +### Description +Determines a vector that is perpendicular (normal) to the plane defined by three given 3D floating-point points `a`, `b`, and `c`. The resulting perpendicular vector is stored in `dest` + ### Lua Example `local voidValue = find_vector_perpendicular_to_plane(dest, a, b, c)` @@ -177,15 +180,15 @@ Calculates the cosine of the given angle, where the angle is specified as a sign ### C Prototype `void *find_vector_perpendicular_to_plane(Vec3f dest, Vec3f a, Vec3f b, Vec3f c);` -### Description -Determines a vector that is perpendicular (normal) to the plane defined by three given 3D floating-point points `a`, `b`, and `c`. The resulting perpendicular vector is stored in `dest` - [:arrow_up_small:](#)
## [get_pos_from_transform_mtx](#get_pos_from_transform_mtx) +### Description +Extracts the position (translation component) from the transformation matrix `objMtx` relative to the coordinate system defined by `camMtx` and stores that 3D position in `dest`. This can be used to get the object's coordinates in camera space + ### Lua Example `get_pos_from_transform_mtx(dest, objMtx, camMtx)` @@ -202,15 +205,15 @@ Determines a vector that is perpendicular (normal) to the plane defined by three ### C Prototype `void get_pos_from_transform_mtx(Vec3f dest, Mat4 objMtx, Mat4 camMtx);` -### Description -Extracts the position (translation component) from the transformation matrix `objMtx` relative to the coordinate system defined by `camMtx` and stores that 3D position in `dest`. This can be used to get the object's coordinates in camera space - [:arrow_up_small:](#)
## [mtxf_align_terrain_normal](#mtxf_align_terrain_normal) +### Description +Aligns `dest` so that it fits the orientation of a terrain surface defined by its normal vector `upDir`. The transformation is positioned at `pos` and oriented with a given `yaw`. This is often used to make objects sit naturally on uneven ground + ### Lua Example `mtxf_align_terrain_normal(dest, upDir, pos, yaw)` @@ -228,15 +231,15 @@ Extracts the position (translation component) from the transformation matrix `ob ### C Prototype `void mtxf_align_terrain_normal(Mat4 dest, Vec3f upDir, Vec3f pos, s16 yaw);` -### Description -Aligns `dest` so that it fits the orientation of a terrain surface defined by its normal vector `upDir`. The transformation is positioned at `pos` and oriented with a given `yaw`. This is often used to make objects sit naturally on uneven ground - [:arrow_up_small:](#)
## [mtxf_align_terrain_triangle](#mtxf_align_terrain_triangle) +### Description +Aligns `mtx` to fit onto a terrain triangle at `pos`, applying a given `yaw` and scaling by `radius`. This helps position objects so they match the orientation of the terrain's surface + ### Lua Example `mtxf_align_terrain_triangle(mtx, pos, yaw, radius)` @@ -254,15 +257,15 @@ Aligns `dest` so that it fits the orientation of a terrain surface defined by it ### C Prototype `void mtxf_align_terrain_triangle(Mat4 mtx, Vec3f pos, s16 yaw, f32 radius);` -### Description -Aligns `mtx` to fit onto a terrain triangle at `pos`, applying a given `yaw` and scaling by `radius`. This helps position objects so they match the orientation of the terrain's surface - [:arrow_up_small:](#)
## [mtxf_billboard](#mtxf_billboard) +### Description +Transforms a 4x4 floating-point matrix `mtx` into a "billboard" oriented toward the camera or a given direction. The billboard is placed at `position` and rotated by `angle`. This is useful for objects that should always face the viewer + ### Lua Example `mtxf_billboard(dest, mtx, position, angle)` @@ -280,15 +283,15 @@ Aligns `mtx` to fit onto a terrain triangle at `pos`, applying a given `yaw` and ### C Prototype `void mtxf_billboard(Mat4 dest, Mat4 mtx, Vec3f position, s16 angle);` -### Description -Transforms a 4x4 floating-point matrix `mtx` into a "billboard" oriented toward the camera or a given direction. The billboard is placed at `position` and rotated by `angle`. This is useful for objects that should always face the viewer - [:arrow_up_small:](#)
## [mtxf_copy](#mtxf_copy) +### Description +Copies the 4x4 floating-point matrix `src` into `dest`. After this operation, `dest` contains the same matrix values as `src` + ### Lua Example `mtxf_copy(dest, src)` @@ -304,15 +307,15 @@ Transforms a 4x4 floating-point matrix `mtx` into a "billboard" oriented toward ### C Prototype `void mtxf_copy(Mat4 dest, Mat4 src);` -### Description -Copies the 4x4 floating-point matrix `src` into `dest`. After this operation, `dest` contains the same matrix values as `src` - [:arrow_up_small:](#)
## [mtxf_cylboard](#mtxf_cylboard) +### Description +Creates a "cylindrical billboard" transformation from the 4x4 matrix `mtx` placed at `position` with a given `angle`. Unlike a full billboard, this might allow rotation around one axis while still facing the viewer on others + ### Lua Example `mtxf_cylboard(dest, mtx, position, angle)` @@ -330,15 +333,15 @@ Copies the 4x4 floating-point matrix `src` into `dest`. After this operation, `d ### C Prototype `void mtxf_cylboard(Mat4 dest, Mat4 mtx, Vec3f position, s16 angle);` -### Description -Creates a "cylindrical billboard" transformation from the 4x4 matrix `mtx` placed at `position` with a given `angle`. Unlike a full billboard, this might allow rotation around one axis while still facing the viewer on others - [:arrow_up_small:](#)
## [mtxf_identity](#mtxf_identity) +### Description +Sets the 4x4 floating-point matrix `mtx` to the identity matrix. The identity matrix leaves points unchanged when they are transformed by it which is useful for matrix math + ### Lua Example `mtxf_identity(mtx)` @@ -353,15 +356,15 @@ Creates a "cylindrical billboard" transformation from the 4x4 matrix `mtx` place ### C Prototype `void mtxf_identity(Mat4 mtx);` -### Description -Sets the 4x4 floating-point matrix `mtx` to the identity matrix. The identity matrix leaves points unchanged when they are transformed by it which is useful for matrix math - [:arrow_up_small:](#)
## [mtxf_inverse](#mtxf_inverse) +### Description +Inverts the 4x4 floating-point matrix `src` and stores the inverse in `dest`. Applying the inverse transformation undoes whatever `src` did, returning points back to their original coordinate space + ### Lua Example `mtxf_inverse(dest, src)` @@ -377,15 +380,15 @@ Sets the 4x4 floating-point matrix `mtx` to the identity matrix. The identity ma ### C Prototype `void mtxf_inverse(Mat4 dest, Mat4 src);` -### Description -Inverts the 4x4 floating-point matrix `src` and stores the inverse in `dest`. Applying the inverse transformation undoes whatever `src` did, returning points back to their original coordinate space - [:arrow_up_small:](#)
## [mtxf_lookat](#mtxf_lookat) +### Description +Adjusts the 4x4 floating-point matrix `mtx` so that it represents a viewing transformation looking from the point `from` toward the point `to`, with a given roll angle. This creates a view matrix oriented toward `to` + ### Lua Example `mtxf_lookat(mtx, from, to, roll)` @@ -403,15 +406,15 @@ Inverts the 4x4 floating-point matrix `src` and stores the inverse in `dest`. Ap ### C Prototype `void mtxf_lookat(Mat4 mtx, Vec3f from, Vec3f to, s16 roll);` -### Description -Adjusts the 4x4 floating-point matrix `mtx` so that it represents a viewing transformation looking from the point `from` toward the point `to`, with a given roll angle. This creates a view matrix oriented toward `to` - [:arrow_up_small:](#)
## [mtxf_mul](#mtxf_mul) +### Description +Multiplies two 4x4 floating-point matrices `a` and `b` (in that order), storing the product in `dest`. This can be used for combining multiple transformations into one + ### Lua Example `mtxf_mul(dest, a, b)` @@ -428,15 +431,15 @@ Adjusts the 4x4 floating-point matrix `mtx` so that it represents a viewing tran ### C Prototype `void mtxf_mul(Mat4 dest, Mat4 a, Mat4 b);` -### Description -Multiplies two 4x4 floating-point matrices `a` and `b` (in that order), storing the product in `dest`. This can be used for combining multiple transformations into one - [:arrow_up_small:](#)
## [mtxf_mul_vec3s](#mtxf_mul_vec3s) +### Description +Multiplies the 4x4 floating-point matrix `mtx` by a 3D signed-integer vector `b`, potentially interpreting `b` as angles or translations depending on usage, and modifies `mtx` accordingly + ### Lua Example `mtxf_mul_vec3s(mtx, b)` @@ -452,15 +455,15 @@ Multiplies two 4x4 floating-point matrices `a` and `b` (in that order), storing ### C Prototype `void mtxf_mul_vec3s(Mat4 mtx, Vec3s b);` -### Description -Multiplies the 4x4 floating-point matrix `mtx` by a 3D signed-integer vector `b`, potentially interpreting `b` as angles or translations depending on usage, and modifies `mtx` accordingly - [:arrow_up_small:](#)
## [mtxf_rotate_xy](#mtxf_rotate_xy) +### Description +Rotates the matrix `mtx` in the XY plane by the given `angle`. Rotating in the XY plane typically means pivoting around the Z axis + ### Lua Example `mtxf_rotate_xy(mtx, angle)` @@ -476,15 +479,15 @@ Multiplies the 4x4 floating-point matrix `mtx` by a 3D signed-integer vector `b` ### C Prototype `void mtxf_rotate_xy(Mtx *mtx, s16 angle);` -### Description -Rotates the matrix `mtx` in the XY plane by the given `angle`. Rotating in the XY plane typically means pivoting around the Z axis - [:arrow_up_small:](#)
## [mtxf_rotate_xyz_and_translate](#mtxf_rotate_xyz_and_translate) +### Description +Rotates `dest` using angles in XYZ order, and then translates it by the 3D floating-point vector `b` and applies the rotations described by `c`. This sets up `dest` with a specific orientation and position in space + ### Lua Example `mtxf_rotate_xyz_and_translate(dest, b, c)` @@ -501,15 +504,15 @@ Rotates the matrix `mtx` in the XY plane by the given `angle`. Rotating in the X ### C Prototype `void mtxf_rotate_xyz_and_translate(Mat4 dest, Vec3f b, Vec3s c);` -### Description -Rotates `dest` using angles in XYZ order, and then translates it by the 3D floating-point vector `b` and applies the rotations described by `c`. This sets up `dest` with a specific orientation and position in space - [:arrow_up_small:](#)
## [mtxf_rotate_zxy_and_translate](#mtxf_rotate_zxy_and_translate) +### Description +Rotates `dest` according to the angles in `rotate` using ZXY order, and then translates it by the 3D floating-point vector `translate`. This effectively positions and orients `dest` in 3D space + ### Lua Example `mtxf_rotate_zxy_and_translate(dest, translate, rotate)` @@ -526,15 +529,15 @@ Rotates `dest` using angles in XYZ order, and then translates it by the 3D float ### C Prototype `void mtxf_rotate_zxy_and_translate(Mat4 dest, Vec3f translate, Vec3s rotate);` -### Description -Rotates `dest` according to the angles in `rotate` using ZXY order, and then translates it by the 3D floating-point vector `translate`. This effectively positions and orients `dest` in 3D space - [:arrow_up_small:](#)
## [mtxf_scale_vec3f](#mtxf_scale_vec3f) +### Description +Scales the 4x4 floating-point matrix `mtx` by the scaling factors found in the 3D floating-point vector `s`, and stores the result in `dest`. This enlarges or shrinks objects in 3D space + ### Lua Example `mtxf_scale_vec3f(dest, mtx, s)` @@ -551,15 +554,15 @@ Rotates `dest` according to the angles in `rotate` using ZXY order, and then tra ### C Prototype `void mtxf_scale_vec3f(Mat4 dest, Mat4 mtx, Vec3f s);` -### Description -Scales the 4x4 floating-point matrix `mtx` by the scaling factors found in the 3D floating-point vector `s`, and stores the result in `dest`. This enlarges or shrinks objects in 3D space - [:arrow_up_small:](#)
## [mtxf_to_mtx](#mtxf_to_mtx) +### Description +Converts the floating-point matrix `src` into a fixed-point (integer-based) matrix suitable for the `Mtx` format, and stores the result in `dest` + ### Lua Example `mtxf_to_mtx(dest, src)` @@ -575,15 +578,15 @@ Scales the 4x4 floating-point matrix `mtx` by the scaling factors found in the 3 ### C Prototype `void mtxf_to_mtx(Mtx *dest, Mat4 src);` -### Description -Converts the floating-point matrix `src` into a fixed-point (integer-based) matrix suitable for the `Mtx` format, and stores the result in `dest` - [:arrow_up_small:](#)
## [mtxf_translate](#mtxf_translate) +### Description +Applies a translation to the 4x4 floating-point matrix `dest` by adding the coordinates in the 3D floating-point vector `b`. This shifts any transformed point by `b` + ### Lua Example `mtxf_translate(dest, b)` @@ -599,15 +602,15 @@ Converts the floating-point matrix `src` into a fixed-point (integer-based) matr ### C Prototype `void mtxf_translate(Mat4 dest, Vec3f b);` -### Description -Applies a translation to the 4x4 floating-point matrix `dest` by adding the coordinates in the 3D floating-point vector `b`. This shifts any transformed point by `b` - [:arrow_up_small:](#)
## [not_zero](#not_zero) +### Description +Checks if `value` is zero. If not, it returns `value`. If it is zero, it returns the `replacement` value. This function ensures that a zero value can be substituted with a fallback value if needed + ### Lua Example `local numberValue = not_zero(value, replacement)` @@ -623,15 +626,15 @@ Applies a translation to the 4x4 floating-point matrix `dest` by adding the coor ### C Prototype `f32 not_zero(f32 value, f32 replacement);` -### Description -Checks if `value` is zero. If not, it returns `value`. If it is zero, it returns the `replacement` value. This function ensures that a zero value can be substituted with a fallback value if needed - [:arrow_up_small:](#)
## [sins](#sins) +### Description +Calculates the sine of the given angle, where the angle is specified as a signed 16-bit integer representing a fixed-point "SM64 angle". This function returns a floating-point result corresponding to sin(angle) + ### Lua Example `local numberValue = sins(sm64Angle)` @@ -646,15 +649,15 @@ Checks if `value` is zero. If not, it returns `value`. If it is zero, it returns ### C Prototype `f32 sins(s16 sm64Angle);` -### Description -Calculates the sine of the given angle, where the angle is specified as a signed 16-bit integer representing a fixed-point "SM64 angle". This function returns a floating-point result corresponding to sin(angle) - [:arrow_up_small:](#)
## [spline_get_weights](#spline_get_weights) +### Description +Computes spline interpolation weights for a given parameter `t` and stores these weights in `result`. This is used in spline-based animations to find intermediate positions between keyframes + ### Lua Example `spline_get_weights(m, result, t, c)` @@ -672,15 +675,15 @@ Calculates the sine of the given angle, where the angle is specified as a signed ### C Prototype `void spline_get_weights(struct MarioState* m, Vec4f result, f32 t, UNUSED s32 c);` -### Description -Computes spline interpolation weights for a given parameter `t` and stores these weights in `result`. This is used in spline-based animations to find intermediate positions between keyframes - [:arrow_up_small:](#)
## [vec3f_add](#vec3f_add) +### Description +Adds the components of the 3D floating-point vector `a` to `dest`. After this operation, `dest.x` will be `dest.x + a.x`, and similarly for the y and z components + ### Lua Example `local voidValue = vec3f_add(dest, a)` @@ -696,15 +699,15 @@ Computes spline interpolation weights for a given parameter `t` and stores these ### C Prototype `void *vec3f_add(Vec3f dest, Vec3f a);` -### Description -Adds the components of the 3D floating-point vector `a` to `dest`. After this operation, `dest.x` will be `dest.x + a.x`, and similarly for the y and z components - [:arrow_up_small:](#)
## [vec3f_combine](#vec3f_combine) +### Description +Takes two 3D floating-point vectors `vecA` and `vecB`, multiplies them by `sclA` and `sclB` respectively, and then adds the scaled vectors together. The final combined vector is stored in `dest` + ### Lua Example `vec3f_combine(dest, vecA, vecB, sclA, sclB)` @@ -723,15 +726,15 @@ Adds the components of the 3D floating-point vector `a` to `dest`. After this op ### C Prototype `void vec3f_combine(Vec3f dest, Vec3f vecA, Vec3f vecB, f32 sclA, f32 sclB);` -### Description -Takes two 3D floating-point vectors `vecA` and `vecB`, multiplies them by `sclA` and `sclB` respectively, and then adds the scaled vectors together. The final combined vector is stored in `dest` - [:arrow_up_small:](#)
## [vec3f_copy](#vec3f_copy) +### Description +Copies the contents of a 3D floating-point vector (`src`) into another 3D floating-point vector (`dest`). After this operation, `dest` will have the same x, y, and z values as `src` + ### Lua Example `local voidValue = vec3f_copy(dest, src)` @@ -747,15 +750,15 @@ Takes two 3D floating-point vectors `vecA` and `vecB`, multiplies them by `sclA` ### C Prototype `void *vec3f_copy(Vec3f dest, Vec3f src);` -### Description -Copies the contents of a 3D floating-point vector (`src`) into another 3D floating-point vector (`dest`). After this operation, `dest` will have the same x, y, and z values as `src` - [:arrow_up_small:](#)
## [vec3f_cross](#vec3f_cross) +### Description +Computes the cross product of two 3D floating-point vectors `a` and `b`. The cross product is a vector perpendicular to both `a` and `b`. The result is stored in `dest` + ### Lua Example `local voidValue = vec3f_cross(dest, a, b)` @@ -772,15 +775,15 @@ Copies the contents of a 3D floating-point vector (`src`) into another 3D floati ### C Prototype `void *vec3f_cross(Vec3f dest, Vec3f a, Vec3f b);` -### Description -Computes the cross product of two 3D floating-point vectors `a` and `b`. The cross product is a vector perpendicular to both `a` and `b`. The result is stored in `dest` - [:arrow_up_small:](#)
## [vec3f_dif](#vec3f_dif) +### Description +Subtracts the components of the 3D floating-point vector `b` from the components of `a` and stores the result in `dest`. For example, `dest.x = a.x - b.x` This results in a vector that represents the difference between `a` and `b`. + ### Lua Example `local voidValue = vec3f_dif(dest, a, b)` @@ -797,15 +800,15 @@ Computes the cross product of two 3D floating-point vectors `a` and `b`. The cro ### C Prototype `void *vec3f_dif(Vec3f dest, Vec3f a, Vec3f b);` -### Description -Subtracts the components of the 3D floating-point vector `b` from the components of `a` and stores the result in `dest`. For example, `dest.x = a.x - b.x` This results in a vector that represents the difference between `a` and `b`. - [:arrow_up_small:](#)
## [vec3f_dist](#vec3f_dist) +### Description +Calculates the distance between two 3D floating-point points `v1` and `v2`. The distance is the length of the vector `v2 - v1`, i.e., sqrt((v2.x - v1.x)² + (v2.y - v1.y)² + (v2.z - v1.z)²) + ### Lua Example `local numberValue = vec3f_dist(v1, v2)` @@ -821,15 +824,15 @@ Subtracts the components of the 3D floating-point vector `b` from the components ### C Prototype `f32 vec3f_dist(Vec3f v1, Vec3f v2);` -### Description -Calculates the distance between two 3D floating-point points `v1` and `v2`. The distance is the length of the vector `v2 - v1`, i.e., sqrt((v2.x - v1.x)² + (v2.y - v1.y)² + (v2.z - v1.z)²) - [:arrow_up_small:](#)
## [vec3f_dot](#vec3f_dot) +### Description +Computes the dot product of the two 3D floating-point vectors `a` and `b`. The dot product is a scalar value defined by (a.x * b.x + a.y * b.y + a.z * b.z), representing how aligned the two vectors are + ### Lua Example `local numberValue = vec3f_dot(a, b)` @@ -845,15 +848,15 @@ Calculates the distance between two 3D floating-point points `v1` and `v2`. The ### C Prototype `f32 vec3f_dot(Vec3f a, Vec3f b);` -### Description -Computes the dot product of the two 3D floating-point vectors `a` and `b`. The dot product is a scalar value defined by (a.x * b.x + a.y * b.y + a.z * b.z), representing how aligned the two vectors are - [:arrow_up_small:](#)
## [vec3f_get_dist_and_angle](#vec3f_get_dist_and_angle) +### Description +Calculates the distance between two points in 3D space (`from` and `to`), as well as the pitch and yaw angles that describe the direction from `from` to `to`. The results are stored in `dist`, `pitch`, and `yaw` + ### Lua Example `vec3f_get_dist_and_angle(from, to, dist, pitch, yaw)` @@ -872,15 +875,15 @@ Computes the dot product of the two 3D floating-point vectors `a` and `b`. The d ### C Prototype `void vec3f_get_dist_and_angle(Vec3f from, Vec3f to, f32 *dist, s16 *pitch, s16 *yaw);` -### Description -Calculates the distance between two points in 3D space (`from` and `to`), as well as the pitch and yaw angles that describe the direction from `from` to `to`. The results are stored in `dist`, `pitch`, and `yaw` - [:arrow_up_small:](#)
## [vec3f_length](#vec3f_length) +### Description +Calculates the length (magnitude) of the 3D floating-point vector `a`. The length is defined as sqrt(x² + y² + z²) for the vector components (x, y, z) + ### Lua Example `local numberValue = vec3f_length(a)` @@ -895,15 +898,15 @@ Calculates the distance between two points in 3D space (`from` and `to`), as wel ### C Prototype `f32 vec3f_length(Vec3f a);` -### Description -Calculates the length (magnitude) of the 3D floating-point vector `a`. The length is defined as sqrt(x² + y² + z²) for the vector components (x, y, z) - [:arrow_up_small:](#)
## [vec3f_mul](#vec3f_mul) +### Description +Multiplies each component of the 3D floating-point vector `dest` by the scalar value `a`. For instance, `dest.x = dest.x * a`, and similarly for y and z. This scales the vector `dest` by `a` + ### Lua Example `local voidValue = vec3f_mul(dest, a)` @@ -919,15 +922,15 @@ Calculates the length (magnitude) of the 3D floating-point vector `a`. The lengt ### C Prototype `void *vec3f_mul(Vec3f dest, f32 a);` -### Description -Multiplies each component of the 3D floating-point vector `dest` by the scalar value `a`. For instance, `dest.x = dest.x * a`, and similarly for y and z. This scales the vector `dest` by `a` - [:arrow_up_small:](#)
## [vec3f_normalize](#vec3f_normalize) +### Description +Normalizes the 3D floating-point vector `dest` so that its length (magnitude) becomes 1, while retaining its direction. This effectively scales `dest` so that it lies on the unit sphere + ### Lua Example `local voidValue = vec3f_normalize(dest)` @@ -942,15 +945,15 @@ Multiplies each component of the 3D floating-point vector `dest` by the scalar v ### C Prototype `void *vec3f_normalize(Vec3f dest);` -### Description -Normalizes the 3D floating-point vector `dest` so that its length (magnitude) becomes 1, while retaining its direction. This effectively scales `dest` so that it lies on the unit sphere - [:arrow_up_small:](#)
## [vec3f_project](#vec3f_project) +### Description +Projects the 3D floating-point vector `vec` onto another 3D floating-point vector `onto`. The resulting projection, stored in `out`, represents how much of `vec` lies along the direction of `onto` + ### Lua Example `vec3f_project(vec, onto, out)` @@ -967,15 +970,15 @@ Normalizes the 3D floating-point vector `dest` so that its length (magnitude) be ### C Prototype `void vec3f_project(Vec3f vec, Vec3f onto, Vec3f out);` -### Description -Projects the 3D floating-point vector `vec` onto another 3D floating-point vector `onto`. The resulting projection, stored in `out`, represents how much of `vec` lies along the direction of `onto` - [:arrow_up_small:](#)
## [vec3f_rotate_zxy](#vec3f_rotate_zxy) +### Description +Rotates the 3D floating-point vector `v` by the angles specified in the 3D signed-integer vector `rotate`, applying the rotations in the order Z, then X, then Y. The rotated vector replaces `v` + ### Lua Example `local voidValue = vec3f_rotate_zxy(v, rotate)` @@ -991,15 +994,15 @@ Projects the 3D floating-point vector `vec` onto another 3D floating-point vecto ### C Prototype `void *vec3f_rotate_zxy(Vec3f v, Vec3s rotate);` -### Description -Rotates the 3D floating-point vector `v` by the angles specified in the 3D signed-integer vector `rotate`, applying the rotations in the order Z, then X, then Y. The rotated vector replaces `v` - [:arrow_up_small:](#)
## [vec3f_set](#vec3f_set) +### Description +Sets the values of the 3D floating-point vector `dest` to the given x, y, and z values. After this function, `dest` will have values (x, y, z) + ### Lua Example `local voidValue = vec3f_set(dest, x, y, z)` @@ -1017,9 +1020,6 @@ Rotates the 3D floating-point vector `v` by the angles specified in the 3D signe ### C Prototype `void *vec3f_set(Vec3f dest, f32 x, f32 y, f32 z);` -### Description -Sets the values of the 3D floating-point vector `dest` to the given x, y, and z values. After this function, `dest` will have values (x, y, z) - [:arrow_up_small:](#)
@@ -1050,6 +1050,9 @@ Sets the values of the 3D floating-point vector `dest` to the given x, y, and z ## [vec3f_sum](#vec3f_sum) +### Description +Adds the corresponding components of two 3D floating-point vectors `a` and `b`, and stores the result in `dest`. For example, `dest.x = a.x + b.x`, `dest.y = a.y + b.y`, and `dest.z = a.z + b.z` + ### Lua Example `local voidValue = vec3f_sum(dest, a, b)` @@ -1066,15 +1069,15 @@ Sets the values of the 3D floating-point vector `dest` to the given x, y, and z ### C Prototype `void *vec3f_sum(Vec3f dest, Vec3f a, Vec3f b);` -### Description -Adds the corresponding components of two 3D floating-point vectors `a` and `b`, and stores the result in `dest`. For example, `dest.x = a.x + b.x`, `dest.y = a.y + b.y`, and `dest.z = a.z + b.z` - [:arrow_up_small:](#)
## [vec3f_to_vec3s](#vec3f_to_vec3s) +### Description +Converts a 3D floating-point vector `a` (Vec3f) into a 3D signed-integer vector and stores it in `dest`. After this operation, `dest` will contain the integer versions of `a`'s floating-point components + ### Lua Example `local voidValue = vec3f_to_vec3s(dest, a)` @@ -1090,15 +1093,15 @@ Adds the corresponding components of two 3D floating-point vectors `a` and `b`, ### C Prototype `void *vec3f_to_vec3s(Vec3s dest, Vec3f a);` -### Description -Converts a 3D floating-point vector `a` (Vec3f) into a 3D signed-integer vector and stores it in `dest`. After this operation, `dest` will contain the integer versions of `a`'s floating-point components - [:arrow_up_small:](#)
## [vec3s_add](#vec3s_add) +### Description +Adds the components of a 3D signed-integer vector `a` to the corresponding components of `dest`. After this operation, each component of `dest` is increased by the corresponding component in `a` + ### Lua Example `local voidValue = vec3s_add(dest, a)` @@ -1114,15 +1117,15 @@ Converts a 3D floating-point vector `a` (Vec3f) into a 3D signed-integer vector ### C Prototype `void *vec3s_add(Vec3s dest, Vec3s a);` -### Description -Adds the components of a 3D signed-integer vector `a` to the corresponding components of `dest`. After this operation, each component of `dest` is increased by the corresponding component in `a` - [:arrow_up_small:](#)
## [vec3s_copy](#vec3s_copy) +### Description +Copies the components of one 3D signed-integer vector (`src`) to another (`dest`). After this function, `dest` will have the same x, y, and z integer values as `src` + ### Lua Example `local voidValue = vec3s_copy(dest, src)` @@ -1138,15 +1141,15 @@ Adds the components of a 3D signed-integer vector `a` to the corresponding compo ### C Prototype `void *vec3s_copy(Vec3s dest, Vec3s src);` -### Description -Copies the components of one 3D signed-integer vector (`src`) to another (`dest`). After this function, `dest` will have the same x, y, and z integer values as `src` - [:arrow_up_small:](#)
## [vec3s_set](#vec3s_set) +### Description +Sets the 3D signed-integer vector `dest` to the specified integer values (x, y, z), so that `dest` becomes (x, y, z). + ### Lua Example `local voidValue = vec3s_set(dest, x, y, z)` @@ -1164,15 +1167,15 @@ Copies the components of one 3D signed-integer vector (`src`) to another (`dest` ### C Prototype `void *vec3s_set(Vec3s dest, s16 x, s16 y, s16 z);` -### Description -Sets the 3D signed-integer vector `dest` to the specified integer values (x, y, z), so that `dest` becomes (x, y, z). - [:arrow_up_small:](#)
## [vec3s_sum](#vec3s_sum) +### Description +Adds the components of two 3D signed-integer vectors `a` and `b` together and stores the resulting vector in `dest`. For example, `dest.x = a.x + b.x`, and similarly for y and z + ### Lua Example `local voidValue = vec3s_sum(dest, a, b)` @@ -1189,15 +1192,15 @@ Sets the 3D signed-integer vector `dest` to the specified integer values (x, y, ### C Prototype `void *vec3s_sum(Vec3s dest, Vec3s a, Vec3s b);` -### Description -Adds the components of two 3D signed-integer vectors `a` and `b` together and stores the resulting vector in `dest`. For example, `dest.x = a.x + b.x`, and similarly for y and z - [:arrow_up_small:](#)
## [vec3s_to_vec3f](#vec3s_to_vec3f) +### Description +Converts a 3D signed-integer vector `a` (vec3s) into a 3D floating-point vector and stores it in `dest`. After this operation, `dest` will contain the floating-point equivalents of `a`'s integer components + ### Lua Example `local voidValue = vec3s_to_vec3f(dest, a)` @@ -1213,9 +1216,6 @@ Adds the components of two 3D signed-integer vectors `a` and `b` together and st ### C Prototype `void *vec3s_to_vec3f(Vec3f dest, Vec3s a);` -### Description -Converts a 3D signed-integer vector `a` (vec3s) into a 3D floating-point vector and stores it in `dest`. After this operation, `dest` will contain the floating-point equivalents of `a`'s integer components - [:arrow_up_small:](#)
diff --git a/docs/lua/functions-5.md b/docs/lua/functions-5.md index 4ee555d16..249f70592 100644 --- a/docs/lua/functions-5.md +++ b/docs/lua/functions-5.md @@ -1766,6 +1766,9 @@ ## [get_fog_color](#get_fog_color) +### Description +Gets a value of the global fog color + ### Lua Example `local integerValue = get_fog_color(index)` @@ -1780,15 +1783,15 @@ ### C Prototype `u8 get_fog_color(u8 index);` -### Description -Gets a value of the global fog color - [:arrow_up_small:](#)
## [get_fog_intensity](#get_fog_intensity) +### Description +Gets the intensity of the fog + ### Lua Example `local numberValue = get_fog_intensity()` @@ -1801,15 +1804,15 @@ Gets a value of the global fog color ### C Prototype `f32 get_fog_intensity(void);` -### Description -Gets the intensity of the fog - [:arrow_up_small:](#)
## [get_lighting_color](#get_lighting_color) +### Description +Gets a value of the global lighting color + ### Lua Example `local integerValue = get_lighting_color(index)` @@ -1824,15 +1827,15 @@ Gets the intensity of the fog ### C Prototype `u8 get_lighting_color(u8 index);` -### Description -Gets a value of the global lighting color - [:arrow_up_small:](#)
## [get_lighting_color_ambient](#get_lighting_color_ambient) +### Description +Gets a value of the global ambient lighting color + ### Lua Example `local integerValue = get_lighting_color_ambient(index)` @@ -1847,15 +1850,15 @@ Gets a value of the global lighting color ### C Prototype `u8 get_lighting_color_ambient(u8 index);` -### Description -Gets a value of the global ambient lighting color - [:arrow_up_small:](#)
## [get_lighting_dir](#get_lighting_dir) +### Description +Gets a value of the global lighting direction + ### Lua Example `local numberValue = get_lighting_dir(index)` @@ -1870,15 +1873,15 @@ Gets a value of the global ambient lighting color ### C Prototype `f32 get_lighting_dir(u8 index);` -### Description -Gets a value of the global lighting direction - [:arrow_up_small:](#)
## [get_skybox](#get_skybox) +### Description +Gets the current skybox + ### Lua Example `local integerValue = get_skybox()` @@ -1891,15 +1894,15 @@ Gets a value of the global lighting direction ### C Prototype `s8 get_skybox(void);` -### Description -Gets the current skybox - [:arrow_up_small:](#)
## [get_skybox_color](#get_skybox_color) +### Description +Gets a value of the global skybox color + ### Lua Example `local integerValue = get_skybox_color(index)` @@ -1914,15 +1917,15 @@ Gets the current skybox ### C Prototype `u8 get_skybox_color(u8 index);` -### Description -Gets a value of the global skybox color - [:arrow_up_small:](#)
## [get_vertex_color](#get_vertex_color) +### Description +Gets a value of the global vertex shading color + ### Lua Example `local integerValue = get_vertex_color(index)` @@ -1937,15 +1940,15 @@ Gets a value of the global skybox color ### C Prototype `u8 get_vertex_color(u8 index);` -### Description -Gets a value of the global vertex shading color - [:arrow_up_small:](#)
## [set_fog_color](#set_fog_color) +### Description +Sets a value of the global fog color + ### Lua Example `set_fog_color(index, value)` @@ -1961,15 +1964,15 @@ Gets a value of the global vertex shading color ### C Prototype `void set_fog_color(u8 index, u8 value);` -### Description -Sets a value of the global fog color - [:arrow_up_small:](#)
## [set_fog_intensity](#set_fog_intensity) +### Description +Sets the intensity of the fog (this value scales very quickly, 1.0 to 1.1 is a desirable range) + ### Lua Example `set_fog_intensity(intensity)` @@ -1984,15 +1987,15 @@ Sets a value of the global fog color ### C Prototype `void set_fog_intensity(f32 intensity);` -### Description -Sets the intensity of the fog (this value scales very quickly, 1.0 to 1.1 is a desirable range) - [:arrow_up_small:](#)
## [set_lighting_color](#set_lighting_color) +### Description +Sets a value of the global lighting color + ### Lua Example `set_lighting_color(index, value)` @@ -2008,15 +2011,15 @@ Sets the intensity of the fog (this value scales very quickly, 1.0 to 1.1 is a d ### C Prototype `void set_lighting_color(u8 index, u8 value);` -### Description -Sets a value of the global lighting color - [:arrow_up_small:](#)
## [set_lighting_color_ambient](#set_lighting_color_ambient) +### Description +Sets a value of the global lighting color (run this after `set_lighting_color` for the ambient color to not be overriden) + ### Lua Example `set_lighting_color_ambient(index, value)` @@ -2032,15 +2035,15 @@ Sets a value of the global lighting color ### C Prototype `void set_lighting_color_ambient(u8 index, u8 value);` -### Description -Sets a value of the global lighting color (run this after `set_lighting_color` for the ambient color to not be overriden) - [:arrow_up_small:](#)
## [set_lighting_dir](#set_lighting_dir) +### Description +Sets a value of the global lighting direction + ### Lua Example `set_lighting_dir(index, value)` @@ -2056,15 +2059,15 @@ Sets a value of the global lighting color (run this after `set_lighting_color` f ### C Prototype `void set_lighting_dir(u8 index, f32 value);` -### Description -Sets a value of the global lighting direction - [:arrow_up_small:](#)
## [set_override_far](#set_override_far) +### Description +Sets the override far plane + ### Lua Example `set_override_far(far)` @@ -2079,15 +2082,15 @@ Sets a value of the global lighting direction ### C Prototype `void set_override_far(f32 far);` -### Description -Sets the override far plane - [:arrow_up_small:](#)
## [set_override_fov](#set_override_fov) +### Description +Sets the override FOV + ### Lua Example `set_override_fov(fov)` @@ -2102,15 +2105,15 @@ Sets the override far plane ### C Prototype `void set_override_fov(f32 fov);` -### Description -Sets the override FOV - [:arrow_up_small:](#)
## [set_override_near](#set_override_near) +### Description +Sets the override near plane + ### Lua Example `set_override_near(near)` @@ -2125,15 +2128,15 @@ Sets the override FOV ### C Prototype `void set_override_near(f32 near);` -### Description -Sets the override near plane - [:arrow_up_small:](#)
## [set_override_skybox](#set_override_skybox) +### Description +Sets the override skybox + ### Lua Example `set_override_skybox(background)` @@ -2148,15 +2151,15 @@ Sets the override near plane ### C Prototype `void set_override_skybox(s8 background);` -### Description -Sets the override skybox - [:arrow_up_small:](#)
## [set_skybox_color](#set_skybox_color) +### Description +Sets a value of the global skybox color + ### Lua Example `set_skybox_color(index, value)` @@ -2172,15 +2175,15 @@ Sets the override skybox ### C Prototype `void set_skybox_color(u8 index, u8 value);` -### Description -Sets a value of the global skybox color - [:arrow_up_small:](#)
## [set_vertex_color](#set_vertex_color) +### Description +Sets a value of the global vertex shading color + ### Lua Example `set_vertex_color(index, value)` @@ -2196,9 +2199,6 @@ Sets a value of the global skybox color ### C Prototype `void set_vertex_color(u8 index, u8 value);` -### Description -Sets a value of the global vertex shading color - [:arrow_up_small:](#)
@@ -2465,6 +2465,9 @@ Sets a value of the global vertex shading color ## [clamp](#clamp) +### Description +Clamps a signed 32-bit integer `a` between bounds `b` (minimum) and `c` (maximum) + ### Lua Example `local integerValue = clamp(a, b, c)` @@ -2481,15 +2484,15 @@ Sets a value of the global vertex shading color ### C Prototype `s32 clamp(s32 a, s32 b, s32 c);` -### Description -Clamps a signed 32-bit integer `a` between bounds `b` (minimum) and `c` (maximum) - [:arrow_up_small:](#)
## [clampf](#clampf) +### Description +Clamps a floating-point number `a` between bounds `b` (minimum) and `c` (maximum) + ### Lua Example `local numberValue = clampf(a, b, c)` @@ -2506,15 +2509,15 @@ Clamps a signed 32-bit integer `a` between bounds `b` (minimum) and `c` (maximum ### C Prototype `f32 clampf(f32 a, f32 b, f32 c);` -### Description -Clamps a floating-point number `a` between bounds `b` (minimum) and `c` (maximum) - [:arrow_up_small:](#)
## [degrees_to_sm64](#degrees_to_sm64) +### Description +Converts an angle from degrees to SM64 format + ### Lua Example `local integerValue = degrees_to_sm64(degreesAngle)` @@ -2529,15 +2532,15 @@ Clamps a floating-point number `a` between bounds `b` (minimum) and `c` (maximum ### C Prototype `s16 degrees_to_sm64(f32 degreesAngle);` -### Description -Converts an angle from degrees to SM64 format - [:arrow_up_small:](#)
## [hypotf](#hypotf) +### Description +Computes the hypotenuse of a right triangle given sides `a` and `b` using the Pythagorean theorem + ### Lua Example `local numberValue = hypotf(a, b)` @@ -2553,15 +2556,15 @@ Converts an angle from degrees to SM64 format ### C Prototype `f32 hypotf(f32 a, f32 b);` -### Description -Computes the hypotenuse of a right triangle given sides `a` and `b` using the Pythagorean theorem - [:arrow_up_small:](#)
## [max](#max) +### Description +Finds the maximum of two signed 32-bit integers + ### Lua Example `local integerValue = max(a, b)` @@ -2577,15 +2580,15 @@ Computes the hypotenuse of a right triangle given sides `a` and `b` using the Py ### C Prototype `s32 max(s32 a, s32 b);` -### Description -Finds the maximum of two signed 32-bit integers - [:arrow_up_small:](#)
## [maxf](#maxf) +### Description +Finds the maximum of two floating-point numbers + ### Lua Example `local numberValue = maxf(a, b)` @@ -2601,15 +2604,15 @@ Finds the maximum of two signed 32-bit integers ### C Prototype `f32 maxf(f32 a, f32 b);` -### Description -Finds the maximum of two floating-point numbers - [:arrow_up_small:](#)
## [min](#min) +### Description +Finds the minimum of two signed 32-bit integers + ### Lua Example `local integerValue = min(a, b)` @@ -2625,15 +2628,15 @@ Finds the maximum of two floating-point numbers ### C Prototype `s32 min(s32 a, s32 b);` -### Description -Finds the minimum of two signed 32-bit integers - [:arrow_up_small:](#)
## [minf](#minf) +### Description +Finds the minimum of two floating-point numbers + ### Lua Example `local numberValue = minf(a, b)` @@ -2649,15 +2652,15 @@ Finds the minimum of two signed 32-bit integers ### C Prototype `f32 minf(f32 a, f32 b);` -### Description -Finds the minimum of two floating-point numbers - [:arrow_up_small:](#)
## [radians_to_sm64](#radians_to_sm64) +### Description +Converts an angle from radians to SM64 format + ### Lua Example `local integerValue = radians_to_sm64(radiansAngle)` @@ -2672,15 +2675,15 @@ Finds the minimum of two floating-point numbers ### C Prototype `s16 radians_to_sm64(f32 radiansAngle);` -### Description -Converts an angle from radians to SM64 format - [:arrow_up_small:](#)
## [sm64_to_degrees](#sm64_to_degrees) +### Description +Converts an angle from SM64 format to degrees + ### Lua Example `local numberValue = sm64_to_degrees(sm64Angle)` @@ -2695,15 +2698,15 @@ Converts an angle from radians to SM64 format ### C Prototype `f32 sm64_to_degrees(s16 sm64Angle);` -### Description -Converts an angle from SM64 format to degrees - [:arrow_up_small:](#)
## [sm64_to_radians](#sm64_to_radians) +### Description +Converts an angle from SM64 format to radians + ### Lua Example `local numberValue = sm64_to_radians(sm64Angle)` @@ -2718,15 +2721,15 @@ Converts an angle from SM64 format to degrees ### C Prototype `f32 sm64_to_radians(s16 sm64Angle);` -### Description -Converts an angle from SM64 format to radians - [:arrow_up_small:](#)
## [sqr](#sqr) +### Description +Computes the square of a signed 32-bit integer + ### Lua Example `local integerValue = sqr(x)` @@ -2741,15 +2744,15 @@ Converts an angle from SM64 format to radians ### C Prototype `s32 sqr(s32 x);` -### Description -Computes the square of a signed 32-bit integer - [:arrow_up_small:](#)
## [sqrf](#sqrf) +### Description +Computes the square of a floating-point number + ### Lua Example `local numberValue = sqrf(x)` @@ -2764,9 +2767,6 @@ Computes the square of a signed 32-bit integer ### C Prototype `f32 sqrf(f32 x);` -### Description -Computes the square of a floating-point number - [:arrow_up_small:](#)
@@ -2779,6 +2779,9 @@ Computes the square of a floating-point number ## [allocate_mario_action](#allocate_mario_action) +### Description +Allocates an action ID with bitwise flags + ### Lua Example `local integerValue = allocate_mario_action(actFlags)` @@ -2793,15 +2796,15 @@ Computes the square of a floating-point number ### C Prototype `u32 allocate_mario_action(u32 actFlags);` -### Description -Allocates an action ID with bitwise flags - [:arrow_up_small:](#)
## [course_is_main_course](#course_is_main_course) +### Description +Checks if a course is a main course and not the castle or secret levels + ### Lua Example `local booleanValue = course_is_main_course(courseNum)` @@ -2816,15 +2819,15 @@ Allocates an action ID with bitwise flags ### C Prototype `bool course_is_main_course(u16 courseNum);` -### Description -Checks if a course is a main course and not the castle or secret levels - [:arrow_up_small:](#)
## [deref_s32_pointer](#deref_s32_pointer) +### Description +Gets the 32-bit integer value from the pointer + ### Lua Example `local integerValue = deref_s32_pointer(pointer)` @@ -2839,15 +2842,15 @@ Checks if a course is a main course and not the castle or secret levels ### C Prototype `s32 deref_s32_pointer(s32* pointer);` -### Description -Gets the 32-bit integer value from the pointer - [:arrow_up_small:](#)
## [djui_attempting_to_open_playerlist](#djui_attempting_to_open_playerlist) +### Description +Checks if the DJUI playerlist is attempting to be opened + ### Lua Example `local booleanValue = djui_attempting_to_open_playerlist()` @@ -2860,15 +2863,15 @@ Gets the 32-bit integer value from the pointer ### C Prototype `bool djui_attempting_to_open_playerlist(void);` -### Description -Checks if the DJUI playerlist is attempting to be opened - [:arrow_up_small:](#)
## [djui_is_playerlist_open](#djui_is_playerlist_open) +### Description +Checks if the DJUI playerlist is open + ### Lua Example `local booleanValue = djui_is_playerlist_open()` @@ -2881,15 +2884,15 @@ Checks if the DJUI playerlist is attempting to be opened ### C Prototype `bool djui_is_playerlist_open(void);` -### Description -Checks if the DJUI playerlist is open - [:arrow_up_small:](#)
## [djui_is_popup_disabled](#djui_is_popup_disabled) +### Description +Returns if popups are disabled + ### Lua Example `local booleanValue = djui_is_popup_disabled()` @@ -2902,15 +2905,15 @@ Checks if the DJUI playerlist is open ### C Prototype `bool djui_is_popup_disabled(void);` -### Description -Returns if popups are disabled - [:arrow_up_small:](#)
## [djui_menu_get_font](#djui_menu_get_font) +### Description +Gets the DJUI menu font + ### Lua Example `local enumValue = djui_menu_get_font()` @@ -2923,15 +2926,15 @@ Returns if popups are disabled ### C Prototype `enum DjuiFontType djui_menu_get_font(void);` -### Description -Gets the DJUI menu font - [:arrow_up_small:](#)
## [djui_menu_get_theme](#djui_menu_get_theme) +### Description +Gets the DJUI menu theme + ### Lua Example `local DjuiThemeValue = djui_menu_get_theme()` @@ -2944,15 +2947,15 @@ Gets the DJUI menu font ### C Prototype `struct DjuiTheme* djui_menu_get_theme(void);` -### Description -Gets the DJUI menu theme - [:arrow_up_small:](#)
## [djui_popup_create_global](#djui_popup_create_global) +### Description +Creates a DJUI popup that is broadcasted to every client + ### Lua Example `djui_popup_create_global(message, lines)` @@ -2968,15 +2971,15 @@ Gets the DJUI menu theme ### C Prototype `void djui_popup_create_global(const char* message, int lines);` -### Description -Creates a DJUI popup that is broadcasted to every client - [:arrow_up_small:](#)
## [djui_reset_popup_disabled_override](#djui_reset_popup_disabled_override) +### Description +Resets if popups are disabled + ### Lua Example `djui_reset_popup_disabled_override()` @@ -2989,15 +2992,15 @@ Creates a DJUI popup that is broadcasted to every client ### C Prototype `void djui_reset_popup_disabled_override(void);` -### Description -Resets if popups are disabled - [:arrow_up_small:](#)
## [djui_set_popup_disabled_override](#djui_set_popup_disabled_override) +### Description +Sets if popups are disabled + ### Lua Example `djui_set_popup_disabled_override(value)` @@ -3012,15 +3015,15 @@ Resets if popups are disabled ### C Prototype `void djui_set_popup_disabled_override(bool value);` -### Description -Sets if popups are disabled - [:arrow_up_small:](#)
## [get_coopnet_id](#get_coopnet_id) +### Description +Gets the CoopNet ID of a player if CoopNet is being used and the player is connected, otherwise "-1" is returned + ### Lua Example `local stringValue = get_coopnet_id(localIndex)` @@ -3035,15 +3038,15 @@ Sets if popups are disabled ### C Prototype `const char* get_coopnet_id(s8 localIndex);` -### Description -Gets the CoopNet ID of a player if CoopNet is being used and the player is connected, otherwise "-1" is returned - [:arrow_up_small:](#)
## [get_current_save_file_num](#get_current_save_file_num) +### Description +Gets the current save file number (1-indexed) + ### Lua Example `local integerValue = get_current_save_file_num()` @@ -3056,15 +3059,15 @@ Gets the CoopNet ID of a player if CoopNet is being used and the player is conne ### C Prototype `s16 get_current_save_file_num(void);` -### Description -Gets the current save file number (1-indexed) - [:arrow_up_small:](#)
## [get_date_and_time](#get_date_and_time) +### Description +Gets the system clock's date and time + ### Lua Example `local DateTimeValue = get_date_and_time()` @@ -3077,15 +3080,15 @@ Gets the current save file number (1-indexed) ### C Prototype `struct DateTime* get_date_and_time(void);` -### Description -Gets the system clock's date and time - [:arrow_up_small:](#)
## [get_dialog_box_state](#get_dialog_box_state) +### Description +Gets the current state of the dialog box + ### Lua Example `local integerValue = get_dialog_box_state()` @@ -3098,15 +3101,15 @@ Gets the system clock's date and time ### C Prototype `s8 get_dialog_box_state(void);` -### Description -Gets the current state of the dialog box - [:arrow_up_small:](#)
## [get_dialog_id](#get_dialog_id) +### Description +Gets the current dialog box ID + ### Lua Example `local integerValue = get_dialog_id()` @@ -3119,15 +3122,15 @@ Gets the current state of the dialog box ### C Prototype `s16 get_dialog_id(void);` -### Description -Gets the current dialog box ID - [:arrow_up_small:](#)
## [get_dialog_response](#get_dialog_response) +### Description +Gets the choice selected inside of a dialog box (0-1) + ### Lua Example `local integerValue = get_dialog_response()` @@ -3140,15 +3143,15 @@ Gets the current dialog box ID ### C Prototype `s32 get_dialog_response(void);` -### Description -Gets the choice selected inside of a dialog box (0-1) - [:arrow_up_small:](#)
## [get_envfx](#get_envfx) +### Description +Gets the non overridden environment effect (e.g. snow) + ### Lua Example `local integerValue = get_envfx()` @@ -3161,15 +3164,15 @@ Gets the choice selected inside of a dialog box (0-1) ### C Prototype `u16 get_envfx(void);` -### Description -Gets the non overridden environment effect (e.g. snow) - [:arrow_up_small:](#)
## [get_environment_region](#get_environment_region) +### Description +Gets an environment region (gas/water boxes) height value + ### Lua Example `local numberValue = get_environment_region(index)` @@ -3184,15 +3187,15 @@ Gets the non overridden environment effect (e.g. snow) ### C Prototype `f32 get_environment_region(u8 index);` -### Description -Gets an environment region (gas/water boxes) height value - [:arrow_up_small:](#)
## [get_global_timer](#get_global_timer) +### Description +Gets the global timer that has been ticking at 30 frames per second since game boot + ### Lua Example `local integerValue = get_global_timer()` @@ -3205,15 +3208,15 @@ Gets an environment region (gas/water boxes) height value ### C Prototype `u32 get_global_timer(void);` -### Description -Gets the global timer that has been ticking at 30 frames per second since game boot - [:arrow_up_small:](#)
## [get_got_file_coin_hi_score](#get_got_file_coin_hi_score) +### Description +Checks if the save file's coin "HI SCORE" was obtained with the last star or key collection + ### Lua Example `local booleanValue = get_got_file_coin_hi_score()` @@ -3226,15 +3229,15 @@ Gets the global timer that has been ticking at 30 frames per second since game b ### C Prototype `bool get_got_file_coin_hi_score(void);` -### Description -Checks if the save file's coin "HI SCORE" was obtained with the last star or key collection - [:arrow_up_small:](#)
## [get_hand_foot_pos_x](#get_hand_foot_pos_x) +### Description +Gets the X coordinate of Mario's hand (0-1) or foot (2-3) but it is important to note that the positions are not updated off-screen + ### Lua Example `local numberValue = get_hand_foot_pos_x(m, index)` @@ -3250,15 +3253,15 @@ Checks if the save file's coin "HI SCORE" was obtained with the last star or key ### C Prototype `f32 get_hand_foot_pos_x(struct MarioState* m, u8 index);` -### Description -Gets the X coordinate of Mario's hand (0-1) or foot (2-3) but it is important to note that the positions are not updated off-screen - [:arrow_up_small:](#)
## [get_hand_foot_pos_y](#get_hand_foot_pos_y) +### Description +Gets the Y coordinate of Mario's hand (0-1) or foot (2-3) but it is important to note that the positions are not updated off-screen + ### Lua Example `local numberValue = get_hand_foot_pos_y(m, index)` @@ -3274,15 +3277,15 @@ Gets the X coordinate of Mario's hand (0-1) or foot (2-3) but it is important to ### C Prototype `f32 get_hand_foot_pos_y(struct MarioState* m, u8 index);` -### Description -Gets the Y coordinate of Mario's hand (0-1) or foot (2-3) but it is important to note that the positions are not updated off-screen - [:arrow_up_small:](#)
## [get_hand_foot_pos_z](#get_hand_foot_pos_z) +### Description +Gets the Z coordinate of Mario's hand (0-1) or foot (2-3) but it is important to note that the positions are not updated off-screen + ### Lua Example `local numberValue = get_hand_foot_pos_z(m, index)` @@ -3298,15 +3301,15 @@ Gets the Y coordinate of Mario's hand (0-1) or foot (2-3) but it is important to ### C Prototype `f32 get_hand_foot_pos_z(struct MarioState* m, u8 index);` -### Description -Gets the Z coordinate of Mario's hand (0-1) or foot (2-3) but it is important to note that the positions are not updated off-screen - [:arrow_up_small:](#)
## [get_last_completed_course_num](#get_last_completed_course_num) +### Description +Gets the last course a star or key was collected in + ### Lua Example `local integerValue = get_last_completed_course_num()` @@ -3319,15 +3322,15 @@ Gets the Z coordinate of Mario's hand (0-1) or foot (2-3) but it is important to ### C Prototype `u8 get_last_completed_course_num(void);` -### Description -Gets the last course a star or key was collected in - [:arrow_up_small:](#)
## [get_last_completed_star_num](#get_last_completed_star_num) +### Description +Gets the last collected star's number (1-7) + ### Lua Example `local integerValue = get_last_completed_star_num()` @@ -3340,15 +3343,15 @@ Gets the last course a star or key was collected in ### C Prototype `u8 get_last_completed_star_num(void);` -### Description -Gets the last collected star's number (1-7) - [:arrow_up_small:](#)
## [get_last_star_or_key](#get_last_star_or_key) +### Description +Gets if the last objective collected was a star (0) or a key (1) + ### Lua Example `local integerValue = get_last_star_or_key()` @@ -3361,15 +3364,15 @@ Gets the last collected star's number (1-7) ### C Prototype `u8 get_last_star_or_key(void);` -### Description -Gets if the last objective collected was a star (0) or a key (1) - [:arrow_up_small:](#)
## [get_local_discord_id](#get_local_discord_id) +### Description +Gets the local discord ID if it isn't disabled, otherwise "0" is returned + ### Lua Example `local stringValue = get_local_discord_id()` @@ -3382,15 +3385,15 @@ Gets if the last objective collected was a star (0) or a key (1) ### C Prototype `const char* get_local_discord_id(void);` -### Description -Gets the local discord ID if it isn't disabled, otherwise "0" is returned - [:arrow_up_small:](#)
## [get_network_area_timer](#get_network_area_timer) +### Description +Gets the current area's networked timer + ### Lua Example `local integerValue = get_network_area_timer()` @@ -3403,15 +3406,15 @@ Gets the local discord ID if it isn't disabled, otherwise "0" is returned ### C Prototype `u32 get_network_area_timer(void);` -### Description -Gets the current area's networked timer - [:arrow_up_small:](#)
## [get_os_name](#get_os_name) +### Description +Gets the name of the operating system the game is running on + ### Lua Example `local stringValue = get_os_name()` @@ -3424,15 +3427,15 @@ Gets the current area's networked timer ### C Prototype `const char* get_os_name(void);` -### Description -Gets the name of the operating system the game is running on - [:arrow_up_small:](#)
## [get_save_file_modified](#get_save_file_modified) +### Description +Checks if the save file has been modified without saving + ### Lua Example `local booleanValue = get_save_file_modified()` @@ -3445,15 +3448,15 @@ Gets the name of the operating system the game is running on ### C Prototype `bool get_save_file_modified(void);` -### Description -Checks if the save file has been modified without saving - [:arrow_up_small:](#)
## [get_temp_s32_pointer](#get_temp_s32_pointer) +### Description +Returns a temporary 32-bit integer pointer + ### Lua Example `local PointerValue = get_temp_s32_pointer(initialValue)` @@ -3468,15 +3471,15 @@ Checks if the save file has been modified without saving ### C Prototype `s32* get_temp_s32_pointer(s32 initialValue);` -### Description -Returns a temporary 32-bit integer pointer - [:arrow_up_small:](#)
## [get_time](#get_time) +### Description +Gets the Unix Timestamp + ### Lua Example `local integerValue = get_time()` @@ -3489,15 +3492,15 @@ Returns a temporary 32-bit integer pointer ### C Prototype `s64 get_time(void);` -### Description -Gets the Unix Timestamp - [:arrow_up_small:](#)
## [get_ttc_speed_setting](#get_ttc_speed_setting) +### Description +Gets TTC's speed setting + ### Lua Example `local integerValue = get_ttc_speed_setting()` @@ -3510,15 +3513,15 @@ Gets the Unix Timestamp ### C Prototype `s16 get_ttc_speed_setting(void);` -### Description -Gets TTC's speed setting - [:arrow_up_small:](#)
## [get_volume_env](#get_volume_env) +### Description +Gets the volume level of environment sounds effects + ### Lua Example `local numberValue = get_volume_env()` @@ -3531,15 +3534,15 @@ Gets TTC's speed setting ### C Prototype `f32 get_volume_env(void);` -### Description -Gets the volume level of environment sounds effects - [:arrow_up_small:](#)
## [get_volume_level](#get_volume_level) +### Description +Gets the volume level of music + ### Lua Example `local numberValue = get_volume_level()` @@ -3552,15 +3555,15 @@ Gets the volume level of environment sounds effects ### C Prototype `f32 get_volume_level(void);` -### Description -Gets the volume level of music - [:arrow_up_small:](#)
## [get_volume_master](#get_volume_master) +### Description +Gets the master volume level + ### Lua Example `local numberValue = get_volume_master()` @@ -3573,15 +3576,15 @@ Gets the volume level of music ### C Prototype `f32 get_volume_master(void);` -### Description -Gets the master volume level - [:arrow_up_small:](#)
## [get_volume_sfx](#get_volume_sfx) +### Description +Gets the volume level of sound effects + ### Lua Example `local numberValue = get_volume_sfx()` @@ -3594,15 +3597,15 @@ Gets the master volume level ### C Prototype `f32 get_volume_sfx(void);` -### Description -Gets the volume level of sound effects - [:arrow_up_small:](#)
## [get_water_level](#get_water_level) +### Description +Gets the water level in an area + ### Lua Example `local integerValue = get_water_level(index)` @@ -3617,15 +3620,15 @@ Gets the volume level of sound effects ### C Prototype `s16 get_water_level(u8 index);` -### Description -Gets the water level in an area - [:arrow_up_small:](#)
## [hud_get_flash](#hud_get_flash) +### Description +Gets if the star counter on the HUD should flash + ### Lua Example `local integerValue = hud_get_flash()` @@ -3638,9 +3641,6 @@ Gets the water level in an area ### C Prototype `s8 hud_get_flash(void);` -### Description -Gets if the star counter on the HUD should flash - [:arrow_up_small:](#)
@@ -3667,6 +3667,9 @@ Gets if the star counter on the HUD should flash ## [hud_hide](#hud_hide) +### Description +Hides the HUD + ### Lua Example `hud_hide()` @@ -3679,15 +3682,15 @@ Gets if the star counter on the HUD should flash ### C Prototype `void hud_hide(void);` -### Description -Hides the HUD - [:arrow_up_small:](#)
## [hud_is_hidden](#hud_is_hidden) +### Description +Checks if the HUD is hidden + ### Lua Example `local booleanValue = hud_is_hidden()` @@ -3700,15 +3703,15 @@ Hides the HUD ### C Prototype `bool hud_is_hidden(void);` -### Description -Checks if the HUD is hidden - [:arrow_up_small:](#)
## [hud_render_power_meter](#hud_render_power_meter) +### Description +Renders a power meter on the HUD + ### Lua Example `hud_render_power_meter(health, x, y, width, height)` @@ -3727,15 +3730,15 @@ Checks if the HUD is hidden ### C Prototype `void hud_render_power_meter(s32 health, f32 x, f32 y, f32 width, f32 height);` -### Description -Renders a power meter on the HUD - [:arrow_up_small:](#)
## [hud_render_power_meter_interpolated](#hud_render_power_meter_interpolated) +### Description +Renders an interpolated power meter on the HUD + ### Lua Example `hud_render_power_meter_interpolated(health, prevX, prevY, prevWidth, prevHeight, x, y, width, height)` @@ -3758,15 +3761,15 @@ Renders a power meter on the HUD ### C Prototype `void hud_render_power_meter_interpolated(s32 health, f32 prevX, f32 prevY, f32 prevWidth, f32 prevHeight, f32 x, f32 y, f32 width, f32 height);` -### Description -Renders an interpolated power meter on the HUD - [:arrow_up_small:](#)
## [hud_set_flash](#hud_set_flash) +### Description +Sets if the star counter on the HUD should flash + ### Lua Example `hud_set_flash(value)` @@ -3781,15 +3784,15 @@ Renders an interpolated power meter on the HUD ### C Prototype `void hud_set_flash(s8 value);` -### Description -Sets if the star counter on the HUD should flash - [:arrow_up_small:](#)
## [hud_set_value](#hud_set_value) +### Description +Sets a HUD display value + ### Lua Example `hud_set_value(type, value)` @@ -3805,15 +3808,15 @@ Sets if the star counter on the HUD should flash ### C Prototype `void hud_set_value(enum HudDisplayValue type, s32 value);` -### Description -Sets a HUD display value - [:arrow_up_small:](#)
## [hud_show](#hud_show) +### Description +Shows the HUD + ### Lua Example `hud_show()` @@ -3826,15 +3829,15 @@ Sets a HUD display value ### C Prototype `void hud_show(void);` -### Description -Shows the HUD - [:arrow_up_small:](#)
## [is_game_paused](#is_game_paused) +### Description +Checks if the game is paused + ### Lua Example `local booleanValue = is_game_paused()` @@ -3847,15 +3850,15 @@ Shows the HUD ### C Prototype `bool is_game_paused(void);` -### Description -Checks if the game is paused - [:arrow_up_small:](#)
## [is_transition_playing](#is_transition_playing) +### Description +Checks if a screen transition is playing + ### Lua Example `local booleanValue = is_transition_playing()` @@ -3868,15 +3871,15 @@ Checks if the game is paused ### C Prototype `bool is_transition_playing(void);` -### Description -Checks if a screen transition is playing - [:arrow_up_small:](#)
## [mod_file_exists](#mod_file_exists) +### Description +Checks if a file exists inside of a mod + ### Lua Example `local booleanValue = mod_file_exists(filename)` @@ -3891,15 +3894,15 @@ Checks if a screen transition is playing ### C Prototype `bool mod_file_exists(const char* filename);` -### Description -Checks if a file exists inside of a mod - [:arrow_up_small:](#)
## [movtexqc_register](#movtexqc_register) +### Description +Registers a custom moving texture entry (used for vanilla water boxes) + ### Lua Example `movtexqc_register(name, level, area, type)` @@ -3917,15 +3920,15 @@ Checks if a file exists inside of a mod ### C Prototype `void movtexqc_register(const char* name, s16 level, s16 area, s16 type);` -### Description -Registers a custom moving texture entry (used for vanilla water boxes) - [:arrow_up_small:](#)
## [play_transition](#play_transition) +### Description +Plays a screen transition + ### Lua Example `play_transition(transType, time, red, green, blue)` @@ -3944,15 +3947,15 @@ Registers a custom moving texture entry (used for vanilla water boxes) ### C Prototype `void play_transition(s16 transType, s16 time, u8 red, u8 green, u8 blue);` -### Description -Plays a screen transition - [:arrow_up_small:](#)
## [reset_window_title](#reset_window_title) +### Description +Resets the window title + ### Lua Example `reset_window_title()` @@ -3965,15 +3968,15 @@ Plays a screen transition ### C Prototype `void reset_window_title(void);` -### Description -Resets the window title - [:arrow_up_small:](#)
## [save_file_get_using_backup_slot](#save_file_get_using_backup_slot) +### Description +Checks if the save file is using its backup slot + ### Lua Example `local booleanValue = save_file_get_using_backup_slot()` @@ -3986,15 +3989,15 @@ Resets the window title ### C Prototype `bool save_file_get_using_backup_slot(void);` -### Description -Checks if the save file is using its backup slot - [:arrow_up_small:](#)
## [save_file_set_using_backup_slot](#save_file_set_using_backup_slot) +### Description +Sets if the save file should use its backup slot + ### Lua Example `save_file_set_using_backup_slot(usingBackupSlot)` @@ -4009,15 +4012,15 @@ Checks if the save file is using its backup slot ### C Prototype `void save_file_set_using_backup_slot(bool usingBackupSlot);` -### Description -Sets if the save file should use its backup slot - [:arrow_up_small:](#)
## [set_environment_region](#set_environment_region) +### Description +Sets an environment region (gas/water boxes) height value + ### Lua Example `set_environment_region(index, value)` @@ -4033,15 +4036,15 @@ Sets if the save file should use its backup slot ### C Prototype `void set_environment_region(u8 index, s32 value);` -### Description -Sets an environment region (gas/water boxes) height value - [:arrow_up_small:](#)
## [set_got_file_coin_hi_score](#set_got_file_coin_hi_score) +### Description +Sets if the save file's coin "HI SCORE" was obtained with the last star or key collection + ### Lua Example `set_got_file_coin_hi_score(value)` @@ -4056,15 +4059,15 @@ Sets an environment region (gas/water boxes) height value ### C Prototype `void set_got_file_coin_hi_score(bool value);` -### Description -Sets if the save file's coin "HI SCORE" was obtained with the last star or key collection - [:arrow_up_small:](#)
## [set_last_completed_course_num](#set_last_completed_course_num) +### Description +Sets the last course a star or key was collected in + ### Lua Example `set_last_completed_course_num(courseNum)` @@ -4079,15 +4082,15 @@ Sets if the save file's coin "HI SCORE" was obtained with the last star or key c ### C Prototype `void set_last_completed_course_num(u8 courseNum);` -### Description -Sets the last course a star or key was collected in - [:arrow_up_small:](#)
## [set_last_completed_star_num](#set_last_completed_star_num) +### Description +Sets the last collected star's number (1-7) + ### Lua Example `set_last_completed_star_num(starNum)` @@ -4102,15 +4105,15 @@ Sets the last course a star or key was collected in ### C Prototype `void set_last_completed_star_num(u8 starNum);` -### Description -Sets the last collected star's number (1-7) - [:arrow_up_small:](#)
## [set_last_star_or_key](#set_last_star_or_key) +### Description +Sets if the last objective collected was a star (0) or a key (1) + ### Lua Example `set_last_star_or_key(value)` @@ -4125,15 +4128,15 @@ Sets the last collected star's number (1-7) ### C Prototype `void set_last_star_or_key(u8 value);` -### Description -Sets if the last objective collected was a star (0) or a key (1) - [:arrow_up_small:](#)
## [set_override_envfx](#set_override_envfx) +### Description +Sets the override environment effect (e.g. snow) + ### Lua Example `set_override_envfx(envfx)` @@ -4148,15 +4151,15 @@ Sets if the last objective collected was a star (0) or a key (1) ### C Prototype `void set_override_envfx(s32 envfx);` -### Description -Sets the override environment effect (e.g. snow) - [:arrow_up_small:](#)
## [set_save_file_modified](#set_save_file_modified) +### Description +Sets if the save file has been modified without saving + ### Lua Example `set_save_file_modified(value)` @@ -4171,15 +4174,15 @@ Sets the override environment effect (e.g. snow) ### C Prototype `void set_save_file_modified(bool value);` -### Description -Sets if the save file has been modified without saving - [:arrow_up_small:](#)
## [set_ttc_speed_setting](#set_ttc_speed_setting) +### Description +Sets TTC's speed setting (TTC_SPEED_*) + ### Lua Example `set_ttc_speed_setting(speed)` @@ -4194,15 +4197,15 @@ Sets if the save file has been modified without saving ### C Prototype `void set_ttc_speed_setting(s16 speed);` -### Description -Sets TTC's speed setting (TTC_SPEED_*) - [:arrow_up_small:](#)
## [set_volume_env](#set_volume_env) +### Description +Sets the volume level of environment sounds effects + ### Lua Example `set_volume_env(volume)` @@ -4217,15 +4220,15 @@ Sets TTC's speed setting (TTC_SPEED_*) ### C Prototype `void set_volume_env(f32 volume);` -### Description -Sets the volume level of environment sounds effects - [:arrow_up_small:](#)
## [set_volume_level](#set_volume_level) +### Description +Sets the volume level of music + ### Lua Example `set_volume_level(volume)` @@ -4240,15 +4243,15 @@ Sets the volume level of environment sounds effects ### C Prototype `void set_volume_level(f32 volume);` -### Description -Sets the volume level of music - [:arrow_up_small:](#)
## [set_volume_master](#set_volume_master) +### Description +Sets the master volume level + ### Lua Example `set_volume_master(volume)` @@ -4263,15 +4266,15 @@ Sets the volume level of music ### C Prototype `void set_volume_master(f32 volume);` -### Description -Sets the master volume level - [:arrow_up_small:](#)
## [set_volume_sfx](#set_volume_sfx) +### Description +Sets the volume level of sound effects + ### Lua Example `set_volume_sfx(volume)` @@ -4286,15 +4289,15 @@ Sets the master volume level ### C Prototype `void set_volume_sfx(f32 volume);` -### Description -Sets the volume level of sound effects - [:arrow_up_small:](#)
## [set_water_level](#set_water_level) +### Description +Sets the water level in an area + ### Lua Example `set_water_level(index, height, sync)` @@ -4311,15 +4314,15 @@ Sets the volume level of sound effects ### C Prototype `void set_water_level(u8 index, s16 height, bool sync);` -### Description -Sets the water level in an area - [:arrow_up_small:](#)
## [set_window_title](#set_window_title) +### Description +Sets the window title to a custom title + ### Lua Example `set_window_title(title)` @@ -4334,9 +4337,6 @@ Sets the water level in an area ### C Prototype `void set_window_title(const char* title);` -### Description -Sets the window title to a custom title - [:arrow_up_small:](#)