News: 11 March 2016 - Forum Rules
Current Moderators - DarkSol, KingMike, MathOnNapkins, Azkadellia, Danke

Author Topic: Snes emulators (Canoe, Snes9x) -- game problems and fixes  (Read 604867 times)

CanoeFan

  • Full Member
  • ***
  • Posts: 125
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1940 on: April 25, 2018, 01:05:48 pm »
You could try if a non-epilepsy protection is applied to US Super Ghouls'n Ghosts when the VC patch is applied. That might be the same version that is also preinstalled.
Or different Preset IDs ?

Bosco82

  • Sr. Member
  • ****
  • Posts: 253
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1941 on: April 25, 2018, 01:44:47 pm »
The VC patches add the epilepsy protection to the rom, as far as I know a clean SGNG can be ran fine with 0000

teahouser

  • Jr. Member
  • **
  • Posts: 96
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1942 on: April 25, 2018, 02:04:30 pm »
Thanks sluffy for patching all these games to be able to run correctly with canoe!

I've noticed something with the audio in Clocktower when played with canoe, it will constantly cut the audio signal off and on with each sound fx played, so you don't end up hearing half of it, such as the sound of her footsteps when there is no music playing in the background. Is this anything that could be fixed?

arkiokin

  • Full Member
  • ***
  • Posts: 101
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1943 on: April 25, 2018, 02:07:42 pm »
If you wrote -no lowlatency than of course you gat an error because it's -no-lowlatency. Getting an error for that command if written correctly would be strange.

you were right, it was not written correctly but not because the absence of a dash, just saw I wrote "lowlatnecy"... ^^'' Anyway, with the correct command line it changes nothing to this slowdown.

And for SGnG, I looked a bit further, and Hakchi allocate preset id to 0410 by default to the Japanese rom. When I changed to 0000, the epilepsy protection was removed. So, it was indeed a pid that triggered this protection and so this "graphical glitch"

CanoeFan

  • Full Member
  • ***
  • Posts: 125
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1944 on: April 25, 2018, 02:20:00 pm »
The VC patches add the epilepsy protection to the rom, as far as I know a clean SGNG can be ran fine with 0000

I guess then the epilepsy protection here is also caused by an automatically set PID, not by the VC patch?


Robin64

  • Full Member
  • ***
  • Posts: 148
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1945 on: April 25, 2018, 02:45:44 pm »
The versions of games on the SNES Mini usually have their VC patch applied,and that's normally the cause of the epilepsy protection. On the NES Mini, there was a global settings that looks for certain flashing and fixed it on the fly. With the SNES, the protection is done through patches.

Of the 21 games on the SNES Mini, 14 of them have VC patches. Really the best way is to consider these new versions, like F-Zero only had a 1.0 release but the one on the SNES Mini is effectively (but not literally) 1.1. But yes, these versions do include the epilepsy protection. For example, let's look at the Link to the Past patch, which MathOnNapkins previously broke down. You can see, this is an anti-epilepsy patch.

Code: [Select]
0003A50D: 03 18
0003A50E: 03 18

Adjusts two consecutive entries in a data table. Those extend the last two states in the Ether Medallion animation to make them last 8 times longer.

Code: [Select]
00067E6F: 1F 05

Modifies the immediate operand of a LDA instruction. This lowers the intensity of the flashing colors that tint the title screen as the sword is dropping into place. Instead of cycling between tints of full intensity red, green, and blue, it's now cycling between dull red, green and blue.

Code: [Select]
00075805: 0E 02
00075818: C0 40
00075819: 01 00
0007582C: 38 08

Modifies immediate operands to ADC instructions in a routine that adjusts colors to gradually tint more towards white. IIRC this is used when the seal on Ganon's Tower is being broken by the Crystal Maidens. The tweaks put in place cause the flashing process to take about 7 times longer.

Code: [Select]
000DE03C: 72 70
000DE03E: 9C 95
000DE040: FF 57

These modify the lower bytes of entries in a large table full of palettes. The first two reduce the red component, and the last change reduces the red and green components of a color. Which palettes? It would take more effort I'd rather not do at the moment to figure that out. Best I can say at the moment is that they are palettes meant for BG tiles in indoor parts of the game. Specifically, my notes mark them as "DungeonMain BG palettes (6 in each group)"

If you want to look at the 14 VC patches uses on the SNES Mini, I've uploaded a zip here: http://robin64.co.uk/files/snesVCpatches.zip.

BUT! On top of that, there are also a few in-memory patches which get applied on top of the already applied VC patch when the game boots. These aren't dumped with the ROM, so they had to be extracted at runtime, thanks to rhester72 for doing that. Most of these are tiny and nobody has really looked into what they do. There are 12 of these, and not all games with a VC patch have one. A task for someone clever, one day, would be to look into what these do! You can grab there here: http://robin64.co.uk/files/snesmempatches.zip

CanoeFan

  • Full Member
  • ***
  • Posts: 125
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1946 on: April 25, 2018, 02:55:07 pm »
But arkiokin's findings suggest it is the PID which causes the epilepsy protection not the VC patch. I think he didn't even have applied the VC patch?

Robin64

  • Full Member
  • ***
  • Posts: 148
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1947 on: April 25, 2018, 02:56:21 pm »
But arkiokin's findings suggest it is the PID which causes the epilepsy protection not the VC patch. I think he didn't even have applied the VC patch?

But maybe the patches are stored on the SNES Mini and applied with a correct PID+ROM too.

But as you can see from the Zelda breakdown above, the patches do contain the anti-epilepsy data. We need to comb through all the patches and document what they do.

And by we I mean MathOnNapkins. :)

Edit: Further to this, the global command "-fp 0" disables some types of epilepsy protection. For example, it works for EarthBound but doesn't work for Contra III.

Edit2: Tested Super Mario RPG in a PC emulator. With the VC patch applied, the anti-epilepsy protection is present in snes9x too. Compare the two images, vanilla on the left, VC patch on the right.

« Last Edit: April 25, 2018, 03:36:47 pm by Robin64 »

Bosco82

  • Sr. Member
  • ****
  • Posts: 253
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1948 on: April 25, 2018, 04:26:53 pm »
Pit Fighter is good to go



sluffy

  • Hero Member
  • *****
  • Posts: 642
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1949 on: April 25, 2018, 04:56:53 pm »
Drift King Shutokou Battle '94 - Tsuchiya Keiichi & Bandou Masaaki (Japan) (10bd, clean)
https://www.sendspace.com/file/6rtoi7

Check speed limiter.

Bosco82

  • Sr. Member
  • ****
  • Posts: 253
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1950 on: April 25, 2018, 05:25:25 pm »
I can't drive good enough to get it much past 200

pimpinelephant

  • Full Member
  • ***
  • Posts: 182
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1951 on: April 25, 2018, 05:27:46 pm »
Drift King - Shutokou Battle '94 now works correctly with DSP-1/A. The car is no longer limited in its speed.
Tested in Higan with DSP-1 firmware.

Of course, this needs to be tested on the Classic as well in order to fully be certain (should work fine though), but the DSP-1 math conversion has been confirmed to be successful!
Very nice job Sluffy!

Not only a hacking wizard, but also a math whiz! :thumbsup:

EDIT:

I just saw Bosco82's post. Looks like it is working correctly on Canoe as well.

EDIT2:

I hope you don't mind me asking Sluffy, but I was wondering if DSP-2 -> DSP-1 math conversion is similar to the DSP-1B for Dungeon Master's case.
Or are the DSP-2 and DSP-1 much more different comparatively?
« Last Edit: April 25, 2018, 05:39:58 pm by pimpinelephant »

sluffy

  • Hero Member
  • *****
  • Posts: 642
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1952 on: April 25, 2018, 05:40:10 pm »
Drift King Shutokou Battle 2 - Tsuchiya Keiichi & Bandou Masaaki (Japan) (10bd, clean)
https://www.sendspace.com/file/990srq

Same speed limiter. :)




Secret of Mana (Europe, rev1, 1016, clean)
https://www.sendspace.com/file/fm6cp7


Secret of Mana (France, rev1, 1016, clean)
Secret of Mana (Germany, 1016, clean)
https://www.sendspace.com/file/sy6g2n

Gamma, ntsc region, pal check removed

reyvgm

  • Hero Member
  • *****
  • Posts: 1202
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1953 on: April 25, 2018, 05:52:16 pm »
Damn it, okay so Act Raiser 2 is again marked again as having issues. By the way, that horizontal line is correct behavior. Happens on Higan too with clean rom.

What are people testing for those Mana patches?
« Last Edit: April 25, 2018, 06:40:42 pm by reyvgm »

pimpinelephant

  • Full Member
  • ***
  • Posts: 182
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1954 on: April 25, 2018, 05:55:48 pm »
Drift King - Shutokou Battle 2 (drift2.ips) unfortunately still limits the speed of the car to 58 km/h with DSP-1/A.
Tested in Higan with DSP-1 firmware.

Bosco82

  • Sr. Member
  • ****
  • Posts: 253
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1955 on: April 25, 2018, 06:07:33 pm »
Same on Canoe still won't go over 58

arkiokin

  • Full Member
  • ***
  • Posts: 101
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1956 on: April 25, 2018, 06:38:44 pm »
Thank you very much Robin64 for all these informations! :), it's now a bit more clear on which games I should take a further look on the original SNESC. Btw, I made the test to patch the clear yoshi's island USA Rev 1 by the mempatch include in canoe with snes9x 1.52 : no strange behaviour in 1-7 level with 9x. However, there was unusual slowdown on some parts of the 6 first levels before, but that's all.

Damn it, okay so Act Raiser 2 is again marked again as having issues. By the way, that vertical line is correct behavior. Happens on Higan too with clean rom.

What are people testing for those Mana patches?

What vertical line are you talking about ? if this concerns the horizontal white line, it doesn't happen on higan with vanilla rom (I had checked this before posted here and again now : no strange line with higan ?) I had noticed also another very small difference with sluffy's patch, the top and bottom tiny pixel line borders on the map are blue color, whereas the normal one is rather a sort of grey (a gradient between dark and blue in fact)

I should test the french mana patch (was very familiar with this game) but no time left for the moment. Perhaps later if nobody would not have yet tested it.

reyvgm

  • Hero Member
  • *****
  • Posts: 1202
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1957 on: April 25, 2018, 06:41:27 pm »
Sorry, yes, horizontal.

The line happens in vanilla USA rom on any pc emulator. It's correct behavior.

arkiokin

  • Full Member
  • ***
  • Posts: 101
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1958 on: April 25, 2018, 06:48:23 pm »
Sorry, yes, horizontal.

The line happens in vanilla USA rom on any pc emulator. It's correct behavior.

For me it happens only with the slowrom patched game on pc emulator. But I tested the vanilla game with higan, snes9x 1.52 and 1.55 : nothing to notice like that, no white line at all. Perhaps a different refresh rate from our PC screens ?

sluffy

  • Hero Member
  • *****
  • Posts: 642
    • View Profile
Re: Snes emulators (Canoe, Snes9x) -- game problems and fixes
« Reply #1959 on: April 25, 2018, 06:55:00 pm »
Europe Mana -- asked several times to fix the menu gamma. Especially french, german. Given recent developments, finally did it.


Have to check Drift King 2 again. Must've missed something (other than using wrong emu to check).


ActRaiser 2 = maybe make a screenshot and highlight with red box that line? I thought I saw something too with slowrom patch but not vanilla. But didn't check bsnes.


Let me get to work on DK2.