Please login or register.

Login with username, password and session length
weapon sprites (in battle)  (Read 10140 times)
Pages: [1] 2
FFAT,Producer, Animator, Spriter, Thread Thief
Mando [Posts: 367]
  • View Profile
  • share
  • [January 31, 2011, 03:45:34 AM]
weapon sprites (in battle)
« on: January 31, 2011, 03:45:34 AM »
Currently I have a small snag in my patch. Since I added new items. Changed up weapons via removal.
I have to match up whats in the item screen and the animation for when it calls forth the sprite.
Does anyone here know the number of colors that maybe used on the WEP palettes?
OR how to make it call forth the correct color I changed it to.
Either one would be helpful.


^ New FFAT website made by St4r!
Vanya [Posts: 3956]
  • View Profile
  • My Facebook
  • share
  • [January 31, 2011, 04:17:39 PM]
Re: weapon sprites (in battle)
« Reply #1 on: January 31, 2011, 04:17:39 PM »
Those can be hex edited. Give me a little while to look through my notes and I'll post back later.

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    FFAT,Producer, Animator, Spriter, Thread Thief
    Mando [Posts: 367]
    • View Profile
    • share
    • [January 31, 2011, 08:22:43 PM]
    Re: weapon sprites (in battle)
    « Reply #2 on: January 31, 2011, 08:22:43 PM »
    I love you vanya  ;)


    ^ New FFAT website made by St4r!
    ALL THE THINGS Official Caretaker.
    RavenOfRazgriz [Posts: 3022]
    • View Profile
    • share
    • [February 02, 2011, 12:18:46 AM]
    Re: weapon sprites (in battle)
    « Reply #3 on: February 02, 2011, 12:18:46 AM »
    I actually needed this info as well, because I remember seeing the need for hex editing being posted before but couldn't google-fu the answer, so I'm also much interested in these notes.
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 02, 2011, 03:00:43 AM]
    Re: weapon sprites (in battle)
    « Reply #4 on: February 02, 2011, 03:00:43 AM »
    Here's a big chunk of data I got from Cheetah.


    I've done some research and have found that the values depend on the weapon type chosen and that they are split up into certain groups.
    For example, swords, ninjato, knight swords, katana, rods and staves share the same graphic area. The Bytes on the left are palette stuff and the one on the right is the graphics pointers. All weapon groups I've tested use increments of 2 except Axe/Flail. I still need to test weapon types after spears & poles.
    « Last Edit: February 02, 2011, 04:30:51 AM by Vanya »
    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    ALL THE THINGS Official Caretaker.
    RavenOfRazgriz [Posts: 3022]
    • View Profile
    • share
    • [February 02, 2011, 03:49:39 AM]
    Re: weapon sprites (in battle)
    « Reply #5 on: February 02, 2011, 03:49:39 AM »
    This is great, thanks very much Vanya.

    ...Though, can I get the retard-friendly version because my brain is currently a piece of mush that somehow feels like its missing something after fighting with Graphics Gale all day?  I get the feeling I'm not the only one who'll need it anyway.
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 02, 2011, 04:43:39 AM]
    Re: weapon sprites (in battle)
    « Reply #6 on: February 02, 2011, 04:43:39 AM »
    After loading BATTLE.BIN in a hex editor search for this address: 0x02D3E6
    Every 2 bytes = one equipment slot corresponding to the order in the patcher.

    xxyy

    xx=palette
    yy=graphic slot from WEP1.SPR

    The specific graphic that is linked to each value depends on the item type set in the patcher.

    swords, ninjato, knight swords, katana, rods and staves share the same section of WEP1.SPR
    The other shared sections I know of are axes/flails, knives, & spear/poles. I haven't tested anything beyond that.
    It's possible to redraw some parts of WEP1.SPR to add more graphics of certain types be overwriting some unused graphics.

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    ALL THE THINGS Official Caretaker.
    RavenOfRazgriz [Posts: 3022]
    • View Profile
    • share
    • [February 02, 2011, 05:51:47 AM]
    Re: weapon sprites (in battle)
    « Reply #7 on: February 02, 2011, 05:51:47 AM »
    xx is easy enough, it shares the same 0-F palette info used by FFTPatcher I assume.

    You lost me on yy.  I have WEP1 opened but I don't see any correlation between the bytes in your quoted notes from Cheetah and what's actually on the sheet, unless I'm reading things horribly wrong. So, do I set the Item Type in FFTPatcher, which loads a base "table" to draw from, and then change the byte itself in Battle.bin which tells it which graphic off that table to reference?  This is what I infer when I read you talking about how things "share sections", since they seem to be grouped based in very similar graphics.  (The various sword types, rods, and staves are all similar in terms of graphic size, as are Spears/Poles, as are Flails/Axes, so this seems to be a sensible deduction.)

    But even deducing this, it still doesn't tell me exactly what value to set for YY to call up a specific graphic, just that the graphics are called by the Item Type and YY together.  Is there an easy way to do this?

    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 02, 2011, 04:48:01 PM]
    Re: weapon sprites (in battle)
    « Reply #8 on: February 02, 2011, 04:48:01 PM »
    So, do I set the Item Type in FFTPatcher, which loads a base "table" to draw from, and then change the byte itself in Battle.bin which tells it which graphic off that table to reference?

    This is correct. They do indeed work together.
    You start with yy =00 for the first graphic in each section. So if you were to set a Rod to 00 it would look like the first sword at the top with that rod's palette. For most graphic sections you increment by 2 to get the next complete graphic, otherwise you are using the bottom of one and the top of the next. Therefore if yy = 02, you are setting the rod to the second sword graphic from the top. Axes/Flails use increments of 3.

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    ALL THE THINGS Official Caretaker.
    RavenOfRazgriz [Posts: 3022]
    • View Profile
    • share
    • [February 02, 2011, 05:10:00 PM]
    Re: weapon sprites (in battle)
    « Reply #9 on: February 02, 2011, 05:10:00 PM »
    That actually should make things fairly simple, knowing that.

    Now that I know how to read it, it also looks like Longbows and Crossbows use increments of 3, Guns use increments of 2, and Shields use increments of 6.

    This should help me greatly and now should be retard-friendly enough for almost anyone to use, barring someone who needs a visual aide.  Thanks much.
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 03, 2011, 12:49:14 AM]
    Re: weapon sprites (in battle)
    « Reply #10 on: February 03, 2011, 12:49:14 AM »
    You're welcome! ^_^
    I really should finish documenting this whole thing and write it up so we know what works what doesn't and what values use what areas of WEP1.SPR

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    I'ma Firin Mah Lazorz!
    RandMuadDib [Posts: 381]
    • View Profile
    • share
    • [February 21, 2011, 06:32:37 AM]
    Re: weapon sprites (in battle)
    « Reply #11 on: February 21, 2011, 06:32:37 AM »
    hey just wondering if you ever finished documenting everything for us retard-strong out here? If not i'll try messing with it tomorrow and see if i can understand what you're saying.

    I will show you the power of SARDIIIIINES!!!!
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 21, 2011, 04:56:16 PM]
    Re: weapon sprites (in battle)
    « Reply #12 on: February 21, 2011, 04:56:16 PM »
    Naw. I've been too busy dealing with some really heavy life issues.
    So, by all means, feel free to continue the documentation and post back your findings. ^_^

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    I'ma Firin Mah Lazorz!
    RandMuadDib [Posts: 381]
    • View Profile
    • share
    • [February 22, 2011, 12:01:01 AM]
    Re: weapon sprites (in battle)
    « Reply #13 on: February 22, 2011, 12:01:01 AM »
    i myself am busy as well but if i get a chance to mess around with it i'll post what i find.
    good luck with your 'heavy life stuff' and i hope its not too heavy

    I will show you the power of SARDIIIIINES!!!!
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 22, 2011, 10:22:47 AM]
    Re: weapon sprites (in battle)
    « Reply #14 on: February 22, 2011, 10:22:47 AM »
    Thanks. I'm gonna need all the luck I can get.

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    I'ma Firin Mah Lazorz!
    RandMuadDib [Posts: 381]
    • View Profile
    • share
    • [February 23, 2011, 06:55:44 AM]
    Re: weapon sprites (in battle)
    « Reply #15 on: February 23, 2011, 06:55:44 AM »
    Well here's what i've discovered so far. Its not much and i think most of it has been posted elsewhere on the site.

    XY ZZ

    As we know there's two bytes for each item slot. The first byte is comprised of two single-digit hex values, X and Y. The second byte is (most likely) a single two-digit value. Granted i haven't tested past daggers yet.

    X controls the palette according to WEP1 in Shishi's. This controls the color of the weapon, essentially. Some palettes are more well defined than others.
    Y controls the palette of the weapon effect (slashing blur, etc) of the attack, as defined in WEP2, below. While you can browse the palettes in shishi's, i'll say here that it seems to cycle various colors, including blue, red, yellow, green, brown, purple and grey (or gray).

    Although now that i think about it i may have to test to see if perhaps the two ZZ digits are actually ZA, where A is the weapon sprite (determined by type) and Z is the effect sprite (also, most likely, determined by type). Needs further testing, will update with results.

    Edit:  So that last thought was wrong. The two ZZ digits are definitely connected. After testing two daggers that were 00 00 and 00 10 i was expecting the same daggers with the same palettes to produce different swoosh effects, and instead i got a dagger and a pole. Definitely still XY ZZ.

    Edit 2: Alright well. I finished testing the daggers. Its mostly garbage when ZZ is higher than 06, though you can definitely tell that the garbage is parts of other items (if you're looking at WEP1). When ZZ was 20, it looped back around. Some quick math revealed that each single increment of ZZ is 8 pixels. (i.e. 01 is 8 px lower than 00) Its late and i'll move on to whatever weapon group is next tomorrow. gross, ninja blades. i can't even pick one out on WEP1.
    « Last Edit: February 23, 2011, 06:09:10 PM by RandMuadDib »
    I will show you the power of SARDIIIIINES!!!!
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 23, 2011, 08:57:08 AM]
    Re: weapon sprites (in battle)
    « Reply #16 on: February 23, 2011, 08:57:08 AM »
    Are you certain about the palette being two single digit values? 'Cause that's pretty significant.

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    I'ma Firin Mah Lazorz!
    RandMuadDib [Posts: 381]
    • View Profile
    • share
    • [February 23, 2011, 06:07:57 PM]
    Re: weapon sprites (in battle)
    « Reply #17 on: February 23, 2011, 06:07:57 PM »
    I am fairly certain. There was a similar thread i saw a while back that suggested this, and i just checked to confirm. Let me see if i can find the thread.

    Yup here it is.
    http://ffhacktics.com/smf/index.php?topic=534.20

    In fact, it was your post Vanya that led me to this conclusion.


    Although i'm not sure what you meant by projectile. I thought you meant arrows and crossbow bolts, but it turned out to be the swoosh/blur effects i mentioned before.

    Edit: Another thing i've found, or at least have been confused about: When i was going through the dagger sprites, I found that there are more than one picture or perhaps frame per sprite, and i could not tell them apart from the screenshots i took in PSx. For example, a weapon with type Knife and a ZZ value of 00 seems to correspond to the first -row- of daggers in WEP1, not just one of them. I haven't yet figured out if one is used for the attack animation and the other is used for, say, weapon guard. I'm going to have to recolor them to figure it out.

    Edit 2: Further testing reveals that each row is essentially the same sprite, just different frames within the sprite.
    « Last Edit: February 23, 2011, 07:22:26 PM by RandMuadDib »
    I will show you the power of SARDIIIIINES!!!!
    Vanya [Posts: 3956]
    • View Profile
    • My Facebook
    • share
    • [February 24, 2011, 10:03:47 AM]
    Re: weapon sprites (in battle)
    « Reply #18 on: February 24, 2011, 10:03:47 AM »
    Edit: Another thing i've found, or at least have been confused about: When i was going through the dagger sprites, I found that there are more than one picture or perhaps frame per sprite, and i could not tell them apart from the screenshots i took in PSx. For example, a weapon with type Knife and a ZZ value of 00 seems to correspond to the first -row- of daggers in WEP1, not just one of them. I haven't yet figured out if one is used for the attack animation and the other is used for, say, weapon guard. I'm going to have to recolor them to figure it out.

    Edit 2: Further testing reveals that each row is essentially the same sprite, just different frames within the sprite.

    That's correct. It's the same with all the weapon sprites. I think your confusion might stem from a misuse of the term sprite. In video games a sprite is a collection of images used to represent an object. It's often the case that an object needs only one image, but in this case the object doesn't technically have a sprite. It just has a graphic.

    • Modding version: Other/Unknown
  • ¯\(°_0)/¯
    I'ma Firin Mah Lazorz!
    RandMuadDib [Posts: 381]
    • View Profile
    • share
    • [February 26, 2011, 07:07:25 AM]
    Re: weapon sprites (in battle)
    « Reply #19 on: February 26, 2011, 07:07:25 AM »
    Alright i've cataloged all of the weapons, their battle.bin offsets, and the ZZ values for everything. it doesnt look like i've discovered anything truly new at this point, but a proper list is always handy to have. I wont have time to post my findings for a few days as i just got promoted and i've got a terrible cold, but as soon as i have a day off i'll post the list and a few .png files for everyone.

    I will show you the power of SARDIIIIINES!!!!
    Pages: [1] 2