MCPcopy Create free account
hub / github.com/HertzDevil/0CC-FamiTracker / Step

Method Step

Source/SeqInstHandler.cpp:216–241  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

214}
215
216void CSeqInstHandler::seq_info_t::Step(bool isReleasing) {
217 ++m_iSeqPointer;
218 int Release = m_pSequence->GetReleasePoint();
219 int Items = m_pSequence->GetItemCount();
220 int Loop = m_pSequence->GetLoopPoint();
221 if (m_iSeqPointer == (Release + 1) || m_iSeqPointer >= Items) {
222 // End point reached
223 if (Loop != -1 && !(isReleasing && Release != -1) && Loop < Release) { // // //
224 m_iSeqPointer = Loop;
225 }
226 else if (m_iSeqPointer >= Items) {
227 // End of sequence
228 if (Loop >= Release && Loop != -1) // // //
229 m_iSeqPointer = Loop;
230 else
231 m_iSeqState = seq_state_t::End;
232 }
233 else if (!isReleasing) {
234 // Waiting for release
235 --m_iSeqPointer;
236 }
237 }
238#ifndef FT0CC_EXT_BUILD
239 FTEnv.GetSoundGenerator()->SetSequencePlayPos(m_pSequence, m_iSeqPointer);
240#endif
241}

Callers 1

UpdateInstrumentMethod · 0.45

Calls 5

GetReleasePointMethod · 0.80
GetLoopPointMethod · 0.80
SetSequencePlayPosMethod · 0.80
GetItemCountMethod · 0.45
GetSoundGeneratorMethod · 0.45

Tested by

no test coverage detected