From bc314e42c42cc2a7c9d1e8cbc61626fbbdeff60d Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Wed, 21 Aug 2002 20:41:01 +0000 Subject: [PATCH] Don't let sample offest of length go negative (crashes RageAudio and doesn't make sense anyway) --- stepmania/src/ScreenEdit.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/stepmania/src/ScreenEdit.cpp b/stepmania/src/ScreenEdit.cpp index 50194b5a7a..493a454836 100644 --- a/stepmania/src/ScreenEdit.cpp +++ b/stepmania/src/ScreenEdit.cpp @@ -934,6 +934,7 @@ void ScreenEdit::InputEdit( const DeviceInput& DeviceI, const InputEventType typ } m_pSong->m_fMusicSampleStartSeconds += fOffsetDelta; + m_pSong->m_fMusicSampleStartSeconds = max(m_pSong->m_fMusicSampleStartSeconds,0); } break; case DIK_SUBTRACT: @@ -953,6 +954,7 @@ void ScreenEdit::InputEdit( const DeviceInput& DeviceI, const InputEventType typ } m_pSong->m_fMusicSampleLengthSeconds += fDelta; + m_pSong->m_fMusicSampleLengthSeconds = max(m_pSong->m_fMusicSampleLengthSeconds,0); } break; }