øAslickproductions.org/forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&action=printpage;topic=2101.0e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/indexf75a.htmlslickproductions.org/forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&topic=2101.0e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/indexf75a.html.zxFg^ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÈ`¦DiPOKtext/htmlISO-8859-1gzip0|ÖiPÿÿÿÿÿÿÿÿTue, 10 Mar 2020 04:39:58 GMT0ó°° ®0®P®€§²ð®Fg^ÎiP Print Page - "New Game" Calling Afterbattle Item Screen then Hangs

Board of Slick

Library of the Ancients => Final Fantasy IV Research & Development => Topic started by: Bahamut ZERO on August 05, 2015, 01:18:56 PM

Title: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 05, 2015, 01:18:56 PM
I noticed last night when I went to start a new game of my project. that it hangs before the opening events (using SNESx9).

MID-POST EDIT: I loaded my projoec with ZSNES and noticed exactly what's going on: For some reason or another, selecting New Game takes me to the item screen that's usually called after a battle. Then it hangs indefinately. What the hell?????

What worries me is... well, there aren't really any differences between my current version and my last backup backup (which is from a few days prior). Only noticble things between the two are:

1 I have altered the text from the events where DK Cecil's speaking to the Elder (twins joining) through returning from Mt.Ordeals.

2: At spots in these events where Porom would hit Palom, I've removed the "POW!" textbox and added a 4 cycle pause in it's place

3: During the event where Palom puts out the Fire on Mt.Ordeals, I removed the text during the scenes with Kain & Golbez (since I plan on having something else          happen in it's place)

4:  When Milon's sprite is falling off the cliff, I have his second text box (graaaaaaahhh!!)  occur after his sprite falls.

5:  a few small edits to the Caves and Sealed Cave tileset graphics (which I'm 99.999% sure aren't the cause)


I'm certainly no expert on FF4's data structure, but I don't see why any of the above would affect my New Game option in such a way. I'm somewhat (well, completely) stumped as to why New Game's calling up the After-battle item screen instead of calling the "Opening events" event.


Any advice, theory, or info  on how New Game sets up the opening events would be greatly appreciated. Heck, if anyone wants to take a stab at looking at my rom for clues, I'd gladly send it and my most current working backup their way. 
 





Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Pinkpuff on August 05, 2015, 01:41:59 PM
Data bleeding is the only thing I can think of... but I thought I caught all the spots where that could happen. Certainly the events. Are you using the RHDN version of FF4kster or the Timecave version?
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 05, 2015, 03:15:09 PM
I'm using the latest time cave version of the editor, the one with the Namingway issue fixed.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Pinkpuff on August 05, 2015, 03:28:08 PM
Could the event pointers have gotten messed up somehow?

Do you have a save game you can load, and try to trigger an event?
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Grimoire LD on August 05, 2015, 05:12:41 PM
That is worrying... try this...

$00/8081   A9 10   LDA #$10   A:0081   X:21E0   Y:00F0   P:eNVMxdizC - Add 10 to A (Starting Events)
$00/8083   20 63 DF   JSR $DF63  [$00:DF63]   A:0010   X:21E0   Y:00F0   P:enVMxdizC - Jump to Subroutine (Event Dealings)

In Rom this is at...

281 - A9 10 - Starting Event.


Change the event that is designated as the "starting event" and see if it still occurs.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 06, 2015, 01:13:28 PM
Could the event pointers have gotten messed up somehow?

Do you have a save game you can load, and try to trigger an event?

From testing different events on my saves (even going as far as setting up the Baron Dancer to trigger the Opening events) everything seems to be working fine event-wise. I'm pretty sure it's the New Game's pointer that's pointed incorrectly.

I'm not sure if that was caused by the editor, but the latest major edit I've done to events was:

1:Mt. Ordeals Fire Put Out By Palom - removing the chunk of event with Golbez, Kain, and Milon, so theevent ends after the fire's put out.



That is worrying... try this...

$00/8081   A9 10   LDA #$10   A:0081   X:21E0   Y:00F0   P:eNVMxdizC - Add 10 to A (Starting Events)
$00/8083   20 63 DF   JSR $DF63  [$00:DF63]   A:0010   X:21E0   Y:00F0   P:enVMxdizC - Jump to Subroutine (Event Dealings)

In Rom this is at...

281 - A9 10 - Starting Event.


Change the event that is designated as the "starting event" and see if it still occurs.


I'll make a backup and then try this out. This is the code that New Game normally calls for the Opening Events to start, correct?
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: chillyfeez on August 06, 2015, 02:25:16 PM
That'll be ROM with header, BTW.
Just 0081 in a ROM without header.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Pinkpuff on August 06, 2015, 03:02:16 PM
If that doesn't work, here's a painstaking but guaranteed way to find the issue:

Make a new copy of your backup, then apply one of the changes you had made, save, test. If the game messes up, you found the (actually "a") culprit (wouldn't hurt to revert and check all the other changes individually in case there's more than one causing the same problem) otherwise, revert and try another change and so on. If none of them cause the problem individually, start trying combinations. Eventually you'll either hit upon a set of changes that causes it, or you'll have a working rom with all your intended changes.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 06, 2015, 04:10:39 PM
Hmm, looks like I'm going with the painstaking route, as the data in hex is correct. At least I know it's something on my end messing it up, so that puts me more at ease with redoing things one at a time. Thanks for the help!
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: chillyfeez on August 06, 2015, 07:54:21 PM
If that doesn't work, there's a utility on RHDN called IPS Peek (http://www.romhacking.net/utilities/1038/) that will break a patch down into every single portion of ROM it edits and (I believe) allows you to apply any of them independently of any others (you specify) to the ROM. You could make a patch of your broken ROM and systematically zero in on exactly what is breaking it. It could take a billion and a half years, but that method has actually saved my ass before.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Pinkpuff on August 07, 2015, 04:04:30 AM
I use a similar technique sometimes when debugging FF4kster. One way to speed things along is to "binary search" your way through them instead of just going linearly:
This way you eliminate half the list at a time instead of one at a time.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: chillyfeez on August 07, 2015, 11:09:00 AM
Wow, Pinkpuff, you just blew my mind.
So simple yet so genius.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 07, 2015, 01:16:43 PM
Well, this is odd... upon an in depth checking of my backup last night, I found that it was as up to date as the broken one, minus a map I had started working on (which was fomally the generic Weapon Shop map), so I think I'll chalk it up to bad luck and breathe a heavy sigh of relief.  :happy:

To be safe, I'll make a new map somwhere else, in case that had a part in it haha.

Also while testing in FF4kster, I found that if you do the following:

1:Go to an NPC in the NPC Editor with "EMPTY" set as it's speech

2:Hit Tab to highlight the messages area

3:hit Tab again to go back to the "Empty" section (now glitched into a small square box)

4:Hit Enter


The editor will crash. For good reason I imagine, but still I think it's worth mentioning lol.




I use a similar technique sometimes when debugging FF4kster. One way to speed things along is to "binary search" your way through them instead of just going linearly:
  • Assign an order to the changes.
  • Apply all the changes in the "first" half
  • If the problem appeared, the culprit is in the first half; discard the other half
  • If the problem didn't appear, the culprit is in the other half; discard the first half
  • Revert your rom to its original state
  • Repeat entire process until you're down to one item; that's the cause of the issue.
This way you eliminate half the list at a time instead of one at a time.


That's a good way to determine a problem quickly! I'll keep that in mind in the future.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: chillyfeez on August 07, 2015, 03:36:21 PM

Also while testing in FF4kster, I found that if you do the following:

1:Go to an NPC in the NPC Editor with "EMPTY" set as it's speech

2:Hit Tab to highlight the messages area

3:hit Tab again to go back to the "Empty" section (now glitched into a small square box)

4:Hit Enter


The editor will crash. For good reason I imagine, but still I think it's worth mentioning lol.

That actually happened to me within the last couple days, too, but I didn't report it because I didn't remember the exact steps I took to generate the crash.
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Pinkpuff on August 08, 2015, 05:00:47 AM
 :banonsmash: Fixed and uploaded to timecave.net
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 19, 2015, 01:01:29 PM
Found another thing that kills the New Game option's functonality. I figured it'd be a good idea to share this tidbit 'o info so others won't run into this by trying the same thing.

If you  add a Yes/No choice message to the "Opening Events" events, congraturations! You just broke your New Game option.  :wink:


Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: chillyfeez on August 19, 2015, 02:08:13 PM
Huh, that's interesting.

Anywhere in the opening events, or only as the first event item?
Title: Re: "New Game" Calling Afterbattle Item Screen then Hangs
Post by: Bahamut ZERO on August 19, 2015, 02:58:19 PM
Upon further testing, the Yes/No message box does work just fine outside of the beginning of the event... huh.

I think it might have to do with the face that I was trying to show the message box before the event loads the opening map (flying airship)... which means if I load the Black Room used for the "meanwhile..." tects and falling down the Tower of Babil, it should function properly.

EDIT: It worked! Turns out you HAVE to load a map before showing a Yes/No message box during the Opening Events! I can't seem to get the "If No" section of the event to function (basically loading a map, and setting a flag to allow players to skip my edited Mysidian Legend IN SPAACE visual in case one of the battles manages to get them killed),  but that's a story for another day.

EDIT2: Seems the Yes/No Box behaves differently during the Opening events. It won't go through the event items in the "if No" section, but it will seemingly skip the next 1 event item.  So picking "Yes" sets flag 127 and skips my M.L.I.S. visual, and picking "No" plays it!  Not sure why it works that way, but it's essentially doing exactly what I wanted to do.

I'm happier than a pig in shoes!


Huh, that's interesting.

Anywhere in the opening events, or only as the first event item?


While it isn't the first event item, it's definitely the first message the player would see.  The first 22-23 event items are the adding/removing of actors to properly set  even experience distribution since I made the two autobattles into normal fights.