øAslickproductions.org/forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&action=printpage;topic=304.0e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/indexa6c3-2.htmlslickproductions.org/forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&topic=304.0e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/indexa6c3-2.html.zxltg^ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÈÐ8±OKtext/htmlISO-8859-1gzip8:Ö8±ÿÿÿÿÿÿÿÿTue, 10 Mar 2020 11:21:39 GMT0ó°° ®0®P®€§²ð®ltg^ÿÿÿÿÿÿÿÿ 8± Print Page - Recall Command

Board of Slick

Library of the Ancients => Final Fantasy IV Research & Development => Topic started by: Deathlike2 on February 18, 2008, 12:33:39 AM

Title: Recall Command
Post by: Deathlike2 on February 18, 2008, 12:33:39 AM
I will replay FF4 (mainly for another stat maxing run), but I will post the spells I recall from memory (ironic) that are included there. I will verify it once I get Tellah and get back to Kaipo for infinite MP usage+testing (or maybe I'll hack in 99 Tinctures/Ethers to make life easier)...

Common:
Ice1, Fire1, Lit1

Uncommon:
Ice2, Fire2, Lit2
Ice3, Fire3, Lit3
Toad
Bio
Break (Stone), Tornado (Weak)
Doom/Death/Fatal, Flare (Nuke)

Not Cast Ever:
Osmose (Psych), Drain
Quake
Meteor

Not Sure Of:
Piggy
Venom, Sleep, Stop

IIRC, he casts a small number of White Magic (the offensive kind).. but I'll have to really test to be sure.

I'll try to remember to take pictures while I do this.
Title: Re: Recall Command
Post by: Pinkpuff on February 18, 2008, 05:59:56 AM
He can cast split Flare off Recall??
Title: Re: Recall Command
Post by: Deathlike2 on February 18, 2008, 07:06:52 AM
He can cast split Flare off Recall??

I believe he tried to once... but he managed to not have enough MP for that.  :tongue:
Title: Re: Recall Command
Post by: Pinkpuff on February 18, 2008, 10:05:28 AM
Wow, that's awesome! I think Recall might actually have been usable if it either worked all the time or didn't cost MP. In fact I think even if both restrictions were lifted it still might not be overpowered.
Title: Re: Recall Command
Post by: Deathlike2 on February 18, 2008, 10:36:36 AM
Ok, the list of casted spells seems to be short... though I need to do more testing to be sure..

Common:
Ice1, Fire1, Lit1

Semi-common:
Bio
Toad
Break (Stone), Tornado (Weak)
Death/Doom/Fatal

This confirms all of what Dragonsbreathern has said.

Recalled spells are not treated as a magical attack. Monsters like the larva (who cast Osmose when attacked) and the Waterbug monster (who heal when attacked by magic) don't react as if it was a magic attack.
Title: Re: Recall Command
Post by: Paladin on February 18, 2008, 12:43:06 PM
He can cast split Flare off Recall??

On this topic, I did some fairly extensive testing of the stock magic graphics this weekend and found a few interesting things.

While you could split the effects of the flare spell itself (the routine) You can't split flare's graphics, or at least the "descending orbs" part of it in a multicast spell. Well you can if you force the game to do so, but the graphics bug up (so it will work, just it looks ugly).

So the game shouldn't be trying to multicast Nuke/Flare with recall. If it is I'd be really surprised.

Also remember that if you're playing an unmodified version  of FF-II and the cast name actually is "Flare", then that's the Twin command "Little Flare / Pyro" spell. It CAN be mulitcast.
Title: Re: Recall Command
Post by: Deathlike2 on February 18, 2008, 04:20:36 PM
An additional detail... if Tellah doesn't have enough MP to cast selected spell, he will use the fail reaction instead of attempting to cast the spell.

I wonder if Tellah's fail reaction is in response to not being able to cast a "9th spell" Meteo? Doubtful but... an interesting thought.

Edit: It's not... oh well, wishful thinking

This command allows for two spells to normally not be multitargetable to be just that (Tornado and Death... multitargeted Tornado is effectively the Behemoth's Storm).. and allow Tellah to cast Death when he normally doesn't obtain said spell (which is strange for the most part).
Title: Re: Recall Command
Post by: Paladin on February 18, 2008, 06:19:19 PM
I still have a couple combinations that I want to test, so I don't have a complete list yet, but there were very few spells that (had graphics that) bugged up when multi-targeted.
For all intents and purposes it *appears* that any spell can be multi-targeted, the only problem is if the stock graphics will comply.

For example Dark Bahamut/Wyvern does cast a multi-targeted version of flare (MegaNuke), it just doesn't have the descending orbs pre-effect.

Figuring out what the spell VFX bytecodes do is rather complicated...When I get more data compiled I will have an Excel Spreadsheet that I will post.


Title: Re: Recall Command
Post by: Deathlike2 on February 18, 2008, 10:24:16 PM
New info: The GBA version treats this command as a magical attack which is obviously logical. That is currently the only difference between the SNES version and the GBA version.
Title: Re: Recall Command
Post by: Deathlike2 on February 19, 2008, 10:56:53 PM
As I promised.. some pics!

(http://img208.imageshack.us/img208/5732/finalfantasyivj00007tc4.th.png) (http://img208.imageshack.us/my.php?image=finalfantasyivj00007tc4.png)

(http://img214.imageshack.us/img214/8673/finalfantasyivj00008kr6.th.png) (http://img214.imageshack.us/my.php?image=finalfantasyivj00008kr6.png)

(http://img208.imageshack.us/img208/8058/finalfantasyivj00009fm4.th.png) (http://img208.imageshack.us/my.php?image=finalfantasyivj00009fm4.png)

(http://img441.imageshack.us/img441/9715/finalfantasyivj00010na0.th.png) (http://img441.imageshack.us/my.php?image=finalfantasyivj00010na0.png)

(http://img208.imageshack.us/img208/1576/finalfantasyivj00012fa5.th.png) (http://img208.imageshack.us/my.php?image=finalfantasyivj00012fa5.png)

Edit: Added a better picture of Break.

(http://img175.imageshack.us/img175/3808/finalfantasyivj00014zm9.th.png) (http://img175.imageshack.us/my.php?image=finalfantasyivj00014zm9.png)
Title: Re: Recall Command
Post by: Deathlike2 on March 03, 2008, 04:47:37 PM
This command is disabled while under Silence.
Title: Re: Recall Command
Post by: Phoenix on March 31, 2008, 03:09:10 AM
Here’s what I’ve figured out about the Recall subroutine:

The spells casted written above are correct: Recall casts Fire1, Ice-1, Lit-1, Stone, Virus, Weak, Fatal, or Toad. The code to determine which spell is casted is like so:

Code: [Select]
r = random number between 0x00 and 0xA0
if 0x00 <= r < 0x08 then spell is 0x2A = Stone
if 0x08 <= r < 0x10 then spell is 0x26 = Virus
if 0x10 <= r < 0x18 then spell is 0x27 = Weak
if 0x18 <= r < 0x20 then spell is 0x2B = Fatal
if 0x20 <= r < 0x38 then spell is 0x1D = Fire1
if 0x38 <= r < 0x50 then spell is 0x20 = Ice-1
if 0x50 <= r < 0x68 then spell is 0x23 = Lit-1
if 0x68 <= r < 0x80 then spell is 0x19 = Toad
if 0x80 <= r < 0xA0 then fail?

I’m not exactly sure what that last part is, it loads battle message 09 (which isn’t displayed or used as far as I can tell) and does something else I don't understand. Does Recall ever fail even if you have enough MP? Anyone know?

For the spells, Fire1/Ice-1/Lit-1/Toad have a three times greater chance of being casted than Stone/Virus/Weak/Fatal. The former have 24 possible values each for the random number, while the latter only have 8 each.
Title: Re: Recall Command
Post by: Deathlike2 on March 31, 2008, 07:15:17 AM
I wrote some other stuff on this...

No, there is no message ever loaded for this commmand.

Yes, not enough MP causes automatic failure.

The only time the "Not Enough MP" message is displayed is when a target is Charmed and simply doesn't have enough MP to cast the spell that was randomly selected.

It's possible that that message was meant to be displayed in this case where he doesn't have enough MP to cast the spell, but it never gets executed apparently...

Failure to cast the spell due to MP or no spell being selected have the same visual actions.
Title: Re: Recall Command
Post by: Entroper on March 31, 2008, 02:51:32 PM
So, 5% each Stone, Virus, Weak, Fatal.  15% each Fire1, Ice-1, Lit-1, Toad.  20% fail.  Those numbers work out very nicely.
Title: Re: Recall Command
Post by: Deathlike2 on March 31, 2008, 03:35:44 PM
It might sounds strange, but Toad is probably the most useful spell of the bunch, given the implications of the status itself vs MP consumption.
Title: Re: Recall Command
Post by: Cleteromagos on April 27, 2008, 06:09:46 AM
Quote from: Deathlike
The only time the "Not Enough MP" message is displayed is when a target is Charmed and simply doesn't have enough MP to cast the spell that was randomly selected.

 :hmm:

Unless I remember incorrectly (a distinct possibility), in FFIV (the SFC version at the very least), MP needed to cast a spell is subtracted at the moment casting is begun (as opposed to upon casting). Spells in a menu may be dimmed out based on MP at the time the menu is generated to prohibit the selection of a spell which cannot be cast due to a lack thereof. Due to this, schematically it would appear to be impossible for the player to initiate casting of a spell which could fail based on lack of MP.

However, if a character’s MP is siphoned away after the menu is called and before it is dismissed, it is not updated and the player can select a spell which should be greyed-out (this was not the case in FFVI, and probably also V). In the case of this anomaly, the game will see the PC go through the required casting time before calling the dialogue box in question: “Not enough MP.â€

Obviously, the message is also seen whenever a monster attempts to cast a spell as a matter of course without enough MP.

Quote from: Deathlike
It might sounds strange, but Toad is probably the most useful spell of the bunch, given the implications of the status itself vs MP consumption.
Are there enemies which Tornado would fail on, considering the period in which the command is available …?

Title: Re: Recall Command
Post by: Deathlike2 on April 27, 2008, 09:11:34 AM
Quote from: Deathlike
The only time the "Not Enough MP" message is displayed is when a target is Charmed and simply doesn't have enough MP to cast the spell that was randomly selected.

 :hmm:

Unless I remember incorrectly (a distinct possibility), in FFIV (the SFC version at the very least), MP needed to cast a spell is subtracted at the moment casting is begun (as opposed to upon casting). Spells in a menu may be dimmed out based on MP at the time the menu is generated to prohibit the selection of a spell which cannot be cast due to a lack thereof. Due to this, schematically it would appear to be impossible for the player to initiate casting of a spell which could fail based on lack of MP.

However, if a character’s MP is siphoned away after the menu is called and before it is dismissed, it is not updated and the player can select a spell which should be greyed-out (this was not the case in FFVI, and probably also V). In the case of this anomaly, the game will see the PC go through the required casting time before calling the dialogue box in question: “Not enough MP.”

That's usually the other possibility, but the number of monsters that cast Psych/Osmose are far and few between (there's the Dark Sage, and the Insectus monsters in FF4A, the Insectus uses it as a magic counter though).

Quote
Obviously, the message is also seen whenever a monster attempts to cast a spell as a matter of course without enough MP.

No, that never happens. Monsters never consume MP. Consider Scarmaglione (the "living" version). His primary attack is Thunder. If Tellah syphons all of his MP, his attack will still occur, regardless. If Thunder ever misses, that's due to magic evade that all characters have except for Dark Knight Cecil.

Quote
Quote from: Deathlike
It might sounds strange, but Toad is probably the most useful spell of the bunch, given the implications of the status itself vs MP consumption.
Are there enemies which Tornado would fail on, considering the period in which the command is available …?

Other than the bosses, no monster is ever immune to the spell. It may be difficult, but that's only because there is a level comparison done.

The Tornado spell has the boss bit set, so it always fails to work on a boss. On the other hand, the one on Abel's Lance is not, which is the only difference. I'm not sure if any other property is different, other than the "set monster to death" vs when Abel Lance's Tornado is used. I believe a custom version of the spell is written for that weapon anyways, the original spell would not do that, even if the boss bit was removed.
Title: Re: Recall Command
Post by: Dragonsbrethren on June 20, 2008, 10:12:01 PM
Phoenix, do you have a disassembly of this command handy? I was going to make one myself, then I remembered (What is it with me and stupid puns tonight?) this thread. I'm going to upgrade it a bit for my hack, far less (Or maybe no) chance of failing, level 2 elementals, but I'll probably scrap the tornado and death effects.
Title: Re: Recall Command
Post by: Phoenix on June 20, 2008, 11:24:24 PM
Indeed I do, and lucky for you, I've also commented the whole routine (not saying whether I'm completely right or not, but those are my thoughts). The offsets are for FF2us 1.0 (headered), as usual. Here's the disassembly from my ASM Interpreter (again, it might be wrong, so double check yourself!):

Code: [Select]
Offset Hex Data ASM Interpretation Comments
------ -------- ------------------ --------
1EC05 7B Transfer D to A ; zero out A
1EC06 AA Transfer A to X ; zero out X
1EC07 A9 A0 Load A with #A0 ; A = #A0
1EC09 20 79 83 Jump to subroutine at 18579 ; < Sets A to a random number between X and A >
1EC0C C9 08 Compare A with #08 ; let the random number be r
1EC0E B0 04 Branch to 1EC14 if carry is set ; if r < #8
1EC10 A9 2A Load A with #2A ; spell #2A = Stone
1EC12 80 40 Branch to 1EC54 ;
1EC14 C9 10 Compare A with #10 ;
1EC16 B0 04 Branch to 1EC1C if carry is set ; if #8 <= r < #10
1EC18 A9 26 Load A with #26 ; spell #26 = Virus
1EC1A 80 38 Branch to 1EC54 ;
1EC1C C9 18 Compare A with #18 ;
1EC1E B0 04 Branch to 1EC24 if carry is set ; if #10 <= r < #18
1EC20 A9 27 Load A with #27 ; spell #27 = Weak
1EC22 80 30 Branch to 1EC54 ;
1EC24 C9 20 Compare A with #20 ;
1EC26 B0 04 Branch to 1EC2C if carry is set ; if #18 <= r < #20
1EC28 A9 2B Load A with #2B ; spell #2B = Fatal
1EC2A 80 28 Branch to 1EC54 ;
1EC2C C9 38 Compare A with #38 ;
1EC2E B0 04 Branch to 1EC34 if carry is set ; if #20 <= r < #38
1EC30 A9 1D Load A with #1D ; spell #1D = Fire1
1EC32 80 20 Branch to 1EC54 ;
1EC34 C9 50 Compare A with #50 ;
1EC36 B0 04 Branch to 1EC3C if carry is set ; if #38 <= r < #50
1EC38 A9 20 Load A with #20 ; spell #20 = Ice-1
1EC3A 80 18 Branch to 1EC54 ;
1EC3C C9 68 Compare A with #68 ;
1EC3E B0 04 Branch to 1EC44 if carry is set ; if #50 <= r < #68
1EC40 A9 23 Load A with #23 ; spell #23 = Lit-1
1EC42 80 10 Branch to 1EC54 ;
1EC44 C9 80 Compare A with #80 ;
1EC46 B0 04 Branch to 1EC4C if carry is set ; if #68 <= r < #80
1EC48 A9 19 Load A with #19 ; spell #19 = Toad
1EC4A 80 08 Branch to 1EC54 ;
1EC4C A9 09 Load A with #09 ; if #80 <= r < #A0
1EC4E 8D CA 34 Store A to $7E:34CA ; load message #09?
1EC51 4C B1 85 Jump to location 187B1 ; < 33C8 = #F8, 33C9 = #03 > = special
1EC54 48 Push A (1 byte) onto stack ; A = #03?
1EC55 AA Transfer A to X ;
1EC56 86 E5 Store X to $00:D+$E5 ; E5 = #03?
1EC58 A2 A0 97 Load X with #97A0 ; \
1EC5B 86 80 Store X to $00:D+$80 ;  |
1EC5D A9 0F Load A with #0F ;  | Load spell/item effect
1EC5F 85 82 Store A to $00:D+$82 ;  | data into 289C-A1
1EC61 A9 06 Load A with #06 ;  |
1EC63 20 5E 84 Jump to subroutine at 1865E ; /
1EC66 AD A0 28 Load A with 1 byte at $7E:28A0 ; \
1EC69 29 7F 'AND' A with #7F ;  |
1EC6B 85 DF Store A to $00:D+$DF ;  |
1EC6D A9 03 Load A with #03 ;  |
1EC6F 85 E1 Store A to $00:D+$E1 ;  |
1EC71 20 E0 83 Jump to subroutine at 185E0 ;  | Load 28A2-4 with
1EC74 A6 E3 Load X with 2 bytes at $00:D+$E3 ;  | element/status effect
1EC76 7B Transfer D to A ;  | data of spell
1EC77 A8 Transfer A to Y ;  |
1EC78 BF 90 A5 0F Load A with 1 byte at 7A790+X ;  |
1EC7C 99 A2 28 Store A to $7E:28A2+Y ;  |
1EC7F C8 Increment Y ;  |
1EC80 E8 Increment X ;  |
1EC81 C0 03 00 Compare Y with #0003 ;  |
1EC84 D0 F2 Branch to 1EC78 if zero flag is clear ; /
1EC86 AD 8B 26 Load A with 1 byte at $7E:268B ; \
1EC89 85 A9 Store A to $00:D+$A9 ;  |
1EC8B AD 8C 26 Load A with 1 byte at $7E:268C ;  | A9 = current MP
1EC8E F0 04 Branch to 1EC94 if zero flag is set ;  | = #FF if > #FF
1EC90 A9 FF Load A with #FF ;  |
1EC92 85 A9 Store A to $00:D+$A9 ; /
1EC94 AD A1 28 Load A with 1 byte at $7E:28A1 ; \
1EC97 29 7F 'AND' A with #7F ;  | Compare MP cost with
1EC99 C5 A9 Compare A with data at $00:D+$A9 ;  | character's current MP
1EC9B F0 06 Branch to 1ECA3 if zero flag is set ;  |
1EC9D 90 04 Branch to 1ECA3 if carry is clear ;  | if MP cost is <= current MP
1EC9F 68 Pull 1 byte from stack and store in A ;  | then A = spell number
1ECA0 4C AD EA Jump to location 1ECAD ;  | else return
1ECA3 68 Pull 1 byte from stack and store in A ;  |
1ECA4 8D D2 26 Store A to $7E:26D2 ; /
1ECA7 EE 5D 35 Increment 1 byte at $7E:355D ; increment 355D
1ECAA 20 36 CC Jump to subroutine at 1CE36 ; < Spell/Item Subroutine >
1ECAD 60 Return from subroutine ; return

Title: Re: Recall Command
Post by: Dragonsbrethren on June 20, 2008, 11:35:34 PM
Thanks. :happy:
Title: Re: Recall Command
Post by: Grimoire LD on December 22, 2009, 04:22:15 PM
Well, I think I have my replacement ability for Baigan, great work here! With this info. I can make him into a semi-Blue Mage (sort of similar to Brina in After Years).