What's Going on with This Music? (Wizards & Warriors III)

Discuss NSF files, FamiTracker, MML tools, or anything else related to NES music.

Moderator: Moderators

User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

Dacicus wrote: Fri Feb 10, 2023 1:42 pm If you want to check it out without playing through the entire game, you can give yourself the gems by placing values 0x07 through 0x0A in the inventory slots $0657-065A in RAM.
That's very helpful, thanks. Is there really no sound test of any kind where I can check the music without playing through the game? Otherwise, I might resort to overwriting the song index in memory.
User avatar
Jedi QuestMaster
Posts: 688
Joined: Thu Sep 07, 2006 1:08 pm
Location: United States
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by Jedi QuestMaster »

Wow, TakuikaNinja! You didn't have to do all this work for a game you haven't even played while also on vacation. :o

As for other glitched music, I'm not sure if this one's intentional or not: the pause music loops indefinitely on the NSF I have, but in-game it loops four times then cuts off two channels mid note, then plays the other channel four more times before going silent. I think they may have done this because, otherwise, the short loop would be annoying to listen to while taking a break.

However, once I noticed the short blip before the notes cut off, I can't unnotice it. Not sure if this is a simple fix?
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

Jedi QuestMaster wrote: Sun Feb 12, 2023 11:04 pm Wow, TakuikaNinja! You didn't have to do all this work for a game you haven't even played while also on vacation. :o

As for other glitched music, I'm not sure if this one's intentional or not: the pause music loops indefinitely on the NSF I have, but in-game it loops four times then cuts off two channels mid note, then plays the other channel four more times before going silent. I think they may have done this because, otherwise, the short loop would be annoying to listen to while taking a break.

However, once I noticed the short blip before the notes cut off, I can't unnotice it. Not sure if this is a simple fix?
I've just returned home yesterday. Track 18 in the NSF I have exhibits the behaviour. I'll have a look at it now.
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

From what I've observed so far, it has something to do with the status register ($4015 write). The channels are still processed but they get disabled for some reason.
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

There's an explicit track number check in the play routine before writing to the status register, so this must be a deliberate choice. The timing for the status changes are handled using a frame counter variable, which is mostly detached from the tempo system. I think that explains the odd cut-offs being observed. The frame counter checks are hard-coded to $1D0 and $3B4, so I could tweak those values to make the cut-off less obvious.
Last edited by TakuikaNinja on Thu Feb 16, 2023 10:52 pm, edited 1 time in total.
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

The best result was obtained with the values $1DD & $3B8, which aren't too far off from the used values. This seems to be yet another symptom of the rushed development period. Attached is the NSF file with the fixes so far.
Attachments
Wizards & Warriors III - Kuros - Visions of Power (Music Fix Test).nsf
(32.11 KiB) Downloaded 50 times
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

Dacicus wrote: Fri Feb 10, 2023 1:42 pm I've always thought that it was the intended music, since the slowing happens just about when you reach the boss or the corridor leading to the boss. It certainly does sound like an error based on the fix that TakuikaNinja implemented, though. But now the fixed part seems to last for too short a time, IMO.
Let me elaborate my reasoning for the tempo I chose. My guess is that the error was caused by a typo when using assembler macros. Let's say the tempo change macro was something like this (asm6 format):

Code: Select all

macro change_tempo arg0
clc
lda tempo
adc arg0
sta tempo
endm
Perhaps the macro was used in that instance with the assumption that it explicitly set the tempo, like this? (a separate name is used here for clarity)

Code: Select all

macro set_tempo arg0
lda arg0
sta tempo
endm
$6F is used as the tempo in a similar sounding section in another song, so I assumed the intended tempo change was $-1B ($6F unsigned).

Following that train of thought, what if a sign symbol was inserted by mistake? Setting $-6F ($91 unsigned) as the argument would change the tempo to $1B, which is what is observed in the final release.
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

TakuikaNinja wrote: Thu Feb 16, 2023 10:16 pm There's an explicit track number check in the play routine before writing to the status register, so this must be a deliberate choice. The timing for the status changes are handled using a frame counter variable, which is mostly detached from the tempo system. I think that explains the odd cut-offs being observed. The frame counter checks are hard-coded to $1D0 and $3B4, so I could tweak those values to make the cut-off less obvious.
Never mind, the track check isn't present in the actual game, so this must've been an addition by the ripper to remove the reliance on the pause function. I had to decrease the counter check values by 2 ($1DB & $3B6), so something must've been changed when ripping the NSF.
Dacicus
Posts: 32
Joined: Sat Dec 20, 2008 4:59 pm

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by Dacicus »

TakuikaNinja wrote: Fri Feb 10, 2023 7:17 pmIs there really no sound test of any kind where I can check the music without playing through the game?
No sound test that I know of, but I personally have not done much along the lines of attempting to hack the music.
TakuikaNinja wrote: Thu Feb 16, 2023 10:52 pm
Dacicus wrote: Fri Feb 10, 2023 1:42 pm I've always thought that it was the intended music, since the slowing happens just about when you reach the boss or the corridor leading to the boss. It certainly does sound like an error based on the fix that TakuikaNinja implemented, though. But now the fixed part seems to last for too short a time, IMO.
Let me elaborate my reasoning for the tempo I chose.
Oh, the tempo is fine. I meant that the duration of the fixed portion is short compared to the rest of the track. There are around 50 seconds of the first part and then the fixed part comes out to something like 10 seconds. Seems weird to me, but the composer can do whatever he wants.
User avatar
TakuikaNinja
Posts: 89
Joined: Mon Jan 09, 2023 6:42 pm
Location: New Zealand
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by TakuikaNinja »

The music fix has been submitted to RHDN. The patch file is attached here as well, for convenience.
https://www.romhacking.net/hacks/7576/
Attachments
Wizards & Warriors III - Kuros...Visions of Power (Music Fix).ips
(50 Bytes) Downloaded 42 times
User avatar
Jedi QuestMaster
Posts: 688
Joined: Thu Sep 07, 2006 1:08 pm
Location: United States
Contact:

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by Jedi QuestMaster »

Woohoo! :mrgreen: Big thankies! :)
Nicholas Steel
Posts: 7
Joined: Thu Sep 19, 2019 1:46 am

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by Nicholas Steel »

Jedi QuestMaster wrote: Wed Feb 08, 2023 8:11 pm I didn't really notice this when I played the game years ago, but looking back at it now, there's no way this sounds intentional to me: https://youtu.be/s_-QUJskVKk

At 50 seconds in, the music seems to be having a stroke.
That's definitely how it sounded on the NES PAL release of the game. Very cool to learn it was probably not intended to be like that and that TakuikaNinja has released a new NSF and also a game patch that addresses it (and other plausible issues).
Nicholas Steel
Posts: 7
Joined: Thu Sep 19, 2019 1:46 am

Re: What's Going on with This Music? (Wizards & Warriors III)

Post by Nicholas Steel »

TakuikaNinja wrote: Fri Feb 10, 2023 3:52 am Track 3 suffers from an off-by-one error in the tempo change, which I've just fixed. Track 9 starts with a tempo change and lacks the command to reset it. I can probably fix that by setting the initial tempo high and immediately subtracting from it at the start of the loop. There's also a corrupted note in one of the pulse channels? I need to investigate that further.
If this is the song used for the area leading up to the final fight (through the blue gate beyond the flying dragon), I imagine it's intentional for it to get progressively faster and faster with each loop. It would ruin the tension of this moment if this was removed, it should prolly stick to the fastest speed it reaches when it reaches it rather than the tempo looping back to the slowest or staying steady the whole time.

Edit: yeah, Track 9 I'm pretty sure is supposed to have a continually increasing tempo.
Post Reply