1070
« on: October 17, 2013, 05:22:16 PM »
Ok, this post will contain the slightly different steps taken to transform Eagle and FloatEye into Indra and Shiva.
I won't explain everything step-by-step. I'm assuming you've read the Imp --> Jinn post, and most of the process is the same.
Eagle uses the third entry in the Graphical data bank at 7CC00, which is
03 02 63 C1
We're turning Eagle into Indra, so first we use Tile Layer and our Hex calculator to figure out Indra's sprite pointer is C2EC, and now we have
03 02 EC C2
Shiva and Indra both require a 6x6 area to work within. This is good, because most Special sizes are larger than 6x6, so it doesn't matter too much whose data we take over. I chose Valvalis, only because I wanted to use monsters that normally undergo image transformations for my first stab at this. Valvalis's initial form is Special size 95. Now we have
95 02 EC C2
And we're done here.
Now to edit special size 95...
Start at 7D000 and count up by fives until you get to the 16th entry, at 7D069.
Note: a quick and easy way to find the appropriate entry is to look at the last byte of each. They are numbered in order beginning at 00 up through special size 9C.
The details for Special size 95 read:
35 18 B1 02 15
Byte 00 (35): Stays the same, unless you want to move Indra forward or backward
Byte 01 (18): Indicates the actual size entry. We want 6x6, which is size 04.
Byte 02 (B1): The palette - Indra uses palette CF
Byte 03 (02): Don't know what it does. Best not to mess with it.
Byte 04 (15): Indicates sprite arrangement. You can, and probably should, keep this the same. When I was at this point, I still did not fully understand what I was doing, so I started writing Indra over K. Eblan (size 9D). I thought I hit a roadblock when I discovered that both of K. Eblan's forms use the same sprite arrangement. Now I know that this is untrue, but it caused me to do something a little weird here. Because I had already arranged Indra over K. Eblan by the time I switched to using Valvalis, I kept K. Eblan's Sprite arrangement. So I changed this byte to 1E. If you're following this easily enough, you don't have to do that, but for the sake of demonstration I'll stick to describing exactly what I did here, exactly as I did it.
So now at 7D069 we have:
35 04 CF 02 1E
On to sprite arranging.
We are looking at the 1Eth sprite arrangement pointer in the index at 75100. Start at 00 and count up two bytes at a time to get to 7513C: BC D8
Add D8BC to 68200 to get 75ABC. This is the location of our sprite arrangement data.
Indra looks like this:
--XX--
XXXXX-
XXXXXX
XXXXXX
XXXXX-
XXXXXXor:
--XX--XXXXX-XXXXXXXXXXXXXXXXX-XXXXXXAnd as with Jinn, these sprites all appear in order, so our arrangement data will look like this:
-- -- -- -- -- -- -- ----- -- -- -- FE 02 00 01
FE 02 02 03 04 05 06 FF-07 08 09 0A 0B 0C 0D 0E
0F 10 11 12 13 14 15 16-17 FF 18 19 1A 1B 1C 1D
That's it for Indra #1. Now for Indra #2...
We'll be writing over the details for Valvalis #2 now, at 7D06E:
35 18 B1 02 16
changes to
35 04 CF 02 02
All the same reasoning as above. Oops! looks like I was still wasting time messing with byte 04 here. So while we wrote over Valvalis #2's details here, we'll be writing over Titan #1's sprite arrangement. Ah well...
Sprite arrangement pointer 02 is 08 D0... Nope! look at this, I changed that, too. I was still learning, I guess. Looks like what I did here was point to just beyond the last bunch of arrangement data. My pointer 02 reads 60 DF.
68200 + DF60 = 76160
By default, this is a bank of ten lines of FFs. My custom Indra #2's sprite arrangement starts here. Sorry if this is a bit confusing, but at least it does show off some of the freedoms you have in this process.
The most notable thing about Indra #2 (in contrast to Jinn #2) is that some of the sprites from the first form are re-used. Notice, looking at Tile Layer, that Indra #2 doesn't have any feet. This is because between the two images, the bottom two rows of sprites are the same. This is something to keep in mind when planning your arrangement.
Indra #2 will look like this (Where "-" is empty space, "X" is a previously unused sprite, and "O" is a repeated sprite):
--XXXX
XXXXXX
XXXXXX
XXXXXX
OOOOO-
OOOOOOor
--XXXXXXXXXXXXXXXXXXXXXXOOOOO-OOOOOOBe sure the sprites used in place of those Os are the same sprites used in the first image.
You'll end up with:
FE 02 1E 1F 20 21 22 23-24 25 26 27 28 29 2A 2B
2C 2D 2E 2F 30 31 32 33-13 14 15 16 17 FF 18 19
1A 1B 1C 1D
The only thing left now is to Edit the monster's AI. Whereas with Jinn (which used sizes 80 and 81), you first changed sprite to 1, then reverted to 0; for Indra you'll change sprite to 22 (that's 16 hex in base-10), then revert back to 21.
So there's Indra. I'm gonna go right into Shiva now, which should also be a demonstration of how, by the third time, I knew how to do this without any wasted steps...