Please login or register.

Login with username, password and session length
Advanced search  

News:

Welcome to FFH! Where all your dreams come true!

EVTCHR Frame Locations  (Read 872 times)
Pages: [1]
TheChad [Posts: 17] Logged
  • View Profile
  • share
  • [June 26, 2011, 06:48:48 PM]
EVTCHR Frame Locations
« on: June 26, 2011, 06:48:48 PM »
I've spent a lot of time recently trying to get EVTCHR frames loaded into custom events.  Through trial and error, I've put together a map tying EVTCHR frames within a sheet to the hex value you call within the UnitAnim() Event Instruction.  Hopefully this will be useful to other event editors who wish to insert custom EVTCHR frames into their events.

A few notes:

RAM Block 1 is x00 using the LoadEVTCHR and SaveEVTCHR Instructions, so

LoadEVTCHR(x00,x66,x00)
WaitForInstruction(x34,x00)
SaveEVTCHR(x00)

Loads EVTCHR Sheet 66 into RAM Block 1.  RAM Block 2 is x01, which for sheet 66 would be:

LoadEVTCHR(x01,x66,x00)
WaitForInstruction(x34,x00)
SaveEVTCHR(x01)

When you go to use UnitAnim(), remember that the 4th input variable is now x01 for RAM Block 1, and x02 for RAM Block 2  (x00 is the normal sprite sheet animation, not EVTCHR).

There is no way that I know of to call a frame in the 8th column on the EVTCHR sheet.  If you look at the EVTCHR sheets in the vanilla game, these all seem to be glitchy images anyway, such as a sprite facing directly at the camera, and are never called in-game.

Curiously, loading the EVTCHR Sheet to RAM Block 2 gives you the option to call all 7 frames on all 5 rows (35 total frames), while loading to RAM Block 1 only gives you access to 23 total frames.  You get all of the first row, the first 5 and 7th from the second row, but then only every other frame from there on out.  If you look at the event instructions from Vanilla, you'll see the game almost always uses RAM Block 2, and only loads RAM Block 1 when a secondary EVTCHR load is needed.

Also, I don't have complete notes on this, but in my experience loading an EVTCHR sheet in both RAM Blocks precludes certain regular animations from occurring, such as a weapon strike during a cutscene.  This is somewhat inconsistent that I've observed, but if all of sudden you add both EVTCHR frames to your custom event and then all of a sudden your characters won't swing their weapon when called, try removing one of the EVTCHR loads.

The attached file tells you which animation frame is called for which hex value.  So if you want to load the first frame on the sheet, your event instructions would include either the following using RAM Block 1:

LoadEVTCHR(x00,x66,x00)
WaitForInstruction(x34,x00)
SaveEVTCHR(x00)

UnitAnim(x85,x00,xF4,x01,x00)

or the following using RAM Block 2:


LoadEVTCHR(x01,x66,x00)
WaitForInstruction(x34,x00)
SaveEVTCHR(x01)

UnitAnim(x85,x00,x58,x02,x00)

This example assumes you're trying to load EVTCHR Sheet 66 and replace the Unit x85 sprite.

If you wanted to load the frame at Row 2, Column 6, your only option would be to use RAM Block 2:

LoadEVTCHR(x01,x66,x00)
WaitForInstruction(x34,x00)
SaveEVTCHR(x01)

UnitAnim(x85,x00,x64,x02,x00)

Where my map has xXX, that means that that frame can't be called for the RAM Block.

Why do the EVTCHR Frames have such unusual starting values for the hex bytes?  I have no idea.  It was extremely frustrating at first trying to figure this out, lacking any good explanation that I could find.  Having the map though makes it relatively pain-free.

This should help other event editors get EVTCHR frames into their events without having to go through a lot of trial and error.

Chad
LastingDawn [Posts: 3419] Logged
  • View Profile
  • share
  • [June 27, 2011, 05:49:45 PM]
Re: EVTCHR Frame Locations
« Reply #1 on: June 27, 2011, 05:49:45 PM »
Hmm, very concise and interesting, good work Chad. Though just a question... how does Hashmalum's death work if this is fully correct? Doesn't that mean his sprite alone takes up four spaces?

"Moment's anger can revert to joy,
sadness can be turned to delight.
A nation destroyed cannot be restored,
the dead brought back to life."

Art of War

Beta & Gretchen Forever!!!!
TheChad [Posts: 17] Logged
  • View Profile
  • share
  • [June 27, 2011, 09:11:31 PM]
Re: EVTCHR Frame Locations
« Reply #2 on: June 27, 2011, 09:11:31 PM »
That's a good point LD - I'm not really sure.  I'll look a bit at that event code - maybe it's hard coded, or maybe Lucavi sprites play by a different set of EVTCHR rules.  In any case, this should hold true for the majority of evtchr uses.
Queen of Palemoon
Celdia [Posts: 1598] Logged
  • View Profile
  • http://steamcommunity.com/profiles/76561198029710324/
  • share
  • [June 28, 2011, 08:16:05 PM]
Re: EVTCHR Frame Locations
« Reply #3 on: June 28, 2011, 08:16:05 PM »
Is there anything in there that determines what palette is called for EVTCHR animation frames or is it always based directly on the sprite being modified by the EVTCHR frames? Because when I tried to import a new EVTCHR image for the event after the Zalera fight (to use the new Meliadoul sprite) it not only fucked up Meliadoul's colors but Ramza's as well. I didn't alter the event itself but I didn't feel I should have needed to from how the EVTCHR sheet was modified.
LastingDawn [Posts: 3419] Logged
  • View Profile
  • share
  • [June 28, 2011, 08:43:55 PM]
Re: EVTCHR Frame Locations
« Reply #4 on: June 28, 2011, 08:43:55 PM »
Hmm, as I recall right some Evtchr's have their own palettes that come with them, but I don't recall the exact reason why this is. I'm sure a more up to date event editor could help you.

"Moment's anger can revert to joy,
sadness can be turned to delight.
A nation destroyed cannot be restored,
the dead brought back to life."

Art of War

Beta & Gretchen Forever!!!!
Lijj [Posts: 1894] Logged
  • View Profile
  • share
  • [June 28, 2011, 08:51:17 PM]
Re: EVTCHR Frame Locations
« Reply #5 on: June 28, 2011, 08:51:17 PM »
I would like to know more about this myself... I've always been peeved by those palette distortions(who isn't) when it seems like it should be a simple fix.
Queen of Palemoon
Celdia [Posts: 1598] Logged
  • View Profile
  • http://steamcommunity.com/profiles/76561198029710324/
  • share
  • [June 29, 2011, 03:42:07 AM]
Re: EVTCHR Frame Locations
« Reply #6 on: June 29, 2011, 03:42:07 AM »
Going back and looking at everything now I think I found my problem. Each EVTCHR sheet only has one palette but you can extract them as separate files per palette. It stands to reason then that you must insert them back in the same manner. So if I want Ramza to look correct I need a separate EVTCHR sheet just for him with its own palette separate from the one Meliadoul uses. Its not like a normal Shishi spritesheet with eight palettes and my assumption that it was may be the critical error here. I'm going to give this one another test and I'll post my results if I find anything useful from it.
LastingDawn [Posts: 3419] Logged
  • View Profile
  • share
  • [June 29, 2011, 05:23:35 AM]
Re: EVTCHR Frame Locations
« Reply #7 on: June 29, 2011, 05:23:35 AM »
That's not completely right... I know that there's some command which tells a unit to keep its native palette... as can be told for the majority of the Evtchr's.

"Moment's anger can revert to joy,
sadness can be turned to delight.
A nation destroyed cannot be restored,
the dead brought back to life."

Art of War

Beta & Gretchen Forever!!!!
Cheetah [Posts: 3645] Logged
  • View Profile
  • share
  • [June 30, 2011, 08:17:03 PM]
Re: EVTCHR Frame Locations
« Reply #8 on: June 30, 2011, 08:17:03 PM »
Each Evtchr sheet has more than one palette associated with it as well. I can't recall the command to assign the relevant palette however. Plus as LD said you can always use the sprites native palette.

Current Projects:
Pages: [1]