07th-mod / ace-higurashi-attorney

13 stars 0 forks source link

Running way too fast #1

Open ZXNova opened 2 years ago

ZXNova commented 2 years ago

When I open up the game the music plays way too fast. I'm not sure what to do about this.

drojf commented 2 years ago

@DoctorDiablo I noticed this too when I was briefly testing it earlier, and upon checking the actual audio files the engine really is playing too fast. Here is the actual opening music file so you can play it: bgml018.zip

After some testing I found the issue was that the music files have a sample rate of 24000hz, but the engine only supports more standard sample rates like 44100hz 22050hz. You can re-convert the files to WAV or a very high quality OGG/MP3 to fix this (I tested a resampled WAV to 44100hz and it fixed the problem), or see if there's a different version of the engine you can use.


side note: for distribution, you don't need to pack the the images and sound back into the arc.nsa, if you just put them next to the .exe the game will load them (like in the root folder you have img, sound, 0.txt, AceHigurashiAttorney-en.exe)

ZXNova commented 2 years ago

There's also an issue with the game opening up in Fullscreen when I don't want it to. Is there a way to make it stop opening up in full screen as default? I didn't do this at first but now it keeps doing that everytime and it messes up things

drojf commented 2 years ago

Press the "f' key to go out of fullscreen. It looks the like game remembers this setting until you next change it, so if you accidentally pressed it, it can be a problem....

I also noticed that when you're in fullscreen mode, you can't quit the game with ALT-F4, the only way I could figure out to quit is to press 'f' to go windowed and exit, or force close via task manager

DoctorDiablo commented 2 years ago

I think I managed to convert the audio files and get things playing properly. Is it only the mp3s that needed to be changed or did it affect the wav files too?

drojf commented 2 years ago

I did some more testing, it looks like all the WAV files are probably fine (game accepts 22050 or 44100 for WAV files), although I didn't individually test all the WAV files, just one of each type.

Any MP3 file which is not 44100 hz needs to be fixed (highlighted in blue in the below image):

image

That is, only 45, bgm0042_sfx, fang, and h-haze don't need to be converted, all others you need to convert (might as well convert all of them at this point).

ZXNova commented 2 years ago

Will something be done?

DoctorDiablo commented 2 years ago

@ZXNova Yeah, I've got the audio all converted, it just need to be tested to make sure this doesn't somehow break things. If you'd like to try it out, here are the files: FixAudioIssue.zip

Make sure you extract it so the sound folder is in the same directory as the exe. image

Let me know if it works for you. If it's all good, we can package it and put together a proper release.

ZXNova commented 2 years ago

I extracted it and it seems to be working. Am hearing no sped up music

ZXNova commented 2 years ago

I extracted it and it seems to be working. Am hearing no sped up music

Though the song during the first flashback seems to have a bad loop, it kinda clips when it loops

DoctorDiablo commented 2 years ago

Glad to hear it's working. Not sure if I have the audio knowhow to fix a bad loop, though.