Remaining worthwhile structs

This commit is contained in:
Sunketchupm 2026-01-29 21:27:11 -05:00
parent 591c71f351
commit 125dce970f
3 changed files with 145 additions and 54 deletions

View file

@ -186,6 +186,9 @@ make_struct_methods = {
"MarioState": { "remove": ["mario"] },
"Object": { "remove": ["object", "obj"] },
"Surface": { "remove": ["surface"] },
"Camera": { "remove": ["camera"] },
"ModAudio": { "remove": ["audio"] },
"NetworkPlayer": { "remove": ["network_player"] },
}
total_structs = 0

View file

@ -217,6 +217,21 @@
--- @field public doorStatus integer
--- @field public areaCenY number
--- @field public mtx Mat4
--- @field public move_mario_head_c_up fun(c: Camera) Moves Mario's head slightly upward when the C-Up button is pressed. This function aligns the camera to match the head movement for consistency
--- @field public transition_next_state fun(c: Camera, frames: integer) Transitions the camera to the next state over a specified number of frames. This is typically used for cutscenes or scripted sequences
--- @field public set_mode fun(c: Camera, mode: integer, frames: integer) Changes the camera to a new mode, optionally interpolating over a specified number of frames. Useful for transitioning between different camera behaviors dynamically
--- @field public soft_reset fun(c: Camera) Resets the camera's state while retaining some settings, such as position or mode. This is often used when soft-resetting gameplay without reinitialization
--- @field public reset fun(c: Camera) Fully resets the camera to its default state and reinitializes all settings. This is typically used when restarting gameplay or loading a new area
--- @field public offset_yaw_outward_radial fun(c: Camera, areaYaw: integer): integer Calculates an outward radial offset based on the camera's yaw angle. Returns the offset yaw, used for positioning or alignment
--- @field public radial_input fun(c: Camera, unused: number): integer Handles radial camera movement based on player input. Updates the camera's position or orientation accordingly
--- @field public handle_c_button_movement fun(c: Camera) Handles camera movement based on input from the C-buttons. Updates the camera's position or angle to match directional player input
--- @field public start_cutscene fun(c: Camera, cutscene: integer) Starts a cutscene based on the provided ID. The camera transitions to predefined behaviors for the duration of the cutscene
--- @field public get_cutscene_from_mario_status fun(c: Camera): integer Gets the appropriate cutscene to play based on Mario's current gameplay state. This function helps determine transitions for cinematic or scripted sequences
--- @field public approach_height fun(c: Camera, goal: number, inc: number) Adjusts the camera's height toward a target value (`goalHeight`) while respecting terrain and obstructions. This is really wonky and probably shouldn't be used, prefer `gLakituStates`
--- @field public course_processing fun(c: Camera): integer Processes course-specific camera settings, such as predefined positions or modes. Adjusts the camera to match the design and gameplay requirements of the current course
--- @field public rotate_around_walls fun(c: Camera, cPos: Vec3f, avoidYaw: integer, yawRange: integer): integer Rotates the camera to avoid walls or other obstructions. Ensures clear visibility of the player or target objects
--- @field public play_cutscene fun(c: Camera) Starts the execution of a predefined cutscene. The camera transitions dynamically to follow the scripted sequence
--- @field public set_mode_fixed fun(c: Camera, x: integer, y: integer, z: integer): integer Activates a fixed camera mode and aligns the camera to specific X, Y, Z coordinates. This is useful for predefined static views in specific areas
--- @class ChainSegment
--- @field public posX number
@ -1443,6 +1458,25 @@
--- @field public isStream boolean
--- @field public baseVolume number
--- @field public loaded boolean
--- @field public stream_destroy fun(audio: ModAudio) Destroys an `audio` stream
--- @field public stream_play fun(audio: ModAudio, restart: boolean, volume: number) Plays an `audio` stream with `volume`. `restart` sets the elapsed time back to 0.
--- @field public stream_pause fun(audio: ModAudio) Pauses an `audio` stream
--- @field public stream_stop fun(audio: ModAudio) Stops an `audio` stream
--- @field public stream_get_position fun(audio: ModAudio): number Gets the position of an `audio` stream in seconds
--- @field public stream_set_position fun(audio: ModAudio, pos: number) Sets the position of an `audio` stream in seconds
--- @field public stream_get_looping fun(audio: ModAudio): boolean Gets if an `audio` stream is looping or not
--- @field public stream_set_looping fun(audio: ModAudio, looping: boolean) Sets if an `audio` stream is looping or not
--- @field public stream_set_loop_points fun(audio: ModAudio, loopStart: integer, loopEnd: integer) Sets an `audio` stream's loop points in samples
--- @field public stream_get_frequency fun(audio: ModAudio): number Gets the frequency of an `audio` stream
--- @field public stream_set_frequency fun(audio: ModAudio, freq: number) Sets the frequency of an `audio` stream
--- @field public stream_get_volume fun(audio: ModAudio): number Gets the volume of an `audio` stream
--- @field public stream_set_volume fun(audio: ModAudio, volume: number) Sets the volume of an `audio` stream
--- @field public sample_destroy fun(audio: ModAudio) Destroys an `audio` sample
--- @field public sample_stop fun(audio: ModAudio) Stops an `audio` sample
--- @field public sample_play fun(audio: ModAudio, position: Vec3f, volume: number) Plays an `audio` sample at `position` with `volume`
--- @field public stream_get_tempo function [DEPRECATED: There may be a replacement for this function in the future]
--- @field public stream_set_tempo function [DEPRECATED: There may be a replacement for this function in the future]
--- @field public stream_set_speed function [DEPRECATED: There may be a replacement for this function in the future]
--- @class ModFs
--- @field public mod Mod
@ -1525,6 +1559,16 @@
--- @field public paletteIndex integer
--- @field public overridePaletteIndex integer
--- @field public overridePaletteIndexLp integer
--- @field public lag_compensation_get_local_state fun(otherNp: NetworkPlayer): MarioState Gets the local Mario's state stored in lag compensation history
--- @field public set_description fun(np: NetworkPlayer, description: string, r: integer, g: integer, b: integer, a: integer) Sets the description field of `np`
--- @field public set_override_location fun(np: NetworkPlayer, location: string) Overrides the location of `np`
--- @field public get_palette_color_channel function Gets a red, green, or blue value from a part in `np`'s color palette
--- @field public get_override_palette_color_channel function Gets a red, green, or blue value from a part in `np`'s override color palette
--- @field public set_override_palette_color fun(np: NetworkPlayer, part: PlayerPart, color: Color) Sets the `part in `np`'s override color palette`
--- @field public reset_override_palette fun(np: NetworkPlayer) Resets `np`'s override color palette
--- @field public is_override_palette_same fun(np: NetworkPlayer): boolean Checks if `np`'s override color palette is identical to the regular color palette
--- @field public color_to_palette function [DEPRECATED: Use `network_player_set_override_palette_color` instead]
--- @field public palette_to_color function [DEPRECATED: Use `network_player_get_palette_color` or `network_player_get_override_palette_color` instead]
--- @class Object
--- @field public header ObjectNode

View file

@ -377,23 +377,38 @@ static struct LuaObjectField sBehaviorValuesFields[LUA_BEHAVIOR_VALUES_FIELD_COU
{ "trajectories", LVT_COBJECT, offsetof(struct BehaviorValues, trajectories), true, LOT_BEHAVIORTRAJECTORIES, 1, sizeof(struct BehaviorTrajectories) },
};
#define LUA_CAMERA_FIELD_COUNT 15
#define LUA_CAMERA_FIELD_COUNT 30
static struct LuaObjectField sCameraFields[LUA_CAMERA_FIELD_COUNT] = {
{ "areaCenX", LVT_F32, offsetof(struct Camera, areaCenX), false, LOT_NONE, 1, sizeof(f32) },
{ "areaCenY", LVT_F32, offsetof(struct Camera, areaCenY), false, LOT_NONE, 1, sizeof(f32) },
{ "areaCenZ", LVT_F32, offsetof(struct Camera, areaCenZ), false, LOT_NONE, 1, sizeof(f32) },
{ "cutscene", LVT_U8, offsetof(struct Camera, cutscene), false, LOT_NONE, 1, sizeof(u8) },
{ "defMode", LVT_U8, offsetof(struct Camera, defMode), false, LOT_NONE, 1, sizeof(u8) },
{ "doorStatus", LVT_U8, offsetof(struct Camera, doorStatus), false, LOT_NONE, 1, sizeof(u8) },
{ "filler31", LVT_U8, offsetof(struct Camera, filler31), false, LOT_NONE, 8, sizeof(u8) },
{ "filler3C", LVT_U8, offsetof(struct Camera, filler3C), false, LOT_NONE, 40, sizeof(u8) },
{ "focus", LVT_COBJECT, offsetof(struct Camera, focus), true, LOT_VEC3F, 1, sizeof(Vec3f) },
{ "mode", LVT_U8, offsetof(struct Camera, mode), false, LOT_NONE, 1, sizeof(u8) },
{ "mtx", LVT_COBJECT, offsetof(struct Camera, mtx), true, LOT_MAT4, 1, sizeof(Mat4) },
{ "nextYaw", LVT_S16, offsetof(struct Camera, nextYaw), false, LOT_NONE, 1, sizeof(s16) },
{ "pos", LVT_COBJECT, offsetof(struct Camera, pos), true, LOT_VEC3F, 1, sizeof(Vec3f) },
{ "unusedVec1", LVT_COBJECT, offsetof(struct Camera, unusedVec1), true, LOT_VEC3F, 1, sizeof(Vec3f) },
{ "yaw", LVT_S16, offsetof(struct Camera, yaw), false, LOT_NONE, 1, sizeof(s16) },
{ "approach_height", LVT_FUNCTION, (size_t) "approach_camera_height", true, LOT_NONE, 1, sizeof(const char *) },
{ "areaCenX", LVT_F32, offsetof(struct Camera, areaCenX), false, LOT_NONE, 1, sizeof(f32) },
{ "areaCenY", LVT_F32, offsetof(struct Camera, areaCenY), false, LOT_NONE, 1, sizeof(f32) },
{ "areaCenZ", LVT_F32, offsetof(struct Camera, areaCenZ), false, LOT_NONE, 1, sizeof(f32) },
{ "course_processing", LVT_FUNCTION, (size_t) "camera_course_processing", true, LOT_NONE, 1, sizeof(const char *) },
{ "cutscene", LVT_U8, offsetof(struct Camera, cutscene), false, LOT_NONE, 1, sizeof(u8) },
{ "defMode", LVT_U8, offsetof(struct Camera, defMode), false, LOT_NONE, 1, sizeof(u8) },
{ "doorStatus", LVT_U8, offsetof(struct Camera, doorStatus), false, LOT_NONE, 1, sizeof(u8) },
{ "filler31", LVT_U8, offsetof(struct Camera, filler31), false, LOT_NONE, 8, sizeof(u8) },
{ "filler3C", LVT_U8, offsetof(struct Camera, filler3C), false, LOT_NONE, 40, sizeof(u8) },
{ "focus", LVT_COBJECT, offsetof(struct Camera, focus), true, LOT_VEC3F, 1, sizeof(Vec3f) },
{ "get_cutscene_from_mario_status", LVT_FUNCTION, (size_t) "get_cutscene_from_mario_status", true, LOT_NONE, 1, sizeof(const char *) },
{ "handle_c_button_movement", LVT_FUNCTION, (size_t) "handle_c_button_movement", true, LOT_NONE, 1, sizeof(const char *) },
{ "mode", LVT_U8, offsetof(struct Camera, mode), false, LOT_NONE, 1, sizeof(u8) },
{ "move_mario_head_c_up", LVT_FUNCTION, (size_t) "move_mario_head_c_up", true, LOT_NONE, 1, sizeof(const char *) },
{ "mtx", LVT_COBJECT, offsetof(struct Camera, mtx), true, LOT_MAT4, 1, sizeof(Mat4) },
{ "nextYaw", LVT_S16, offsetof(struct Camera, nextYaw), false, LOT_NONE, 1, sizeof(s16) },
{ "offset_yaw_outward_radial", LVT_FUNCTION, (size_t) "offset_yaw_outward_radial", true, LOT_NONE, 1, sizeof(const char *) },
{ "play_cutscene", LVT_FUNCTION, (size_t) "play_cutscene", true, LOT_NONE, 1, sizeof(const char *) },
{ "pos", LVT_COBJECT, offsetof(struct Camera, pos), true, LOT_VEC3F, 1, sizeof(Vec3f) },
{ "radial_input", LVT_FUNCTION, (size_t) "radial_camera_input", true, LOT_NONE, 1, sizeof(const char *) },
{ "reset", LVT_FUNCTION, (size_t) "reset_camera", true, LOT_NONE, 1, sizeof(const char *) },
{ "rotate_around_walls", LVT_FUNCTION, (size_t) "rotate_camera_around_walls", true, LOT_NONE, 1, sizeof(const char *) },
{ "set_mode", LVT_FUNCTION, (size_t) "set_camera_mode", true, LOT_NONE, 1, sizeof(const char *) },
{ "set_mode_fixed", LVT_FUNCTION, (size_t) "set_camera_mode_fixed", true, LOT_NONE, 1, sizeof(const char *) },
{ "soft_reset", LVT_FUNCTION, (size_t) "soft_reset_camera", true, LOT_NONE, 1, sizeof(const char *) },
{ "start_cutscene", LVT_FUNCTION, (size_t) "start_cutscene", true, LOT_NONE, 1, sizeof(const char *) },
{ "transition_next_state", LVT_FUNCTION, (size_t) "transition_next_state", true, LOT_NONE, 1, sizeof(const char *) },
{ "unusedVec1", LVT_COBJECT, offsetof(struct Camera, unusedVec1), true, LOT_VEC3F, 1, sizeof(Vec3f) },
{ "yaw", LVT_S16, offsetof(struct Camera, yaw), false, LOT_NONE, 1, sizeof(s16) },
};
#define LUA_CHAIN_SEGMENT_FIELD_COUNT 6
@ -1728,12 +1743,31 @@ static struct LuaObjectField sModFields[LUA_MOD_FIELD_COUNT] = {
{ "size", LVT_U64, offsetof(struct Mod, size), true, LOT_NONE, 1, sizeof(size_t) },
};
#define LUA_MOD_AUDIO_FIELD_COUNT 4
#define LUA_MOD_AUDIO_FIELD_COUNT 23
static struct LuaObjectField sModAudioFields[LUA_MOD_AUDIO_FIELD_COUNT] = {
{ "baseVolume", LVT_F32, offsetof(struct ModAudio, baseVolume), false, LOT_NONE, 1, sizeof(f32) },
{ "filepath", LVT_STRING_P, offsetof(struct ModAudio, filepath), true, LOT_NONE, 1, sizeof(const char*) },
{ "isStream", LVT_BOOL, offsetof(struct ModAudio, isStream), true, LOT_NONE, 1, sizeof(bool) },
{ "loaded", LVT_BOOL, offsetof(struct ModAudio, loaded), true, LOT_NONE, 1, sizeof(bool) },
{ "baseVolume", LVT_F32, offsetof(struct ModAudio, baseVolume), false, LOT_NONE, 1, sizeof(f32) },
{ "filepath", LVT_STRING_P, offsetof(struct ModAudio, filepath), true, LOT_NONE, 1, sizeof(const char*) },
{ "isStream", LVT_BOOL, offsetof(struct ModAudio, isStream), true, LOT_NONE, 1, sizeof(bool) },
{ "loaded", LVT_BOOL, offsetof(struct ModAudio, loaded), true, LOT_NONE, 1, sizeof(bool) },
{ "sample_destroy", LVT_FUNCTION, (size_t) "audio_sample_destroy", true, LOT_NONE, 1, sizeof(const char *) },
{ "sample_play", LVT_FUNCTION, (size_t) "audio_sample_play", true, LOT_NONE, 1, sizeof(const char *) },
{ "sample_stop", LVT_FUNCTION, (size_t) "audio_sample_stop", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_destroy", LVT_FUNCTION, (size_t) "audio_stream_destroy", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_get_frequency", LVT_FUNCTION, (size_t) "audio_stream_get_frequency", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_get_looping", LVT_FUNCTION, (size_t) "audio_stream_get_looping", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_get_position", LVT_FUNCTION, (size_t) "audio_stream_get_position", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_get_tempo", LVT_FUNCTION, (size_t) "audio_stream_get_tempo", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_get_volume", LVT_FUNCTION, (size_t) "audio_stream_get_volume", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_pause", LVT_FUNCTION, (size_t) "audio_stream_pause", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_play", LVT_FUNCTION, (size_t) "audio_stream_play", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_frequency", LVT_FUNCTION, (size_t) "audio_stream_set_frequency", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_loop_points", LVT_FUNCTION, (size_t) "audio_stream_set_loop_points", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_looping", LVT_FUNCTION, (size_t) "audio_stream_set_looping", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_position", LVT_FUNCTION, (size_t) "audio_stream_set_position", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_speed", LVT_FUNCTION, (size_t) "audio_stream_set_speed", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_tempo", LVT_FUNCTION, (size_t) "audio_stream_set_tempo", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_set_volume", LVT_FUNCTION, (size_t) "audio_stream_set_volume", true, LOT_NONE, 1, sizeof(const char *) },
{ "stream_stop", LVT_FUNCTION, (size_t) "audio_stream_stop", true, LOT_NONE, 1, sizeof(const char *) },
};
#define LUA_MOD_FS_FIELD_COUNT 15
@ -1790,40 +1824,50 @@ static struct LuaObjectField sNametagsSettingsFields[LUA_NAMETAGS_SETTINGS_FIELD
{ "showSelfTag", LVT_BOOL, offsetof(struct NametagsSettings, showSelfTag), false, LOT_NONE, 1, sizeof(bool) },
};
#define LUA_NETWORK_PLAYER_FIELD_COUNT 32
#define LUA_NETWORK_PLAYER_FIELD_COUNT 42
static struct LuaObjectField sNetworkPlayerFields[LUA_NETWORK_PLAYER_FIELD_COUNT] = {
{ "connected", LVT_BOOL, offsetof(struct NetworkPlayer, connected), true, LOT_NONE, 1, sizeof(bool) },
{ "currActNum", LVT_S16, offsetof(struct NetworkPlayer, currActNum), true, LOT_NONE, 1, sizeof(s16) },
{ "currAreaIndex", LVT_S16, offsetof(struct NetworkPlayer, currAreaIndex), true, LOT_NONE, 1, sizeof(s16) },
{ "currAreaSyncValid", LVT_BOOL, offsetof(struct NetworkPlayer, currAreaSyncValid), true, LOT_NONE, 1, sizeof(bool) },
{ "currCourseNum", LVT_S16, offsetof(struct NetworkPlayer, currCourseNum), true, LOT_NONE, 1, sizeof(s16) },
{ "currLevelAreaSeqId", LVT_U16, offsetof(struct NetworkPlayer, currLevelAreaSeqId), true, LOT_NONE, 1, sizeof(u16) },
{ "currLevelNum", LVT_S16, offsetof(struct NetworkPlayer, currLevelNum), true, LOT_NONE, 1, sizeof(s16) },
{ "currLevelSyncValid", LVT_BOOL, offsetof(struct NetworkPlayer, currLevelSyncValid), true, LOT_NONE, 1, sizeof(bool) },
{ "currPositionValid", LVT_BOOL, offsetof(struct NetworkPlayer, currPositionValid), true, LOT_NONE, 1, sizeof(bool) },
{ "description", LVT_STRING, offsetof(struct NetworkPlayer, description), true, LOT_NONE, 1, sizeof(char) },
{ "descriptionA", LVT_U8, offsetof(struct NetworkPlayer, descriptionA), true, LOT_NONE, 1, sizeof(u8) },
{ "descriptionB", LVT_U8, offsetof(struct NetworkPlayer, descriptionB), true, LOT_NONE, 1, sizeof(u8) },
{ "descriptionG", LVT_U8, offsetof(struct NetworkPlayer, descriptionG), true, LOT_NONE, 1, sizeof(u8) },
{ "descriptionR", LVT_U8, offsetof(struct NetworkPlayer, descriptionR), true, LOT_NONE, 1, sizeof(u8) },
{ "fadeOpacity", LVT_U8, offsetof(struct NetworkPlayer, fadeOpacity), true, LOT_NONE, 1, sizeof(u8) },
{ "globalIndex", LVT_U8, offsetof(struct NetworkPlayer, globalIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "lastPingSent", LVT_F32, offsetof(struct NetworkPlayer, lastPingSent), true, LOT_NONE, 1, sizeof(f32) },
{ "lastReceived", LVT_F32, offsetof(struct NetworkPlayer, lastReceived), true, LOT_NONE, 1, sizeof(f32) },
{ "lastSent", LVT_F32, offsetof(struct NetworkPlayer, lastSent), true, LOT_NONE, 1, sizeof(f32) },
{ "localIndex", LVT_U8, offsetof(struct NetworkPlayer, localIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "modelIndex", LVT_U8, offsetof(struct NetworkPlayer, modelIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "name", LVT_STRING, offsetof(struct NetworkPlayer, name), true, LOT_NONE, 1, sizeof(char) },
{ "onRxSeqId", LVT_U8, offsetof(struct NetworkPlayer, onRxSeqId), true, LOT_NONE, 1, sizeof(u8) },
{ "overrideLocation", LVT_STRING, offsetof(struct NetworkPlayer, overrideLocation), true, LOT_NONE, 1, sizeof(char) },
{ "overrideModelIndex", LVT_U8, offsetof(struct NetworkPlayer, overrideModelIndex), false, LOT_NONE, 1, sizeof(u8) },
{ "overridePalette", LVT_COBJECT, offsetof(struct NetworkPlayer, overridePalette), false, LOT_PLAYERPALETTE, 1, sizeof(struct PlayerPalette) },
{ "overridePaletteIndex", LVT_U8, offsetof(struct NetworkPlayer, overridePaletteIndex), false, LOT_NONE, 1, sizeof(u8) },
{ "overridePaletteIndexLp", LVT_U8, offsetof(struct NetworkPlayer, overridePaletteIndexLp), true, LOT_NONE, 1, sizeof(u8) },
{ "palette", LVT_COBJECT, offsetof(struct NetworkPlayer, palette), true, LOT_PLAYERPALETTE, 1, sizeof(struct PlayerPalette) },
{ "paletteIndex", LVT_U8, offsetof(struct NetworkPlayer, paletteIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "ping", LVT_U32, offsetof(struct NetworkPlayer, ping), true, LOT_NONE, 1, sizeof(u32) },
{ "type", LVT_U8, offsetof(struct NetworkPlayer, type), true, LOT_NONE, 1, sizeof(u8) },
{ "color_to_palette", LVT_FUNCTION, (size_t) "network_player_color_to_palette", true, LOT_NONE, 1, sizeof(const char *) },
{ "connected", LVT_BOOL, offsetof(struct NetworkPlayer, connected), true, LOT_NONE, 1, sizeof(bool) },
{ "currActNum", LVT_S16, offsetof(struct NetworkPlayer, currActNum), true, LOT_NONE, 1, sizeof(s16) },
{ "currAreaIndex", LVT_S16, offsetof(struct NetworkPlayer, currAreaIndex), true, LOT_NONE, 1, sizeof(s16) },
{ "currAreaSyncValid", LVT_BOOL, offsetof(struct NetworkPlayer, currAreaSyncValid), true, LOT_NONE, 1, sizeof(bool) },
{ "currCourseNum", LVT_S16, offsetof(struct NetworkPlayer, currCourseNum), true, LOT_NONE, 1, sizeof(s16) },
{ "currLevelAreaSeqId", LVT_U16, offsetof(struct NetworkPlayer, currLevelAreaSeqId), true, LOT_NONE, 1, sizeof(u16) },
{ "currLevelNum", LVT_S16, offsetof(struct NetworkPlayer, currLevelNum), true, LOT_NONE, 1, sizeof(s16) },
{ "currLevelSyncValid", LVT_BOOL, offsetof(struct NetworkPlayer, currLevelSyncValid), true, LOT_NONE, 1, sizeof(bool) },
{ "currPositionValid", LVT_BOOL, offsetof(struct NetworkPlayer, currPositionValid), true, LOT_NONE, 1, sizeof(bool) },
{ "description", LVT_STRING, offsetof(struct NetworkPlayer, description), true, LOT_NONE, 1, sizeof(char) },
{ "descriptionA", LVT_U8, offsetof(struct NetworkPlayer, descriptionA), true, LOT_NONE, 1, sizeof(u8) },
{ "descriptionB", LVT_U8, offsetof(struct NetworkPlayer, descriptionB), true, LOT_NONE, 1, sizeof(u8) },
{ "descriptionG", LVT_U8, offsetof(struct NetworkPlayer, descriptionG), true, LOT_NONE, 1, sizeof(u8) },
{ "descriptionR", LVT_U8, offsetof(struct NetworkPlayer, descriptionR), true, LOT_NONE, 1, sizeof(u8) },
{ "fadeOpacity", LVT_U8, offsetof(struct NetworkPlayer, fadeOpacity), true, LOT_NONE, 1, sizeof(u8) },
{ "get_override_palette_color_channel", LVT_FUNCTION, (size_t) "network_player_get_override_palette_color_channel", true, LOT_NONE, 1, sizeof(const char *) },
{ "get_palette_color_channel", LVT_FUNCTION, (size_t) "network_player_get_palette_color_channel", true, LOT_NONE, 1, sizeof(const char *) },
{ "globalIndex", LVT_U8, offsetof(struct NetworkPlayer, globalIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "is_override_palette_same", LVT_FUNCTION, (size_t) "network_player_is_override_palette_same", true, LOT_NONE, 1, sizeof(const char *) },
{ "lag_compensation_get_local_state", LVT_FUNCTION, (size_t) "lag_compensation_get_local_state", true, LOT_NONE, 1, sizeof(const char *) },
{ "lastPingSent", LVT_F32, offsetof(struct NetworkPlayer, lastPingSent), true, LOT_NONE, 1, sizeof(f32) },
{ "lastReceived", LVT_F32, offsetof(struct NetworkPlayer, lastReceived), true, LOT_NONE, 1, sizeof(f32) },
{ "lastSent", LVT_F32, offsetof(struct NetworkPlayer, lastSent), true, LOT_NONE, 1, sizeof(f32) },
{ "localIndex", LVT_U8, offsetof(struct NetworkPlayer, localIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "modelIndex", LVT_U8, offsetof(struct NetworkPlayer, modelIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "name", LVT_STRING, offsetof(struct NetworkPlayer, name), true, LOT_NONE, 1, sizeof(char) },
{ "onRxSeqId", LVT_U8, offsetof(struct NetworkPlayer, onRxSeqId), true, LOT_NONE, 1, sizeof(u8) },
{ "overrideLocation", LVT_STRING, offsetof(struct NetworkPlayer, overrideLocation), true, LOT_NONE, 1, sizeof(char) },
{ "overrideModelIndex", LVT_U8, offsetof(struct NetworkPlayer, overrideModelIndex), false, LOT_NONE, 1, sizeof(u8) },
{ "overridePalette", LVT_COBJECT, offsetof(struct NetworkPlayer, overridePalette), false, LOT_PLAYERPALETTE, 1, sizeof(struct PlayerPalette) },
{ "overridePaletteIndex", LVT_U8, offsetof(struct NetworkPlayer, overridePaletteIndex), false, LOT_NONE, 1, sizeof(u8) },
{ "overridePaletteIndexLp", LVT_U8, offsetof(struct NetworkPlayer, overridePaletteIndexLp), true, LOT_NONE, 1, sizeof(u8) },
{ "palette", LVT_COBJECT, offsetof(struct NetworkPlayer, palette), true, LOT_PLAYERPALETTE, 1, sizeof(struct PlayerPalette) },
{ "paletteIndex", LVT_U8, offsetof(struct NetworkPlayer, paletteIndex), true, LOT_NONE, 1, sizeof(u8) },
{ "palette_to_color", LVT_FUNCTION, (size_t) "network_player_palette_to_color", true, LOT_NONE, 1, sizeof(const char *) },
{ "ping", LVT_U32, offsetof(struct NetworkPlayer, ping), true, LOT_NONE, 1, sizeof(u32) },
{ "reset_override_palette", LVT_FUNCTION, (size_t) "network_player_reset_override_palette", true, LOT_NONE, 1, sizeof(const char *) },
{ "set_description", LVT_FUNCTION, (size_t) "network_player_set_description", true, LOT_NONE, 1, sizeof(const char *) },
{ "set_override_location", LVT_FUNCTION, (size_t) "network_player_set_override_location", true, LOT_NONE, 1, sizeof(const char *) },
{ "set_override_palette_color", LVT_FUNCTION, (size_t) "network_player_set_override_palette_color", true, LOT_NONE, 1, sizeof(const char *) },
{ "type", LVT_U8, offsetof(struct NetworkPlayer, type), true, LOT_NONE, 1, sizeof(u8) },
};
#define LUA_OBJECT_FIELD_COUNT 894