mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Don't allow resending vote if you have delay
This commit is contained in:
parent
31728166ca
commit
d2960ce93d
1 changed files with 7 additions and 7 deletions
14
src/k_vote.c
14
src/k_vote.c
|
|
@ -1270,23 +1270,23 @@ static void Y_TickVoteSelection(void)
|
||||||
{
|
{
|
||||||
boolean moved = false;
|
boolean moved = false;
|
||||||
|
|
||||||
if (vote.players[i].delay)
|
|
||||||
{
|
|
||||||
vote.players[i].delay--;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (Y_PlayerCanSelect(i) == true)
|
if (Y_PlayerCanSelect(i) == true)
|
||||||
{
|
{
|
||||||
if (vote.timer == 0)
|
if (vote.players[i].delay > 0)
|
||||||
|
{
|
||||||
|
vote.players[i].delay--;
|
||||||
|
}
|
||||||
|
else if (vote.timer == 0)
|
||||||
{
|
{
|
||||||
// Time's up, send our vote ASAP.
|
// Time's up, send our vote ASAP.
|
||||||
if (vote.players[i].sentTimeOutVote == false)
|
if (vote.players[i].sentTimeOutVote == false)
|
||||||
{
|
{
|
||||||
Y_PlayerSendVote(i);
|
Y_PlayerSendVote(i);
|
||||||
vote.players[i].sentTimeOutVote = true;
|
vote.players[i].sentTimeOutVote = true;
|
||||||
|
vote.players[i].delay = NEWTICRATE/7;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (menuactive == false && vote.players[i].delay == 0)
|
else if (menuactive == false)
|
||||||
{
|
{
|
||||||
if (G_PlayerInputDown(i, gc_left, 0))
|
if (G_PlayerInputDown(i, gc_left, 0))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue