feat(sound): add SESoundInternal::GetVolume

This commit is contained in:
fallenoak 2025-11-26 23:28:05 -06:00
parent 0f9a2afe2a
commit 08dc4513af
No known key found for this signature in database
GPG Key ID: 7628F8E61AEA070D
2 changed files with 17 additions and 0 deletions

View File

@ -13,6 +13,22 @@ SESoundInternal::SESoundInternal() {
this->m_uniqueID = SESound::s_UniqueID++; this->m_uniqueID = SESound::s_UniqueID++;
} }
float SESoundInternal::GetVolume() {
if (!SESound::s_Initialized) {
return 0.0f;
}
float volume = this->m_volume;
if (this->m_fadeIn || this->m_fadeOut) {
volume *= this->m_fadeVolume;
}
// TODO
return volume;
}
void SESoundInternal::Play() { void SESoundInternal::Play() {
FMOD_RESULT result; FMOD_RESULT result;

View File

@ -50,6 +50,7 @@ class SESoundInternal : public TSLinkedNode<SESoundInternal> {
// Member functions // Member functions
SESoundInternal(); SESoundInternal();
float GetVolume();
void Play(); void Play();
}; };