[Scummvm-tracker] [ScummVM] #10605: ZVISION: ZGI: Stuck on the burning doll screen
Torbjörn Andersson
trac at scummvm.org
Sat Jun 30 17:29:23 CEST 2018
#10605: ZVISION: ZGI: Stuck on the burning doll screen
-------------------------+-----------------------
Reporter: eriktorbjorn | Owner: (none)
Type: defect | Status: new
Priority: normal | Component: --Unset--
Keywords: | Game:
-------------------------+-----------------------
If you bring up the inventory screen after lighting the inquisitor doll on
fire before anyone has yelled "Fire! Fire!", you will get stuck on that
screen. This appears to be yet another script bug.
In pe.scr, there is the following:
{{{
puzzle:17159 { # pe_fire_on_the_box
criteria {
[17160] = 1 # pe5e_fire_fire
}
results {
action:assign(17160, 0) # pe5e_fire_fire
action:timer:17161(15) # pe_fire
}
}
puzzle:17162 { # pe_fire_reset
criteria {
[17161] > 10 # pe_fire
}
results {
action:add(17161, -10) # pe_fire
action:timer:17161([17161]) # pe_fire
action:assign(17162, 0) # pe_fire_reset
}
flags {
once_per_inst
}
}
puzzle:17163 { # pe_play_alarm_vo
criteria {
[17161] = 2 # pe_fire
}
results {
action:assign(17161, 0) # pe_fire
action:crossfade(01011 01012 -1 0 55 0 500) # NULL
action:kill(01011) # voice_over
action:assign(01013, 16) # person_talking
action:universe_music:01011(0 pe5eh03p.raw 0 [17155]) #
pe_guard_current_volume
}
}
}}}
So the timer starts at 15, and as long as it's > 10 it will count down by
10. When it times out, it's automagically set to 2, which triggers the
"Fire! Fire!" sound.
But if the time is killed prematurely, it will write the remaining time
into the state value, like this:
{{{
TimerNode::~TimerNode() {
if (_key != StateKey_NotSet)
_engine->getScriptManager()->setStateValue(_key, 2);
int32 timeLeft = _timeLeft / (_engine->getGameId() == GID_NEMESIS
? 1000 : 100);
if (timeLeft > 0)
_engine->getScriptManager()->setStateValue(_key,
timeLeft); // If timer was stopped by stop or kill
}
}}}
So if the timer is killed while the remaining time is less than 10, the
timer will stop counting down.
--
Ticket URL: <https://bugs.scummvm.org/ticket/10605>
ScummVM <https://bugs.scummvm.org>
ScummVM
More information about the Scummvm-tracker
mailing list