mirror of
https://github.com/whoahq/whoa.git
synced 2026-11-10 08:33:10 +03:00
feat(sound): add SESoundInternal::GetVolume
This commit is contained in:
2 files changed
+17
No files matched your search
@@ -13,6 +13,22 @@ SESoundInternal::SESoundInternal() {
|
||||
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() {
|
||||
FMOD_RESULT result;
|
||||
|
||||
|
||||
@@ -50,6 +50,7 @@ class SESoundInternal : public TSLinkedNode<SESoundInternal> {
|
||||
|
||||
// Member functions
|
||||
SESoundInternal();
|
||||
float GetVolume();
|
||||
void Play();
|
||||
};
|
||||
|
||||
|
||||
Reference in new issue
Block a user