From 166ba1b38504264dafc295e3630333eff2bc136f Mon Sep 17 00:00:00 2001 From: Robert Göffringmann Date: Tue, 16 Dec 2003 19:55:59 +0000 Subject: fix speech animations svn-id: r11690 --- sword1/logic.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'sword1') diff --git a/sword1/logic.cpp b/sword1/logic.cpp index 48251066ab..c5d8077f56 100644 --- a/sword1/logic.cpp +++ b/sword1/logic.cpp @@ -317,10 +317,11 @@ int SwordLogic::speechDriver(BsObject *compact) { uint8 *animData = ((uint8*)_resMan->openFetchRes(compact->o_anim_resource)) + sizeof(Header); int32 numFrames = READ_LE_UINT32(animData); animData += 4; + compact->o_anim_pc++; // go to next frame of anim if (_speechFinished || (compact->o_anim_pc >= numFrames) || (_speechRunning && (_sound->amISpeaking() == 0))) - compact->o_anim_pc = 0; + compact->o_anim_pc = 0; //set to frame 0, closed mouth AnimUnit *animPtr = (AnimUnit*)(animData + sizeof(AnimUnit) * compact->o_anim_pc); if (!(compact->o_status & STAT_SHRINK)) { -- cgit v1.2.3