flycast icon indicating copy to clipboard operation
flycast copied to clipboard

The Maze of the Kings (NAOMI GD-ROM): Repeating and cut off SFX

Open RavenMacDaddy opened this issue 2 years ago • 6 comments

Platform / OS / Hardware:

Windows 11 - 22000.376 Ryzen 3600 GTX 1080 - driver 497.29

Github hash: 7555263 (v1.2)

Description of the Issue

The Sega NAOMI GD-ROM game The Maze of the Kings seems to have been a tricky one to emulate, especially sound-wise.

The most apparent area being the first boss with a waterfall in the background.

As you hit the waterfall while shooting the triangles being fired at you, the intended SFX will start to disappear and repeat more and more, and after a while, it will only play the sound of hitting the waterfall.

The game overall gets its SFX cut off and repeated constantly - the above is simply a great example.

The same exact issues were seen in the now-old DEMUL emulator.

Debugging Steps Tested

  • Playing with DSP enabled and disabled (didn't see anything else of importance, especially since this has been a problem for seemingly all emulators).

Logs Gathered

00:13:118 hw\mem\_vmem.cpp:505 N[VMEM]: Info: nvmem is enabled, with addr space of size 512MB
00:13:142 hw\mem\_vmem.cpp:505 N[VMEM]: Info: nvmem is enabled, with addr space of size 512MB
00:18:393 hw\naomi\naomi_cart.cpp:367 N[NAOMI]: NAOMI GAME ID [THE MAZE OF THE KINGS]
00:18:394 emulator.cpp:227 N[BOOT]: Game ID is [THE MAZE OF THE KINGS]

RavenMacDaddy avatar Jan 05 '22 07:01 RavenMacDaddy

I tested with the latest build and didn't notice any audio issue. I fixed an audio problem recently that used to affect Demul as well. So it's possible it fixed this problem as well.

Let me know if the issue persists with the latest build (77a2bbbb8dc707fb26d8da425f203329b532d726).

flyinghead avatar Apr 30 '22 14:04 flyinghead

image

The issue is still there - I appreciate you working on it.

image

This is the problematic area.

I'm pretty sure there are other areas as well, but that's at least one of the first where it's really noticeable.

RavenMacDaddy avatar Apr 30 '22 16:04 RavenMacDaddy

The issue persists in the latest nightly build [76bf574]. I can upload a save state if it would make testing easier. The first level sounds all fine until the first boss. From then on the bug happens sporadically in all subsequent levels. It only seems to affect gunfire and enemy hit reactions. Music, voices and cutscenes sound okay, so it may give the false impression that everything is normal.

Also, I did some digging: the last version of demul (0.7 apr 28 2018) does not have this bug.

superblobster avatar Jul 21 '22 01:07 superblobster

I was able to reproduce it but I have no idea what could be the cause.

flyinghead avatar Jul 26 '22 07:07 flyinghead

With the latest builds (started testing again with the release of NAOMI 2 support - great job BTW), currently running aa97a6d and e0d87eb, the issue is more severe - cutting SFX already when only shooting at enemies and the floor/walls, no water involved (i.e., more SFX involved).

Hopefully it provides some clues to what's the cause; some recent change might've made it worse.

Attempting to find exactly in which build it happened led to a dead end, cause both the oldest and newest commits under master and dev respectively give the same results.

...or maybe it's simply been a while since I last played the game, and I'm hallucinating that the issue has gotten worse when in reality it's unchanged.

RavenMacDaddy avatar Sep 02 '22 12:09 RavenMacDaddy

I don't think any recent change would have any effect on this bug. One not-so-recent change could however: the clock speed of the audio cpu was doubled to fix a naomi 2 bug. This could have made things worse for this bug.

flyinghead avatar Sep 02 '22 12:09 flyinghead

Should be fixed in the latest dev build.

flyinghead avatar Dec 31 '23 11:12 flyinghead

Indeed, it seems to be — fantastic job!

I'll let you know if the issue creeps up in the feature — closing as completed.

RavenMacDaddy avatar Jan 02 '24 11:01 RavenMacDaddy