mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 01:59:43 +01:00
Update activity prompt fade in fixed-timestep gamelogic()
Otherwise it goes by too quickly.
This commit is contained in:
parent
e897543383
commit
92ee33043d
2 changed files with 16 additions and 6 deletions
|
@ -1479,4 +1479,20 @@ void gamelogic()
|
|||
game.returntoeditor();
|
||||
}
|
||||
#endif
|
||||
|
||||
if (game.activeactivity > -1)
|
||||
{
|
||||
if (game.act_fade < 5)
|
||||
{
|
||||
game.act_fade = 5;
|
||||
}
|
||||
if (game.act_fade < 10)
|
||||
{
|
||||
game.act_fade++;
|
||||
}
|
||||
}
|
||||
else if (game.act_fade > 5)
|
||||
{
|
||||
game.act_fade--;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1635,11 +1635,6 @@ void gamerender()
|
|||
game.activity_r = obj.blocks[game.activeactivity].r;
|
||||
game.activity_g = obj.blocks[game.activeactivity].g;
|
||||
game.activity_b = obj.blocks[game.activeactivity].b;
|
||||
if(game.act_fade<5) game.act_fade=5;
|
||||
if(game.act_fade<10)
|
||||
{
|
||||
game.act_fade++;
|
||||
}
|
||||
graphics.drawtextbox(16, 4, 36, 3, game.activity_r*(game.act_fade/10.0f), game.activity_g*(game.act_fade/10.0f), game.activity_b*(game.act_fade/10.0f));
|
||||
graphics.Print(5, 12, game.activity_lastprompt, game.activity_r*(game.act_fade/10.0f), game.activity_g*(game.act_fade/10.0f), game.activity_b*(game.act_fade/10.0f), true);
|
||||
}
|
||||
|
@ -1649,7 +1644,6 @@ void gamerender()
|
|||
{
|
||||
graphics.drawtextbox(16, 4, 36, 3, game.activity_r*(game.act_fade/10.0f), game.activity_g*(game.act_fade/10.0f), game.activity_b*(game.act_fade/10.0f));
|
||||
graphics.Print(5, 12, game.activity_lastprompt, game.activity_r*(game.act_fade/10.0f), game.activity_g*(game.act_fade/10.0f), game.activity_b*(game.act_fade/10.0f), true);
|
||||
game.act_fade--;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue