[Scummvm-tracker] [ScummVM :: Bugs] #13335: AGS: Quest for Glory II: Trial by Fire Remake - Winning Keapon Laffin's Game causes crash

ScummVM :: Bugs trac at scummvm.org
Mon May 29 03:26:18 UTC 2023


#13335: AGS: Quest for Glory II: Trial by Fire Remake - Winning Keapon Laffin's
Game causes crash
---------------------+--------------------------------
Reporter:  bliznik   |       Owner:  (none)
    Type:  defect    |      Status:  new
Priority:  normal    |   Component:  Engine: AGS
 Version:            |  Resolution:
Keywords:  AGD:QFG2  |        Game:  Quest for Glory 2
---------------------+--------------------------------
Comment (by PushmePullyu):

 It looks like the problem occurred when an auto save was triggered during
 loading of a new room after the wizard game:
 old engines/ags/shared/game/room_struct.cpp (from
 [https://github.com/scummvm/scummvm/commit/5d9ae41cd6569f046ec2113e7d3bd213a90e5cce
 5d9ae41cd6569f046ec2113e7d3bd213a90e5cce]):

 {{{
 AGS3::AGS::Shared::load_room(...) {
   room->Free(); // <----------------------- room background frames are
 zeroed here
   room->InitDefaults();  // <-------------- and not set here

   update_polled_stuff_if_runtime(); // <--- this can trigger a queued auto
 save event
   /* room loading code is here */ // <----- before the room is loaded here
 }
 }}}

 The auto save code would eventually call
 "AGS3::create_savegame_screenshot()".
 This lead to an attempt to draw the current room with background frames
 set to 0, thus causing the crash.

 If this is correct, the bug should be fixed since commit
 [https://github.com/scummvm/scummvm/commit/c366ce5eefbd01435f063a4efe9d828a1d648f0c
 c366ce5eefbd01435f063a4efe9d828a1d648f0c]
 (which removes the "update_polled_stuff_if_runtime()" call).
-- 
Ticket URL: <https://bugs.scummvm.org/ticket/13335#comment:6>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM


More information about the Scummvm-tracker mailing list