Skip to content

Commit

Permalink
SoundUnit: fix sample map
Browse files Browse the repository at this point in the history
  • Loading branch information
tildearrow committed Oct 23, 2023
1 parent f4bb5f2 commit c0acd47
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/engine/platform/su.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -233,8 +233,7 @@ void DivPlatformSoundUnit::tick(bool sysTick) {
}
if (chan[i].keyOn) {
if (chan[i].pcm) {
DivInstrument* ins=parent->getIns(chan[i].ins,DIV_INS_SU);
int sNum=ins->amiga.getSample(chan[i].note);
int sNum=chan[i].sample;
DivSample* sample=parent->getSample(sNum);
if (sample!=NULL && sNum>=0 && sNum<parent->song.sampleLen) {
unsigned int sampleEnd=sampleOffSU[sNum]+(sample->getLoopEndPosition());
Expand Down

0 comments on commit c0acd47

Please sign in to comment.