mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Merge public master
This commit is contained in:
commit
053a99718a
3 changed files with 32 additions and 3 deletions
|
|
@ -4303,7 +4303,11 @@ boolean SV_SpawnServer(void)
|
||||||
|
|
||||||
// strictly speaking, i'm not convinced the following is necessary
|
// strictly speaking, i'm not convinced the following is necessary
|
||||||
// but I'm not confident enough to remove it entirely in case it breaks something
|
// but I'm not confident enough to remove it entirely in case it breaks something
|
||||||
{
|
|
||||||
|
// in a listen server, this sends the local player information to the server so
|
||||||
|
// that the client has players replicated on the server. in dedicated, there is
|
||||||
|
// no local player!
|
||||||
|
if (!dedicated) {
|
||||||
UINT8 *availabilitiesbuffer = R_GetSkinAvailabilities(false, -1);
|
UINT8 *availabilitiesbuffer = R_GetSkinAvailabilities(false, -1);
|
||||||
SINT8 node = 0;
|
SINT8 node = 0;
|
||||||
for (; node < MAXNETNODES; node++)
|
for (; node < MAXNETNODES; node++)
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,7 @@
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
#include "r_fps.h"
|
||||||
#include "v_video.h"
|
#include "v_video.h"
|
||||||
#include "z_zone.h"
|
#include "z_zone.h"
|
||||||
|
|
||||||
|
|
@ -65,6 +66,7 @@ typedef struct drawitem_s {
|
||||||
INT32 threshold;
|
INT32 threshold;
|
||||||
boolean bossmode;
|
boolean bossmode;
|
||||||
boolean p4;
|
boolean p4;
|
||||||
|
enum viewcontext_e splitnum; // save view number to account for splitscreen
|
||||||
} drawitem_t;
|
} drawitem_t;
|
||||||
|
|
||||||
// The internal structure of a drawlist.
|
// The internal structure of a drawlist.
|
||||||
|
|
@ -202,6 +204,7 @@ void LUA_HUD_AddDraw(
|
||||||
item->patch = patch;
|
item->patch = patch;
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
item->colormap = colormap;
|
item->colormap = colormap;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawScaled(
|
void LUA_HUD_AddDrawScaled(
|
||||||
|
|
@ -223,6 +226,7 @@ void LUA_HUD_AddDrawScaled(
|
||||||
item->patch = patch;
|
item->patch = patch;
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
item->colormap = colormap;
|
item->colormap = colormap;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawStretched(
|
void LUA_HUD_AddDrawStretched(
|
||||||
|
|
@ -246,6 +250,7 @@ void LUA_HUD_AddDrawStretched(
|
||||||
item->patch = patch;
|
item->patch = patch;
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
item->colormap = colormap;
|
item->colormap = colormap;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawNum(
|
void LUA_HUD_AddDrawNum(
|
||||||
|
|
@ -263,6 +268,7 @@ void LUA_HUD_AddDrawNum(
|
||||||
item->y = y;
|
item->y = y;
|
||||||
item->num = num;
|
item->num = num;
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawPaddedNum(
|
void LUA_HUD_AddDrawPaddedNum(
|
||||||
|
|
@ -282,6 +288,7 @@ void LUA_HUD_AddDrawPaddedNum(
|
||||||
item->num = num;
|
item->num = num;
|
||||||
item->digits = digits;
|
item->digits = digits;
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawPingNum(
|
void LUA_HUD_AddDrawPingNum(
|
||||||
|
|
@ -301,6 +308,7 @@ void LUA_HUD_AddDrawPingNum(
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
item->num = num;
|
item->num = num;
|
||||||
item->colormap = colormap;
|
item->colormap = colormap;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawFill(
|
void LUA_HUD_AddDrawFill(
|
||||||
|
|
@ -320,6 +328,7 @@ void LUA_HUD_AddDrawFill(
|
||||||
item->w = w;
|
item->w = w;
|
||||||
item->h = h;
|
item->h = h;
|
||||||
item->c = c;
|
item->c = c;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawString(
|
void LUA_HUD_AddDrawString(
|
||||||
|
|
@ -339,6 +348,7 @@ void LUA_HUD_AddDrawString(
|
||||||
item->stroffset = CopyString(list, str);
|
item->stroffset = CopyString(list, str);
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
item->align = align;
|
item->align = align;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddFadeScreen(
|
void LUA_HUD_AddFadeScreen(
|
||||||
|
|
@ -352,6 +362,7 @@ void LUA_HUD_AddFadeScreen(
|
||||||
item->type = DI_FadeScreen;
|
item->type = DI_FadeScreen;
|
||||||
item->color = color;
|
item->color = color;
|
||||||
item->strength = strength;
|
item->strength = strength;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawTitleCardString(
|
void LUA_HUD_AddDrawTitleCardString(
|
||||||
|
|
@ -377,6 +388,7 @@ void LUA_HUD_AddDrawTitleCardString(
|
||||||
item->timer = timer;
|
item->timer = timer;
|
||||||
item->threshold = threshold;
|
item->threshold = threshold;
|
||||||
item->p4 = p4;
|
item->p4 = p4;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddDrawKartString(
|
void LUA_HUD_AddDrawKartString(
|
||||||
|
|
@ -394,6 +406,7 @@ void LUA_HUD_AddDrawKartString(
|
||||||
item->y = y;
|
item->y = y;
|
||||||
item->stroffset = CopyString(list, str);
|
item->stroffset = CopyString(list, str);
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddSetClipRect(
|
void LUA_HUD_AddSetClipRect(
|
||||||
|
|
@ -413,6 +426,7 @@ void LUA_HUD_AddSetClipRect(
|
||||||
item->w = w;
|
item->w = w;
|
||||||
item->h = h;
|
item->h = h;
|
||||||
item->flags = flags;
|
item->flags = flags;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_AddClearClipRect(
|
void LUA_HUD_AddClearClipRect(
|
||||||
|
|
@ -422,6 +436,7 @@ void LUA_HUD_AddClearClipRect(
|
||||||
size_t i = AllocateDrawItem(list);
|
size_t i = AllocateDrawItem(list);
|
||||||
drawitem_t *item = &list->items[i];
|
drawitem_t *item = &list->items[i];
|
||||||
item->type = DI_ClearClipRect;
|
item->type = DI_ClearClipRect;
|
||||||
|
item->splitnum = R_GetViewNumber();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LUA_HUD_DrawList(huddrawlist_h list)
|
void LUA_HUD_DrawList(huddrawlist_h list)
|
||||||
|
|
@ -436,6 +451,10 @@ void LUA_HUD_DrawList(huddrawlist_h list)
|
||||||
{
|
{
|
||||||
drawitem_t *item = &list->items[i];
|
drawitem_t *item = &list->items[i];
|
||||||
const char *itemstr = &list->strbuf[item->stroffset];
|
const char *itemstr = &list->strbuf[item->stroffset];
|
||||||
|
enum viewcontext_e old_viewcontext = viewcontext;
|
||||||
|
|
||||||
|
// Set view context to account for V_SPLITSCREEN
|
||||||
|
R_SetViewContext(item->splitnum);
|
||||||
|
|
||||||
switch (item->type)
|
switch (item->type)
|
||||||
{
|
{
|
||||||
|
|
@ -514,5 +533,8 @@ void LUA_HUD_DrawList(huddrawlist_h list)
|
||||||
I_Error("can't draw draw list item: invalid draw list item type");
|
I_Error("can't draw draw list item: invalid draw list item type");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Reset view context back, just incase of some stupid shenanigans
|
||||||
|
R_SetViewContext(old_viewcontext);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9508,6 +9508,7 @@ void Command_dumprrautomedaltimes(void)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
fclose(out);
|
fclose(out);
|
||||||
|
CONS_Printf("Medal times written to %s\n", outname);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Command_Platinums(void)
|
void Command_Platinums(void)
|
||||||
|
|
@ -9558,8 +9559,10 @@ void Command_Platinums(void)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
CONS_Printf(", %s (+%d:%02d)", stafftime.second.c_str(),
|
CONS_Printf(", %s (+%d:%02d:%02d)", stafftime.second.c_str(),
|
||||||
G_TicsToSeconds(stafftime.first - platinumtime), G_TicsToCentiseconds(stafftime.first - platinumtime));
|
G_TicsToMinutes(stafftime.first - platinumtime, true),
|
||||||
|
G_TicsToSeconds(stafftime.first - platinumtime),
|
||||||
|
G_TicsToCentiseconds(stafftime.first - platinumtime));
|
||||||
}
|
}
|
||||||
|
|
||||||
names[stafftime.second]++;
|
names[stafftime.second]++;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue