From 340d515754197d2f54570760440740b25b25e12b Mon Sep 17 00:00:00 2001 From: katsy <205-katsy@users.noreply.git.do.srb2.org> Date: Sun, 29 Oct 2023 17:43:40 +0000 Subject: [PATCH] Fix for "Leader of the Chaotix" name change bug (credit Zwip Zwap Zapony) --- src/netcode/d_netcmd.c | 2 +- src/p_saveg.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/netcode/d_netcmd.c b/src/netcode/d_netcmd.c index 5afa95561..52df53b5a 100644 --- a/src/netcode/d_netcmd.c +++ b/src/netcode/d_netcmd.c @@ -1241,7 +1241,7 @@ static void SetColorLocal(INT32 playernum, UINT16 color) // static void SendNameAndColor(void) { - char buf[MAXPLAYERNAME+6]; + char buf[MAXPLAYERNAME+7]; char *p; p = buf; diff --git a/src/p_saveg.c b/src/p_saveg.c index faecd1377..4aa2318fd 100644 --- a/src/p_saveg.c +++ b/src/p_saveg.c @@ -175,7 +175,7 @@ static void P_NetArchivePlayers(void) WRITEUINT16(save_p, players[i].flashpal); WRITEUINT16(save_p, players[i].flashcount); - WRITEUINT8(save_p, players[i].skincolor); + WRITEUINT16(save_p, players[i].skincolor); WRITEINT32(save_p, players[i].skin); WRITEUINT32(save_p, players[i].availabilities); WRITEUINT32(save_p, players[i].score); @@ -404,7 +404,7 @@ static void P_NetUnArchivePlayers(void) players[i].flashpal = READUINT16(save_p); players[i].flashcount = READUINT16(save_p); - players[i].skincolor = READUINT8(save_p); + players[i].skincolor = READUINT16(save_p); players[i].skin = READINT32(save_p); players[i].availabilities = READUINT32(save_p); players[i].score = READUINT32(save_p);