mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2024-11-25 13:35:12 +00:00
Fix custom coopdx server settings working in coop lobbies
This commit is contained in:
parent
3af855b440
commit
641c2f4159
2 changed files with 27 additions and 16 deletions
|
@ -231,7 +231,7 @@ bool exec_chat_command(char* command) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (gServerSettings.nametags) {
|
||||||
if (strcmp("/nametags", command) == 0) {
|
if (strcmp("/nametags", command) == 0) {
|
||||||
djui_chat_message_create(DLANG(CHAT, NAMETAGS_MISSING_PARAMETERS));
|
djui_chat_message_create(DLANG(CHAT, NAMETAGS_MISSING_PARAMETERS));
|
||||||
return true;
|
return true;
|
||||||
|
@ -246,6 +246,7 @@ bool exec_chat_command(char* command) {
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef DEVELOPMENT
|
#ifdef DEVELOPMENT
|
||||||
if (exec_dev_chat_command(command)) {
|
if (exec_dev_chat_command(command)) {
|
||||||
|
@ -267,7 +268,9 @@ void display_chat_commands(void) {
|
||||||
djui_chat_message_create(DLANG(CHAT, MOD_DESC));
|
djui_chat_message_create(DLANG(CHAT, MOD_DESC));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (gServerSettings.nametags) {
|
||||||
djui_chat_message_create(DLANG(CHAT, NAMETAGS_DESC));
|
djui_chat_message_create(DLANG(CHAT, NAMETAGS_DESC));
|
||||||
|
}
|
||||||
#ifdef DEVELOPMENT
|
#ifdef DEVELOPMENT
|
||||||
dev_display_chat_commands();
|
dev_display_chat_commands();
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -164,14 +164,22 @@ void network_receive_join(struct Packet* p) {
|
||||||
packet_read(p, &myGlobalIndex, sizeof(u8));
|
packet_read(p, &myGlobalIndex, sizeof(u8));
|
||||||
packet_read(p, &gCurrSaveFileNum, sizeof(s16));
|
packet_read(p, &gCurrSaveFileNum, sizeof(s16));
|
||||||
packet_read(p, &gServerSettings.playerInteractions, sizeof(u8));
|
packet_read(p, &gServerSettings.playerInteractions, sizeof(u8));
|
||||||
if (!gCoopCompatibility) { packet_read(p, &gServerSettings.bouncyLevelBounds, sizeof(u8)); }
|
if (!gCoopCompatibility) {
|
||||||
|
packet_read(p, &gServerSettings.bouncyLevelBounds, sizeof(u8));
|
||||||
|
} else {
|
||||||
|
gServerSettings.bouncyLevelBounds = BOUNCY_LEVEL_BOUNDS_OFF;
|
||||||
|
}
|
||||||
packet_read(p, &gServerSettings.playerKnockbackStrength, sizeof(u8));
|
packet_read(p, &gServerSettings.playerKnockbackStrength, sizeof(u8));
|
||||||
packet_read(p, &gServerSettings.stayInLevelAfterStar, sizeof(u8));
|
packet_read(p, &gServerSettings.stayInLevelAfterStar, sizeof(u8));
|
||||||
packet_read(p, &gServerSettings.skipIntro, sizeof(u8));
|
packet_read(p, &gServerSettings.skipIntro, sizeof(u8));
|
||||||
packet_read(p, &gServerSettings.enableCheats, sizeof(u8));
|
packet_read(p, &gServerSettings.enableCheats, sizeof(u8));
|
||||||
packet_read(p, &gServerSettings.bubbleDeath, sizeof(u8));
|
packet_read(p, &gServerSettings.bubbleDeath, sizeof(u8));
|
||||||
packet_read(p, &gServerSettings.headlessServer, sizeof(u8));
|
packet_read(p, &gServerSettings.headlessServer, sizeof(u8));
|
||||||
if (!gCoopCompatibility) { packet_read(p, &gServerSettings.nametags, sizeof(u8)); }
|
if (!gCoopCompatibility) {
|
||||||
|
packet_read(p, &gServerSettings.nametags, sizeof(u8));
|
||||||
|
} else {
|
||||||
|
gServerSettings.nametags = false;
|
||||||
|
}
|
||||||
packet_read(p, &gServerSettings.maxPlayers, sizeof(u8));
|
packet_read(p, &gServerSettings.maxPlayers, sizeof(u8));
|
||||||
packet_read(p, eeprom, sizeof(u8) * 512);
|
packet_read(p, eeprom, sizeof(u8) * 512);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue