mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Merge branch 'v2-master' into followme-internal
This commit is contained in:
commit
4eac7f8366
7 changed files with 21 additions and 19 deletions
|
|
@ -2773,8 +2773,8 @@ void CL_RemovePlayer(INT32 playernum, INT32 reason)
|
||||||
RemoveAdminPlayer(playernum); // don't stay admin after you're gone
|
RemoveAdminPlayer(playernum); // don't stay admin after you're gone
|
||||||
}
|
}
|
||||||
|
|
||||||
if (playernum == g_localplayers[0] && !demo.playback)
|
if (playernum == displayplayers[0] && !demo.playback)
|
||||||
g_localplayers[0] = consoleplayer; // don't look through someone's view who isn't there
|
displayplayers[0] = consoleplayer; // don't look through someone's view who isn't there
|
||||||
|
|
||||||
#ifdef HAVE_BLUA
|
#ifdef HAVE_BLUA
|
||||||
LUA_InvalidatePlayer(&players[playernum]);
|
LUA_InvalidatePlayer(&players[playernum]);
|
||||||
|
|
|
||||||
|
|
@ -1770,14 +1770,6 @@ void G_DoLoadLevel(boolean resetplayer)
|
||||||
if (!resetplayer)
|
if (!resetplayer)
|
||||||
P_FindEmerald();
|
P_FindEmerald();
|
||||||
|
|
||||||
g_localplayers[0] = consoleplayer; // view the guy you are playing
|
|
||||||
|
|
||||||
for (i = 0; i < MAXSPLITSCREENPLAYERS; i++)
|
|
||||||
{
|
|
||||||
if (i > 0 && r_splitscreen < i)
|
|
||||||
g_localplayers[i] = consoleplayer;
|
|
||||||
}
|
|
||||||
|
|
||||||
gameaction = ga_nothing;
|
gameaction = ga_nothing;
|
||||||
#ifdef PARANOIA
|
#ifdef PARANOIA
|
||||||
Z_CheckHeap(-2);
|
Z_CheckHeap(-2);
|
||||||
|
|
|
||||||
|
|
@ -739,6 +739,7 @@ static void Got_Saycmd(UINT8 **p, INT32 playernum)
|
||||||
{
|
{
|
||||||
const char *prefix = "", *cstart = "", *cend = "", *adminchar = "\x82~\x83", *remotechar = "\x82@\x83", *fmt2, *textcolor = "\x80";
|
const char *prefix = "", *cstart = "", *cend = "", *adminchar = "\x82~\x83", *remotechar = "\x82@\x83", *fmt2, *textcolor = "\x80";
|
||||||
char *tempchar = NULL;
|
char *tempchar = NULL;
|
||||||
|
char color_prefix[2];
|
||||||
|
|
||||||
if (players[playernum].spectator)
|
if (players[playernum].spectator)
|
||||||
{
|
{
|
||||||
|
|
@ -760,7 +761,8 @@ static void Got_Saycmd(UINT8 **p, INT32 playernum)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
cstart = "\x80" + (K_SkincolorToTextColor(players[playernum].skincolor) >> V_CHARCOLORSHIFT);
|
sprintf(color_prefix, "%c", '\x80' + (K_SkincolorToTextColor(players[playernum].skincolor) >> V_CHARCOLORSHIFT));
|
||||||
|
cstart = color_prefix;
|
||||||
}
|
}
|
||||||
|
|
||||||
prefix = cstart;
|
prefix = cstart;
|
||||||
|
|
|
||||||
|
|
@ -10049,8 +10049,9 @@ static void K_drawKartNameTags(void)
|
||||||
bary += (vid.height - (BASEVIDHEIGHT * vid.dupy)) / 2;
|
bary += (vid.height - (BASEVIDHEIGHT * vid.dupy)) / 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
V_DrawFill(barx, bary, barw, (3 * vid.dupy), colormap[31]|V_NOSCALESTART);
|
// Lat: 10/06/2020: colormap can be NULL on the frame you join a game, just arbitrarily use palette indexes 31 and 0 instead of whatever the colormap would give us instead to avoid crashes.
|
||||||
V_DrawFill(barx, bary + vid.dupy, barw, vid.dupy, colormap[0]|V_NOSCALESTART);
|
V_DrawFill(barx, bary, barw, (3 * vid.dupy), (colormap ? colormap[31] : 31)|V_NOSCALESTART);
|
||||||
|
V_DrawFill(barx, bary + vid.dupy, barw, vid.dupy, (colormap ? colormap[0] : 0)|V_NOSCALESTART);
|
||||||
// END DRAWFILL DUMBNESS
|
// END DRAWFILL DUMBNESS
|
||||||
|
|
||||||
// Draw the stem
|
// Draw the stem
|
||||||
|
|
|
||||||
12
src/m_menu.c
12
src/m_menu.c
|
|
@ -5494,7 +5494,11 @@ static void DrawReplayHutReplayInfo(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Character face!
|
// Character face!
|
||||||
if (W_CheckNumForName(skins[demolist[dir_on[menudepthleft]].standings[0].skin].facewant) != LUMPERROR)
|
|
||||||
|
// Lat: 08/06/2020: For some reason missing skins have their value set to 255 (don't even ask me why I didn't write this)
|
||||||
|
// and for an even STRANGER reason this passes the first check below, so we're going to make sure that the skin here ISN'T 255 before we do anything stupid.
|
||||||
|
|
||||||
|
if (demolist[dir_on[menudepthleft]].standings[0].skin != 0xFF && W_CheckNumForName(skins[demolist[dir_on[menudepthleft]].standings[0].skin].facewant) != LUMPERROR)
|
||||||
{
|
{
|
||||||
patch = facewantprefix[demolist[dir_on[menudepthleft]].standings[0].skin];
|
patch = facewantprefix[demolist[dir_on[menudepthleft]].standings[0].skin];
|
||||||
colormap = R_GetTranslationColormap(
|
colormap = R_GetTranslationColormap(
|
||||||
|
|
@ -5692,7 +5696,11 @@ static void M_DrawReplayStartMenu(void)
|
||||||
V_DrawString(BASEVIDWIDTH-92, STARTY + i*20 + 9, V_SNAPTOTOP, va("%d", demolist[dir_on[menudepthleft]].standings[i].timeorscore));
|
V_DrawString(BASEVIDWIDTH-92, STARTY + i*20 + 9, V_SNAPTOTOP, va("%d", demolist[dir_on[menudepthleft]].standings[i].timeorscore));
|
||||||
|
|
||||||
// Character face!
|
// Character face!
|
||||||
if (W_CheckNumForName(skins[demolist[dir_on[menudepthleft]].standings[i].skin].facerank) != LUMPERROR)
|
|
||||||
|
// Lat: 08/06/2020: For some reason missing skins have their value set to 255 (don't even ask me why I didn't write this)
|
||||||
|
// and for an even STRANGER reason this passes the first check below, so we're going to make sure that the skin here ISN'T 255 before we do anything stupid.
|
||||||
|
|
||||||
|
if (demolist[dir_on[menudepthleft]].standings[0].skin != 0xFF && W_CheckNumForName(skins[demolist[dir_on[menudepthleft]].standings[i].skin].facerank) != LUMPERROR)
|
||||||
{
|
{
|
||||||
patch = facerankprefix[demolist[dir_on[menudepthleft]].standings[i].skin];
|
patch = facerankprefix[demolist[dir_on[menudepthleft]].standings[i].skin];
|
||||||
colormap = R_GetTranslationColormap(
|
colormap = R_GetTranslationColormap(
|
||||||
|
|
|
||||||
|
|
@ -8235,8 +8235,8 @@ boolean P_SpectatorJoinGame(player_t *player)
|
||||||
player->playerstate = PST_REBORN;
|
player->playerstate = PST_REBORN;
|
||||||
|
|
||||||
//Reset away view
|
//Reset away view
|
||||||
if (P_IsLocalPlayer(player) && g_localplayers[0] != consoleplayer)
|
if (P_IsLocalPlayer(player) && displayplayers[0] != consoleplayer)
|
||||||
g_localplayers[0] = consoleplayer;
|
displayplayers[0] = consoleplayer;
|
||||||
|
|
||||||
HU_AddChatText(va(M_GetText("\x82*%s entered the game."), player_names[player-players]), false);
|
HU_AddChatText(va(M_GetText("\x82*%s entered the game."), player_names[player-players]), false);
|
||||||
return true; // no more player->mo, cannot continue.
|
return true; // no more player->mo, cannot continue.
|
||||||
|
|
|
||||||
|
|
@ -1909,7 +1909,6 @@ void V_DrawStringScaled(
|
||||||
if (!( flags & V_SNAPTOLEFT ))
|
if (!( flags & V_SNAPTOLEFT ))
|
||||||
{
|
{
|
||||||
left = ( right - BASEVIDWIDTH )/ 2;/* left edge of drawable area */
|
left = ( right - BASEVIDWIDTH )/ 2;/* left edge of drawable area */
|
||||||
x = ( left << FRACBITS )+ x;
|
|
||||||
right -= left;
|
right -= left;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue