Make it past kart & mixer files

This commit is contained in:
Sally Coolatta 2021-03-01 01:13:03 -05:00
parent 885b7673eb
commit 1619efec82
4 changed files with 27 additions and 3 deletions

View file

@ -134,6 +134,9 @@ static INT16 consistancy[TICQUEUE];
static UINT8 player_joining = false; static UINT8 player_joining = false;
UINT8 hu_redownloadinggamestate = 0; UINT8 hu_redownloadinggamestate = 0;
// kart, true when a player is connecting or disconnecting so that the gameplay has stopped in its tracks
boolean hu_stopped = false;
UINT8 adminpassmd5[16]; UINT8 adminpassmd5[16];
boolean adminpasswordset = false; boolean adminpasswordset = false;
@ -5317,8 +5320,14 @@ void TryRunTics(tic_t realtics)
} }
#endif #endif
if (neededtic > gametic)
{
hu_stopped = false;
}
if (player_joining) if (player_joining)
{ {
hu_stopped = true;
return; return;
} }
@ -5332,6 +5341,7 @@ void TryRunTics(tic_t realtics)
D_StartTitle(); D_StartTitle();
} }
else else
{
// run the count * tics // run the count * tics
while (neededtic > gametic) while (neededtic > gametic)
{ {
@ -5350,6 +5360,11 @@ void TryRunTics(tic_t realtics)
if (client && gamestate == GS_LEVEL && leveltime > 3 && neededtic <= gametic + cv_netticbuffer.value) if (client && gamestate == GS_LEVEL && leveltime > 3 && neededtic <= gametic + cv_netticbuffer.value)
break; break;
} }
}
}
else
{
hu_stopped = true;
} }
} }

View file

@ -524,6 +524,12 @@ extern UINT8 hu_redownloadinggamestate;
extern UINT8 adminpassmd5[16]; extern UINT8 adminpassmd5[16];
extern boolean adminpasswordset; extern boolean adminpasswordset;
//
// SRB2Kart
//
extern boolean hu_stopped;
typedef struct rewind_s { typedef struct rewind_s {
UINT8 savebuffer[(768*1024)]; UINT8 savebuffer[(768*1024)];
tic_t leveltime; tic_t leveltime;

View file

@ -792,6 +792,7 @@ static INT16 K_FindBotController(mobj_t *mo)
msecnode_t *node; msecnode_t *node;
ffloor_t *rover; ffloor_t *rover;
INT16 lineNum = -1; INT16 lineNum = -1;
mtag_t tag;
I_Assert(mo != NULL); I_Assert(mo != NULL);
I_Assert(!P_MobjWasRemoved(mo)); I_Assert(!P_MobjWasRemoved(mo));
@ -803,7 +804,8 @@ static INT16 K_FindBotController(mobj_t *mo)
continue; continue;
} }
lineNum = P_FindSpecialLineFromTag(2004, node->m_sector->tag, -1); tag = Tag_FGet(&node->m_sector->tags);
lineNum = P_FindSpecialLineFromTag(2004, tag, -1); // todo: needs to not use P_FindSpecialLineFromTag
if (lineNum != -1) if (lineNum != -1)
{ {
@ -825,7 +827,8 @@ static INT16 K_FindBotController(mobj_t *mo)
} }
rs = &sectors[rover->secnum]; rs = &sectors[rover->secnum];
lineNum = P_FindSpecialLineFromTag(2004, rs->tag, -1); tag = Tag_FGet(&rs->tags);
lineNum = P_FindSpecialLineFromTag(2004, tag, -1);
if (lineNum != -1) if (lineNum != -1)
{ {

View file

@ -3217,7 +3217,7 @@ static void P_ConvertBinaryMap(void)
break; break;
case 2001: // MT_WAYPOINT case 2001: // MT_WAYPOINT
{ {
INT32 firstline = P_FindSpecialLineFromTag(2000, mapthings[i].angle, -1); INT32 firstline = Tag_FindLineSpecial(2000, (INT16)mapthings[i].angle);
Tag_FSet(&mapthings[i].tags, mapthings[i].angle); Tag_FSet(&mapthings[i].tags, mapthings[i].angle);
mapthings[i].args[0] = mapthings[i].z; mapthings[i].args[0] = mapthings[i].z;