øAslickproductions.org/forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&action=profile;u=123;area=showposts;start=540e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/index7544.htmlslickproductions.org/forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&action=profile;area=showposts;u=123e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/index7544.html.zxòg^ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÈ P,_çOKtext/htmlISO-8859-1gzip0|Ö_çÿÿÿÿÿÿÿÿTue, 10 Mar 2020 20:17:51 GMT0ó°° ®0®P®€§²ð®òg^ÿÿÿÿÿÿÿÿ™W_ç Show Posts - Grimoire LD

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Grimoire LD

541
So in preparation of releasing v0.14 I've been replaying my mod to make sure everything is working right (after that OctoMamm fiasco I couldn't chance it without playing through myself) but I decided to do something a little different, I decided I would not stop and grind at all, that means no purposely looking for Dead Man Clothes or Gooey Axes to help me with the Dark Knight portion of the game (and Mt. Ordeals, oh boy!).

I normally grind to level 13 or 14 before fighting the Mist Dragon to make sure I'm prepared, I did not this time and fought what only was thrown at me. I handled the Mist Dragon with a very close call (Cecil dead, Kain down to 6 HP). Rydia with 80 HP allows her to survive much easier and I headed straight to the Waterway and she was Level 8 before meeting Tellah.

Everything was going smooth...ish, until I reached OctoMamm. At 31 Speed he gets maybe two to three turns on you and he has a guaranteed Paralysis... I then noticed the error with that and changed his speed down to 23 and gave him a different AI pattern (Fight, Fight, Entangle) it might not have Blink be as useful, but it does prevent everyone from being paralyzed at one time. The real difficulty is getting those first three hits, once you have those his speed drops down to manageable levels. I cast Regen, switched swords from Shadow to Dark (Shadow Sword uses Dark Omen sometimes which turns Cecil into a Zombie and can really throw off defense in a boss fight).

Next I sped through Antlion's Den, and finally realized how useful my Madhura Harp was (Edward's first harp in Combat Boost) since it deals x4 damage to spirits, and the Weepers in there are no joke. If they're alone they will cast a 700+ damage Holy, he can take them out in one blow at any level. Antlion was surprisingly difficult, I've been wondering if I need to change him at all, maybe something to make it a near necessity to use the Bardsong in some manner, but I think he's difficult enough, I do think that using the Madhura's Harp Protect might actually help a bit during it.

Next was Mt. Hobbs and MomBomb, with the changed strength of Level 1 Elemental Spells, characters were taking 80-160 damage from Fire1 from the Spirits, Souls, and MomBomb, MomBomb herself was a bit tricky to bring down to her next phase but I succeeded and a secret to defeating the rest of the bombs is to use a battle item. All battle items in FFIV:CB are immensely powerful (except StopTrap which has been nerfed since it lasts Forever now it has the same power as Stop.)

Yang was only Level 11 when we reached Fabul and I lost the Fabul Siege several times, Cecil would just take one too many hits (sometimes being hit by the undead Weepers who deal x2 Damage to Dark Knight Cecil because he is weak to the Dark Element, more on that later) and he was dead by the 3rd fight and Yang soon followed, so it was up to Edward tossing battle items every which way in a vain attempt to survive. We had just enough to do so.

without purposeful grinding I did not acquire a single rare item until I was in the area around Mysidia, then the rare items just raked in. I got a Traveler Knife and 10 Yoichi Arrows by the time I reached Mt. Ordeals.

Mt. Ordeals without a Gooey Axe or Thief Knife is Tough! First, one thing I need to mention is that Undead enemies use Dark Elemental attacks which Dark Knight Cecil is weak to due to the Dark Armor, so it's best to go up the mountain with nothing on. I gave Porom a Crossbow with Pearl Arrows and Palom used a FlameRod. It was rough going and I had to leave and heal several times (note: I do not consider that grinding as it was an earnest attempt to scale the mountain, just failing to do so, so it was best to cut losses and retreat rather than die)

Cecil was barely Level 20 when we made it to Milon. The first phase kind of threw me for a loop, I didn't expect it to be so difficult, but again a BombArm made short work of it winning this I got a Dead Man's Clothes, right on time to! Milon-Z is no joke!

I always thought I didn't change Milon-Z sufficiently enough, he has a new Fire-Counter  which is basic death in most respects. but I thought his basic attacks were a little too weak, I was wrong. He could deal anywhere from 30-80 Damage to the person wearing the Dead Man's Clothes and his critical hits could deal upwards to 160-200 to the person wearing the Dead Man's Clothes and his normal attacks would deal 100-380 damage including criticals. Curing Curse was a constant to assure anyone had a chance to survive. The real trick to this I've seen is not to be too defensive, he does not resist the Dark Sword, so Cecil can use that to its fullest give him Berserk and let him fight, Palom's magic at exactly Level 20 only did 500-600 damage to Milon-Z's 7000 HP pool and Tellah couldn't really get a good roll with Elemental Sword. But smart use of Blink and early use of Regen really helped out a lot, Cecil could deal 300-400 damage per hit since he was Berserked. It was difficult, but it was done.

By the time Cecil got off Mt. Ordeals he was Level 10 and by the return trip to Mysidia he was Level 12. By now I had acquired a second Traveler's Knife, a Thief's Knife and a couple of Battle Items from random battles, most importantly though I received the Master's Headband from a DeludImp on my way back, which will be great for Yang!  Then it was onto the Serpent Road...

The Serpent Road caused me a lot of problems with much higher level parties, but now I seem to know the tricks of the trade (tricks of my own trade, imagine that.) I used Piercing Sight on the Mindflayers and cast Aura on Cecil to deal higher damage to the Mindflayers because they are a Mage-type and Aura's second level of power (20 Wisdom) grants 4 damage to Mages) and stocked up on GaeaRobes (which now prevent Stun, by being "grounded" to the Earth). With the Mad Mages I used a similar strategy but also threw in Piercing Sight to deal +weakness damage to the Mad Mages. Finally the Serpent's were dealt with by efficient uses of Ice 3 and the Traveler's Knife, now equipped on Cecil due to their being Beast-type foes and the Traveler's Knife dealing x4 damage to Beasts.

And with that the Serpent Road was done which is where I currently am at.

Cecil is only Level 15, Porom is Level 20, Palom is 22, and Tellah is Level 25.

So far this "rushing things" has worked out, so I know that it is still possible, even in my mod so grinding is by no means mandatory but just fighting the battles as they come and retreating when things look bleak, work just fine.

Also the next post I will release v0.14 (which will be done tomorrow at Romhacking.net).



542
You added in layer 2 background support and it looks rather fantastic! Though when you go to highlight an area while in Maps the cursor never clears properly and there are then white boxes all over the map.

Enemy AI editing also seems to look clearner rather than the remnant of boxes spread all about.


543
I think I found the function of Command F8, ... I've had no luck figuring out F8

Is one of these supposed to be F6?

...Yes, haha! F6 and FA are still unknown to me.

544
Weirdest part about count is that it works fine on the first monster it's used on each battle, but doesn't work at all after that. I believe, too, that if the effects are split, it doesn't work on any of the monsters (I might be wrong about that - it was a while ago that I played around with it).

Oh no, if you try to use Count on all or split-all monsters, the game locks up when the timers reach 00, seemingly unable to figure out what to do next. I think Count can take out the first two enemies (as seen with the plague enemies), but it cannot take out the last one at all. It is rather strange and my bet is some built-in safeguards against it which actually end up making things worse, but without seeing the routine it's difficult to say.

545
Final Fantasy IV Research & Development / Re: Spell Visual Effects
« on: December 27, 2014, 09:28:35 PM »
You made it Much clearer, that was a legitimately enlightening post on spell effects, now I think I more-or-less fully grasp the way spell effects are drawn.


546
Game Modification Station / Re: FF6 isn't the only poorly coded game...
« on: December 27, 2014, 06:16:22 PM »
...How do you even make that mistake? The only thing i can imagine is that there may have been a function there originally, but then they decided to axe it for a reason.

547
Final Fantasy IV Research & Development / Re: Spell Visual Effects
« on: December 27, 2014, 06:15:11 PM »
This is pretty fantastic information, yet can you give an example or two of how these correspond to the Sprite/Sequence/Effects portion of a Spells data? Maybe it's plainly there, but when it comes to graphics I'm not that bright.

548
So I've been doing a little more testing with AI and I think I found the function of Command F8, it looks to either be a debugging setup or possibly a remnant of an earlier setup to show when a given monster is acting (if this is in their AI script), it's not complete though as it will only display the name for the first enemy of each group, after that it will display blank for the remaining enemies in the group. Command F7 at 0 is a Screen Darkening function, it's only used in the King Eblan script. I've had no luck figuring out F8 or FA though.

549
Interesting experiment, I would see no reason why you couldn't kill Zeromus with HP Leak, he is just another enemy. The only thing I'd wonder is if the line "HP Ran out" would show up. You didn't quite write if the experiment worked or not. I imagine it would have, but you can never be too sure with FFIV.

That is a good question on why Stop breaks the game in several ways in the SNES versions, my guess is something about timers not clearing correctly, hence the entire battle system grinds to a halt. In theory all of the information to figure that out is now available. I would also love to know what goes wrong with Count. Death Sentence is such a neat idea for a status and would make an ideal replacement to any "instant-ko" weapon, but Count doesn't work properly on enemies for some reason...


550
This looks wonderful! Being able to see any size monsters (and not just Imps, Zyrthofar's editor!) and place them where you like to see how they would look, would be great!

551
Under Charm Routine

Code: [Select]
$03/AB3E BD 04 20 LDA $2004,x[$7E:2004] A:0000 X:0000 Y:0012 P:envMxdiZc - Load Status Byte 02 into A.
$03/AB41 29 08 AND #$08 A:0008 X:0000 Y:0012 P:envMxdizc - Is it Charm?
$03/AB43 F0 05 BEQ $05    [$AB4A] A:0008 X:0000 Y:0012 P:envMxdizc - If not, branch.
$03/AB45 20 AD AB JSR $ABAD  [$03:ABAD] A:0008 X:0000 Y:0012 P:envMxdizc - Jump to Subroutine.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/ABAD A6 A6 LDX $A6    [$00:00A6] A:0008 X:0000 Y:0012 P:envMxdizc - Load Target Identifier.
$03/ABAF 9E 53 20 STZ $2053,x[$7E:2053] A:0008 X:0000 Y:0012 P:envMxdiZc - Store Zero in Monster Target
$03/ABB2 9E 54 20 STZ $2054,x[$7E:2054] A:0008 X:0000 Y:0012 P:envMxdiZc - Store Zero in Party Target
$03/ABB5 20 8B 85 JSR $858B  [$03:858B] A:0008 X:0000 Y:0012 P:envMxdiZc - Jump to Subroutine (Random Number)
$03/ABB8 C9 46 CMP #$46 A:0025 X:0000 Y:0012 P:envMxdizc - Compare the number to 46
$03/ABBA B0 24 BCS $24    [$ABE0] A:0025 X:0000 Y:0012 P:eNvMxdizc - If greater than 46, branch to normal Fight Routine
$03/ABBC AE 34 35 LDX $3534  [$7E:3534] A:0025 X:0000 Y:0012 P:eNvMxdizc - Load Slot into X.
$03/ABBF A0 05 00 LDY #$0005 A:0025 X:0000 Y:0012 P:envMxdiZc - Load 0005 into Y.
$03/ABC2 BD 03 33 LDA $3303,x[$7E:3303] A:0025 X:0000 Y:0005 P:envMxdizc - Load A from Command Locations.
$03/ABC5 C9 02 CMP #$02 A:0000 X:0000 Y:0005 P:envMxdiZc - Is it Black Magic?
$03/ABC7 F0 0D BEQ $0D    [$ABD6] A:0000 X:0000 Y:0005 P:eNvMxdizc - If so branch.
------------------------------------------------------------------------------------------------------------------
$03/ABC9 C9 03 CMP #$03 A:0000 X:0000 Y:0005 P:eNvMxdizc - Is it White Magic?
$03/ABCB F0 09 BEQ $09    [$ABD6] A:0000 X:0000 Y:0005 P:eNvMxdizc - If so branch.
--------------------------------------------------------------------------------------------------------------------
$03/ABCD E8 INX A:0000 X:0000 Y:0005 P:eNvMxdizc - +4
$03/ABCE E8 INX A:0000 X:0001 Y:0005 P:envMxdizc
$03/ABCF E8 INX A:0000 X:0002 Y:0005 P:envMxdizc
$03/ABD0 E8 INX A:0000 X:0003 Y:0005 P:envMxdizc
$03/ABD1 88 DEY A:0000 X:0004 Y:0005 P:envMxdizc -1 Y
$03/ABD2 D0 EE BNE $EE    [$ABC2] A:0000 X:0004 Y:0004 P:envMxdizc - Branch back if not gone through all five commands looking for White/Black Magic.
$03/ABD4 80 0A BRA $0A    [$ABE0] A:0001 X:0014 Y:0000 P:envMxdiZc - Branch always.
---------------------------------------------------------------------------------------------------------------------
$03/ABD6 64 90 STZ $90    [$00:0090] A:0002 X:0058 Y:0004 P:envMxdiZC - Store Zero in 90
$03/ABD8 20 FD AB JSR $ABFD  [$03:ABFD] A:0002 X:0058 Y:0004 P:envMxdiZC - Jump to Subroutine

---------------------------------------------------------------------------------------------------------------------
$03/ABE0 A6 A6 LDX $A6    [$00:00A6] A:0001 X:0014 Y:0000 P:envMxdiZc - Load Slot Identity.
$03/ABE2 A9 80 LDA #$80 A:0001 X:0000 Y:0000 P:envMxdiZc - Load 80 into A.
$03/ABE4 9D 50 20 STA $2050,x[$7E:2050] A:0080 X:0000 Y:0000 P:eNvMxdizc - Store A in 2050
$03/ABE7 9E 51 20 STZ $2051,x[$7E:2051] A:0080 X:0000 Y:0000 P:eNvMxdizc - Store Zero in 2051 (Fight)
$03/ABEA 20 82 85 JSR $8582  [$03:8582] A:0080 X:0000 Y:0000 P:eNvMxdizc - Jump to Subroutine (0-4 Random Choice)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/8582 A2 00 00 LDX #$0000 A:0080 X:0000 Y:0000 P:eNvMxdizc - Load 00 into X.
$03/8585 A9 04 LDA #$04 A:0080 X:0000 Y:0000 P:envMxdiZc - Load 04 into A.
$03/8587 20 79 83 JSR $8379  [$03:8379] A:0004 X:0000 Y:0000 P:envMxdizc - Jump to RNG.
$03/8379 E2 10 SEP #$10 A:0004 X:0000 Y:0000 P:envMxdizc - Set Processor to 10.
$03/858A 60 RTS A:0004 X:0000 Y:0000 P:envMxdizc - Return
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/ABEE BD 40 35 LDA $3540,x[$7E:3544] A:0004 X:0004 Y:0000 P:envMxdizc - Load Slot to Target ?Status?
$03/ABF1 D0 F7 BNE $F7    [$ABEA] A:0000 X:0004 Y:0000 P:envMxdiZc - Branch if ?Incapacitated? back to roll again.
$03/ABF3 7B TDC A:0000 X:0004 Y:0000 P:envMxdiZc - Tranfer Direct Page.
$03/ABF4 20 5F 85 JSR $855F  [$03:855F] A:0000 X:0004 Y:0000 P:envMxdiZc  - Jump to Subroutine
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/855F 1F FE FE 13 ORA $13FEFE,x[$13:FF02] A:0000 X:0004 Y:0000 P:envMxdiZc - ??
$03/8563 60 RTS A:0008 X:0004 Y:0000 P:envMxdizc - Return
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/ABF7 A6 A6 LDX $A6    [$00:00A6] A:0008 X:0004 Y:0000 P:envMxdizc - Load Slot Identifier
$03/ABF9 9D 54 20 STA $2054,x[$7E:2054] A:0008 X:0000 Y:0000 P:envMxdiZc - Store A in Party Target.
$03/ABFC 60 RTS A:0008 X:0000 Y:0000 P:envMxdiZc - Return
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/ABFD AE 36 35 LDX $3536  [$7E:3536] A:0002 X:0058 Y:0004 P:envMxdiZC - Load Spell Pointer
$03/AC00 86 A9 STX $A9    [$00:00A9] A:0002 X:0360 Y:0004 P:envMxdizC - Store X in A9.
$03/AC02 A0 30 00 LDY #$0030 A:0002 X:0360 Y:0004 P:envMxdizC - Load 0030 into Y.
$03/AC05 BD 7A 2C LDA $2C7A,x[$7E:2FDA] A:0002 X:0360 Y:0030 P:envMxdizC - Load A from Spell Menu Data
$03/AC08 10 0C BPL $0C    [$AC16] A:0020 X:0360 Y:0030 P:envMxdizC -Branch if Positive (meaning a spell is there).
-------------------------------------------------------------------------------------------------------------------

-------------------------------------------------------------------------------------------------------------------
$03/AC16 7B TDC A:0020 X:0360 Y:0030 P:envMxdizC - Transfer Direct Page
$03/AC17 AA TAX A:0000 X:0360 Y:0030 P:envMxdiZC - Transfer A to X.
$03/AC18 A9 2F LDA #$2F A:0000 X:0000 Y:0030 P:envMxdiZC - Load 2F into A.
$03/AC1A 20 79 83 JSR $8379  [$03:8379] A:002F X:0000 Y:0030 P:envMxdizC - Jump to RNG
$03/AC1E 8E 3D 39 STX $393D  [$7E:393D] A:0002 X:0002 Y:0030 P:envMxdizc - Store X in 393D.
$03/AC21 A2 04 00 LDX #$0004 A:0002 X:0002 Y:0030 P:envMxdizc - Load 04 into X.
$03/AC24 8E 3F 39 STX $393F  [$7E:393F] A:0002 X:0004 Y:0030 P:envMxdizc - Store X in 393F.
$03/AC27 20 B9 83 JSR $83B9  [$03:83B9] A:0002 X:0004 Y:0030 P:envMxdizc - Jump to Subroutine (Divides several 393X values)
$03/AC2A 18 CLC A:0000 X:0000 Y:0030 P:envMxdiZc - Clear Carry Flag.
$03/AC2B A5 A9 LDA $A9    [$00:00A9] A:0000 X:0000 Y:0030 P:envMxdiZc - Load A from A9.
$03/AC2D 6D 41 39 ADC $3941  [$7E:3941] A:0060 X:0000 Y:0030 P:envMxdizc - Add value from 3941 onto A.
$03/AC30 85 AB STA $AB    [$00:00AB] A:0068 X:0000 Y:0030 P:envMxdizc - Store A in AB.
$03/AC32 A5 AA LDA $AA    [$00:00AA] A:0068 X:0000 Y:0030 P:envMxdizc - Load A from AA.
$03/AC34 6D 42 39 ADC $3942  [$7E:3942] A:0003 X:0000 Y:0030 P:envMxdizc - Add value from 3942 onto A.
$03/AC37 85 AC STA $AC    [$00:00AC] A:0003 X:0000 Y:0030 P:envMxdizc - Store A in AC.
$03/AC39 A6 AB LDX $AB    [$00:00AB] A:0003 X:0000 Y:0030 P:envMxdizc - Load X from AB.
$03/AC3B BD 7A 2C LDA $2C7A,x[$7E:2FE2] A:0003 X:0368 Y:0030 P:envMxdizc - Load A from next Spell.
$03/AC3E 85 AD STA $AD    [$00:00AD] A:0080 X:0368 Y:0030 P:eNvMxdizc - Store A in AD.
$03/AC40 30 D4 BMI $D4    [$AC16] A:0080 X:0368 Y:0030 P:eNvMxdizc - Branch back if 80.
------------------------------------------------------------------------------------------------------------------------------
$03/AC42 BD 7B 2C LDA $2C7B,x[$7E:2FDB] A:0020 X:0360 Y:0030 P:envMxdizc - Load Spell Number into A.
$03/AC45 A6 A6 LDX $A6    [$00:00A6] A:001C X:0360 Y:0030 P:envMxdizc - Load Slot ID into A.
$03/AC47 9D 52 20 STA $2052,x[$7E:21D2] A:001C X:0180 Y:0030 P:envMxdizc - Store A in Spell Choice.
$03/AC4A A9 20 LDA #$20 A:001C X:0180 Y:0030 P:envMxdizc - Load 20 into A.
$03/AC4C 9D 50 20 STA $2050,x[$7E:21D0] A:0020 X:0180 Y:0030 P:envMxdizc - Store A in 2050.
$03/AC4F A9 02 LDA #$02 A:0020 X:0180 Y:0030 P:envMxdizc - Load 02 into A.
$03/AC51 9D 51 20 STA $2051,x[$7E:21D1] A:0002 X:0180 Y:0030 P:envMxdizc - Store A in Command.
$03/AC54 A5 AD LDA $AD    [$00:00AD] A:0002 X:0180 Y:0030 P:envMxdizc - Load AD into A.
$03/AC56 29 40 AND #$40 A:0020 X:0180 Y:0030 P:envMxdizc - Get rid of all bytes that not 40.
$03/AC58 D0 25 BNE $25    [$AC7F] A:0000 X:0180 Y:0030 P:envMxdiZc - Branch if not 00.
-------------------------------------------------------------------------------------------------------------------
$03/AC5A A5 AD LDA $AD    [$00:00AD] A:0000 X:0180 Y:0030 P:envMxdiZc - Load AD into A (Targeting?)
$03/AC5C 29 10 AND #$10 A:0020 X:0180 Y:0030 P:envMxdizc - Get rid of all bytes that are not 10.
$03/AC5E F0 17 BEQ $17    [$AC77] A:0000 X:0180 Y:0030 P:envMxdiZc - Branch if 00.
-------------------------------------------------------------------------------------

---------------------------------------------------------------------------------
$03/AC77 A9 FF LDA #$FF A:0000 X:0180 Y:0030 P:envMxdiZc - Load FF into A.
$03/AC79 A6 A6 LDX $A6    [$00:00A6] A:00FF X:0180 Y:0030 P:eNvMxdizc - Load A from A6.
$03/AC7B 9D 53 20 STA $2053,x[$7E:21D3] A:00FF X:0180 Y:0030 P:envMxdizc - Store A in Party Target.
$03/AC7E 60 RTS A:00FF X:0180 Y:0030 P:envMxdizc - Return

Whew! A lot of coding there, but worth it in some respects, the way the game draws spells can easily be discerned, but I somewhat doubt this set is used for monsters at all.









552
Well, I had a post all ready to go but now I've lost the vast majority of it due to my idiocy so here are the notes at least, but now I need to collect the pointers again and what they reference. Thankfully I saved (most) of the ASM work, I will need to redo Count again though.

Pointers to Status Expirations

Located at 038922

Status Expirations

03A897 - Stop Timer
03A8CC - Hold/Sleep Timer
03A8E6 - HP Leak
03A8FD - Poison
03A978 - Gradual Petrification
03A9D8 - Wall
03A9EF  - Count

Stop Timer Expiration

Code: [Select]
$03/A897 A6 A6 LDX $A6    [$00:00A6] A:0003 X:0000 Y:000D P:envMxdizc - Load Target Identifier.
$03/A899 BD 05 20 LDA $2005,x[$7E:2305] A:0003 X:0300 Y:000D P:envMxdizc - Load Status Byte 04 into A.
$03/A89C 29 BF AND #$BF A:0040 X:0300 Y:000D P:envMxdizc - Get rid of 40 (Stop) from A.
$03/A89E 9D 05 20 STA $2005,x[$7E:2305] A:0000 X:0300 Y:000D P:envMxdiZc - Store A in Status Byte 05.
$03/A8A1 AE 30 35 LDX $3530  [$7E:3530] A:0000 X:0300 Y:000D P:envMxdiZc - Load X from a Pointer x15?
$03/A8A4 9E 06 2A STZ $2A06,x[$7E:2A84] A:0000 X:007E Y:000D P:envMxdizc - Store Zero in Status Duration.
$03/A8A7 A9 03 LDA #$03 A:0000 X:007E Y:000D P:envMxdizc - Load 03 into A.
$03/A8A9 20 69 85 JSR $8569  [$03:8569] A:0003 X:007E Y:000D P:envMxdizc - Jump to Subroutine (??)
$03/A8AF BD 06 2A LDA $2A06,x[$7E:2A87] A:0000 X:0081 Y:000D P:envMxdizc - Load Status Duration into A.
$03/A8B2 10 0B BPL $0B    [$A8BF] A:0000 X:0081 Y:000D P:envMxdiZc - Branch if positive.
--------------------------------------------------------------------------------------------------
$03/A8B4 9E 06 2A STZ $2A06,x[$7E:2A12] A:0040 X:000C Y:000D P:envMxdizc - Store Zero in Status Duration3.
$03/A8B7 A9 01 LDA #$01 A:0040 X:000C Y:000D P:envMxdizc - Load 01 into A.
$03/A8B9 9D 04 2A STA $2A04,x[$7E:2A10] A:0040 X:000C Y:000D P:envMxdizc - Store A in Status Duration1.
$03/A8BC 9E 05 2A STZ $2A05,x[$7E:2A11] A:0040 X:000C Y:000D P:envMxdizc Store Zero in Status Duration2.
--------------------------------------------------------------------------------------------------------
$03/A8BF A5 D2 LDA $D2    [$00:00D2] A:0000 X:0081 Y:000D P:envMxdiZc - Load A from D2.
$03/A8C1 0A ASL A A:0006 X:0081 Y:000D P:envMxdizc - x2 A.
$03/A8C2 AA TAX A:000C X:0081 Y:000D P:envMxdizc - Transfer A to X.
$03/A8C3 BD EB 29 LDA $29EB,x[$7E:29F7] A:000C X:000C Y:000D P:envMxdizc - Load Status Expirations.
$03/A8C6 29 7F AND #$7F A:00C0 X:000C Y:000D P:eNvMxdizc - Get rid of 81.
$03/A8C8 9D EB 29 STA $29EB,x[$7E:29F7] A:0040 X:000C Y:000D P:envMxdizc - Store A in Status Expirations.
$03/A8CB 60 RTS A:0040 X:000C Y:000D P:envMxdizc - Return



Sleep/Paralysis Timer Expiration.
Code: [Select]
$03/A8CC A6 A6 LDX $A6    [$00:00A6] A:0003 X:0002 Y:000D P:envMxdizc - Load Target Identifier.
$03/A8CE BD 04 20 LDA $2004,x[$7E:2404] A:0003 X:0400 Y:000D P:envMxdizc - Load Status Byte 2.
$03/A8D1 29 CF AND #$CF A:0020 X:0400 Y:000D P:envMxdizc - Get rid of Sleep and Paralysis (30)
$03/A8D3 9D 04 20 STA $2004,x[$7E:2404] A:0000 X:0400 Y:000D P:envMxdiZc - Store A in Status Byte 2.
$03/A8D6 64 D6 STZ $D6    [$00:00D6] A:0000 X:0400 Y:000D P:envMxdiZc - Store Zero in D6.
$03/A8D8 A5 D2 LDA $D2    [$00:00D2] A:0000 X:0400 Y:000D P:envMxdiZc - Load A from D2.
$03/A8DA 20 36 9E JSR $9E36  [$03:9E36] A:0008 X:0400 Y:000D P:envMxdizc - Jump to Subroutine (??)
$03/A8DD A9 03 LDA #$03 A:0000 X:0041 Y:0041 P:envMxdizc - Load 03 into A.
$03/A8DF 20 C8 85 JSR $85C8  [$03:85C8] A:0003 X:0041 Y:0041 P:envMxdizc - ??
$03/A8E2 9E 06 2A STZ $2A06,x[$7E:2AB1] A:0000 X:00AB Y:0041 P:envMxdiZc - Store Zero in Status Duration
$03/A8E5 60 RTS A:0000 X:00AB Y:0041 P:envMxdiZc - Return.

HP Leak Expiration

Code: [Select]
$03/A8E6 A6 A6 LDX $A6    [$00:00A6] A:0003 X:0004 Y:000D P:envMxdizc - Load Target Identifier Byte
$03/A8E8 BD 06 20 LDA $2006,x[$7E:2206] A:0003 X:0200 Y:000D P:envMxdizc - Load Status Byte 04.
$03/A8EB 29 BF AND #$BF A:0040 X:0200 Y:000D P:envMxdizc - Get rid of 40 (HP Leak).
$03/A8ED 9D 06 20 STA $2006,x[$7E:2206] A:0000 X:0200 Y:000D P:envMxdiZc - Store A in Status Byte 04.
$03/A8F0 A5 D2 LDA $D2    [$00:00D2] A:0000 X:0200 Y:000D P:envMxdiZc - Load Pointer into A.
$03/A8F2 0A ASL A A:0004 X:0200 Y:000D P:envMxdizc  - x2 A.
$03/A8F3 AA TAX A:0008 X:0200 Y:000D P:envMxdizc - Transfer A to X.
$03/A8F4 BD EB 29 LDA $29EB,x[$7E:29F3] A:0008 X:0008 Y:000D P:envMxdizc - Load Status Duration into A.
$03/A8F7 29 DF AND #$DF A:0060 X:0008 Y:000D P:envMxdizc - Get rid of 20 bit.
$03/A8F9 9D EB 29 STA $29EB,x[$7E:29F3] A:0040 X:0008 Y:000D P:envMxdizc - Store A Status Duration.
$03/A8FC 60 RTS A:0040 X:0008 Y:000D P:envMxdizc - Return


Poison Progress (Is up several posts)




Gradual Petrification Progress

Code: [Select]
$03/A978 A6 A6 LDX $A6    [$00:00A6] A:0003 X:0008 Y:000D P:envMxdizc - Load Target Identifier into A.
$03/A97A BD 05 20 LDA $2005,x[$7E:2105] A:0003 X:0100 Y:000D P:envMxdizc - Load Target's Status Byte 3 into A.
$03/A97D 29 02 AND #$02 A:0000 X:0100 Y:000D P:envMxdiZc - Get rid of all bits that are not Jumping
$03/A97F D0 56 BNE $56    [$A9D7] A:0000 X:0100 Y:000D P:envMxdiZc - If Jumping branch to Return.
$03/A981 BD 06 20 LDA $2006,x[$7E:2106] A:0000 X:0100 Y:000D P:envMxdiZc - Load Status Byte 04.
$03/A984 30 51 BMI $51    [$A9D7] A:0001 X:0100 Y:000D P:envMxdizc - Branch if Hiding to Return.
$03/A986 BD 04 20 LDA $2004,x[$7E:2104] A:0001 X:0100 Y:000D P:envMxdizc - Load Status Byte 02.
$03/A989 29 03 AND #$03 A:0001 X:0100 Y:000D P:envMxdizc - Get rid of all bits that are not Petrify1/2.
$03/A98B 1A INC A A:0001 X:0100 Y:000D P:envMxdizc - +1 to A.
$03/A98C 85 A9 STA $A9    [$00:00A9] A:0002 X:0100 Y:000D P:envMxdizc - Store A in A9.
$03/A98E C9 04 CMP #$04 A:0002 X:0100 Y:000D P:envMxdizc - Is it 04? (Full Petrification)
$03/A990 D0 1D BNE $1D    [$A9AF] A:0002 X:0100 Y:000D P:eNvMxdizc If not, branch.
-------------------------------------------------------------------------------------------------------------
$03/A992 BD 04 20 LDA $2004,x[$7E:2104] A:0004 X:0100 Y:000D P:envMxdiZC - Load Status Byte 02 into A.
$03/A995 29 FC AND #$FC A:0003 X:0100 Y:000D P:envMxdizC - Get rid of these Petrify1/2.
$03/A997 9D 04 20 STA $2004,x[$7E:2104] A:0000 X:0100 Y:000D P:envMxdiZC - Store A in Status Byte 02.
$03/A99A BD 03 20 LDA $2003,x[$7E:2103] A:0000 X:0100 Y:000D P:envMxdiZC - Load Status byte 01. 
$03/A99D 09 40 ORA #$40 A:0000 X:0100 Y:000D P:envMxdiZC - Add Petrification to A.
$03/A99F 9D 03 20 STA $2003,x[$7E:2103] A:0040 X:0100 Y:000D P:envMxdizC - Store A in Status Byte 01.
$03/A9A2 A5 D2 LDA $D2    [$00:00D2] A:0040 X:0100 Y:000D P:envMxdizC - Load A from D2.
$03/A9A4 0A ASL A A:0002 X:0100 Y:000D P:envMxdizC - x2 A.
$03/A9A5 AA TAX A:0004 X:0100 Y:000D P:envMxdizc - Transfer A to X.
$03/A9A6 AD EB 29 LDA $29EB  [$7E:29EB] A:0004 X:0004 Y:000D P:envMxdizc - Load A from Status Expiration
$03/A9A9 29 F7 AND #$F7 A:0048 X:0004 Y:000D P:envMxdizc - Get rid of Bit 08.
$03/A9AB 8D EB 29 STA $29EB  [$7E:29EB] A:0040 X:0004 Y:000D P:envMxdizc - Store A in Status Expiration
$03/A9AE 60 RTS A:0040 X:0004 Y:000D P:envMxdizc - Return
-------------------------------------------------------------------------------------------------------------
$03/A9AF BD 04 20 LDA $2004,x[$7E:2104] A:0002 X:0100 Y:000D P:eNvMxdizc - Load Status Byte 02.
$03/A9B2 05 A9 ORA $A9    [$00:00A9] A:0001 X:0100 Y:000D P:envMxdizc - Add 1 if applicable.
$03/A9B4 9D 04 20 STA $2004,x[$7E:2104] A:0003 X:0100 Y:000D P:envMxdizc - Store A in Status Byte 02
$03/A9B7 A5 D2 LDA $D2    [$00:00D2] A:0003 X:0100 Y:000D P:envMxdizc - Load D2 into A.
$03/A9B9 0A ASL A A:0002 X:0100 Y:000D P:envMxdizc - x2 A.
$03/A9BA AA TAX A:0004 X:0100 Y:000D P:envMxdizc - Transfer A to X.
$03/A9BB BD 44 2B LDA $2B44,x[$7E:2B48] A:0004 X:0004 Y:000D P:envMxdizc - Load A from 2B44.
$03/A9BE 85 A9 STA $A9    [$00:00A9] A:0021 X:0004 Y:000D P:envMxdizc - Store A in A9.
$03/A9C0 BD 45 2B LDA $2B45,x[$7E:2B49] A:0021 X:0004 Y:000D P:envMxdizc - Load A from 2B46.
$03/A9C3 85 AA STA $AA    [$00:00AA] A:0000 X:0004 Y:000D P:envMxdiZc - Store A in AA
$03/A9C5 AE 55 35 LDX $3555  [$7E:3555] A:0000 X:0004 Y:000D P:envMxdiZc - Load X into 3555.
$03/A9C8 A5 A9 LDA $A9    [$00:00A9] A:0000 X:0036 Y:000D P:envMxdizc - Load A from A9.
$03/A9CA 9D 04 2A STA $2A04,x[$7E:2A3A] A:0021 X:0036 Y:000D P:envMxdizc - Store A in Status Duration Slot.
$03/A9CD A5 AA LDA $AA    [$00:00AA] A:0021 X:0036 Y:000D P:envMxdizc - Load A from AA.
$03/A9CF 9D 05 2A STA $2A05,x[$7E:2A3B] A:0000 X:0036 Y:000D P:envMxdiZc - Store A in Status Duration Slot.
$03/A9D2 A9 40 LDA #$40 A:0000 X:0036 Y:000D P:envMxdiZc - Load 40 into A.
$03/A9D4 9D 06 2A STA $2A06,x[$7E:2A3C] A:0040 X:0036 Y:000D P:envMxdizc  Store A in Status Duration Slot.
$03/A9D7 60 RTS A:0040 X:0036 Y:000D P:envMxdizc - Return

Wall's Expiration Timer

Code: [Select]

$03/A9D8 A6 A6 LDX $A6    [$00:00A6] A:0003 X:000A Y:000D P:envMxdizc - Load Target Identifier into A.
$03/A9DA BD 06 20 LDA $2006,x[$7E:2206] A:0003 X:0200 Y:000D P:envMxdizc - Load Status Byte 04 into A.
$03/A9DD 29 DF AND #$DF A:0020 X:0200 Y:000D P:envMxdizc - Get rid of 20 Bit (Wall)
$03/A9DF 9D 06 20 STA $2006,x[$7E:2206] A:0000 X:0200 Y:000D P:envMxdiZc - Store A in Status Byte 04.
$03/A9E2 A5 D2 LDA $D2    [$00:00D2] A:0000 X:0200 Y:000D P:envMxdiZc - Load A from D2 (Possibly a pointer)
$03/A9E4 0A ASL A A:0004 X:0200 Y:000D P:envMxdizc - x2 A
$03/A9E5 AA TAX A:0008 X:0200 Y:000D P:envMxdizc - Transfer A to X.
$03/A9E6 BD EB 29 LDA $29EB,x[$7E:29F3] A:0008 X:0008 Y:000D P:envMxdizc - Load Status Duration into A.
$03/A9E9 29 FB AND #$FB A:0044 X:0008 Y:000D P:envMxdizc - Get rid of 4 Bit.
$03/A9EB 9D EB 29 STA $29EB,x[$7E:29F3] A:0040 X:0008 Y:000D P:envMxdizc Store A in Status Duration
$03/A9EE 60 RTS A:0040 X:0008 Y:000D P:envMxdizc - Return

Is this glitched? I noticed that the effect of Barrier does not wear when the Wall does and I tested this in battle. This seems like a fairly large oversight, but it is easy enough to fix and since I've never seen it as a bug for FFIV it seems to never have been noticed. To fix this you would just change...

$03/A9DD   29 DF   AND #$DF   A:0020   X:0200   Y:000D   P:envMxdizc - Get rid of 20 Bit (Wall)

To CF to make it account for Barrier as well.

Count Timer Expiration

Code: [Select]
$03/A9EF A6 A6 LDX $A6    [$00:00A6] A:0003 X:000C Y:000D P:envMxdizc - Load Target Identifier.
$03/A9F1 BD 05 20 LDA $2005,x[$7E:2011] A:0003 X:000C Y:000D P:envMxdizc - Load Status Byte 03 into A.
$03/A9F4 29 02 AND #$02 A:0003 X:000C Y:000D P:envMxdizc - Get rid of all but Jumping.
$03/A9F6 D0 16 BNE $16    [$AA0E] A:0003 X:000C Y:000D P:envMxdizc - If Jumping branch to Return.
$03/A9F8 BD 06 20 LDA $2006,x[$7E:2012] A:0003 X:000C Y:000D P:envMxdizc - Load Status Byte 04 into A.
$03/A9FB 30 11 BMI $11    [$AA0E] A:0003 X:000C Y:000D P:envMxdizc - Branch if Hiding to Return.
$03/A9FD A6 A6 LDX $A6    [$00:00A6] A:0003 X:000C Y:000D P:envMxdizc - Load Target Identifier (But you just did that!)
$03/A9FF BD 03 20 LDA $2003,x[$7E:200F] A:0003 X:000C Y:000D P:envMxdizc - Load Status Byte 01 into A.
$03/AA02 09 80 ORA #$80 A:0003 X:000C Y:000D P:envMxdizc - Add 80 (Death) if applicable.
$03/AA04 9D 03 20 STA $2003,x[$7E:200F] A:0003 X:000C Y:000D P:envMxdizc - Store A in Status Byte 01.
$03/AA07 A5 D2 LDA $D2    [$00:00D2] A:0003 X:000C Y:000D P:envMxdizc - Load A from D2.
$03/AA09 0A ASL A A:0003 X:000C Y:000D P:envMxdizc - x2 A
$03/AA0A AA TAX A:0003 X:000C Y:000D P:envMxdizc - Transfer A to X.
$03/AA0B 9E EB 29 STZ $29EB,x[$7E:29F7] A:0003 X:000C Y:000D P:envMxdizc - Store Zero in Status Expirations.
$03/AA0E 60 RTS A:0003 X:000C Y:000D P:envMxdizc - Return


And that covers all timers and what happens when those timers expire.

553
Well, that was interesting. I found what I was looking for and here is the useful information to the casual hacker who may not want to pore through code to find inexact numbers.

Sleep/Hold Timer

Enemy Only
$03/9ED2   BD 2F 20   LDA $202F,x[$7E:212F]   A:0000   X:0100   Y:0010   P:envMxdiZC - Load Target's "Status/Steal Defense" into A.

PC Only
$03/9ED7   BD 18 20   LDA $2018,x[$7E:2118]   A:0000   X:0100   Y:0010   P:envMxdiZc - Load Target's Will into A.

Timer
$03/9EE1   A9 2C   LDA #$2C   A:0027   X:0100   Y:0010   P:eNvMxdizC - Load 2C into A. (From there it subtracts 2C from the value of Will/Status Defense x4)

Wall/Barrier Timer

What is Loaded
$03/9F26   AD 7B 39   LDA $397B  [$7E:397B]   A:0003   X:0200   Y:0010   P:envMxdizc - Load Spell Power (10 for Wall Item and 20 for Barrier Item)
$03/9F2D   06 AD   ASL $AD    [$00:00AD]   A:0000   X:0200   Y:0010   P:envMxdiZc - x2 AD
$03/9F2F   26 AE   ROL $AE    [$00:00AE]   A:0000   X:0200   Y:0010   P:envMxdiZc - x2 AD (if over 255 only)

Timer
$03/9F34   69 1E   ADC #$1E   A:0000   X:0200   Y:0010   P:envMxdiZc - Add 1E into A. (Spell Power x2 +1E (30) Ticks.)

HP Leak - There's some kind of Wisdom+Will combo here which does... something, but it's likely not that major. What is the important part is this...

Timer
$03/9F6F   69 1E   ADC #$1E   A:0000   X:0000   Y:0010   P:envMxdiZc - Add 1E to A. (30 Ticks as DeathLike2's FAQ says.)

Stop

Timer is based on Spell Power only.

$03/9F7F   AD 7B 39   LDA $397B  [$7E:397B]   A:0003   X:0280   Y:0010   P:envMxdizc - Load Spell Power Byte

Poison/Gradual Petrification (Yes they share the same timer, not sure what idiot thought that was a good idea!)

Enemy
$03/9F12   BD 2F 20   LDA $202F,x[$7E:232F]   A:0001   X:0300   Y:0010   P:envMxdizc - Load A from Target's Status Defense

PC
$03/9F17   BD 16 20   LDA $2016,x[$7E:2026]   A:0023   X:0010   Y:0010   P:envMxdizc - Load A from Target's Modified Vitality

Timer
$03/9F1B   69 14   ADC #$14   A:000F   X:0300   Y:0010   P:envMxdizc - Add 14 to Target's Modified Vitality/Status Defense

And there you have it! All of the Status Timers to see where these are in ROM just add 1FE00 to these values. (Remember, non-headered ROM)

 :edit:
Heh, well Count's Timer is silly simple. It's the Spell Power of any spell that casts Count. All things with Count are mostly drawn from my initial Routine recording.

Count Routine






554
Far too long if you ask me, yes I noticed this as well that the game's battle system is generally slow, I even removed the "Damaged from Poison" text box because it is generally clear why something is taking the damage that they're taking. I do wonder if they made an error with HP Leak though, wearing off after 40 ticks of 1 HP seems ill-made, I imagine it was meant to go for a lot longer or deal a lot more damage at one point in time. But as far as I'm aware no remake has bothered to make it do more than that.

555
Now this is useful! Extraordinarily so, in fact! Great work there Avalanche! As I've said before, (I don't believe to you) supply me with a line and a hook and I can catch a fish of any size! This is definitely the line to catch the Status Timer school of fish (granted your notes show that you've already dived through there, but may not have recorded the specifics down). So I'll mop that up and we should have a lot more freedom on status ailment timers by the time I'm finished.

Also a note: The "unknown byte" referred to as 2F is used by Enemies to resist Steal, and apparently status timers. (May also deal something with Odin) That amount is always Enemy Level +0A and the only thing that can effect it is Porom's Cry which reduces this byte by half of her own "Steal Defense" (which is always a default 0A) so 05.

I'll post on my results and edit this post as I go through the list. Again, thank you for setting this straight! How careless of me to not notice that a pointer was being generated.



3 - 039EA3 is called when a Spell is Cast.
Code: [Select]
$03/9EA3 AD 7B 39 LDA $397B  [$7E:397B] A:0003 X:0180 Y:0010 P:envMxdizc - Load A from Spell Number
$03/9EA6 85 DF STA $DF    [$00:00DF] A:0041 X:0180 Y:0010 P:envMxdizc - Store A in DF.
$03/9EA8 A9 06 LDA #$06 A:0041 X:0180 Y:0010 P:envMxdizc - Load 06 into A.
$03/9EAA 85 E1 STA $E1    [$00:00E1] A:0006 X:0180 Y:0010 P:envMxdizc - Store A in E1.
$03/9EAC 20 E0 83 JSR $83E0  [$03:83E0] A:0006 X:0180 Y:0010 P:envMxdizc - Jump to Subroutine (??)
$03/83E0 64 E0 STZ $E0    [$00:00E0] A:0006 X:0180 Y:0010 P:envMxdizc - Store Zero in E0.
$03/9EAF A6 E3 LDX $E3    [$00:00E3] A:0000 X:0000 Y:0010 P:envMxdiZc - Load X from E3.
$03/9EB1 BF A0 97 0F LDA $0F97A0,x[$0F:9926] A:0000 X:0186 Y:0010 P:envMxdizc - Load A from ROM 0F97A0 (Spell Designation)
$03/9EB5 29 1F AND #$1F A:00A0 X:0186 Y:0010 P:eNvMxdizc - Get rid of bits.
$03/9EB7 AA TAX A:0000 X:0186 Y:0010 P:envMxdiZc - Transfer A to X.
$03/9EB8 86 A9 STX $A9    [$00:00A9] A:0000 X:0000 Y:0010 P:envMxdiZc - Store X in A9.
$03/9EBA 06 A9 ASL $A9    [$00:00A9] A:0000 X:0000 Y:0010 P:envMxdiZc - x2 A9.
$03/9EBC 26 AA ROL $AA    [$00:00AA] A:0000 X:0000 Y:0010 P:envMxdiZc - x2 AA
$03/9EBE AD 8B 38 LDA $388B  [$7E:388B] A:0000 X:0000 Y:0010 P:envMxdiZc - Load Battle-Type (Battle or Auto-Battle)
$03/9EC1 F0 04 BEQ $04    [$9EC7] A:0000 X:0000 Y:0010 P:envMxdiZc - If Normal Battle, branch.
---------------------------------------------------------------

--------------------------------------------------------------
$03/9EC7 20 E2 9F JSR $9FE2  [$03:9FE2] A:0000 X:0000 Y:0010 P:envMxdiZc - Jump to Subroutine  (??)
$03/9ECA 4C D9 9F JMP $9FD9  [$03:9FD9] A:0000 X:0000 Y:0010 P:envMxdiZc - Jump out of Routine.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
$03/9FD9 A4 AB LDY $AB    [$00:00AB] A:0000 X:0000 Y:0010 P:envMxdiZc - Load Y from AB.
$03/9FDB 10 02 BPL $02    [$9FDF] A:0000 X:0000 Y:0000 P:envMxdiZc - Branch if plus
----------------------------------------------------

-------------------------------------------------
$03/9FDF 84 D4 STY $D4    [$00:00D4] A:0000 X:0000 Y:0000 P:envMxdiZc - Store Y in D4.
$03/9FE1 60 RTS A:0000 X:0000 Y:0000 P:envMxdiZc - Return
(Of note, this jump to 9FD9 seems to be universal in these timer dealings.)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 

To my eyes it seems as if this routine is only meant to be used in Auto-Battles which likely makes the spell take place close to immediately rather than using it's actual Charge time, possibly? It did reveal that the Spell Number is stored somewhere when cast and where, so that could be useful.

4 - Sleep/Hold Timer 039ECD

Code: [Select]
$03/9ECD AD 58 35 LDA $3558  [$7E:3558] A:0003 X:0100 Y:0010 P:envMxdizc - PC or Enemy
$03/9ED0 F0 05 BEQ $05    [$9ED7] A:0000 X:0100 Y:0010 P:envMxdiZc - If PC branch.
-------------------------------------------------------------------------------------------------------
$03/9ED2 BD 2F 20 LDA $202F,x[$7E:212F] A:0000 X:0100 Y:0010 P:envMxdiZC - Load Target's "Status/Steal Defense" into A.
$03/9ED5 80 03 BRA $03    [$9EDA] A:0000 X:0100 Y:0010 P:envMxdiZC - Branch past the Will check.
----------------------------------------------------------------------------------------------------------
$03/9ED7 BD 18 20 LDA $2018,x[$7E:2118] A:0000 X:0100 Y:0010 P:envMxdiZc - Load Target's Will into A.
$03/9EDA 85 AD STA $AD    [$00:00AD] A:0027 X:0100 Y:0010 P:envMxdizc - Store A in AD.
$03/9EDC 06 AD ASL $AD    [$00:00AD] A:0027 X:0100 Y:0010 P:envMxdizc - x2 A
$03/9EDE 06 AD ASL $AD    [$00:00AD] A:0027 X:0100 Y:0010 P:envMxdizc - x2 A
$03/9EE0 38 SEC A:0027 X:0100 Y:0010 P:eNvMxdizc - Set Carry
$03/9EE1 A9 2C LDA #$2C A:0027 X:0100 Y:0010 P:eNvMxdizC - Load 2C into A.
$03/9EE3 E5 AD SBC $AD    [$00:00AD] A:002C X:0100 Y:0010 P:envMxdizC - Subtract 2C from Target's x4 Will/SD.
$03/9EE5 85 A9 STA $A9    [$00:00A9] A:0090 X:0100 Y:0010 P:eNVMxdizc - Store A in A9.
$03/9EE7 A9 01 LDA #$01 A:0090 X:0100 Y:0010 P:eNVMxdizc - Load 01 into A.
$03/9EE9 E9 00 SBC #$00 A:0001 X:0100 Y:0010 P:enVMxdizc - Subtract A?
$03/9EEB 85 AA STA $AA    [$00:00AA] A:0000 X:0100 Y:0010 P:envMxdiZC - Store A in AA.
$03/9EED B0 05 BCS $05    [$9EF4] A:0000 X:0100 Y:0010 P:envMxdiZC - Branch if 00 or less? (I fail to see how this could be anything but 00)
------------------------------------------------------------------------------------------------------
$03/9EEF A2 01 00 LDX #$0001 A:0000 X:0100 Y:0010 P:envMxdiZC - Load 0001 into X.
$03/9EF2 86 A9 STX $A9    [$00:00A9] A:0000 X:0100 Y:0010 P:envMxdiZC - Store X in A9. (Seems to be an "If below 00, make 01"?
-------------------------------------------------------------------------------------------------------
$03/9EF4 20 E2 9F JSR $9FE2  [$03:9FE2] A:0000 X:0100 Y:0010 P:envMxdiZC - ? Universal to Status Timers.
$03/9EF7 A6 AB LDX $AB    [$00:00AB] A:0000 X:0090 Y:0010 P:envMxdizc - Load X from AB (Speed Modifier?)
$03/9EF9 8E 45 39 STX $3945  [$7E:3945] A:0000 X:0090 Y:0010 P:envMxdizc - Store X in 3945.
$03/9EFC A2 06 00 LDX #$0006 A:0000 X:0090 Y:0010 P:envMxdizc - Load 0006 into X.
$03/9EFF 8E 47 39 STX $3947  [$7E:3947] A:0000 X:0006 Y:0010 P:envMxdizc - Store X in 3947.
$03/9F02 20 07 84 JSR $8407  [$03:8407] A:0000 X:0006 Y:0010 P:envMxdizc - ??
$03/8407 C2 20 REP #$20 A:0000 X:0006 Y:0010 P:envMxdizc - Reset Processor Status
$03/9F05 AE 49 39 LDX $3949  [$7E:3949] A:0000 X:0000 Y:0010 P:envMxdiZc - Load X from 3949.
$03/9F08 86 AB STX $AB    [$00:00AB] A:0000 X:0018 Y:0010 P:envMxdizc - Store X in AB
$03/9F0A 4C D9 9F JMP $9FD9  [$03:9FD9] A:0000 X:0018 Y:0010 P:envMxdizc - Finish status Timer (Universal to Status Timers)


That 2C would likely be the matter to change for Paralysis/Sleep Status from a default point. I'm not sure I saw where a /16 or a /6 was. Did I miss the meaning somewhere in there?


Poison's already been taken care of, so... wait, Gradual Petrification is in there as well...? Hmm... phew, well I can just tie Gradual Petrification's timer than to the timer of Hold/Sleep, the timing seems similar and I would think that a magical fortitude would be better for resisting the petrification of the body personally.

This did alert me to a really stupid coding mistake I made with Rebalanced Poison though, oy... I set the resistance to 201F, rather than the character's innate "Status Defense" byte.


8 - Timer used by Wall/(Barrier?) 039F26

Code: [Select]
$03/9F26 AD 7B 39 LDA $397B  [$7E:397B] A:0003 X:0200 Y:0010 P:envMxdizc - Load Spell Power (Why it's spell power and not in the Spell Cast, I have no idea) into A.
$03/9F29 85 AD STA $AD    [$00:00AD] A:0000 X:0200 Y:0010 P:envMxdiZc - Store A in AD
$03/9F2B 64 AE STZ $AE    [$00:00AE] A:0000 X:0200 Y:0010 P:envMxdiZc - Store Zero in AE.
$03/9F2D 06 AD ASL $AD    [$00:00AD] A:0000 X:0200 Y:0010 P:envMxdiZc - x2 AD
$03/9F2F 26 AE ROL $AE    [$00:00AE] A:0000 X:0200 Y:0010 P:envMxdiZc - x2 AD
$03/9F31 18 CLC A:0000 X:0200 Y:0010 P:envMxdiZc - Clear Carry Flag.
$03/9F32 A5 AD LDA $AD    [$00:00AD] A:0000 X:0200 Y:0010 P:envMxdiZc - Load the value from AD into A.
$03/9F34 69 1E ADC #$1E A:0000 X:0200 Y:0010 P:envMxdiZc - Add 1E into A.
$03/9F36 85 A9 STA $A9    [$00:00A9] A:001E X:0200 Y:0010 P:envMxdizc - Store A in A9.
$03/9F38 A5 AE LDA $AE    [$00:00AE] A:001E X:0200 Y:0010 P:envMxdizc - Load the value from AE into A.
$03/9F3A 69 00 ADC #$00 A:0000 X:0200 Y:0010 P:envMxdiZc - Add 00.
$03/9F3C 85 AA STA $AA    [$00:00AA] A:0000 X:0200 Y:0010 P:envMxdiZc - Store A in AA.
$03/9F3E 20 E2 9F JSR $9FE2  [$03:9FE2] A:0000 X:0200 Y:0010 P:envMxdiZc - ? Universal to Status Timers.
$03/9F41 4C D9 9F JMP $9FD9  [$03:9FD9] A:0000 X:0046 Y:0010 P:envMxdizc - Finish Status Timer.

An interesting thought, so it takes the Spell Power of which Wall is being used (default Wall spell is 00, Item is 10, and Barrier is 14) and x4's that value before adding 1E to it. Simple enough, and simple enough for anyone desiring to change.


9 - HP Leak 039F44

Code: [Select]
$03/9F44 AD 58 35 LDA $3558  [$7E:3558] A:0003 X:0080 Y:0010 P:envMxdizc - PC or Enemy
$03/9F47 F0 0B BEQ $0B    [$9F54] A:0000 X:0080 Y:0010 P:envMxdiZc - Branch if Enemy
-------------------------------------------------
$03/9F49 BD 2F 20 LDA $202F,x[$7E:204D] A:0000 X:001E Y:0010 P:envMxdizc - Load Enemy's Status Resistance Byte
$03/9F4C 85 AD STA $AD    [$00:00AD] A:0000 X:001E Y:0010 P:envMxdizc - Store A in AD.
$03/9F4E A9 04 LDA #$04 A:0000 X:001E Y:0010 P:envMxdizc - Load 04 into A.
$03/9F50 85 AE STA $AE    [$00:00AE] A:0000 X:001E Y:0010 P:envMxdizc - Store A in AE,
$03/9F52 80 0D BRA $0D    [$9F61] A:0000 X:001E Y:0010 P:envMxdizc - Branch past Wisdom/Will adding.
-------------------------------------------------
$03/9F54 18 CLC A:0000 X:0080 Y:0010 P:envMxdiZc - Clear Carry Flag
$03/9F55 BD 17 20 LDA $2017,x[$7E:2097] A:0000 X:0080 Y:0010 P:envMxdiZc - Load Target's Modified Wisdom
$03/9F58 7D 18 20 ADC $2018,x[$7E:2098] A:0003 X:0080 Y:0010 P:envMxdizc - Add Target's Modified Will - Store value in AD.
$03/9F5B 85 AD STA $AD    [$00:00AD] A:0009 X:0080 Y:0010 P:envMxdizc - Store A in AD.
$03/9F5D A9 02 LDA #$02 A:0009 X:0080 Y:0010 P:envMxdizc - Load 02 into A.
$03/9F5F 85 AE STA $AE    [$00:00AE] A:0002 X:0080 Y:0010 P:envMxdizc - Store A in AE.
$03/9F61 A5 AD LDA $AD    [$00:00AD] A:0002 X:0080 Y:0010 P:envMxdizc - Load Wisdom+Will into A.
$03/9F63 85 DF STA $DF    [$00:00DF] A:0009 X:0080 Y:0010 P:envMxdizc - Store A in DF.
$03/9F65 A5 AE LDA $AE    [$00:00AE] A:0009 X:0080 Y:0010 P:envMxdizc - Load AE into A.
$03/9F67 85 E2 STA $E2    [$00:00E2] A:0002 X:0080 Y:0010 P:envMxdizc - Store A in E2.
$03/9F69 20 E0 83 JSR $83E0  [$03:83E0] A:0002 X:0080 Y:0010 P:envMxdizc - Jump to Subroutine (??)
$03/9F6C 18 CLC A:0000 X:0000 Y:0010 P:envMxdiZc - Clear Carry Flag
$03/9F6D A5 E3 LDA $E3    [$00:00E3] A:0000 X:0000 Y:0010 P:envMxdiZc - Load A from E3.
$03/9F6F 69 1E ADC #$1E A:0000 X:0000 Y:0010 P:envMxdiZc - Add 1E to A.
$03/9F71 85 A9 STA $A9    [$00:00A9] A:001E X:0000 Y:0010 P:envMxdizc - Store A in A9.
$03/9F73 A5 E4 LDA $E4    [$00:00E4] A:001E X:0000 Y:0010 P:envMxdizc - Load A from E4.
$03/9F75 69 00 ADC #$00 A:0000 X:0000 Y:0010 P:envMxdiZc - Add 00 into A.
$03/9F77 85 AA STA $AA    [$00:00AA] A:0000 X:0000 Y:0010 P:envMxdiZc - Store A in AA.
$03/9F79 20 E2 9F JSR $9FE2  [$03:9FE2] A:0000 X:0000 Y:0010 P:envMxdiZc - ? Universal to Status Timers
$03/9F7C 4C D9 9F JMP $9FD9  [$03:9FD9] A:0000 X:001E Y:0010 P:envMxdizc - Finish Status Timers.


I thought that HP Leak was a guaranteed 30 ticks? This shows a different reality, what that means is difficult though. You can change the 1E to anything you like though and generally that makes it so you can control the duration.

 A: (SpellPowerByte? * 3) * SpeedModifier / 16
        Used by Stop, Magnet. I think Stop passes 10 decimal, Magnet 50 decimal. - 039F7F

Code: [Select]
$03/9F7F AD 7B 39 LDA $397B  [$7E:397B] A:0003 X:0280 Y:0010 P:envMxdizc - Load Spell Power Byte
$03/9F82 85 DF STA $DF    [$00:00DF] A:0032 X:0280 Y:0010 P:envMxdizc - Store Spell Power in DF.
$03/9F84 A9 03 LDA #$03 A:0032 X:0280 Y:0010 P:envMxdizc - Load 03 into A.
$03/9F86 85 E1 STA $E1    [$00:00E1] A:0003 X:0280 Y:0010 P:envMxdizc - Store A in E1.
$03/9F88 20 E0 83 JSR $83E0  [$03:83E0] A:0003 X:0280 Y:0010 P:envMxdizc - Jump to Subroutine (??)
$03/9F8B A6 E3 LDX $E3    [$00:00E3] A:0000 X:0000 Y:0010 P:envMxdiZc - Load X from E3.
$03/9F8D 86 A9 STX $A9    [$00:00A9] A:0000 X:0096 Y:0010 P:envMxdizc - Store X in A9.
$03/9F8F 20 E2 9F JSR $9FE2  [$03:9FE2] A:0000 X:0096 Y:0010 P:envMxdizc - ? Universal to Status Timers
$03/9F92 4C D9 9F JMP $9FD9  [$03:9FD9] A:0000 X:0096 Y:0010 P:envMxdizc - Finish Status Timers.
Well, that was short. Like Very short. Apparently that's stop. Hah.

Count still needs accounted for so it must be one of these remaining ones.

Count is in 03A005, which is even before the normal timer, they must have really wanted this status.

-1 - Count 039E6F

Code: [Select]
$03/9E6F 20 E2 9F JSR $9FE2  [$03:9FE2] A:0003 X:0300 Y:0010 P:envMxdizc - ? Universal in Status Timers
$03/9FE2 A6 A9 LDX $A9    [$00:00A9] A:0003 X:0300 Y:0010 P:envMxdizc - Load X from A9.
$03/9E72 A4 AB LDY $AB    [$00:00AB] A:0000 X:0041 Y:0010 P:envMxdizc - Load Y from AB.
$03/9E74 D0 02 BNE $02    [$9E78] A:0000 X:0041 Y:0041 P:envMxdizc - Branch if not 00.
------------------------------------------
$03/9E76 E6 AB INC $AB    [$00:00AB] A:0000 X:0041 Y:0041 P:envMxdizc - +1 to AB
--------------------------------------------
$03/9E78 4C D9 9F JMP $9FD9  [$03:9FD9] A:0000 X:0041 Y:0041 P:envMxdizc - Finish Status Timer (What?!)

Well... that was uneventful, so nothing with Count is actually in Count's status timer address.


Well that covers (most) Status Timers. Now it's just a matter of finding specifics in the Status themselves.