More new formulas!
This formula will remove any active statuses on the target and apply them to self. Accuracy is Fa(MA+x)%
<Patch name="Formula 13 = Fa(ma+x)% hit, steal status from target">
<Description>Will take status that is active on target, cancel it, and apply it to
self.</Description>
<Location file="BATTLE_BIN" offset="122164">
4E470508
00000000
</Location>
<Location file="BATTLE_BIN" offset="ead38">
E8FFBD27
1000BFAF
8922060C
00000000
1E004014
00000000
1980013C
982D228C
902D238C
8C2D2A8C
21200000
58004590
59004690
5A004790
5B004890
5C004990
1B0045A1
1C0046A1
1D0047A1
1E0048A1
1F0049A1
200065A0
210066A0
220067A0
230068A0
240069A0
1980013C
8C2D258C
902D238C
01000434
0000A4A0
000064A0
08000434
2500A4A0
250064A0
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
This formula will steal a random item from the target. If the target has Maintenance or is naked, it'll do MP damage instead. It uses vanilla Geomancy routine (which with my Formula Rebalance Pack turns into (PA+Y)*MA). Credit goes to Glain for helping me write the stealing inner routine.
<Patch name="Formula 53 - Steal random item from target, MP damage if unit has Maintenance or is
naked">
<Description>Requires "Convert Damage to MP Damage routine" and "Steal/Break random slot inner
routine" to work.</Description>
<Location file="BATTLE_BIN" offset="1235e4">
E8FFBD27
1000BFAF
5D2F060C
00000000
4421060C
00000000
16004014
00000000
8378050C
00000000
07004010
00000000
1980033C
902D638C
10000134
100061A0
0C000010
00000000
5017060C
00000000
A921060C
00000000
F277050C
00000000
1980033C
902D648C
01000234
000082A0
E93862A0
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
<Patch name="Convert Damage to MP Damage Routine">
<Description>A small inner routine. Use this after the damage calculation to make the formula
deal MP damage instead of HP damage.</Description>
<Location file="BATTLE_BIN" offset="f6fc8">
E8FFBD27
1000BFAF
1980023C
902D428C
20000334
04004494
040040A4
250043A0
912E060C
080044A4
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
<Patch name="Steal/Break random slot inner routine">
<Description>Credit goes to Glain for helping me write this. :) To be used as an inner routine
for abilities which steal or break a random item from a target. Routine will return r2 = 0 if unit
has Maintenance or is naked.</Description>
<Location file="BATTLE_BIN" offset="f720c">
E8FFBD27
1000BFAF
1400B0AF
1980013C
982D218C
00001034
91002290
00000000
04004230
2B004014
00000234
0800A427
1A000734
FF000334
21000B34
0E00EB10
00000000
21482700
00002291
00000000
06004310
00000000
04004010
00000000
21289000
0000A7A0
01001026
0100E724
92780508
00000000
16000012
00000234
C388000C
00000000
1A005000
10100000
0800A427
21288200
0000A690
1980013C
982D2A8C
902D238C
80000934
1A000834
21584601
00006C91
00000000
1A006CA0
E6FFCE24
0648C901
190069A0
06000010
00000000
1980013C
902D218C
00000234
000022A0
100022A0
1400B08F
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
Also it's time to get rid of Distribute. Through a bunch of testing, I've figured out that Distribute was causing problems for many of my new reactions. This clears up a bunch of space, fixes Distribute bugs on any of the Multi-Reaction Deluxe reactions, and clears Distribute's slot for use for something else. Distribute's slot is not compatible with Multi-Reaction Deluxe, but it is compatible with another hack I'll post after this one:
<Patch name="Disables Distribute">
<Description>Completely disables the effects of Distribute. This frees up Distribute's slot for other use (not compatible with Multi-reaction deluxe without further coding), and eliminates any weirdness/bugs that are related to use of Multi-reaction deluxe.</Description>
<Location file="BATTLE_BIN" offset="125c94">
2B330608
</Location>
<Location file="BATTLE_BIN" offset="1262a8">
0800E003
00000000
</Location>
<Location file="BATTLE_BIN" offset="124168">
812C0608
00000000
</Location>
<Location file="BATTLE_BIN" offset="115bbc">
30F30508
00000000
</Location>
</Patch>
This changes Distribute to Synchronize - if a unit is targeted with a status effect, it will react by applying all its current effects to the target. It reacts at a Br% as usual. Requires Disable Distribute, and this code will break Secret Hunt/Train's code.
<Patch name="Distribute = Synchronize (Status infliction on a target has a Br% chance to inflict all current statuses on the caster)">
<Description>Disables Secret Hunt/Train (use instead of Disable Secret Hunt/Train hack). Requires Disable Distribute.</Description>
<Location file="BATTLE_BIN" offset="124984">
7661050C
00000000
</Location>
<Location file="BATTLE_BIN" offset="f15d8">
E8FFBD27
1000BFAF
19800A3C
982D488D
902D498D
8D000391
25002491
02006330
38006010
00000000
08008430
35008010
00000000
21200001
5A32060C
00000000
30004014
00000000
19800A3C
982D488D
00000000
24000591
3378010C
64000434
28004014
00000000
19800A3C
982D488D
902D4B8D
8C2D498D
58000291
1B006391
00000000
25104300
1B0022A1
59000291
1C006391
00000000
25104300
1C0022A1
5A000291
1D006391
00000000
25104300
1D0022A1
5B000291
1E006391
00000000
25104300
1E0022A1
5C000291
1F006391
00000000
25104300
1F0022A1
C912060C
00000434
07004010
00000000
19800A3C
8C2D498D
01000134
000021A1
08000234
250022A1
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
This formula will remove any active statuses on the target and apply them to self. Accuracy is Fa(MA+x)%
<Patch name="Formula 13 = Fa(ma+x)% hit, steal status from target">
<Description>Will take status that is active on target, cancel it, and apply it to
self.</Description>
<Location file="BATTLE_BIN" offset="122164">
4E470508
00000000
</Location>
<Location file="BATTLE_BIN" offset="ead38">
E8FFBD27
1000BFAF
8922060C
00000000
1E004014
00000000
1980013C
982D228C
902D238C
8C2D2A8C
21200000
58004590
59004690
5A004790
5B004890
5C004990
1B0045A1
1C0046A1
1D0047A1
1E0048A1
1F0049A1
200065A0
210066A0
220067A0
230068A0
240069A0
1980013C
8C2D258C
902D238C
01000434
0000A4A0
000064A0
08000434
2500A4A0
250064A0
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
This formula will steal a random item from the target. If the target has Maintenance or is naked, it'll do MP damage instead. It uses vanilla Geomancy routine (which with my Formula Rebalance Pack turns into (PA+Y)*MA). Credit goes to Glain for helping me write the stealing inner routine.
<Patch name="Formula 53 - Steal random item from target, MP damage if unit has Maintenance or is
naked">
<Description>Requires "Convert Damage to MP Damage routine" and "Steal/Break random slot inner
routine" to work.</Description>
<Location file="BATTLE_BIN" offset="1235e4">
E8FFBD27
1000BFAF
5D2F060C
00000000
4421060C
00000000
16004014
00000000
8378050C
00000000
07004010
00000000
1980033C
902D638C
10000134
100061A0
0C000010
00000000
5017060C
00000000
A921060C
00000000
F277050C
00000000
1980033C
902D648C
01000234
000082A0
E93862A0
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
<Patch name="Convert Damage to MP Damage Routine">
<Description>A small inner routine. Use this after the damage calculation to make the formula
deal MP damage instead of HP damage.</Description>
<Location file="BATTLE_BIN" offset="f6fc8">
E8FFBD27
1000BFAF
1980023C
902D428C
20000334
04004494
040040A4
250043A0
912E060C
080044A4
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
<Patch name="Steal/Break random slot inner routine">
<Description>Credit goes to Glain for helping me write this. :) To be used as an inner routine
for abilities which steal or break a random item from a target. Routine will return r2 = 0 if unit
has Maintenance or is naked.</Description>
<Location file="BATTLE_BIN" offset="f720c">
E8FFBD27
1000BFAF
1400B0AF
1980013C
982D218C
00001034
91002290
00000000
04004230
2B004014
00000234
0800A427
1A000734
FF000334
21000B34
0E00EB10
00000000
21482700
00002291
00000000
06004310
00000000
04004010
00000000
21289000
0000A7A0
01001026
0100E724
92780508
00000000
16000012
00000234
C388000C
00000000
1A005000
10100000
0800A427
21288200
0000A690
1980013C
982D2A8C
902D238C
80000934
1A000834
21584601
00006C91
00000000
1A006CA0
E6FFCE24
0648C901
190069A0
06000010
00000000
1980013C
902D218C
00000234
000022A0
100022A0
1400B08F
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>
Also it's time to get rid of Distribute. Through a bunch of testing, I've figured out that Distribute was causing problems for many of my new reactions. This clears up a bunch of space, fixes Distribute bugs on any of the Multi-Reaction Deluxe reactions, and clears Distribute's slot for use for something else. Distribute's slot is not compatible with Multi-Reaction Deluxe, but it is compatible with another hack I'll post after this one:
<Patch name="Disables Distribute">
<Description>Completely disables the effects of Distribute. This frees up Distribute's slot for other use (not compatible with Multi-reaction deluxe without further coding), and eliminates any weirdness/bugs that are related to use of Multi-reaction deluxe.</Description>
<Location file="BATTLE_BIN" offset="125c94">
2B330608
</Location>
<Location file="BATTLE_BIN" offset="1262a8">
0800E003
00000000
</Location>
<Location file="BATTLE_BIN" offset="124168">
812C0608
00000000
</Location>
<Location file="BATTLE_BIN" offset="115bbc">
30F30508
00000000
</Location>
</Patch>
This changes Distribute to Synchronize - if a unit is targeted with a status effect, it will react by applying all its current effects to the target. It reacts at a Br% as usual. Requires Disable Distribute, and this code will break Secret Hunt/Train's code.
<Patch name="Distribute = Synchronize (Status infliction on a target has a Br% chance to inflict all current statuses on the caster)">
<Description>Disables Secret Hunt/Train (use instead of Disable Secret Hunt/Train hack). Requires Disable Distribute.</Description>
<Location file="BATTLE_BIN" offset="124984">
7661050C
00000000
</Location>
<Location file="BATTLE_BIN" offset="f15d8">
E8FFBD27
1000BFAF
19800A3C
982D488D
902D498D
8D000391
25002491
02006330
38006010
00000000
08008430
35008010
00000000
21200001
5A32060C
00000000
30004014
00000000
19800A3C
982D488D
00000000
24000591
3378010C
64000434
28004014
00000000
19800A3C
982D488D
902D4B8D
8C2D498D
58000291
1B006391
00000000
25104300
1B0022A1
59000291
1C006391
00000000
25104300
1C0022A1
5A000291
1D006391
00000000
25104300
1D0022A1
5B000291
1E006391
00000000
25104300
1E0022A1
5C000291
1F006391
00000000
25104300
1F0022A1
C912060C
00000434
07004010
00000000
19800A3C
8C2D498D
01000134
000021A1
08000234
250022A1
1000BF8F
1800BD27
0800E003
00000000
</Location>
</Patch>