Author Topic: Developing FF4kster: a comprehensive editor for FF4  (Read 223608 times)

Pinkpuff

  • Flan Princess
  • *
  • Posts: 923
  • Find a Megalixir in Unprecedented Crisis!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #270 on: February 17, 2013, 05:29:14 AM »
Does anybody know... Is it impossible to completely extricate the name of the character in Paladin Cecil's slot from that of the character in DK Cecil's slot?
When I change the name assignment for the Paladin slot, the Dark Knight name still appears in battle, thus making it impossible for these to be two separate characters...

I meant to ask about this. I know it's a known thing that the name assignments in battle are stored separately from the name assignments used everywhere else, but I can't seem to find any posts or docs that actually say where that is. If someone knows and is willing to post the data, it should be a trivial fix to update the editor with that functionality.

:edit: I was able to work around this by using Golbez's Slot, but this leads me to a request about FF4kster:
Pinkpuff - would it be possible to add in the ability to manipulate Golbez's actor? As it stands, I have to use a hex editor to do so. This includes adding/removing the actor in the event editor, in addition to editing starting name and battle commands.

Hm, I was under the impression that there are some strange things about Golbez's actor... maybe someone more knowlegable can either back me up or prove me wrong on this? If not, and his actor is no different from any other, then once again it should be a fairly trivial fix.
Let's dance!

chillyfeez

  • FF4 Hacker
  • *
  • Posts: 1,234
  • Gender: Male
  • Go ahead, ask me about Angel Feathers!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #271 on: February 17, 2013, 03:24:52 PM »
Hm, I was under the impression that there are some strange things about Golbez's actor... maybe someone more knowlegable can either back me up or prove me wrong on this? If not, and his actor is no different from any other, then once again it should be a fairly trivial fix.
Far as I can see, he has limited job and character properties, but his actor is customizable. That is, his name, set of commands, and load/save assignment are unique. The one possible exception might be his starting equipment, which may be set to draw from that of DK Cecil (since in the original programming, Golbez obviously had no need for equipment). This does give him just enough unique characteristics to use him to make DKC and PC different characters.

chillyfeez

  • FF4 Hacker
  • *
  • Posts: 1,234
  • Gender: Male
  • Go ahead, ask me about Angel Feathers!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #272 on: February 21, 2013, 03:46:52 PM »
Hey Pinkpuff-
Have you considered putting targeting options into the command editor?
From the bab-il docs:
Code: [Select]
Each menu command also has a byte associated with it in a table that extends from 9FFC3 to 9FFDC indicating what it targets; this only affects the cursor, not the actual effects.
bits 0-2: not used?
bit 3: unknown
bits 4-6:
000 N/A
001 one ally
010 all allies
011 one/all allies/enemies (defaults to allies)
100 one enemy
101 one ally/enemy (defaults to enemy)
110 all enemies
111 one/all allies/enemies (defaults to enemies) bit 7: not used?

# Name Tg Comments -- ---- -- --------
00 Fight 50 one ally/enemy
01 Item 00 opens a sub-menu
02 White 00 opens a sub-menu
03 Black 00 opens a sub-menu
04 Call 00 opens a sub-menu
05 Dummy 60 all enemy (Dark Wave)
06 Jump 58 one ally/enemy
07 Dummy 60 all enemy (Remember)
08 Sing 50 one enemy
09 Hide 00
0A Dummy 20 all allies (Medicine)
0B Dummy 20 all allies (Pray)
0C Aim 50 one ally/enemy
0D Dummy 50 one enemy (Store)
0E Kick 60 all enemy
0F Dummy 00 (Endure)
10 Twin 60 all enemy
11 Dummy 00 (Strengthen)
12 Dummy 60 all enemies (Cry)
13 Cover 18 one ally
14 Peep 58 one ally/enemy
15 Dummy 60 (Unknown and unused command)
16 Dart 50 one ally/enemy
17 Sneak 50 one ally/enemy
18 Ninja 00 opens a sub-menu
19 Dummy 28 all allies (Spirit Wave)
1A Chang -- Yes, this really is "Chang" in the ROM; I don't know where the e gets put in.
1B Parry --
1C Show --
1D Off --

This is REALLY easy to do with a hex editor, but it also seems like the kind of thing you would want to put in there. Split ally and split enemy are possibilities, just no commands use them by default.

Pinkpuff

  • Flan Princess
  • *
  • Posts: 923
  • Find a Megalixir in Unprecedented Crisis!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #273 on: February 28, 2013, 06:55:20 AM »
Hey Pinkpuff-
Have you considered putting targeting options into the command editor?

The main reason I haven't is this line here:

Quote from: Bab-Il Docs
this only affects the cursor, not the actual effects.

Thus meaning any changes to it would be cosmetic only. I didn't really see the point. For example, if Dark Wave targets all enemies even after changing it to single or split then... why fool the players like that?

But if there is demand for it I can certainly throw it in there.

Also sorry it's been so long, I put the homebrew channel on my Wii and got obsessed with playing NES roms and hacks and stuff instead of working on this ^_^;
Let's dance!

Dragonsbrethren

  • Forum Overlord
  • *
  • Posts: 1,820
    • View Profile
    • Dragonsbrethren Industries
Re: Developing a comprehensive editor for FF4
« Reply #274 on: February 28, 2013, 07:56:39 AM »
I'm almost certain that cursor data does affect certain commands (or there's more somewhere else which I've forgotten).

chillyfeez

  • FF4 Hacker
  • *
  • Posts: 1,234
  • Gender: Male
  • Go ahead, ask me about Angel Feathers!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #275 on: February 28, 2013, 09:21:38 AM »
I can confirm it works effectively with Sing, so I figured the bab-il docs were mistaken or I was misinterpreting their meaning there. That's the only command I tried it with... perhaps it works with sing because sing calls upon other abilities (spells)... though it can make normally "target all" spells (such as Meteo) target a single ally, or make normally "target one" spells (like weak) target all. I guess more testing is needed to determine which commands can be changed and which cannot. My guess is recall, gird and pray will all work for the same reason sing does. I'll get back to you on that. Might not be til tomorrow.

chillyfeez

  • FF4 Hacker
  • *
  • Posts: 1,234
  • Gender: Male
  • Go ahead, ask me about Angel Feathers!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #276 on: March 02, 2013, 11:11:01 AM »
OK, here are my findings.
The summary is that it's really only worth the while to modify targeting of Sing and Recall, but here's the rest:

Code: [Select]
00 Fight - NO
05 Dark Wave - NO
06 Jump - NO
07 Recall - YES
08 Sing - YES
09 Hide - NO
0A Medicine - NO
0B Pray - YES (sorta... you can make it target only the caster instead of the whole party, because it NEVER has a cursor)
0C Aim - NO
0D Store - NO
0E Kick - NO, (but the visual change is complete - only the targeted enemy will flash, but all take damage)
0F Gird - can't tell, but only the caster gets the "armor" animation
11 Strengthen - Honestly, I have no idea what this does. I thought it was supposed to raise the caster's WIS score, but saw no such thing happen when using SNES 9X Debugger, so I don't know...
12 Cry - irrelevant
13 Cover - NO
14 Peep - NO
16 Dart - NO
17 Sneak - NO
19 Spirit Wave - NO

I did not test magic commands, because they open sub-menus, with sub-commands that have their own targeting details. I DID test Dart, because those items do not have their own targeting details, but apparently it is not even possible to affect the targeting options of Dart (even when you change the byte to target multiple, the cursor will still only allow single targeting)

Grimoire LD

  • FF4 Hacker
  • *
  • Posts: 1,676
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #277 on: March 09, 2013, 11:52:12 AM »
I have verified (and I'm sure others have as well that Boast increases Wisdom by 16 (10 in Hex) for each casting of it. I recall it being a simple change to Wisdom, nothing special like some of the other statuses seem to work on. If you run before finishing a battle after using Boast (And Protect and Shell incidentally) you can see that your Wisdom is still 16 up (until you next enter battle and it resets itself)

chillyfeez

  • FF4 Hacker
  • *
  • Posts: 1,234
  • Gender: Male
  • Go ahead, ask me about Angel Feathers!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #278 on: March 10, 2013, 01:16:25 AM »
Yeah, I realized after I wrote that that a seperate portion of RAM is devoted to in battle character stats, which copy the regular record when the battle begins and write to it at the end. I was looking at the wrong RAM location. I guess I should at some point try again to see if the targeting is changeable, but based on all of my other results, I think I already know the answer.

Pinkpuff

  • Flan Princess
  • *
  • Posts: 923
  • Find a Megalixir in Unprecedented Crisis!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #279 on: March 10, 2013, 10:19:44 AM »
Ok I finally got up off my butt and finished the map properties editor. Have at 'er.
Let's dance!

Grimoire LD

  • FF4 Hacker
  • *
  • Posts: 1,676
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #280 on: March 10, 2013, 04:35:19 PM »
Looks like everything works! The scrolling, the background, all of that jazz seems to work perfectly. And oddly enough though I was skeptical about the Underground byte, it does seem to allow Dwarves to appear on Overworld maps, but I have no idea what it does in the normal Underground maps, if anything.

Just for further notes (probably marked elsewhere)

 Battle BG 0 - Field
 Battle BG 1 - Forest
 Battle BG 2 - Mountains
 Battle BG 3 - Indoors
 Battle BG 4 - Caves
 Battle BG 5 - Moon
 Battle BG 6 - Aboard Airship (Or Boat)
 Battle BG 7 - Watery Caves
 Battle BG 8 - Cave with chasms in background (Sealed Cave?)
 Battle BG 9 - Desert
Battle BG 10 - Beach
Battle BG 11 - Feymarch/Sylph Cave
Battle BG 12 - Tower of Zot/Babil/Giant
Battle BG 13 - Lunar Subterrane/Bahamut's Cave
Battle BG 14 - Crystal Room
Battle BG 15 - Underworld

That's strange. Are you sure 15 is the last of the available Battle BG's? I didn't see Zeromus' background in there at all.


Pinkpuff

  • Flan Princess
  • *
  • Posts: 923
  • Find a Megalixir in Unprecedented Crisis!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #281 on: March 10, 2013, 07:57:06 PM »
That's strange. Are you sure 15 is the last of the available Battle BG's? I didn't see Zeromus' background in there at all.

Not sure at all actually... according to the doc there are three mystery bits in that byte:

Quote from: LOCPROP.TXT
00: Battle Properties
   bits 0-3: Battle Background
   bits 4-6: ?
   bit 7: Battles have Magnetic Effect if event flag E1 is set

Right now the editor just ignores those bits and leaves them alone but I could see what happens if I interpret one or all of them to be part of the battle BG...
Let's dance!

Zozma

  • FF4 Hacker
  • *
  • Posts: 120
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #282 on: March 11, 2013, 05:45:48 AM »
i just wanted to take time to say that this program is great! it even properly works with my hack in which i reassigned the level up data so that every character has level 1 data.

i also am interested in being able to change the targetting of skills.

and as for golbez actor? the actor is fine but cannot be given a learnable magic set and cannot be saved to the shadow party (which i really wish could be fixed)
some extra info: the pig sprite can be used to create a full golbez sprite (his palette assignment begins there) instead of overwriting another characters sprite and IF you are ok with dummying mini, and pig it frees up a full overworld sprite slot as well as a portait. there is technically enough sprite space to have a full anna sprite as well however it requires removing the small twin moon gfx from the intro screen when cecil and cain first leave for mist.

ohh btw, I created a special black magic set for my Anna (fusoya's actor) where she actually learns spells that i cant access on the magic learning menu. any way to allow this to select spells further down the list? Fire/Ice/Bolt 4 are a bit overkill but hey its the daughter of the great sage afterall lol..
« Last Edit: March 11, 2013, 06:02:12 AM by Zozma »
eh, what do I care...

Pinkpuff

  • Flan Princess
  • *
  • Posts: 923
  • Find a Megalixir in Unprecedented Crisis!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #283 on: March 11, 2013, 08:25:17 AM »
Glad to hear you're finding it useful!  :childish:

I think my policy on things like the Golbez actor and the learning of monster techs is that, if it can't be made to work properly/elegantly from using FF4kster alone, then FF4kster is not going to let you do it from within it. If you make changes using some kind of other tool, including hex editors, then FF4kster will throw up its hands and absolve itself of any responsibility with regards to what happens.

So with regards to the particulars above, there will be no golbez actor, and no learning monster techs, but there will be targeting options for the commands for which it actually does something (Recall and Sing), since the commands are already handled in a very piece-wise, case-by-case basis.
Let's dance!

chillyfeez

  • FF4 Hacker
  • *
  • Posts: 1,234
  • Gender: Male
  • Go ahead, ask me about Angel Feathers!
    • View Profile
Re: Developing a comprehensive editor for FF4
« Reply #284 on: March 11, 2013, 11:36:24 AM »
couple of things... well, one long thing...
It doesn't look like ff4kster enables you to alter the second byte of map properties (the "map index").
This, to me, is possibly the most useful property of a map to be able to edit.

Example 1:
Let's say I want to repopulate Eblan Castle.  Well, it's easy enough to put the NPCs in the castle, but Eblan has no Bank 2 (well, only one per map anyway), so the only way to make them speak is to waste events.
BUT, by repopulating Eblan, maybe I wouldn't need Cave Eblana inhabited anymore...
SO, in the second byte of map properties for Cave Eblana B2F ("Cave Eblan Settlement" in ff4kster, map C8), which has 10 Bank 2 messages, I change the C8 to 5E.
NOW, when the game is called upon to put the player in Cave Eblana B2F, the player winds up in Eblan Castle 1F.
VOILA! I have NPCs in Eblan 1F that use the Bank 2 messages from Cave Eblana B2F.

Example 2:
Let's say I want multiple locations that look identical. I only have to program the tile layout of this location once, then I can make multiple maps reference it by way of the second byte.  I think the game does this with the sealed cave, and possibly with a chocobo forest or two (though I could be wrong...).

Come to think of it, this almost definitely has something to do with the use of the "underground" byte as well...