[Scummvm-git-logs] scummvm master -> e2e0431adc533dd43f5613464cfac53c4013ed13
whiterandrek
whiterandrek at gmail.com
Mon Oct 12 21:31:25 UTC 2020
This automated email contains information about 3 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
77ad33ad8e PETKA: fix sound balance in dialogs
9e5729d6fb PETKA: implement sound balance for objects
e2e0431adc PETKA: implement sound balance for hero
Commit: 77ad33ad8e4c54a46aa3ac2abbdbc5ec1866dc93
https://github.com/scummvm/scummvm/commit/77ad33ad8e4c54a46aa3ac2abbdbc5ec1866dc93
Author: Andrei Prykhodko (whiterandrek at gmail.com)
Date: 2020-10-13T00:26:29+03:00
Commit Message:
PETKA: fix sound balance in dialogs
Changed paths:
engines/petka/interfaces/dialog_interface.cpp
diff --git a/engines/petka/interfaces/dialog_interface.cpp b/engines/petka/interfaces/dialog_interface.cpp
index cf3a6b17b2..a5ec7178d7 100644
--- a/engines/petka/interfaces/dialog_interface.cpp
+++ b/engines/petka/interfaces/dialog_interface.cpp
@@ -198,7 +198,7 @@ void DialogInterface::playSound(const Common::String &name) {
FlicDecoder *flc = g_vm->resMgr()->loadFlic(_talker->_resourceId);
if (flc) {
Common::Rect bounds = flc->getBounds();
- s->setBalance(bounds.left + _talker->_x + bounds.width(), 640);
+ s->setBalance(bounds.left + _talker->_x + bounds.width(), _qsys->_sceneWidth);
}
s->play(false);
}
Commit: 9e5729d6fb98d35ab320c5af70ce71912034bb2b
https://github.com/scummvm/scummvm/commit/9e5729d6fb98d35ab320c5af70ce71912034bb2b
Author: Andrei Prykhodko (whiterandrek at gmail.com)
Date: 2020-10-13T00:29:37+03:00
Commit Message:
PETKA: implement sound balance for objects
Changed paths:
engines/petka/objects/object.cpp
diff --git a/engines/petka/objects/object.cpp b/engines/petka/objects/object.cpp
index 8577b4fa48..026c0790dd 100644
--- a/engines/petka/objects/object.cpp
+++ b/engines/petka/objects/object.cpp
@@ -520,6 +520,11 @@ void QObject::update(int time) {
_time += time;
FlicDecoder *flc = g_vm->resMgr()->loadFlic(_resourceId);
if (flc && flc->getFrameCount() != 1) {
+ if (_sound) {
+ Common::Rect bounds = flc->getBounds();
+ _sound->setBalance(bounds.left + bounds.width() / 2 - g_vm->getQSystem()->_xOffset, 640);
+ }
+
while (_time >= (int32)flc->getDelay()) {
if (_sound && flc->getCurFrame() == 0) {
_startSound = true;
Commit: e2e0431adc533dd43f5613464cfac53c4013ed13
https://github.com/scummvm/scummvm/commit/e2e0431adc533dd43f5613464cfac53c4013ed13
Author: Andrei Prykhodko (whiterandrek at gmail.com)
Date: 2020-10-13T00:31:05+03:00
Commit Message:
PETKA: implement sound balance for hero
Changed paths:
engines/petka/objects/heroes.cpp
diff --git a/engines/petka/objects/heroes.cpp b/engines/petka/objects/heroes.cpp
index 5775a9fa60..724bb4a2e7 100644
--- a/engines/petka/objects/heroes.cpp
+++ b/engines/petka/objects/heroes.cpp
@@ -322,6 +322,11 @@ void QObjectPetka::update(int time) {
_time += time;
FlicDecoder *flc = g_vm->resMgr()->loadFlic(_resourceId);
if (flc && flc->getFrameCount() != 1) {
+ if (_sound) {
+ Common::Rect bounds = flc->getBounds();
+ _sound->setBalance(bounds.left + bounds.width() / 2 - g_vm->getQSystem()->_xOffset, 640);
+ }
+
while (_time >= (int)flc->getDelay()) {
if (_sound && flc->getCurFrame() == 0) {
_startSound = true;
More information about the Scummvm-git-logs
mailing list