øA slickproductions.org /forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&action=printpage;topic=786.0 e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/index198b.html slickproductions.org /forum/index.php?PHPSESSID=5f0fck550j2m4m2fpbtkj2vkm1&topic=786.0 e:/My Web Sites/Slick Productions - FFIV Message Board/slickproductions.org/forum/index198b.html.z x ¢—g^ ÿÿÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÈ #u OK text/html ISO-8859-1 gzip @øÕ ÿÿÿÿÿÿÿÿ Tue, 10 Mar 2020 13:51:54 GMT 0ó° °® 0® P® €§² ð® ¢—g^ ´
Print Page - NPC Palettes
Board of Slick
Library of the Ancients => Final Fantasy IV Research & Development => Topic started by: Phoenix on September 01, 2008, 11:41:55 AM
Title: NPC Palettes
Post by: Phoenix on September 01, 2008, 11:41:55 AM
Does anyone know how the NPC palette byte (the 6th byte in the location properties data) works? I can't quite figure it out. I know that that byte determines the palettes available for a location map, and from there each NPC can load one of four palettes. The problem is, I don't know how that byte determines which four palettes. So far, I've discovered the bottom four bits increment the palette count by 2. It's the top four bits I can't figure out. I'll keep working on it, but if someone already knows, please share.
Title: Re: NPC Palettes
Post by: Phoenix on September 01, 2008, 12:06:34 PM
Nevermind, I figured it out. Just needed to think about it a little more. The bottom 4 bits determine the first and second palettes available, and the top 4 bits determine the third and fourth palettes available. All of the palettes start at 1, and each step up in bits adds 2 to that.
So for example, at the town of Baron the NPC palette byte is 10. This means the bottom four bytes are 0000, so the first and second palettes available are palettes 1 and 2. The top four bytes are 0001, so the third and fourth palettes available are palettes (1+2) and (2+2) = 3 and 4. In the Village Mist, the top four bits are 1001, so the third and fourth palettes are (1+9*2) and (2+9*2) = 19 and 20.