DQ4R130 hangs after activating some events after displaying custom menu #989

fdelapena opened this Issue Aug 12, 2016 · 1 comment


None yet

2 participants

fdelapena commented Aug 12, 2016 edited

This game got reported multiple times via Android app email bug report with some hanging issues. At first, it was just a hang after sleeping, however this game has some more general issue. Thanks carstene1ns for finding this game and also thanks to T. Kashiwabara for insisting with this game bug report.

Name of the game:

Dragon Quest IV: The Legend of Rivast 1.30.

Savegame: Save01.lsd.zip

Menu option

Describe the issue in detail and how to reproduce it:

Enter to the town and find the inn place around the bottom part. There is an NPC seller with 5 chests and an NPC to trigger the inn call.

At least the following ways are hanging the game for me:

Step 1 (option A)

  • Talk with the chests NPC by pressing the decision key and select the first (default) option of 8 available, then select the first (default again) to buy.

Step 1 (option B)

  • Talk with the INN NPC by pressing the decision key and select the first (default) option of 8 available, then select any of two options to buy or cancel.

Step 2 (option A)

  • Try going upstairs to any other map or to the vessel (except overworld map).

Step 2 (option B)

  • Try pressing the decision key in the same map.

Then, the actor will stop moving and custom menu won't be accessible.

You can try any option from the step 1 then any option from the step 2 to hang it, however:

  • It does not hang if you go to the overworld map and return again.
  • There is some difference in the command from the chest NPC because canceling compared to the INN NPC because the cancel option there does not trigger the hang issue.
Zegeri commented Aug 16, 2016

This is caused by a race condition between two parallel common events. One of the events shows the dialogue messages and the other prepares the rest of the UI. The former expects the latter to have finished before reaching certain commands, but this isn't always the case. The first issue with Player is that all parallel common events wait while there are messages of the other common events. This has been fixed in 3779ad3. There's another issue in KeyInputProc, that gets fixed by 2d2c9c4.

Even after these two commits, you can still get this hang if you rush through the dialogue fast enough. In fact, you can get this hang also with RPG_RT.exe, but you must start it in TestPlay mode, hold the Shift key and mash the Enter key while you talk to the NPC. However, you can do this in Player outside of TestPlay mode. I noticed that the message text appeared much faster in Player than in RPG_RT. On the default speed, Player shows 2 character per frame, while RPG_RT seems to show 1 full-width character or 2 half-width character per frame. After implementing this behaviour f6eb5f4, the situation gets much better. It's still possible to hang the game if you go too fast through the dialogue, though.

@fdelapena fdelapena added this to the 0.5.0 milestone Aug 16, 2016
@Ghabry Ghabry closed this in #999 Aug 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment