mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
commit throwdir fix
I did a bunch of other demo-related cleanup in this branch so I'm throwing it in here too
This commit is contained in:
parent
a46036e489
commit
53848bd5fa
3 changed files with 0 additions and 28 deletions
14
src/g_game.c
14
src/g_game.c
|
|
@ -2368,21 +2368,7 @@ void G_Ticker(boolean run)
|
|||
|
||||
if (playeringame[i])
|
||||
{
|
||||
//@TODO all this throwdir stuff shouldn't be here! But it stays for now to maintain 1.0.4 compat...
|
||||
// Remove for 1.1!
|
||||
|
||||
// SRB2kart
|
||||
// Save the dir the player is holding
|
||||
// to allow items to be thrown forward or backward.
|
||||
if (cmd->buttons & BT_FORWARD)
|
||||
players[i].kartstuff[k_throwdir] = 1;
|
||||
else if (cmd->buttons & BT_BACKWARD)
|
||||
players[i].kartstuff[k_throwdir] = -1;
|
||||
else
|
||||
players[i].kartstuff[k_throwdir] = 0;
|
||||
|
||||
G_CopyTiccmd(cmd, &netcmds[buf][i], 1);
|
||||
|
||||
// Use the leveltime sent in the player's ticcmd to determine control lag
|
||||
cmd->latency = modeattacking ? 0 : min(((leveltime & 0xFF) - cmd->latency) & 0xFF, MAXPREDICTTICS-1); //@TODO add a cvar to allow setting this max
|
||||
}
|
||||
|
|
|
|||
11
src/p_tick.c
11
src/p_tick.c
|
|
@ -620,18 +620,7 @@ void P_Ticker(boolean run)
|
|||
G_ReadDemoExtraData();
|
||||
for (i = 0; i < MAXPLAYERS; i++)
|
||||
if (playeringame[i])
|
||||
{
|
||||
//@TODO all this throwdir stuff shouldn't be here! But it's added to maintain 1.0.4 compat for now...
|
||||
// Remove for 1.1!
|
||||
if (players[i].cmd.buttons & BT_FORWARD)
|
||||
players[i].kartstuff[k_throwdir] = 1;
|
||||
else if (players[i].cmd.buttons & BT_BACKWARD)
|
||||
players[i].kartstuff[k_throwdir] = -1;
|
||||
else
|
||||
players[i].kartstuff[k_throwdir] = 0;
|
||||
|
||||
G_ReadDemoTiccmd(&players[i].cmd, i);
|
||||
}
|
||||
}
|
||||
|
||||
for (i = 0; i < MAXPLAYERS; i++)
|
||||
|
|
|
|||
|
|
@ -8136,8 +8136,6 @@ void P_PlayerThink(player_t *player)
|
|||
|
||||
cmd = &player->cmd;
|
||||
|
||||
//@TODO This fixes a one-tic latency on direction handling, AND makes behavior consistent while paused, but is not BC with 1.0.4. Do this for 1.1!
|
||||
#if 0
|
||||
// SRB2kart
|
||||
// Save the dir the player is holding
|
||||
// to allow items to be thrown forward or backward.
|
||||
|
|
@ -8147,7 +8145,6 @@ void P_PlayerThink(player_t *player)
|
|||
player->kartstuff[k_throwdir] = -1;
|
||||
else
|
||||
player->kartstuff[k_throwdir] = 0;
|
||||
#endif
|
||||
|
||||
// Add some extra randomization.
|
||||
if (cmd->forwardmove)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue