Ticket #8044: samsound.diff

File samsound.diff, 2.1 KB (added by eriktorbjorn, 18 years ago)

Patch against a September 11 CVS snapshot

  • scummvm/scumm/sound.cpp

    diff -ur ScummVM-cvs20020911/scummvm/scumm/sound.cpp ScummVM-cvs20020911+hack/scummvm/scumm/sound.cpp
    old new  
    382382        bool b, finished;
    383383
    384384        if (_talk_sound_mode != 0) {
    385                 if (_talk_sound_mode == 2)
    386                         _talkChannel = startTalkSound(_talk_sound_a, _talk_sound_b, _talk_sound_mode);
    387                 else
    388                         startTalkSound(_talk_sound_a, _talk_sound_b, _talk_sound_mode);
     385                if (_talk_sound_mode & 1)
     386
     387                        startTalkSound(_talk_sound_a1, _talk_sound_b1, 1);
     388                if (_talk_sound_mode & 2)
     389                        _talkChannel = startTalkSound(_talk_sound_a2, _talk_sound_b2, 2);
    389390                _talk_sound_mode = 0;
    390391        }
    391392
     
    623624}
    624625
    625626void Sound::talkSound(uint32 a, uint32 b, int mode, int frame) {
    626         _talk_sound_a = a;
    627         _talk_sound_b = b;
    628         _talk_sound_mode = mode;
     627        if (mode == 1) {
     628                _talk_sound_a1 = a;
     629                _talk_sound_b1 = b;
     630        } else {
     631                _talk_sound_a2 = a;
     632                _talk_sound_b2 = b;
     633        }
     634
    629635        _talk_sound_frame = frame;
     636        _talk_sound_mode |= mode;
    630637}
    631638
    632639/* The sound code currently only supports General Midi.
  • scummvm/scumm/sound.h

    diff -ur ScummVM-cvs20020911/scummvm/scumm/sound.h ScummVM-cvs20020911+hack/scummvm/scumm/sound.h
    old new  
    5454
    5555        int _talkChannel;       /* Mixer channel actor is talking on */
    5656        File *_sfxFile;
    57         uint32 _talk_sound_a, _talk_sound_b;
     57        uint32 _talk_sound_a1, _talk_sound_a2, _talk_sound_b1, _talk_sound_b2;
    5858        byte _talk_sound_mode;
    5959        int _talk_sound_frame;
    6060        bool _mouthSyncMode;
  • scummvm/scumm/string.cpp

    diff -ur ScummVM-cvs20020911/scummvm/scumm/string.cpp ScummVM-cvs20020911+hack/scummvm/scumm/string.cpp
    old new  
    294294        }
    295295
    296296        if (a && !string[0].no_talk_anim) {
    297 //              a->startAnimActor(a->talkFrame1);
    298297                has_anim = true;
    299298                _useTalkAnims = true;
    300299        }