This commit is contained in:
Dan Balasescu 2017-06-26 23:05:35 +09:00 committed by GitHub
parent cbf188c293
commit 803bb3c780
1 changed files with 3 additions and 4 deletions

View File

@ -12,7 +12,6 @@ public class BackgroundScreenDefault : BackgroundScreen
private int currentDisplay; private int currentDisplay;
private const int background_count = 5; private const int background_count = 5;
private string backgroundName => $@"Menu/menu-background-{currentDisplay % background_count + 1}"; private string backgroundName => $@"Menu/menu-background-{currentDisplay % background_count + 1}";
private Background current; private Background current;
@ -23,12 +22,12 @@ private void load()
display(new Background(backgroundName)); display(new Background(backgroundName));
} }
private void display(Background b) private void display(Background newBackground)
{ {
current?.FadeOut(800, EasingTypes.OutQuint); current?.FadeOut(800, EasingTypes.OutQuint);
current?.Expire(); current?.Expire();
Add(current = b); Add(current = newBackground);
} }
public void Next() public void Next()