Netcode Overhaul
Rewrote netcode to be more stable and functional. Packet-server mode has been restrategized and will now be the default netmode when playing with 3+ non-LAN players. TryRunTics has been cleaned up with older tick control behavior removed to account for the rewritten renderer. The main thread is now more consistent when playing online to prevent potential slow downs and lock ups. Load barriers are better accounted for to prevent spikes on level transition. Improvements to chat and lobby systems including a force start game button. Added a suite of new host options such as kicking and controlling who can pause the game. Max players increased from 8 to 16 since the new code can now handle it. Note: Demo functionality is untested. This will be rewritten at a later time alongside improvements to GZDoom's playback features (e.g. freecam mode).
This commit is contained in:
parent
abfd91e8f1
commit
94be307225
45 changed files with 3119 additions and 2669 deletions
|
|
@ -2572,7 +2572,7 @@ static double P_XYMovement (AActor *mo, DVector2 scroll)
|
|||
{ // slide against wall
|
||||
if (BlockingLine != NULL &&
|
||||
mo->player && mo->waterlevel && mo->waterlevel < 3 &&
|
||||
(mo->player->cmd.ucmd.forwardmove | mo->player->cmd.ucmd.sidemove) &&
|
||||
(mo->player->cmd.forwardmove | mo->player->cmd.sidemove) &&
|
||||
mo->BlockingLine->sidedef[1] != NULL)
|
||||
{
|
||||
double spd = mo->FloatVar(NAME_WaterClimbSpeed);
|
||||
|
|
@ -2811,7 +2811,7 @@ static double P_XYMovement (AActor *mo, DVector2 scroll)
|
|||
// moving corresponding player:
|
||||
if (fabs(mo->Vel.X) < STOPSPEED && fabs(mo->Vel.Y) < STOPSPEED
|
||||
&& (!player || (player->mo != mo)
|
||||
|| !(player->cmd.ucmd.forwardmove | player->cmd.ucmd.sidemove)))
|
||||
|| !(player->cmd.forwardmove | player->cmd.sidemove)))
|
||||
{
|
||||
// if in a walking frame, stop moving
|
||||
// killough 10/98:
|
||||
|
|
@ -3273,7 +3273,7 @@ void AActor::FallAndSink(double grav, double oldfloorz)
|
|||
double startvelz = Vel.Z;
|
||||
|
||||
if (waterlevel == 0 || (player &&
|
||||
!(player->cmd.ucmd.forwardmove | player->cmd.ucmd.sidemove)))
|
||||
!(player->cmd.forwardmove | player->cmd.sidemove)))
|
||||
{
|
||||
// [RH] Double gravity only if running off a ledge. Coming down from
|
||||
// an upward thrust (e.g. a jump) should not double it.
|
||||
|
|
@ -6101,7 +6101,7 @@ AActor *FLevelLocals::SpawnPlayer (FPlayerStart *mthing, int playernum, int flag
|
|||
p->cheats = CF_CHASECAM;
|
||||
|
||||
// setup gun psprite
|
||||
if (!(flags & SPF_TEMPPLAYER))
|
||||
if (!(flags & SPF_TEMPPLAYER) || oldactor == nullptr)
|
||||
{ // This can also start a script so don't do it for the dummy player.
|
||||
P_SetupPsprites (p, !!(flags & SPF_WEAPONFULLYUP));
|
||||
}
|
||||
|
|
@ -6156,7 +6156,7 @@ AActor *FLevelLocals::SpawnPlayer (FPlayerStart *mthing, int playernum, int flag
|
|||
}
|
||||
|
||||
// [BC] Do script stuff
|
||||
if (!(flags & SPF_TEMPPLAYER))
|
||||
if (!(flags & SPF_TEMPPLAYER) || oldactor == nullptr)
|
||||
{
|
||||
if (state == PST_ENTER || (state == PST_LIVE && !savegamerestore))
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue