barbudreadmon / fbalpha-backup-dontuse-ty

Deprecated port of Final Burn Alpha to Libretro (v0.2.97.43).
61 stars 43 forks source link

MVS Mode game sound issues #163

Closed OBurgerGuy closed 6 years ago

OBurgerGuy commented 6 years ago

.42 has is missing sound in parts of these games in mvs mode: nam1975 bstars bstarsh Possibly other clones of same games as well.

OBurgerGuy commented 6 years ago

sorry, supposed broken roms was a PEBKAC error, but i accidentally left one game out... with all the hubbub and bickering in the begining i forgot to add karnovr has the same sound issues as well, during fighter selection screen and in-game, the update from source did fix bstars and nam1975 but not karnovr, tested in all modes, again only us has issue. during testing all games for brokage i was reminded about karnovr...

barbudreadmon commented 6 years ago

Yes, i confirm i still have this issue with kanrovr, actually on this one i got it with any mvs bios too.

Btw, most of the code in the speedhack was actually targeted at s1945p, so if you feel like testing 1 game in depth, that's probably the one who needs it the most.

OBurgerGuy commented 6 years ago

Any word on karnovr?

barbudreadmon commented 6 years ago

http://neosource.1emulation.com/forums/index.php?topic=1731.840

So no, upstream remember fixing this issue at some point, but don't remember how, and don't know why and when the bug reappeared.

OBurgerGuy commented 6 years ago

The bug is not present in fba 2012, because that’s what I was using to remedy the problem. So not likely to get fixed any time soon?

barbudreadmon commented 6 years ago

After some testing, i think i finally understood the big issue here, including why you had the first issue with all mvs bios while i had it only for usa bios.

Fs files are at fault here, old version of fba generate fs files, and when those files are read by newer version, they potentially break things, removing "karnovr.fs" from retroarch's savefile folder fixed the issue with sounds in karnovr on my side, let me know if it does on yours (if you don't know where it is, check "savefile_directory" in your retroarch.cfg).

The fact "savefiles" are stored in the same directory for fba, fba2012, and probably the different mame flavors, with the same name, potentially overriding each other, is a big issue i think. The issue you had with all mvs bios probably came from having the games started with fba2012 at some point.

I think i'll have to move savefiles to a subdirectory, to be sure savefiles from another core are not interfering with this core. Having every arcade cores doing the same thing would probably be a good idea.

OBurgerGuy commented 6 years ago

.fs files are used for game and dipswitch settings, they typically get saved within the same directory as game-name.zip, it would be nice to know where the new bios location is, the roms directory is fine, but i have to dupe the zip for every directory, and traditionally it’s shown in the gamelist.xml but if you edit es_systems.cfg and remove the uppercase .ZIP then rename each of your bios to neogeo.ZIP fba will still honor the file, but ES will not show it in your game list. Will test and get back to you, great work!

OBurgerGuy commented 6 years ago

Noop! no good... deleted .fs file, set settings to what theyre supposed to be in Unibios, also it might benefit you to know i am using unibios 3.3 renamed to 3.2, still curious why 3.3 hasnt been added, before you ask, yes... ive tested with 3.2 free version, and same results.

barbudreadmon commented 6 years ago

Could you give me a step by step tutorial of what you did when you say "deleted .fs file, set settings to what theyre supposed to be in Unibios" ? I'll try to reproduce, perhaps there is still another issue.

Anyway i'm 100% positive deleting karnovr.fs file fixed my issue at default fba settings, which means the loaded bios was asia-s3.rom, aka "MVS Asia/Europe ver.6 (1 slot)", and when i switched to unibios (i stayed with the default setting of Arcade/Europe) for testing, i still had music on select screen and ingame.

Also, i forgot to tell you that after seeing your videos, i think you have a misunderstanding on how "Force Neo Geo mode (if available)" core option works, it overrides the bios option in dipswitches if you select anything besides "DIPSWITCH" in it :

OBurgerGuy commented 6 years ago

karnovr always worked properly on European settings, just not USA, if you set it to USA arcade it won’t work. When you delete .fs file it sets unibios back to Europe default, by setting USA/arcade it creates. Brand new .fs file. As far as misunderstandings, I assumed just what you said, the only thing you have educate me on is that the force option overrides ANY bios setting below in the settings, whereas it will auto select an attributing rom, so here’s the thing then.. I don’t need a FULL bios, just USA and unibios 3.2 and the basic core files because I am only running USA arcade roms, and I’m running unibios not original bios.

barbudreadmon commented 6 years ago

Ok, so if i understand well because it's kinda unclear, after deleting karnovr.fs your issue only happens with unibios + arcade/usa settings ? Normal mvs/aes bios and unibios with any setting besides arcade/usa work fine ?

OBurgerGuy commented 6 years ago

ok so yes... aaaand no.. yes deleting karnovr.fs and running any bios setting other than aes results in failure, so... unibios, force mvs, force dipswitch and choose bios, all produce no sound EXCEPT aes which appears to work fine, also have deleted the.fs file every time i tested with new bios settings and still no change.

OBurgerGuy commented 6 years ago

you explained what neo-epo.bin is what is neo-po.bin and do you have a complete list of bios files of what is what? i found this list but its incomplete:

sp-s2.sp1 (mainbios $0 - 128k) Europe MVS (Ver. 2) sp-s.sp1 (mainbios $0 - 128k) Europe MVS (Ver. 1) usa_2slt.bin (mainbios $0 - 128k) US MVS (Ver. 2?) <-- CLRMamePro doesnt pick this up sp-e.sp1 (mainbios $0 - 128k) US MVS (Ver. 1) asia-s3.rom (mainbios $0 - 128k) Asia MVS (Ver. 3) vs-bios.rom (mainbios $0 - 128k) Japan MVS (Ver. 3) sp-j2.sp1 (mainbios $0 - 128k) Japan MVS (Ver. 2) sp1.jipan.1024 (mainbios $0 - 128k) Japan MVS (Ver. 1) sp-45.sp1 (mainbios $0 - 128k) NEO-MVH MV1C sp-1v1_3db8c.bin (mainbios $0 - 512k) Custom Japanese Hotel uni-bios_2_3.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 2.3) uni-bios_2_3o.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 2.3, older?) uni-bios_2_2.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 2.2) uni-bios_2_1.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 2.1) uni-bios_2_0.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 2.0) uni-bios_1_3.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 1.3) uni-bios_1_2.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 1.2) uni-bios_1_2o (mainbios $0 - 128k) Universe Bios (Hack, Ver. 1.2, older) uni-bios_1_1.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 1.1) uni-bios_1_0.rom (mainbios $0 - 128k) Universe Bios (Hack, Ver. 1.0) sm1.sm1 (audiobios $0 - 128k) sm1.sm1 (audi $0 - 128k) 000-lo.lo (zoomy $0 - 128k) sfix.sfix (fixedbios $0 - 128k) what is NEO-MVH MV1C... usa, jap, eur? the list is missing japan-j3.bin, neodebug.bin, neo-epo.bin, neo-po.bin, v2.bin and sp-u2.sp1

barbudreadmon commented 6 years ago

Ok, i was finally able to reproduce your issue by doing the following :

Actually it does seem the issue only happens if you insert coin after the music start on title screen, i'll report this upstream.

OBurgerGuy commented 6 years ago

is there a way to get music by the actions you do after running the rom? like wait to insert coin?

also neo-epo.bin us/eur or jap?

barbudreadmon commented 6 years ago

Insert coins before title screen music begin, or insert coin after title screen disappear (select character screen and further).

OBurgerGuy commented 6 years ago

None of that resulted in sound...

barbudreadmon commented 6 years ago

I spent way too much time on this one, i did my last report about this upstream ( http://neosource.1emulation.com/forums/index.php?topic=1731.msg24806#msg24806 ), if they can't answer, i'll let it go.

OBurgerGuy commented 6 years ago

i can confirm your .fs file theory, as i was just playing Blazing Star (Unibios 3.3 US/Arcade mode) to get my screenshot collection completed, and the first stage at the boss entry the music disappears, deleted the .fs file and unibios wanted its info again, set US/Arcade and Dont show splash, and got to boss again, there was sound this time, so yet another project to get to... delete all the old .fs files and remake.

barbudreadmon commented 6 years ago

I was suspecting this to be a potential source of issues for some time now, i'll move this core's nv/fs files to a subdirectory, it won't solve the issue with karnovr though since it happens with fresh karnovr.fs file.

I didn't withdraw from this issue yet, i still have a couple of things i wanna try, but i'm getting pessimistic about fixing it.

OBurgerGuy commented 6 years ago

Let me know what directory and where when you update the source

barbudreadmon commented 6 years ago

The core should now create a subdirectory called "fba" in the directory they used to be saved (it depends on your setup), nv/fs files will be loaded/saved there.

OBurgerGuy commented 6 years ago

ok.... more problems stemming probably from the updates to source "aof3" now gives me this error when running unibios usa/arcade, and MVS usa bios, and (default) bios force mvs or dipswitch, but it doesnt popup during aes, able to start and play game, it never did this before photo_2017-12-15_21-54-36

OBurgerGuy commented 6 years ago

tested the remaining 149, no issues, just this one, also the aof3 error screen doesnt appear in binary version FB Alpha v0.2.97.42 (retroarch 1.6.9), this issue seems specific to FB Alpha v0.2.97.42 26ee52f (updated from source) and updated to bab11d0 still doesn't work, running 0005781 on my supergun and aof3 runs fine

OBurgerGuy commented 6 years ago

is this thread still being monitored? i would appreciate some feedback, barbudreadmon?

barbudreadmon commented 6 years ago

This is not a forum, don't bump topic. Yes this is monitored.

OBurgerGuy commented 6 years ago

sorry, thank you... wasn't sure i was heard. thanks

OBurgerGuy commented 6 years ago

soo... my other retropie setup that I updated to bab11d0 runs aof3 just fine in us mode and what not, but sometimes i have to set unibios settings again... like they disappear, but the .fs file is always there...?

barbudreadmon commented 6 years ago

Right now i'm trying to fix #162 , there is a buffer overflow and it could be the root of both issues, this buffer overflow could be in retroarch's core option system.

OBurgerGuy commented 6 years ago

i had a weird feeling it may be the high score dat, ill delete and report findings

OBurgerGuy commented 6 years ago

no difference, cant nail down what the issue is... will just wait for a fix to be sent upstream, please notify me when it happens.

barbudreadmon commented 6 years ago

The hiscore issue is just a symptom of the buffer overflow, we don't know yet if this is the hiscore code which is at fault for this overflow.

barbudreadmon commented 6 years ago

I can't reproduce the aof3 issue, do you still have it ?

OBurgerGuy commented 6 years ago

Yes

OBurgerGuy commented 6 years ago

Accidentally closed

barbudreadmon commented 6 years ago

Even after updating to the latest commit and deleting your aof3.fs file ? I'm pretty sure a lot of issues with file corruption and settings not being saved properly were related to #162.

I tried MVS Europe/Asia, MVS Usa, and UNIBIOS 3.2 with USA/ARCADE settings. No problem here.

OBurgerGuy commented 6 years ago

I will test again on two separate set ups and get back to you possibly in the next couple days but definitely by Tuesday thanks again for your help with this issue

barbudreadmon commented 6 years ago

Actually i just tested karnovr with unibios, the sound works fine for me with any settings now. Only the genuine mvs bioses seems to have the sound issue.

OBurgerGuy commented 6 years ago

Nope, still no sound in karnovr and aof3 is still giving me the counterfeit board error

barbudreadmon commented 6 years ago

I'm wondering, how are you building this ? By retropie's scripts ? Or directly from command line ? And if you are using command line, what parameters are you using on the make command ?

OBurgerGuy commented 6 years ago

Retropie script “build from source”

OBurgerGuy commented 6 years ago

also, deleted hiscores.dat from "/opt/retropie/libretrocores/lr-fbalpha/metadata" and "/home/pi/RetroPie/BIOS/fba" to be sure i was compliant. no changes, what really gets me is the AOF3 counterfeit board error... why? and why now?

barbudreadmon commented 6 years ago

If i understand well, the issue with aof3 started for you after i moved the .fs files to a sub directory, which means you previously had an aof3.fs file which fixed this issue, probably generated by fbalpha2012. Did you try copying the aof3.fs file from fbalpha2012 to the fba subdirectory for this fbalpha ?

The .fs files are savestates, i have a feeling all of this could be somehow related to alignment issues (#166) in the savestates, that's why i asked how you built this, i don't use any "platform cflags" when i do my tests, i build this with a plain "make -f makefile.libretro".

Actually, while fixing the issues in the savestates a few days ago, something came to mind : we are aligning parts of the savestates's code to 8 bytes adresses, which if i understand well is the size of a "normal" address for x86/x86_64, but if i'm not wrong, depending on the cflags, the compiler could end up using specific extensions of the cpu (sse2, avx, ...) which have a different address size, and probably can mess with the execution of the code in some odd way. I think arm or part of it (neon ?) could also have different address sizes.

I would be interested to know what @fr500 @twinaphex and/or whoever is more knowledgable than me in C/C++ (which is not difficult) think about this.

OBurgerGuy commented 6 years ago

I don’t have the original FS file for aof 3 on that system any longer but I think I have it on my supergun I tried putting everything back and it didn’t work but I don’t think it was the 2012 FS file let me try to put that back in the next couple hours from the supergun and we’ll see what happens

barbudreadmon commented 6 years ago

From the documentation, it seems arm uses 8 bytes addresses, but neon uses 16 bytes addresses, same as sse2, avx and the such. I'll try building on my raspberry with neon enabled to see if i can reproduce the same results than you.

OBurgerGuy commented 6 years ago

you were right about the math, used two aof3.fs files with different checksums and filesizes, thought they were from 2012 and current, but might have both been from current, found a backup of roms/fs files i made before upgrading from 2012 and boom! works, so heres the files see for yourself if you can: OburgerGuy-aof3-fs.zip files are used with retropie on rpi, in case you didnt know.

barbudreadmon commented 6 years ago

Thanks, that's a great news, it basically means this issue is most likely savestates related. Now we just need to figure out in which way.

barbudreadmon commented 6 years ago

Sounds in karnovr seemed to work up to https://github.com/libretro/fbalpha/commit/228fb15c79382dba17f8ff4265a88b2425efe9d2, which is the commit prior to the .37 release. I'll compare .36 with .37 to see if i can find a reason for this.

barbudreadmon commented 6 years ago

Could you let me know if my latest commit fix the karnovr sound issue for you ? That's a dirty fix, but it works for me

OBurgerGuy commented 6 years ago

will do, updating from source now