mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-02-21 04:51:45 +00:00
G_MapIntoRoundQueue: Seperate into a general append function *and* a specific placement function. A surprise tool that will help us later
This commit is contained in:
parent
371c52d457
commit
a1065d9036
2 changed files with 12 additions and 5 deletions
16
src/g_game.c
16
src/g_game.c
|
|
@ -3991,6 +3991,16 @@ static void G_HandleSaveLevel(void)
|
|||
// Next map apparatus
|
||||
struct roundqueue roundqueue;
|
||||
|
||||
void G_MapSlipIntoRoundQueue(UINT8 position, UINT16 map, UINT8 setgametype, boolean setencore, boolean rankrestricted)
|
||||
{
|
||||
I_Assert(position < ROUNDQUEUE_MAX);
|
||||
|
||||
roundqueue.entries[position].mapnum = map;
|
||||
roundqueue.entries[position].gametype = setgametype;
|
||||
roundqueue.entries[position].encore = setencore;
|
||||
roundqueue.entries[position].rankrestricted = rankrestricted;
|
||||
}
|
||||
|
||||
void G_MapIntoRoundQueue(UINT16 map, UINT8 setgametype, boolean setencore, boolean rankrestricted)
|
||||
{
|
||||
if (roundqueue.size >= ROUNDQUEUE_MAX)
|
||||
|
|
@ -3999,11 +4009,7 @@ void G_MapIntoRoundQueue(UINT16 map, UINT8 setgametype, boolean setencore, boole
|
|||
return;
|
||||
}
|
||||
|
||||
roundqueue.entries[roundqueue.size].mapnum = map;
|
||||
roundqueue.entries[roundqueue.size].gametype = setgametype;
|
||||
roundqueue.entries[roundqueue.size].encore = setencore;
|
||||
roundqueue.entries[roundqueue.size].rankrestricted = rankrestricted;
|
||||
|
||||
G_MapSlipIntoRoundQueue(roundqueue.size, map, setgametype, setencore, rankrestricted);
|
||||
roundqueue.size++;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -72,6 +72,7 @@ extern struct roundqueue
|
|||
roundentry_t entries[ROUNDQUEUE_MAX]; // Entries in the round queue
|
||||
} roundqueue;
|
||||
|
||||
void G_MapSlipIntoRoundQueue(UINT8 position, UINT16 map, UINT8 setgametype, boolean setencore, boolean rankrestricted);
|
||||
void G_MapIntoRoundQueue(UINT16 map, UINT8 setgametype, boolean setencore, boolean rankrestricted);
|
||||
void G_GPCupIntoRoundQueue(cupheader_t *cup, UINT8 setgametype, boolean setencore);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue