Fix possible nullref if no fruits are ever caught

This commit is contained in:
smoogipoo 2018-07-26 21:00:18 +09:00
parent dc6898e7e0
commit 71c49de031

View File

@ -52,6 +52,9 @@ namespace osu.Game.Rulesets.Catch.UI
{
void runAfterLoaded(Action action)
{
if (lastPlateableFruit == null)
return;
// this is required to make this run after the last caught fruit runs UpdateState at least once.
// TODO: find a better alternative
if (lastPlateableFruit.IsLoaded)