Fix Tower crash if background is missing (#525)
* Fix Tower crash if down background is missing oopsie * oh yeah, the up tower too
This commit is contained in:
parent
21f8ea4ff6
commit
78c90419e5
@ -156,9 +156,9 @@ namespace TJAPlayer3
|
||||
: downDirs[random.Next(0, downDirs.Length)];
|
||||
|
||||
DownScript = new ScriptBG($@"{downPath}{Path.DirectorySeparatorChar}Script.lua");
|
||||
DownScript.Init();
|
||||
DownScript?.Init();
|
||||
|
||||
IsDownNotFound = false;
|
||||
if (DownScript.Exists()) IsDownNotFound = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -296,8 +296,8 @@ namespace TJAPlayer3
|
||||
|
||||
if (!IsUpNotFound)
|
||||
{
|
||||
if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) UpScript.Update();
|
||||
UpScript.Draw();
|
||||
if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) UpScript?.Update();
|
||||
UpScript?.Draw();
|
||||
if (TJAPlayer3.stage選曲.n確定された曲の難易度[0] == (int)Difficulty.Tower)
|
||||
{
|
||||
#region [Tower animations variables]
|
||||
@ -643,8 +643,8 @@ namespace TJAPlayer3
|
||||
{
|
||||
if (!IsDownNotFound)
|
||||
{
|
||||
if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) DownScript.Update();
|
||||
DownScript.Draw();
|
||||
if (!TJAPlayer3.stage演奏ドラム画面.bPAUSE) DownScript?.Update();
|
||||
DownScript?.Draw();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user