øAslickproductions.org/forum/index.php?PHPSESSID=dg9cbo6f5cfg2noj1ie8haqla2&action=printpage;topic=2298.0e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/index619d-3.htmlslickproductions.org/forum/index.php?PHPSESSID=dg9cbo6f5cfg2noj1ie8haqla2&topic=2298.0e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/index619d-3.html.zx6´h^ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÈ@ðWŒOKtext/htmlISO-8859-1gzip@øÕŒÿÿÿÿÿÿÿÿWed, 11 Mar 2020 10:06:07 GMT0ó°° ®0®P®€§²ð®6´h^ Œ Print Page - Enemies using weapons

Board of Slick

Library of the Ancients => Final Fantasy IV Research & Development => Topic started by: fedorajoe on October 23, 2016, 06:52:53 PM

Title: Enemies using weapons
Post by: fedorajoe on October 23, 2016, 06:52:53 PM
When you fight a player character as an enemy... what determines the weapon the enemy is equipped with?

Just playing around, I tested enemy Kain and Enemy Yang, and if told to use the Fight command, they have weapons equipped.  But I can't see how to change the values, and it doesn't seem to relate to what the actual characters/actors have equipped.

Anybody know?

Thanks!
Title: Re: Enemies using weapons
Post by: Grimoire LD on October 25, 2016, 10:23:54 PM
Indeed, this was an old mystery that I put to bed some time ago. It is set to be the Deathbringer. I posit that this is part of a removed sequence where the Dark Knight copy would attack Paladin Cecil normally at one point or another...

http://slickproductions.org/forum/index.php?topic=1883.msg22449#msg22449

Here is the information on that, but here is the pertinent part of that...


02/D028   AD 4E ED   LDA $ED4E  [$7E:ED4E]   A:0080   X:0000   Y:0012   P:eNvMxdizc - Load Monster... something (Yousei's RAM notes say that ED50 is palette data so it may deal something with size or graphic or something)
$02/D02B   29 10   AND #$10   A:001F   X:0000   Y:0012   P:envMxdizc - Get rid of all but 10.
$02/D02D   F0 1B   BEQ $1B    [$D04A]   A:0010   X:0000   Y:0012   P:envMxdizc - All normal monsters branch here where Battle Characters continue on.
----------------------------------------------------------------------------------------------------------------
$02/D02F           A9 18   LDA #$18   A:0010   X:0000   Y:0012   P:envMxdizc - Load Deathbringer into A.
$02/D031   20 BA D8   JSR $D8BA  [$02:D8BA]   A:0018   X:0000   Y:0012   P:envMxdizc - Jump to Subroutine

The weapon number (yes, singular they never planned on any other weapon being available to Enemy PC's) follows the normal listings.
Title: Re: Enemies using weapons
Post by: chillyfeez on October 26, 2016, 08:56:33 AM
Given that it's a two-byte load command preceded by a branch and followed by a subroutine jump, it'd be tricky to rewire in order to get a character-dependent routine in there... but nothing's impossible.
It will most likely be something I implement for my own purposes eventually, so I'Lloyd remember to post here when I do.
Title: Re: Enemies using weapons
Post by: fedorajoe on October 26, 2016, 04:58:01 PM
Oh nice! Thank you, this was driving me bonkers!