Thursday, May 8, 2014

Map 258

Figured out how the "Special Event" triggers work.  The 0x02 bit that I was ignoring from map header byte[3] is part of it, and the two bits together indicate the index of the tile in the collision layer that executes the special event.

This fixes map 258, the elder's house in potos:

For now I'm indicating them with yellow squares.  With two bits, you can pick either tile 0xC0 (which is out of range, and indicates no special event), 0xBF, 0xBE, or 0xBD for the special event trigger.  These can be useful if you want a bunch of tiles in a row to execute the same event without putting in multiple triggers.  SoM also uses them in maps with whippable posts to execute the event that shoves your party together to prepare for a whip transfer thingy.


RetroHelix said...

Well done. Congrats for figuring it out.
So do you rewrote the code for the triggers to include this information already?

Keep it up!

Mop said...

Well, the point of these is apparently that you don't need to place triggers for them, and can effectively have the same trigger be in multiple spots without placing each one - so I think converting these to placeable triggers defeats their purpose and they will stay as-is. The only(?) thing left to do with triggers should be converting the exit-type ones.

RetroHelix said...

...I see. I just misunderstood.