Request: Sequential IPS Patching

Found a bug? Please report it, but remember to follow the bug reporting guidelines.
Missing a sane feature? Let us know!
But please do NOT request ports to other systems.

Moderator: ZSNES Mods

Post Reply
xMetaRidley
Rookie
Posts: 12
Joined: Sat Feb 12, 2005 11:31 pm

Request: Sequential IPS Patching

Post by xMetaRidley »

I think it would be cool if ZSNES could apply multiple IPS patches at ROM startup instead of just one. I know you can do this manually using an IPS patching tool but I dont like permanently modifying a ROM image.

Basically it would work like this:
  1. ZSNES gets filename of ROM to load
  2. ZSNES checks if soft IPS patching is enabled
  3. If not, it doesnt apply any patches and loads the game, if so, it continues
  4. ZSNES checks directory or zip file for files named like this: "Example Rom Image [!].ips" and "Example Rom Image [!].ips[N]", [N] being a number from 0-9.
  5. IPS0 file would be given top priority and would be patched first, followed by IPS1, IPS2, etc. If there is no .IPS0, it would just apply the .IPS (f there is one). If the sequence is ever broken (example, there is an IPS0 and an IPS2 but no IPS1), it would stop the sequential IPS patching. After the numbered IPS patches, it would apply the remaining .ips file if there is one, or all remaining .ips files if it is in a zip (would be convenient).
  6. If no IPS files are found in the directory of the ROM or the zip containing the ROM, it checks the save directory. Repeat the above check.
  7. After patching is completed, the patched ROM would load.
Joe Camacho
Devil's Advocate
Posts: 2293
Joined: Mon Aug 02, 2004 7:51 pm
Location: Hmo. Son.

Post by Joe Camacho »

I fail to see any example of these feature really being necesary, could you show us a couple?
*Sometimes I edit my posts just to correct mistakes.
Noxious Ninja
Dark Wind
Posts: 1271
Joined: Thu Jul 29, 2004 8:58 pm
Location: Texas
Contact:

Post by Noxious Ninja »

Example: Soft-patching the old SO beta patch and the menu patch.
[u][url=http://bash.org/?577451]#577451[/url][/u]
Aerdan
Winter Knight
Posts: 467
Joined: Mon Aug 16, 2004 10:16 pm
Contact:

Post by Aerdan »

Seiken Densetsu 3 + translation + colour improvement patch.
LobStar
Lurker
Posts: 189
Joined: Tue Dec 14, 2004 3:43 pm
Location: Corlo Island
Contact:

Post by LobStar »

I love this idea ^_^
... Ever take a look at the Earthbound ROM? I SWEAR THE PROGRAMMERS WERE ON CRACK WHEN THEY DID IT! JUST LOOK AT IT!
AspiringSquire
Born to Rule... Impatiently
Posts: 265
Joined: Wed Nov 17, 2004 8:21 pm
Location: Everywhere I want to be.
Contact:

Post by AspiringSquire »

LobStar wrote:I love this idea ^_^
I concur; this is a great idea.

It would be perfect for games that have bugfix patches (I'm thinking FF3/FF6), so you can easily choose which fixes you want and change it around to keep more or less of the bugs that were present in the original game—without needing to make a newly patched ROM every time you want to test a different setup.

With this one thing, however, I don't agree:
xMetaRidley wrote:After the numbered IPS patches, it would apply the remaining .ips file if there is one
I think the .ips non-numbered patch should be applied first, so it can be the "main" patch. That makes more sense to me than using the numbered IPS files before one with the actual standard for the file extension.
[url=http://board.zsnes.com/phpBB2/viewtopic.php?t=3298][color=brown]My [u]NES palette[/u][/color][/url] - better colors with any emulator.

"the more you know, and the more you can do... the more you are."
- [url=http://www.danielbohman.com][color=brown][u]daniel bohman[/u][/color][/url]
Clements
Randomness
Posts: 1172
Joined: Wed Jul 28, 2004 4:01 pm
Location: UK
Contact:

Post by Clements »

Like the idea, but I would suggest the extensions to be .ips, .ip1, .ip2 etc. to fall in line with the save state naming system.
Tallgeese
Justice is Blind
Posts: 620
Joined: Wed Jul 28, 2004 3:33 pm
Location: Test
Contact:

Post by Tallgeese »

I too like the idea. The question is, how hard would it be to implement?
Aerdan
Winter Knight
Posts: 467
Joined: Mon Aug 16, 2004 10:16 pm
Contact:

Post by Aerdan »

Clements wrote:Like the idea, but I would suggest the extensions to be .ips, .ip1, .ip2 etc. to fall in line with the save state naming system.
That's a hack, though; MS-DOS only handles the 8.3 'standard'. Now that we're all using Windows or Linux, we really don't need to be encouraging bad habits like that hack.
Tallgeese
Justice is Blind
Posts: 620
Joined: Wed Jul 28, 2004 3:33 pm
Location: Test
Contact:

Post by Tallgeese »

Aerdan wrote:
Clements wrote:Like the idea, but I would suggest the extensions to be .ips, .ip1, .ip2 etc. to fall in line with the save state naming system.
That's a hack, though; MS-DOS only handles the 8.3 'standard'. Now that we're all using Windows or Linux, we really don't need to be encouraging bad habits like that hack.
That eventually entals dropping DOS though, does it not? Is there any support for doing so?
Agozer
16-bit Corpse | Nyoron~
Posts: 3534
Joined: Sun Aug 01, 2004 7:14 pm
Location: Nokia Land

Post by Agozer »

I wouldn't drop the DOS port completely.
whicker: franpa is grammatically correct, and he still gets ripped on?
sweener2001: Grammatically correct this one time? sure. every other time? no. does that give him a right? not really.
Image
DataPath
Lurker
Posts: 128
Joined: Wed Jul 28, 2004 1:35 am
Contact:

Post by DataPath »

IIRC, with the way long filenames work, you should be able to make the short filename blah.ip1 while the long filename is blah.ips2.
anomie
Lurker
Posts: 151
Joined: Tue Dec 07, 2004 1:40 am

Post by anomie »

Here's a suggestion: Pick the first option that a file exists for:
1. If .ips exists, use that and do no other patches. This is preferred for a single patch.
2. If .ips0 exists, then look for .ips1, .ips2, ..., .ips10, .ips11, and so on up to .ips4294967295 or so and stop when the next number in the sequence doesn't exist. This is preferred for multiple patches.
3. If .ip0 exists, then look for .ip1, ..., .ip9. If you want more than 10 patches, tough. This is not preferred, but present for any fiilesystem that limits extensions to 3 characters.

If multiple directories are searched for patches, do all three in each directory (and as usual stop when a patch is found) rather than going over all directories for each option.
AspiringSquire
Born to Rule... Impatiently
Posts: 265
Joined: Wed Nov 17, 2004 8:21 pm
Location: Everywhere I want to be.
Contact:

Post by AspiringSquire »

anomie's suggestion is the definitely the system I would choose if I were in charge of bringing this new feature to fruition. ;)

I'd like to add one thing: I think it should search the zip/jma file for patches after checking the directories so outside files will take precedence and override the 'default' patching within the archive.
[url=http://board.zsnes.com/phpBB2/viewtopic.php?t=3298][color=brown]My [u]NES palette[/u][/color][/url] - better colors with any emulator.

"the more you know, and the more you can do... the more you are."
- [url=http://www.danielbohman.com][color=brown][u]daniel bohman[/u][/color][/url]
Nach
ZSNES Developer
ZSNES Developer
Posts: 3904
Joined: Tue Jul 27, 2004 10:54 pm
Location: Solar powered park bench
Contact:

Post by Nach »

AspiringSquire wrote: I'd like to add one thing: I think it should search the zip/jma file for patches after checking the directories so outside files will take precedence and override the 'default' patching within the archive.
Why? I think it should be the exact opposite. If it's bundled with the file, then logically shouldn't that take precedence?
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
anomie
Lurker
Posts: 151
Joined: Tue Dec 07, 2004 1:40 am

Post by anomie »

AspiringSquire wrote:I'd like to add one thing: I think it should search the zip/jma file for patches after checking the directories so outside files will take precedence and override the 'default' patching within the archive.
I have snes9x looking in 3 places: same location as the ROM, inside the ZIP, and finally in the "patch directory" (~/.snes9x/patches in my config). The idea being that patches with the actual ROM should override patches in the patch directory, and if you're dumping an ips in the same dir as a zip-with-ips, you're probably testing a new patch and would want that override.
Noxious Ninja
Dark Wind
Posts: 1271
Joined: Thu Jul 29, 2004 8:58 pm
Location: Texas
Contact:

Post by Noxious Ninja »

anomie wrote:
AspiringSquire wrote:I'd like to add one thing: I think it should search the zip/jma file for patches after checking the directories so outside files will take precedence and override the 'default' patching within the archive.
I have snes9x looking in 3 places: same location as the ROM, inside the ZIP, and finally in the "patch directory" (~/.snes9x/patches in my config). The idea being that patches with the actual ROM should override patches in the patch directory, and if you're dumping an ips in the same dir as a zip-with-ips, you're probably testing a new patch and would want that override.
Yeah, I think the same way.
[u][url=http://bash.org/?577451]#577451[/url][/u]
AspiringSquire
Born to Rule... Impatiently
Posts: 265
Joined: Wed Nov 17, 2004 8:21 pm
Location: Everywhere I want to be.
Contact:

Post by AspiringSquire »

anomie wrote:you're probably testing a new patch and would want that override.
This should quell your skepticism, Nach. :)
[url=http://board.zsnes.com/phpBB2/viewtopic.php?t=3298][color=brown]My [u]NES palette[/u][/color][/url] - better colors with any emulator.

"the more you know, and the more you can do... the more you are."
- [url=http://www.danielbohman.com][color=brown][u]daniel bohman[/u][/color][/url]
Nach
ZSNES Developer
ZSNES Developer
Posts: 3904
Joined: Tue Jul 27, 2004 10:54 pm
Location: Solar powered park bench
Contact:

Post by Nach »

AspiringSquire wrote:
anomie wrote:you're probably testing a new patch and would want that override.
This should quell your skepticism, Nach. :)
anomie's logic I can understand.

Though it would break my JMA based sequential IPS patcher somewhat to do that...
May 9 2007 - NSRT 3.4, now with lots of hashing and even more accurate information! Go download it.
_____________
Insane Coding
kieran_
Mugwump
Posts: 824
Joined: Fri Jul 30, 2004 9:05 pm

Post by kieran_ »

I love this idea. I wanted something like this since the retransaltion of FFVI came out, what with the multiple patchings and the whatnot.
Post Reply