Skip to content

Commit

Permalink
prevent crash on notefield preview when no steps exists
Browse files Browse the repository at this point in the history
  • Loading branch information
poco0317 committed Nov 5, 2021
1 parent 7b23352 commit c3747c6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Etterna/Actor/Gameplay/ArrowEffects.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -341,6 +341,8 @@ ArrowEffects::GetYOffset(const PlayerState* pPlayerState,

const auto fSongBeat = position.m_fSongBeatVisible;
Steps* pCurSteps = GAMESTATE->m_pCurSteps;
if (pCurSteps == nullptr)
return 0.F;

/* Usually, fTimeSpacing is 0 or 1, in which case we use entirely beat
* spacing or entirely time spacing (respectively). Occasionally, we tween
Expand Down

0 comments on commit c3747c6

Please sign in to comment.