Skip to content

Commit 584f2a8

Browse files
werwerwerwerwerwerwer's birthday
1 parent f9a0e1f commit 584f2a8

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/NoteField.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,11 @@ NoteField::Update(float fDeltaTime)
361361
{
362362
if (!this->GetVisible())
363363
return;
364+
if (!GAMESTATE->m_pCurSong) {
365+
this->DeleteAllChildren();
366+
return;
367+
}
368+
364369
if (m_bFirstUpdate) {
365370
m_pCurDisplay->m_ReceptorArrowRow.PlayCommand("On");
366371
}
@@ -824,6 +829,11 @@ NoteField::CalcPixelsBeforeAndAfterTargets()
824829
void
825830
NoteField::DrawPrimitives()
826831
{
832+
if (!GAMESTATE->m_pCurSong) {
833+
this->DeleteAllChildren();
834+
return;
835+
}
836+
827837
// LOG->Trace( "NoteField::DrawPrimitives()" );
828838

829839
// This should be filled in on the first update.

0 commit comments

Comments
 (0)