mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-12-27 04:41:23 +00:00
Accommodate Kart splitscreen code for CHAT via #define NETSPLITSCREEN
This commit is contained in:
parent
0f0e30924f
commit
fb3722a6f3
3 changed files with 21 additions and 16 deletions
|
@ -22,6 +22,7 @@
|
|||
#define MAXNETNODES 32
|
||||
#define BROADCASTADDR MAXNETNODES
|
||||
#define MAXSPLITSCREENPLAYERS 2 // Max number of players on a single computer
|
||||
//#define NETSPLITSCREEN // Kart's splitscreen netgame feature
|
||||
|
||||
#define STATLENGTH (TICRATE*2)
|
||||
|
||||
|
|
|
@ -1488,27 +1488,27 @@ static void HU_drawChatLog(INT32 offset)
|
|||
if (chat_scroll > chat_maxscroll)
|
||||
chat_scroll = chat_maxscroll;
|
||||
|
||||
/*if (splitscreen)
|
||||
#ifdef NETSPLITSCREEN
|
||||
if (splitscreen)
|
||||
{
|
||||
boxh = max(6, boxh/2);
|
||||
if (splitscreen > 1)
|
||||
boxw = max(64, boxw/2);
|
||||
}*/
|
||||
|
||||
// Unused SRB2KART splitscreen stuff. I'll leave it here in case it ever happens in Vanilla?
|
||||
}
|
||||
#endif
|
||||
|
||||
y = chaty - offset*charheight - (chat_scroll*charheight) - boxh*charheight - 12;
|
||||
|
||||
/*if (splitscreen)
|
||||
#ifdef NETSPLITSCREEN
|
||||
if (splitscreen)
|
||||
{
|
||||
y -= BASEVIDHEIGHT/2;
|
||||
if (splitscreen > 1)
|
||||
y += 16;
|
||||
}*/
|
||||
}
|
||||
#endif
|
||||
y -= (G_RingSlingerGametype() ? 16 : 0);
|
||||
|
||||
// Unused SRB2KART splitscreen stuff. I'll leave it here in case it ever happens in Vanilla? (x2)
|
||||
|
||||
|
||||
chat_topy = y + chat_scroll*charheight;
|
||||
chat_bottomy = chat_topy + boxh*charheight;
|
||||
|
@ -1607,7 +1607,8 @@ static void HU_DrawChat(void)
|
|||
const char *talk = ntalk;
|
||||
const char *mute = "Chat has been muted.";
|
||||
|
||||
/*if (splitscreen)
|
||||
#ifdef NETSPLITSCREEN
|
||||
if (splitscreen)
|
||||
{
|
||||
y -= BASEVIDHEIGHT/2;
|
||||
if (splitscreen > 1)
|
||||
|
@ -1615,11 +1616,10 @@ static void HU_DrawChat(void)
|
|||
y += 16;
|
||||
boxw = max(64, boxw/2);
|
||||
}
|
||||
}*/
|
||||
}
|
||||
#endif
|
||||
y -= (G_RingSlingerGametype() ? 16 : 0);
|
||||
|
||||
// More unused SRB2KART stuff.
|
||||
|
||||
if (teamtalk)
|
||||
{
|
||||
talk = ttalk;
|
||||
|
@ -1703,16 +1703,16 @@ static void HU_DrawChat(void)
|
|||
{
|
||||
INT32 count = 0;
|
||||
INT32 p_dispy = chaty - charheight -1;
|
||||
/*if (splitscreen)
|
||||
#ifdef NETSPLITSCREEN
|
||||
if (splitscreen)
|
||||
{
|
||||
p_dispy -= BASEVIDHEIGHT/2;
|
||||
if (splitscreen > 1)
|
||||
p_dispy += 16;
|
||||
}*/
|
||||
}
|
||||
#endif
|
||||
p_dispy -= (G_RingSlingerGametype() ? 16 : 0);
|
||||
|
||||
// more kart leftovers.
|
||||
|
||||
i = 0;
|
||||
for(i=0; (i<MAXPLAYERS); i++)
|
||||
{
|
||||
|
|
|
@ -58,7 +58,11 @@ typedef struct
|
|||
//------------------------------------
|
||||
#define HU_MAXMSGLEN 224
|
||||
#define CHAT_BUFSIZE 64 // that's enough messages, right? We'll delete the older ones when that gets out of hand.
|
||||
#ifdef NETSPLITSCREEN
|
||||
#define OLDCHAT (cv_consolechat.value == 1 || dedicated || vid.width < 640)
|
||||
#else
|
||||
#define OLDCHAT (!splitscreen && (cv_consolechat.value == 1 || dedicated || vid.width < 640))
|
||||
#endif
|
||||
#define CHAT_MUTE (cv_mute.value && !(server || IsPlayerAdmin(consoleplayer))) // this still allows to open the chat but not to type. That's used for scrolling and whatnot.
|
||||
#define OLD_MUTE (OLDCHAT && cv_mute.value && !(server || IsPlayerAdmin(consoleplayer))) // this is used to prevent oldchat from opening when muted.
|
||||
|
||||
|
|
Loading…
Reference in a new issue