mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 12:31:54 +00:00
Challenges Menu: Adjust ticker behaviour for flipping panels
- Handle beginning a flip in M_ChallengesTick - Removes set in M_ChallengesInput - Reduces complexity of set in M_ChallengesAutoFocus - Fixes an issue where starting the menu would have the tiles partly compacted during the intro wipe
This commit is contained in:
parent
afbea1ccc4
commit
91fa244dec
1 changed files with 5 additions and 12 deletions
|
|
@ -85,13 +85,9 @@ static void M_ChallengesAutoFocus(UINT8 unlockid, boolean fresh)
|
||||||
challengesmenu.row = challengesmenu.hiliy = i%CHALLENGEGRIDHEIGHT;
|
challengesmenu.row = challengesmenu.hiliy = i%CHALLENGEGRIDHEIGHT;
|
||||||
|
|
||||||
// Begin animation
|
// Begin animation
|
||||||
if (challengesmenu.extradata[i].flip == 0)
|
if (challengesmenu.pending)
|
||||||
{
|
{
|
||||||
challengesmenu.extradata[i].flip =
|
challengesmenu.extradata[i].flip = (TILEFLIP_MAX/2);
|
||||||
(challengesmenu.pending
|
|
||||||
? (TILEFLIP_MAX/2)
|
|
||||||
: 1
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fresh)
|
if (fresh)
|
||||||
|
|
@ -178,6 +174,7 @@ menu_t *M_InterruptMenuWithChallenges(menu_t *desiredmenu)
|
||||||
|
|
||||||
if (challengesmenu.pending || desiredmenu == NULL)
|
if (challengesmenu.pending || desiredmenu == NULL)
|
||||||
{
|
{
|
||||||
|
challengesmenu.ticker = 0;
|
||||||
challengesmenu.requestnew = false;
|
challengesmenu.requestnew = false;
|
||||||
challengesmenu.currentunlock = MAXUNLOCKABLES;
|
challengesmenu.currentunlock = MAXUNLOCKABLES;
|
||||||
challengesmenu.unlockcondition = NULL;
|
challengesmenu.unlockcondition = NULL;
|
||||||
|
|
@ -297,7 +294,7 @@ void M_ChallengesTick(void)
|
||||||
{
|
{
|
||||||
allthewaythrough = (!seeeveryone && !challengesmenu.pending && i != id);
|
allthewaythrough = (!seeeveryone && !challengesmenu.pending && i != id);
|
||||||
maxflip = ((seeeveryone || !allthewaythrough) ? (TILEFLIP_MAX/2) : TILEFLIP_MAX);
|
maxflip = ((seeeveryone || !allthewaythrough) ? (TILEFLIP_MAX/2) : TILEFLIP_MAX);
|
||||||
if ((seeeveryone || (challengesmenu.extradata[i].flip > 0))
|
if ((seeeveryone || (i == id) || (challengesmenu.extradata[i].flip > 0))
|
||||||
&& (challengesmenu.extradata[i].flip != maxflip))
|
&& (challengesmenu.extradata[i].flip != maxflip))
|
||||||
{
|
{
|
||||||
challengesmenu.extradata[i].flip++;
|
challengesmenu.extradata[i].flip++;
|
||||||
|
|
@ -629,13 +626,9 @@ boolean M_ChallengesInputs(INT32 ch)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
i = (challengesmenu.hilix * CHALLENGEGRIDHEIGHT) + challengesmenu.hiliy;
|
//i = (challengesmenu.hilix * CHALLENGEGRIDHEIGHT) + challengesmenu.hiliy;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Begin animation
|
|
||||||
if (challengesmenu.extradata[i].flip == 0)
|
|
||||||
challengesmenu.extradata[i].flip++;
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue