diff --git a/autogen/lua_definitions/structs.lua b/autogen/lua_definitions/structs.lua index fe37b472..81b5f76d 100644 --- a/autogen/lua_definitions/structs.lua +++ b/autogen/lua_definitions/structs.lua @@ -1725,7 +1725,6 @@ --- @field public maxPlayers integer --- @field public playerInteractions PlayerInteractions --- @field public playerKnockbackStrength integer ---- @field public shareLives integer --- @field public skipIntro integer --- @field public stayInLevelAfterStar integer diff --git a/docs/lua/structs.md b/docs/lua/structs.md index 9a80c9bf..b7295a57 100644 --- a/docs/lua/structs.md +++ b/docs/lua/structs.md @@ -2185,7 +2185,6 @@ | maxPlayers | `integer` | | | playerInteractions | [enum PlayerInteractions](constants.md#enum-PlayerInteractions) | | | playerKnockbackStrength | `integer` | | -| shareLives | `integer` | | | skipIntro | `integer` | | | stayInLevelAfterStar | `integer` | | diff --git a/src/game/mario.c b/src/game/mario.c index d1cdb75e..beda5e91 100644 --- a/src/game/mario.c +++ b/src/game/mario.c @@ -428,9 +428,6 @@ void mario_set_bubbled(struct MarioState* m) { set_mario_action(m, ACT_BUBBLED, 0); if (m->numLives != -1) { m->numLives--; - if (gServerSettings.shareLives) { - network_send_death(); - } } m->healCounter = 0; m->hurtCounter = 31; @@ -503,7 +500,7 @@ s32 mario_get_floor_class(struct MarioState *m) { } // Crawling allows Mario to not slide on certain steeper surfaces. - if (m->action == ACT_CRAWLING && m->floor->normal.y > 0.5f && floorClass == SURFACE_CLASS_DEFAULT) { + if (m->action == ACT_CRAWLING && m->floor && m->floor->normal.y > 0.5f && floorClass == SURFACE_CLASS_DEFAULT) { floorClass = SURFACE_CLASS_NOT_SLIPPERY; } diff --git a/src/pc/configfile.c b/src/pc/configfile.c index dc325905..ac7be1aa 100644 --- a/src/pc/configfile.c +++ b/src/pc/configfile.c @@ -115,7 +115,6 @@ bool configCameraAnalog = true; bool configCameraMouse = false; #endif bool configSkipIntro = 0; -bool configShareLives = 0; bool configEnableCheats = 0; bool configBubbleDeath = true; unsigned int configAmountofPlayers = 16; @@ -249,7 +248,6 @@ static const struct ConfigOption options[] = { {.name = "coop_custom_palette_cap", .type = CONFIG_TYPE_COLOR , .colorValue = &configCustomPalette.parts[CAP]}, {.name = "coop_stay_in_level_after_star", .type = CONFIG_TYPE_UINT , .uintValue = &configStayInLevelAfterStar}, {.name = "coop_singleplayer_pause", .type = CONFIG_TYPE_BOOL , .boolValue = &configSingleplayerPause}, - {.name = "share_lives", .type = CONFIG_TYPE_BOOL , .boolValue = &configShareLives}, {.name = "disable_popups", .type = CONFIG_TYPE_BOOL , .boolValue = &configDisablePopups}, #if defined(DEVELOPMENT) {.name = "lua_profiler", .type = CONFIG_TYPE_BOOL , .boolValue = &configLuaProfiler}, diff --git a/src/pc/configfile.h b/src/pc/configfile.h index 54b0bb6a..eabde56a 100644 --- a/src/pc/configfile.h +++ b/src/pc/configfile.h @@ -76,7 +76,6 @@ extern bool configCameraAnalog; #endif extern bool configHUD; extern bool configSkipIntro; -extern bool configShareLives; extern bool configEnableCheats; extern bool configBubbleDeath; extern unsigned int configAmountofPlayers; diff --git a/src/pc/djui/djui_panel_host_settings.c b/src/pc/djui/djui_panel_host_settings.c index a2ff3116..c355e1d1 100644 --- a/src/pc/djui/djui_panel_host_settings.c +++ b/src/pc/djui/djui_panel_host_settings.c @@ -60,7 +60,6 @@ void djui_panel_host_settings_create(struct DjuiBase* caller) { djui_selectionbox_create(body, DLANG(HOST_SETTINGS, ON_STAR_COLLECTION), lChoices, 3, &configStayInLevelAfterStar, NULL); djui_checkbox_create(body, DLANG(HOST_SETTINGS, SKIP_INTRO_CUTSCENE), &configSkipIntro, NULL); - djui_checkbox_create(body, DLANG(HOST_SETTINGS, SHARE_LIVES), &configShareLives, NULL); djui_checkbox_create(body, DLANG(HOST_SETTINGS, ENABLE_CHEATS), &configEnableCheats, NULL); djui_checkbox_create(body, DLANG(HOST_SETTINGS, BUBBLE_ON_DEATH), &configBubbleDeath, NULL); diff --git a/src/pc/lua/smlua_cobject_autogen.c b/src/pc/lua/smlua_cobject_autogen.c index 68eb961a..8dc73118 100644 --- a/src/pc/lua/smlua_cobject_autogen.c +++ b/src/pc/lua/smlua_cobject_autogen.c @@ -1888,7 +1888,7 @@ static struct LuaObjectField sRayIntersectionInfoFields[LUA_RAY_INTERSECTION_INF { "surface", LVT_COBJECT_P, offsetof(struct RayIntersectionInfo, surface), false, LOT_SURFACE }, }; -#define LUA_SERVER_SETTINGS_FIELD_COUNT 11 +#define LUA_SERVER_SETTINGS_FIELD_COUNT 10 static struct LuaObjectField sServerSettingsFields[LUA_SERVER_SETTINGS_FIELD_COUNT] = { { "bubbleDeath", LVT_U8, offsetof(struct ServerSettings, bubbleDeath), false, LOT_NONE }, { "enableCheats", LVT_U8, offsetof(struct ServerSettings, enableCheats), false, LOT_NONE }, @@ -1898,7 +1898,6 @@ static struct LuaObjectField sServerSettingsFields[LUA_SERVER_SETTINGS_FIELD_COU { "maxPlayers", LVT_U8, offsetof(struct ServerSettings, maxPlayers), false, LOT_NONE }, { "playerInteractions", LVT_S32, offsetof(struct ServerSettings, playerInteractions), false, LOT_NONE }, { "playerKnockbackStrength", LVT_U8, offsetof(struct ServerSettings, playerKnockbackStrength), false, LOT_NONE }, - { "shareLives", LVT_U8, offsetof(struct ServerSettings, shareLives), false, LOT_NONE }, { "skipIntro", LVT_U8, offsetof(struct ServerSettings, skipIntro), false, LOT_NONE }, { "stayInLevelAfterStar", LVT_U8, offsetof(struct ServerSettings, stayInLevelAfterStar), false, LOT_NONE }, }; diff --git a/src/pc/network/network.c b/src/pc/network/network.c index c3e8b326..7e3619b6 100644 --- a/src/pc/network/network.c +++ b/src/pc/network/network.c @@ -69,7 +69,6 @@ struct ServerSettings gServerSettings = { .playerInteractions = PLAYER_INTERACTIONS_SOLID, .playerKnockbackStrength = 25, .skipIntro = 0, - .shareLives = 0, .enableCheats = 0, .bubbleDeath = 1, .enablePlayersInLevelDisplay = 1, @@ -110,7 +109,6 @@ bool network_init(enum NetworkType inNetworkType, bool reconnecting) { gServerSettings.playerKnockbackStrength = configPlayerKnockbackStrength; gServerSettings.stayInLevelAfterStar = configStayInLevelAfterStar; gServerSettings.skipIntro = configSkipIntro; - gServerSettings.shareLives = configShareLives; gServerSettings.enableCheats = configEnableCheats; gServerSettings.bubbleDeath = configBubbleDeath; gServerSettings.maxPlayers = configAmountofPlayers; diff --git a/src/pc/network/network.h b/src/pc/network/network.h index 10cd992e..406858cd 100644 --- a/src/pc/network/network.h +++ b/src/pc/network/network.h @@ -68,7 +68,6 @@ struct ServerSettings { u8 playerKnockbackStrength; u8 stayInLevelAfterStar; u8 skipIntro; - u8 shareLives; u8 enableCheats; u8 bubbleDeath; u8 enablePlayersInLevelDisplay; diff --git a/src/pc/network/packets/packet_join.c b/src/pc/network/packets/packet_join.c index ff2ad27b..7d4f17d7 100644 --- a/src/pc/network/packets/packet_join.c +++ b/src/pc/network/packets/packet_join.c @@ -115,7 +115,6 @@ void network_send_join(struct Packet* joinRequestPacket) { packet_write(&p, &gServerSettings.playerKnockbackStrength, sizeof(u8)); packet_write(&p, &gServerSettings.stayInLevelAfterStar, sizeof(u8)); packet_write(&p, &gServerSettings.skipIntro, sizeof(u8)); - packet_write(&p, &gServerSettings.shareLives, sizeof(u8)); packet_write(&p, &gServerSettings.enableCheats, sizeof(u8)); packet_write(&p, &gServerSettings.bubbleDeath, sizeof(u8)); packet_write(&p, &gServerSettings.headlessServer, sizeof(u8)); @@ -166,7 +165,6 @@ void network_receive_join(struct Packet* p) { packet_read(p, &gServerSettings.playerKnockbackStrength, sizeof(u8)); packet_read(p, &gServerSettings.stayInLevelAfterStar, sizeof(u8)); packet_read(p, &gServerSettings.skipIntro, sizeof(u8)); - packet_read(p, &gServerSettings.shareLives, sizeof(u8)); packet_read(p, &gServerSettings.enableCheats, sizeof(u8)); packet_read(p, &gServerSettings.bubbleDeath, sizeof(u8)); packet_read(p, &gServerSettings.headlessServer, sizeof(u8));