summaryrefslogtreecommitdiff
path: root/libs/JSystem/src/JAudio2/JAUSoundAnimator.cpp
blob: 21d97eeb1a91565c2aacc4caf97f564682a5fcb4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//
// Translation Unit: JAUSoundAnimator
//

#include "JSystem/JSystem.h" // IWYU pragma: keep

#include "JSystem/JAudio2/JAUSoundAnimator.h"

int JAUSoundAnimation::getStartSoundIndex(f32 param_0) const {
    int i;
    for (i = 0; i < getNumSounds(); i++) {
        if (getSound(i)->field_0x04 >= param_0) {
            break;
        }
    }
    return i;
}

int JAUSoundAnimation::getEndSoundIndex(f32 param_0) const {
    int i;
    for (i = 0; i < getNumSounds(); i++) {
        if (getSound(i)->field_0x04 > param_0) {
            break;
        }
    }
    return i;
}