Jump to content

Battle Frames Part 2


Jubby
 Share

Recommended Posts

This is a sort of interesting thing I've discovered; I haven't discovered any glitches yet so I think it's pretty safe.

You'll need:

- To have read Rey's tutorial, here: http://www.bwdyeti.c....php?topic=21.0

- A general knowledge of TSA and crap, so maybe try his way first.

- And know that a tile is an 8x8 pixel square. This is what the game uses, and if you pop open the tiles for the battle frame in Usenti and turn the Tile Grid on, you should see the individual tiles.

Major super huge credit to Ryrumeli for inventing this awesome method, and of course to shadowofchaos for writing the tutorial. Also, I use VincentASM's battle template later in the tutorial, so credit to him for that (and thanks for being an awesome dude and letting everybody use it :D) And credit to Blazer for listening to me flippin out when I figured this out xD

Okay, so if you've read Rey's tutorial, he talks a bit about a tile limit; there is one, some freaky stuff happens if you don't obey it. If you check Part 4 of his tutorial, you'll see some fucked up images of what happens if you replace the name tiles with other ones. Not good. :/

This tutorial is about essentially increasing the tile limit :P

Part 1: the Transparent tile:

First thing's first. One tile that would be REALLY bad to overwrite is the 31st tile. This is treated by the game as the transparent tile. If you save as a bitmap from GBAGE, and look at it in Usenti:

Usentiimage-31sttiles.png

That last tile, I circled it.

Now, here, I'll put something there:

Withsomethingthere.png

Ladela, reinsert and repoint, then put in the TSA, and:

WTFifyouoverwritethe31sttile.png

Oh fuck. So don't overwrite 31. (Shows up as the 32nd tile if you count in Usenti cause FE uses 0 as well.)

Next thing not to do with TSA: Well, Rey already warned us not to change the name or weapon name areas, so that's a no brainer.

Name and Weapon Tiles:

And finally, the name and weapon name tiles must be transparent. They start at tile 32 (If you click the first tile in the enemy name frame it'll say it's graphic 32) and end at 83, here:

Totheend-83.png

(I coloured it in fuschia and highlighted the graphics number, or tile number, as I call it)

Therefore, when we insert new tiles, there can't be anything from 31 to 83. If I were to change a normal tile to 32, the game would just throw in the first name frame tile, which'd look like crap. So don't.

Part 3: Getting around the Tile Limit:

So, how do we get around this tile limit? Why, we put the extra tiles after 83! That means 84+ are free!!! :D

Hold on now. Ryru's method of using Wingrit is gonna be a bit funky then, cause it doesn't give a shit about making the tiles 31 to 83 transparent. So we improvise. Check SoC's tutorial for the Wingrit method. Then come back.

When you've got your img.bin and pal.bin files, use the pal.bin as Rey says, but for the img.bin, follow these steps carefully:

1)Open GBAGE.

2)Load raw your img.bin file.

3)Save this as a bitmap, and then DON'T save your ROM.

Now, pop open your new PNG tiles in Usenti, figure out how many tiles you have, then add 51 to that, and figure out a new height and width. Leave the first 31 tiles alone, (remember the game sees it as 0 to 30, so they're good) but take everything after that and move it down to the 84th tile (OHSHIT MANUAL COUNTING) and put it at 85 and beyond.

Then, reinsert and edit the TSA the way you want :3

Here's an example:

Go from this, your tiles straight from Wingrit:

Tilesfortutorial.png

to this:

FEDStiles1.png

IMPORTANT NOTE: Your graphics for tiles 127 and up cause a weird fuckup; they're fine till someone attacks and then it messes up. So you can use 0 to 30, and 84 to 126. That's a lot more than before.

Aaaaaaaand, everybody needs proof, so:

AWESOMESUCCESS-1.png

Enjoy. If that's not clear enough, post what you don't understand, I'll try to explain better. Also if anyone has a reason why this might glitch (I know next to nothing about memory and ASM stuff) let me know. I haven't tested tooooooo much but I did use two HUGE battle animations and a big long spell, and it held up fine under those. Good night, SF. Big thanks again to Ryrumeli for creating this method, shadowofchaos for making the tutorial in the first place, and VincentASM for letting me use his frame, and in general making an awesome frame.

If you want the package for the frame above, it's here:

http://serenesforest...dpost&p=1818742

Edited by Jubby
Link to comment
Share on other sites

Well, crap. Congrats. clap2.gif

Mind uploading a patch or something so I can capture video of it?

You certainly can have a patch, I know you used that frame a while ago, and if my work should go to anybody, it's you and Ryru :) So yeah, I'll probably upload one tomorrow, gotta copy paste to a clean ROM to do a UPS patch and i've got school tomorrow so I shouldn't even be on here atm, but anything for you, my good man xD

Edit: And thank you :3

Edited by Jubby
Link to comment
Share on other sites

I quoted you and linked to this thread on the original tutorial. Hoped you didn't mind :P

Now I want to get off my butt and redo that GBA Critical Animation Collection with as many custom battle frames as I can.

Edited by shadowofchaos
Link to comment
Share on other sites

I quoted you and linked to this thread on the original tutorial. Hoped you didn't mind :P

Now I want to get off my butt and redo that GBA Critical Animation Collection with as many custom battle frames as I can.

Oh hey, I watched that! :3 Can't sleep :( I certainly don't, I'm glad you liked it so much (I don't know if anybody else will get it since most people get confused by yours and you're actually good at writing tutorials XD)

But hopefully I can have that patch tomorrow, if not probably the day after, i've still gotta do a couple fixes (I think I need to add one tile, fix the enemy weapon name, and add green and purple palettes :P)

Link to comment
Share on other sites

I should get credit just for listening to his rants

Seriously though awesome work man. Props, this is a great contribution to the advancement of graphical hacking. I'd be honored if this could be in the UT eventually (i.e. when I finally stop being lazy).

Link to comment
Share on other sites

I should get credit just for listening to his rants

Seriously though awesome work man. Props, this is a great contribution to the advancement of graphical hacking. I'd be honored if this could be in the UT eventually (i.e. when I finally stop being lazy).

Edited in

No, seriously. :D

And thanks, I'd be honored if this could be in the UT as well, I'm probably going to do a couple mini tutorials about inserting stuff with GBAGE and such, so those can go in the UT too if you want :3

You can edit out the profanity too if you want :$

Link to comment
Share on other sites

You're... bad at taking jokes (:P) but anyhow, if I ever stop being lazy, it'll only be a shortage enough of laziness to copy/paste it, you can forget about doing anything else, like censoring it... XD

Edited by Strawhat Luffy
Link to comment
Share on other sites

You're... bad at taking jokes (:P) but anyhow, if I ever stop being lazy, it'll only be a shortage enough of laziness to copy/paste it, you can forget about doing anything else, like censoring it... XD

I know it was a joke, but... I seriously spammed your PM inbox. Like, I'm surprised you even read them :P So credit to you! (And for the PM record too!) Fuck censoring

Link to comment
Share on other sites

You're... bad at taking jokes (:P)

Blaz.RAR

I seriously spammed your PM inbox. Like, I'm surprised you even read them :P

Honestly, getting messages from you is like having an intelligent conversation. Now if you were one of the people who just randomly show up asking for random impractical crap, and then disappears never to be heard from again... or the typical Youtube idiot PM example... THEN we would be annoyed.

But again, you're neither of those things.

Link to comment
Share on other sites

The tiles fucking up at index 127+ are a function of how the ROM loads the data (if my observations are correct - I could be completely wrong)

Now then, from what Rey told me, each tile is represented as one short - two bytes, for you laymen non-savvy. This can be expressed as a collection of twelve bits. I'll be using an example from the actual frame's tile mapping.

0x1914 is the first short at offset 0x1D8C34. In binary, that looks like this -

0001 0101 0001 0010

0001 = 1

0101 = 9

0001 = 1

0100 = 4

Hex to binary works pretty simply, actually. Go use a scientific calculator if you really need to.

Each set of four bits denotes a byte. Now, I wish it was so simple as "byte 1 = this and byte 2 = that". But alas, it's not. The bits arranged work in a slightly different way. If you were to separate the way the game reads the data, it would look like this:

0001010100 0 1 0100

The first ten bits denote the graphic index. Indirectly. The next bit is a true/false value for 'vertical flip', the next is for horizontal. The final four bits (half a byte- a nybble) are for the palette of the tile, also indirectly. You can have up to 15 different palettes for the same image.

Now, to elaborate on what I mean by 'indirectly'.

0001010100b (the 'b' denotes binary) is equal 100 (the number you get when you add 36 and 64) in decimal. Take my word for it, but you can check with a calculator if you need it.

If you go to the tile index represented by this short in GBAGE, though, you see this:

cUT3.png

25 =/= 100, right? Not to mention, the palette byte for this tile is 4, not 1. I puzzled over this for a while, until I saw myself being an idiot and noticed that 100 divided by 4 = 25. Likewise, 4 divided by 4 is 1. A quick check on the other tiles showed that this held for the rest of the map as well.

How does this tie into my original statement? Well, the maximum value you can get with 10 bits is 1023. If you do it properly, you should never get a value that's not divisible by 4, meaning that the actual highest value is 1020. 1020 divided by 4 = 255, half of which is 127 (rounded down). I'm not sure why 127 is the upper limit instead of 255 and I don't have the memory reading skills to figure it out, but if I had to guess I'd say it's because the game needs to load two bytes for every tiles.

...great now I want to build a tile map builder just to make it so much less tedious to do this.

Edited by Camtech
Link to comment
Share on other sites

Blaz.RAR

Honestly, getting messages from you is like having an intelligent conversation. Now if you were one of the people who just randomly show up asking for random impractical crap, and then disappears never to be heard from again... or the typical Youtube idiot PM example... THEN we would be annoyed.

But again, you're neither of those things.

well, thank you :) I do try biggrin.gif But yeah me and Blazer are at 10 pages blink.gif

Haha anyway, about that patch; to make it more practical instead of a patch I'll probably get a series of indexed PNGs and a binary file with the palette and TSA data, then you can insert it no matter where you wanna put it XP (My current hack's ROM is hugely expanded so I find it better to be able to put it wherever you want instead)

@Cam you just confused the fuck out of me but I think it makes sense xD If it's upward of 127 it gets a really weird transparent awkward thing :P I took a screenshot at one point but I don't know where I put it, if I find it I'll post it.

And DAMMIT CAM YOU'RE DESTROYING MY WAY TO GET SPRITES!

Edited by Jubby
Link to comment
Share on other sites

just dump the raw data and palette and tile map so he can skip the intermediary step of Wingrit

Wingrit? No I was gonna just drop everything in a blank ROM/bin file, i.e. the TSA and palette, so the rom would JUST be that, then he could just C/P in HxD (or whatever Rey uses) then just pngs so he can insert and repoint wherever he wants with GBAGE :P

Link to comment
Share on other sites

I'm not sure why 127 is the upper limit instead of 255 and I don't have the memory reading skills to figure it out, but if I had to guess I'd say it's because the game needs to load two bytes for every tiles.

...great now I want to build a tile map builder just to make it so much less tedious to do this.

Signed bit maybe? Like how Radiant Dawn can only have 127 for stats/HP until it goes down to zero. I'm assuming it's a negative number which is why it's going down to zero.

01111111 = 127

I wouldn't know why it would have a signed bit either >_>;

Edited by shadowofchaos
Link to comment
Share on other sites

That makes sense. Although, like you said, that brings up the question of "why the fuck is it signe-"

Wait wait wait someone try putting something at index 0xFF. It could be something retarded like opacity (although probably not).

EDIT: Also, what does 'TSA' even stand for? Tile map is a much better term.

Edited by Camtech
Link to comment
Share on other sites

That makes sense. Although, like you said, that brings up the question of "why the fuck is it signe-"

Wait wait wait someone try putting something at index 0xFF. It could be something retarded like opacity (although probably not).

EDIT: Also, what does 'TSA' even stand for? Tile map is a much better term.

Supposed to be Tile Sortment Array or some crap like that :P

Doesn't know what else is going on

I'll be posting the frame stuff in a few minutes, just need a readme.

Link to comment
Share on other sites

EDIT: Also, what does 'TSA' even stand for? Tile map is a much better term.
TSA (Tiles Squaroid Assembler) is resposible for all of those blocks that levels are built out of. Essentially, it takes the 256 currently loaded background tiles and builds blocks of sizes 2x2 (we'll refer to it as a micro from now on) and sometimes even 4x4 tiles (a macro) out of them. Formats vary, but most of them are relatively simple, both to find and edit.

:)

Tilemaps are generally large sheets which are built from tiles. TSA is reserved for actual tilesets, which have become unnecessary with advancing technology allowing less need to squish everything into available memory banks. The backgrounds of conversations in the GBA Fire Emblems would be tilemaps. The battle animations, would be TSA. The former is just a large image that's not put together/switches a few things like mirroring or color choices. The latter literally builds images out of a mess of tiles.

Link to comment
Share on other sites

People have used TSA for a long time. It has a lot of precedence and most people will know what we're talking about if we say "TSA". A "map" might be a much simpler and possibly more accurate term but implementing such a term would cause a lot of confusion for the people who aren't familiar with the subject (i.e. most everyone). And of course making change takes a lot of effort that no one wants or feels there is a need to put in.

tl;dr we're probably going to keep saying TSA for a while

Anyhow I like to split the loading of an image into 3 parts: graphics, palette, TSA. Graphics are the actual tiles that make up the image. They can be in any order (but are preferably in the order they actually appear in). Tiles are 8x8 pixels. Palette is a string of hexadecimal color values. We all know that. And the TSA is that map that tells the game where to load each tile, and with what palette. "With what palette" refers to the ability of a 4bpp image to be more than 16 colors by making different tiles use different palettes within the same image via TSA. FEditor has a CG Editor or something of the like that can do such a thing (though the automated process is only so good because of the general... complexity of creating a formula to make such images--it's good enough as it is anyway).

Something I thought of doing was making the battle template appear to be what it really was. That is to say, make the TSA redundant by making the TSA load every tile exactly where it appears in the graphics. I never tried because I was too disheartened by all the things I heard regarding problems with getting battle templates to work that and ShadowofChaos's tutorial is mega-scary but it probably wouldn't have worked due to all the generally annoying limits that I feared. I did such a thing with the DS Battle Backgrounds though: every image uses the same TSA, and every image is what it appears to be, i.e. when you load it in GBAGE it's just not a mess of tiles, it's exactly what it seems. It's too bad we can't magically do that with battle templates, or else this process would be as easy as making a like, 256x168 image with a tiny format that would take less than 1 minute to do, making sure it's 16 colors, and inserting it. >___>

Guys can dream, right? <___<

@Shadowofchaos lol@trollmark. You're implication was right though, I can't take that joke. I normally don't care but that joke just makes me lose my cool. Completely. XD

And I agree that Jubby is moreintelligentthan he seems, I normally despise PMs though I've ironically answered hundreds of hacking questions via PM and e-mailbut speaking with people who aren't idiots is like, refreshing. >_> And that is coming from someone who is not even smart >_> Sad world we live in where the idiots pity of the bigger idiots

Edited by Strawhat Luffy
Link to comment
Share on other sites

That is to say, make the TSA redundant by making the TSA load every tile exactly where it appears in the graphics. I never tried because I was too disheartened by all the things I heard regarding problems with getting battle templates to work

Isn't that what FE8 did? At least, I seem to recall it being that way. But I haven't looked into the games since '08, so it could be fogging with some other game. If it's not completely without TSA, it should be a lot more... "built" than the FE7 one you see in the first post.

Link to comment
Share on other sites

Isn't that what FE8 did? At least, I seem to recall it being that way. But I haven't looked into the games since '08, so it could be fogging with some other game. If it's not completely without TSA, it should be a lot more... "built" than the FE7 one you see in the first post.

FE8 still loads in a similar way to FE7 but has a more generous tile limit, because around the HP box thing, there's an intricate flowery pattern I guess, don't know what to call it that's made up of all unique tiles, which results in it loading that box almost exactly the way the tiles are arranged :D I think. I don't really touch FE8 :/ But from Rey's tutorial's FE8 section that's what it looked like :P

And Blazer, you're pretty smart, don't sell yourself short :)

By the way I have the package for this, just wanted to ask VincentASM if it was okay to upload it, but we're good :) READ THE README, cause the steps HAVE TO be in that order >:P

Oh and I tried neatening it up by spoilering stuff like Rey's, but the entire unspoilered block can be found at the link to Rey's tutorial, he C/Ped it :P In case you want a doc version for if internet goes down or something :) I totally have most of Arch's Event Hacking Guide C/Ped to Word :P

VASM\'s FEDS Frame Package.zip

Edited by Jubby
Link to comment
Share on other sites

FE8 still loads in a similar way to FE7 but has a more generous tile limit, because around the HP box thing, there's an intricate flowery pattern I guess, don't know what to call it

Filigree, is the name. You could also refer to it as twine, such as ivory twine, gold twine on the edges, etc.. But filigree is the proper name for the designs :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...