Move title usages of towerbg to titlebg

With the previous commit in place, we can now simply move some usages of
the previous towerbg to use a separate object instead. That way, we
don't have to mess with a monolithic state, or some better way to phrase
what I just said, and we instead have two separate objects that can
coexist side-by-side.
This commit is contained in:
Misa
2020-11-02 15:23:53 -08:00
committed by Ethan Lee
parent 72c048d71e
commit 70f3d457dd
10 changed files with 54 additions and 44 deletions

View File

@@ -3292,7 +3292,7 @@ void editorrender()
{
if(!game.colourblindmode)
{
graphics.drawtowerbackground(graphics.towerbg);
graphics.drawtowerbackground(graphics.titlebg);
}
else
{
@@ -3679,8 +3679,8 @@ void editorlogic()
game.shouldreturntoeditor = false;
}
graphics.towerbg.bypos -= 2;
graphics.towerbg.bscroll = -2;
graphics.titlebg.bypos -= 2;
graphics.titlebg.bscroll = -2;
ed.entframedelay--;
if(ed.entframedelay<=0)
@@ -3740,14 +3740,14 @@ void editorlogic()
}
else if (!game.colourblindmode)
{
graphics.updatetowerbackground(graphics.towerbg);
graphics.updatetowerbackground(graphics.titlebg);
}
if (graphics.fademode == 1)
{
//Return to game
map.nexttowercolour();
graphics.towerbg.colstate = 10;
graphics.titlebg.colstate = 10;
game.gamestate = TITLEMODE;
script.hardreset();
graphics.fademode = 4;