added delay before start playing sample to get chance for doComand

svn-id: r5109
This commit is contained in:
Paweł Kołodziejski 2002-10-08 14:32:19 +00:00
parent c10698a614
commit 15675e5652
2 changed files with 7 additions and 0 deletions

View File

@ -4866,6 +4866,11 @@ void IMuseDigital::handler() {
continue;
}
if (_channel[l]._delay > 0) {
_channel[l]._delay--;
continue;
}
if (_channel[l]._volumeFade != -1) {
if (_channel[l]._volumeFadeStep < 0) {
if (_channel[l]._volume > _channel[l]._volumeFade) {
@ -4991,6 +4996,7 @@ void IMuseDigital::startSound(int sound) {
_channel[l]._volume = 127;
_channel[l]._volumeFade = -1;
_channel[l]._volumeFadeParam = 0;
_channel[l]._delay = 1;
uint32 tag, size = 0, r, t;

View File

@ -85,6 +85,7 @@ private:
int8 _volumeFade;
int8 _volumeFadeParam;
int8 _volumeFadeStep;
uint32 _delay;
bool _isJump;
uint32 _numLoops;
uint32 _offsetStop;