Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions data/file_list.yml
Original file line number Diff line number Diff line change
Expand Up @@ -280404,19 +280404,19 @@ Library/Se/Project/SePlayParam.o:
label:
- _ZN2al11SePlayParamC1Ev
- _ZN2al11SePlayParamC2Ev
status: NotDecompiled
status: Matching
- offset: 0x9e8fb0
size: 16
label: _ZN2al11SePlayParam5resetEv
status: NotDecompiled
status: Matching
- offset: 0x9e8fc0
size: 16
label: _ZN2al11SePlayParam3setENS_15SePlayParamTypeEff
status: NotDecompiled
status: Matching
- offset: 0x9e8fd0
size: 24
label: _ZN2al11SePlayParam6setMulENS_15SePlayParamTypeEff
status: NotDecompiled
status: Matching
Library/Se/Project/SePlayParamList.o:
'.text':
- offset: 0x9e8fe8
Expand Down
28 changes: 28 additions & 0 deletions lib/al/Library/Se/Project/SePlayParam.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#include "Library/Se/Project/SePlayParam.h"

namespace al {

SePlayParam::SePlayParam() {
reset();
}

void SePlayParam::reset() {
mType = SePlayParamType::Invalid;
mValue = 1.0f;
mValue2 = 0.0f;
}

void SePlayParam::set(SePlayParamType type, f32 value, f32 value2) {
mType = type;
mValue = value;
mValue2 = value2;
}

void SePlayParam::setMul(SePlayParamType type, f32 value, f32 value2) {
f32 mul = mValue * value;
mType = type;
mValue2 = value2;
mValue = mul;
}

} // namespace al
35 changes: 35 additions & 0 deletions lib/al/Library/Se/Project/SePlayParam.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#pragma once

#include <basis/seadTypes.h>

namespace al {

enum class SePlayParamType {
Invalid,
Volume,
Pitch,
SeqTempoRatio,
EffectSend,
SeqLocalVariable,
SeqGlobalVariable,
LpfFreq,
BiquadFilter,
};

class SePlayParam {
public:
SePlayParam();

void reset();
void set(SePlayParamType type, f32 value, f32 value2);
void setMul(SePlayParamType type, f32 value, f32 value2);

private:
SePlayParamType mType;
f32 mValue;
f32 mValue2;
};

static_assert(sizeof(SePlayParam) == 0xC);

} // namespace al