YesNoOk
avatar

How do I make a "patcher"? (Read 107807 times)

Started by DeathScythe, June 06, 2023, 02:30:43 pm
Share this topic:
How do I make a "patcher"?
#1  June 06, 2023, 02:30:43 pm
  • ****
    • crepa.neocities.org

  • Online
Hello everyone!
So, recently I've been working on global effects and assets for my characters and is looking good so far, but for the characters to use it I need to place a few things in their .def, .air and -3 states. It's not a big deal for a small roster, but would be a lot easier if I could make a patcher, more or less like add004 that patches every character at once. The thing is, I have 0 knowledge of how this is done, but I imagine it's not too hard. If someone could give me a direction to start, I'd be really thankful!
Re: How do I make a "patcher"?
#2  June 11, 2023, 06:13:41 pm
  • *
The add004pie patcher essentially is a batch copy/paste and backup tool. You can put anything in the .ini file. Ikemen will handle such a task much easier. I use it for complex multi-layered fightfx similar to how add004 handles them, albeit with features Ikemen has made redundant stripped out. Common states, lifebar, tag related, etc. All in good ol classic inefficient cns format as I'm still learning zss. Just call out the file in the common states section of the save.json file. It works nearly identically to character patching because Ikemen common states are applied the same way common1.cns is. A third option would be using notepad++ to open chars folder as workspace, find in files code adjacent to new code such as [state -1, existing command] and replace with [state -1, existing command] \n\n[state -1, new stuff] using extended option search and replace. Be sure no space after \n or it won't go on next line. Should work fine for multi-line stuff as long as you copy the exising without the line break, which is invisible. For instance when copying a single line I always click the line number to highlight the entire line. This will transfer the line break causing it to stack the next line horizontally. Big fan of your work btw.
Last Edit: June 11, 2023, 06:41:47 pm by T1t@n Ur@nus
Re: How do I make a "patcher"?
#3  June 11, 2023, 10:10:32 pm
  • ****
    • crepa.neocities.org

  • Online
Oh, right, I forgot batch was a thing. ;P
I'll look up some tutorials. All the files I need to modify are text files (including .air) so it should not be a problem.
Thanks for the answer and for the kind words, glad you like my work. :nice:
Re: How do I make a "patcher"?
#4  September 13, 2023, 02:15:15 am
  • ****
    • crepa.neocities.org

  • Online
Reviving this to say... I managed to do some things, but not others.
As stated above by T1t@n Ur@nus, I learned that add004pie can be modified, so I thought on giving it a try. Works fine for the most part. I can write the code I need to all my characters in -2 states and the air file. Even in the commands and -1, but these I don't need. The one thing I need and I can't use add004pie for that is... overwrite helper states.

I have the codes for the helpers in my common1.cns and I want to use those instead of the chars own helpers. This replaces mostly effects like hitsparks and superpauses, and also fixes a few things so it can be compatible with the codes in -2.

The method I came with was to place statedef with the same numbers as the helpers, then changestates to the new helpers in common1, everything right above statedef 0.
In mugen, if there are more than one statedef with the same number, mugen will read the first one found and ignore the others, so it works fine. I just can't find a way to "batch" this into all my chars.

Well, I can (using softwares like VS Code), but I want it to be easier for OTHER people to use, since I plan to release it publicly. Add004pie doesn't work for that specific thing.
Any suggestions?

I've tried to learn batch but... I suck. lol
Last Edit: September 14, 2023, 03:35:01 am by DS
Re: How do I make a "patcher"?
#5  September 13, 2023, 06:44:53 pm
  • *
Glad you did revive the topic. Reminds me around that time Jesuszilla updated his CvS characters with a tool he made that does just such a thing. I wanted to test it for myself before replying but completely forgot. It's on his github. I don't have a link handy, wanted to reply to this quickly before getting side tracked again. It looked promising. I'l report with results and/or anything else I might come up with.
Re: How do I make a "patcher"?
#6  September 15, 2023, 04:08:25 am
  • ****
    • crepa.neocities.org

  • Online
Glad you did revive the topic. Reminds me around that time Jesuszilla updated his CvS characters with a tool he made that does just such a thing. I wanted to test it for myself before replying but completely forgot. It's on his github. I don't have a link handy, wanted to reply to this quickly before getting side tracked again. It looked promising. I'l report with results and/or anything else I might come up with.

I'm super interested. I've used some of the tools from JZ's github before (namely the AIR turbo speed converter and, of course, the Cheat Engine tables), I could go to his github and grab it myself but I think it's better to wait for your response, along with more informations. ;D