Skip to content

Commit

Permalink
Temporary desactivate FMODAudioEngine
Browse files Browse the repository at this point in the history
  • Loading branch information
Jouca committed Jun 4, 2024
1 parent 728149c commit 040a4eb
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
5 changes: 3 additions & 2 deletions src/Notifications/EventsPush.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,7 @@ bool EventsPush::init(sio::message::ptr const& data) {
diffFace = cocos2d::CCSprite::createWithSpriteFrameName(getDemonDifficultyIcon(starsum));
mythic = GJDifficultySprite::create(static_cast<int>(getDemonDifficulty(starsum)), static_cast<GJDifficultyName>(0));
}

diffFace->setPosition({26.f, 43.f});
diffFace->setScale(.8F);
CCSprite* star = cocos2d::CCSprite::createWithSpriteFrameName("star_small01_001.png");
Expand Down Expand Up @@ -709,8 +710,8 @@ bool EventsPush::init(sio::message::ptr const& data) {
nullptr
));

if (Mod::get()->getSettingValue<bool>("sfx") && type != 3 && type != 4) FMODAudioEngine::sharedEngine()->playEffect("crystal01.ogg");
if (Mod::get()->getSettingValue<bool>("sfx") && (type == 3 || type == 4)) FMODAudioEngine::sharedEngine()->playEffect("reward01.ogg");
/*if (Mod::get()->getSettingValue<bool>("sfx") && type != 3 && type != 4) FMODAudioEngine::sharedEngine()->playEffect("crystal01.ogg");
if (Mod::get()->getSettingValue<bool>("sfx") && (type == 3 || type == 4)) FMODAudioEngine::sharedEngine()->playEffect("reward01.ogg");*/

return true;
}
Expand Down
4 changes: 2 additions & 2 deletions src/Secret/VideoPlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ namespace videoplayer {
};

void VideoPlayer::initAudio() {
FMODAudioEngine* engine = FMODAudioEngine::sharedEngine();
/*FMODAudioEngine* engine = FMODAudioEngine::sharedEngine();
int sampleRate = plm_get_samplerate(m_stream);
Expand All @@ -142,7 +142,7 @@ namespace videoplayer {
m_channel->setVolume(m_volume);
m_channel->setUserData(this);
if (m_loop) m_channel->setCallback(&VideoPlayer::audioCallback);
if (m_loop) m_channel->setCallback(&VideoPlayer::audioCallback);*/
}

FMOD_RESULT F_CALLBACK videoplayer::VideoPlayer::audioCallback(FMOD_CHANNELCONTROL *chanControl, FMOD_CHANNELCONTROL_TYPE controlType, FMOD_CHANNELCONTROL_CALLBACK_TYPE callbackType, void *commandData1, void *commandData2) {
Expand Down
2 changes: 0 additions & 2 deletions src/Utils/SpotifyHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,6 @@ class $modify(EditorUI) {
void onPlaytest(CCObject* sender) {
EditorUI::onPlaytest(sender);
if (!Mod::get()->getSettingValue<bool>("inEditorSpotify")) return;
auto gm = FMODAudioEngine::sharedEngine();
//if (gm->m_backgroundMusicVolume > 0.0f) {
if (1 > 0.0F) { // temp until someone adds fields
toggleSpotifyMute();
Expand All @@ -274,7 +273,6 @@ class $modify(EditorUI) {
EditorUI::onPlayback(sender);
if (!Mod::get()->getSettingValue<bool>("inEditorSpotify")) return;

auto gm = FMODAudioEngine::sharedEngine();
//if (gm->m_backgroundMusicVolume > 0.0f) {
if (1 > 0.0F) { // temp until someone adds fields
toggleSpotifyMute();
Expand Down

0 comments on commit 040a4eb

Please sign in to comment.