Jump to content

Deciphering the growths


Recommended Posts

Values from Marth's probably-growths were being sent in to a function at 0x02049280 within register 1. The last thing this function does is store a value to R0, which I collected.

[...]

The function that the values are run through is pretty small but I don't have most of the information I would need to understand what it's doing.

What kind of other information? I'd be curious to see the function, though you'd probably understand it better than me.

Link to comment
Share on other sites

  • Replies 117
  • Created
  • Last Reply

Top Posters In This Topic

Not sure what the function could be, but I noticed the subtraction of the 1st and 2nd row matches with the obtained numbers. So even if we don't find out what the function is, as long as we have enough representations of different growth rates, then it should be fairly easy to gather the remaining growths.

Eg.

Marth
Subtrac 39 3A BE 3A 3A 71 63 7E
Growths 32 2D 05 2D 2D 50 19 0A

Luke

Subtrac 39 3A 00 63 65 65 63 7E
Growths 32 2D 00 19 28 28 19 0A

Ryan

Subtrac 65 65 00 4F 3F 65 63 7E
Growths 28 28 00 3C 14 28 19 0A

Growth / Subtracted number
00 00
05 BE
0A 7E
0F
14 3F
19 63
28 65
2D 3A
32 39
37
3C 4F
...
50 71

Edited by VincentASM
Link to comment
Share on other sites

Desmume-> Load Game-> Tools-> View Memory-> for memory, to say, look at what values are stored in the memory for growth rates

To look at the code at an offset (function/routine) use the disassembler (under tools menu) and go to an offset. If you don't understand it though, it probably won't be too much help...

I think that's how it works.

Also, I'll take you up on your offer if you're still willing, Vincent--could you post any NMMs you might have made? I didn't plan on making any due to other people's general lack of interest but it'd be cool to have it anyhow and it saves me a bunch of work since I've little interest in figuring out stuff which is why I'm not bothering with growth rates.

P.S. to anyone who wants to decompress the stupid LZ77-11 files, such as the data file, you can use Puyo Tools. Nintenlord's Compressor, unLZ-GBA, GBAGE, etc., don't work, they only support LZ77-10. I still am not sure what the difference is between the two besides the header byte...

Link to comment
Share on other sites

Thank you!

It looks like the zero growths should be easy to pick out (that's what Bantu's stats were for). I wanted to see if it was a simple operation to decipher the values (Norne's Luck in FE11 is the same as Draug's, and I wasn't sure if it carried over). Looks like the answer to my question is no.

Ah well, best of luck in deciphering this!

Link to comment
Share on other sites

Wow, if those are Cecile's real growths, we may see the best speed growth on a character since Geneology. 95% Speed growth as an archer. To give you an idea of how awesome that is, she will tie her speed with Cav!Cecile in 5 levels, proceeding to get faster from there. Ludicrously quick for someone ducking into archer (considering Lunatic of course). Too bad 5 move sucks, but getting OHKOd and getting countered is worse.

Link to comment
Share on other sites

BTW, how do view these registers? Do you need to use a debugger, check the RAM or something else?

I wasn't able to figure out how to break execution and step through the disassembler in DesMume - I think it requires GDB to be hooked into it first - so I modified the source to print out debugging information at points I was interested in and built custom versions. Since it's under GPL I can't put up the current custom version anywhere without going through all the rigmarole associated with that but if you have the ability to build it yourself the relevant additions are adding

if(ARMPROC.instruct_adr == 0x020492C0)
{
INFO("Potential character growth: %d.\n", ARMPROC.R[0]);
}
if(ARMPROC.instruct_adr == 0x02049458)
{
INFO("Potential class growth: %d.\n", ARMPROC.R[0]);
}

to times after the arm instructions are ran in armcpu.cpp:armcpu_exec() (At line 566 in the copy of the source that I have - there are a couple of other points where instructions can be run from, but none of them seem to be relevant here).

What kind of other information? I'd be curious to see the function, though you'd probably understand it better than me.

0204:9280 - Move R3, R4, R5, LR onto the stack
0204:9284 - Copy R2 (unknown) into R5
0204:9288 - Copy R1 (growth value) into R4
0204:928C - Branch/Link to 0204:91E4

0204:91E4 - Load *0204920C (constant 0x021BE658) into R1
0204:91E8 - Load *02049210 (constant 0xB21642C9) into R2
0204:91EC - Load *R1 (0x0229898C) into R1
0204:91F0 - Load *(R1 + 8) (When I was transcibing, this was a pointer to Marth - may either always select the relevant character or always select the first character) into R1
0204:91F4 - Subtract R1 (pointer to Marth, maybe) from R0 (unknown) and put the result in R3
0204:91F8 - Signed Multiply R2 (0xB21642C9) by R3 (unknown) and put the results in R0 (high) R1 (low).
0204:91FC - Add R0 (unknown) to R3 (unknown) and put the result in R0
0204:9200 - Shift R3 (unknown) right by 0x1F (almost half shifted out) and put the result in R1
0204:9204 - Add R1 (unknown) to R0 (unknown), shift the result right arithmetically by 6, and put the result in R0 (actually I'm not sure whether is shifts the result or shifts R0 alone - I don't have any experience with the command (ADD R0, R1, R0, ASR 0x6))
0204:9208 - Return

0204:9290 - XOR R0 (unknown) with 0x3E, and put the result in R2
0204:9294 - Add R5 (unknown) to itself and shift left once, and put the result in R0
0204:9298 - Load *020492C4 (constant 0x021E658) into R1
0204:929C - Subtract R0 (unknown) from R2 (unknown) and put the result in R2
0204:92A0 - Load constant 57 into R0
0204:92A4 - Multiple R0 (57) by R2 (unknown) and put the result in R3
0204:92A8 - Load *R1 (maybe constant 0x0229898C - not sure whether 0x021E658 is within ROM offhand) into R0
0204:92AC - XOR R3 (unknown) with 0xF, and put the result in R1
0204:92B0 - Subtract R1 (unknown) from R4 (growth value) and put the result in R1
0204:92B4 - Load *(R0 + 0x4C) (unknown) into R0
0204:92B8 - AND R1 (growth value with unknown subtracted) with 0xFF (restrict to 8-bit) and put the result in R1
0204:92BC - Load8 *(R0 + R1) (unknown & growth value with unknown subtracted) into R0
0204:92C0 - Move R3, R4, R5, PC off the stack (LR -> PC causes return)

The class function was similar, but I didn't run through it at the time so I don't know exactly how similar.

Link to comment
Share on other sites

Thanks for posting it. After staring at it for a good 10 minutes, there were quite a few things that puzzled me.

I'll bet anything that going into that function, R0 is some sort of "character number". Then this line

0204:91F4 - Subtract R1 (pointer to Marth, maybe) from R0 (unknown) and put the result in R3

saves the offset to R3. The next line is baffling; it multiplies the answer it just came up with by some crazy (negative) number.

A couple lines later there's a right shift, which destroys all but the most significant digit in R3. Wtf?

At this point I became thoroughly confused. Can anyone else make heads or tails out of this?

I also noticed this weird thing:

0204:9294 - Add R5 (unknown) to itself and shift left once, and put the result in R0

Isn't this the same as multiplying by 4/shifting left by 2? Odd.

Edited by Meteor
Link to comment
Share on other sites

The last line you mention there is the similar to another line I mentioned where it tags the shift operation into the operands of the add operation. It's possible that the shift happens to the operand it's next to instead of to the result as a whole, and you would consequently end up with R5 x 3, which would make more sense. But as I said I haven't seen that used before and I haven't looked it up to see what it should be doing.

Link to comment
Share on other sites

I'd like to try deciphering it, but my laptop's about to die, and I don't have a power cord handy. It looks like my theory about doing something to both registers was true, but I didn't realize just HOW MUCH needed to be done!

Link to comment
Share on other sites

Although her Speed growth still isn't that good, which is to be expected. Her growth was bad in the original, but enemies were so slow that her base plus star orb shards would carry it to end game.

Link to comment
Share on other sites

I was wondering, do you guys think that clock abuse will be applicable to this game like it was to FE11? I hope this isn't too off-topic. :(

Edited by Leif
Link to comment
Share on other sites

Some other combined growths:

Cavalier Growths

40, 15, -10, 25, 10, 0, 15, -5

Luke Growths

50, 45, 0, 25, 40, 40, 25, 10

Combined

90% HP

60% Strength

0% Magic

50% Skill

40% Speed

40% Luck

5% Res

Archer Growths

40, 10, -10, 20, 30, 0, 10, -10

Gordin Growths

30, 30, 0, 20, 10, 50, 20, 10

Combined

70% HP

40% Strength

0% Magic

40% Skill

40% Speed

50% Luck

30% Defence

0% Resistance

All the other character growths (I got from main site) look incomplete. Plus there's no other class growths yet.

EDIT: Also, a my unit cavalier would be this (without the option 3 added bonus to growths)

Cavalier Growths

40, 15, -10, 25, 10, 0, 15, -5

My unit Growths

30, 25, 15, 30, 30, 60, 20, 10

Combined growths

70% HP

40% Strength

5% Magic

55% Skill

40% Speed

60% Luck

35% Defence

5% Res

Yeah.. I think the future option affects growths a lot.

Edited by Kelsper
Link to comment
Share on other sites

One thing I notice is that units seem to be having an average of 30% defense class by class lately (save for classes like Fighter, Hunter and Magical classes of course). I guess they realized that 20% isn't that strong a staple average Def growth anymore.

Speaking of which.

Archer Cecile

70% HP

40% Str

65% Skl

95% Spd (lololololl)

50% Lck

25% Def

Now, she can make up for the loss of 2 speed in 5 levels, which is stunningly quick. Only problem is, she's now got the issues of being an archer on top of still being very vulnerable.

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...