lushen124 / Universal-FE-Randomizer

Properly universal this time.
MIT License
98 stars 28 forks source link

GBA Promotion Randomization #425

Open Geeene opened 1 year ago

Geeene commented 1 year ago

Adds Promotion Randomization logic for GBAFE

Partially based on https://github.com/lushen124/Universal-FE-Randomizer/issues/349, aswell as using the here provided .dmp files.

grafik

Options: Default promotions

Similar promotions (Promoted class has all unpromoted Weapon types)

Random (No natural requirement for weapon sharing)

FE8 Specific: Disallow Monster Classes for either randomization setting

FE6 Specific: Adds ability to allow Thieves to promote, also if promotions are unrandomized, using the Hero Crest. Thieves will by default promote into Sword Masters. There is an option to keep the ability to steal / open chests, either only for thieves (by creating a copy) or in general, so any class that promotes into the same class can also steal.

lushen124 commented 8 months ago

I actually have an idea for this one. You may have seen the logic to create a duplicate class for the lord to try to respect the forced promotion times for the lords. It is technically possible to do that for every playable character as well. We would have to drastically recreate class lists for all the effective pointers, but this allows us to do two things:

In theory, for the first one, we only need to duplicate unprompted classes, but the second one would require duplicating every class for every playable character. But I think that could be a more interesting option, because it more closely matches FE4's random promotion option.

Geeene commented 8 months ago

That is a very good idea

I do know that for having to repoint the effectiveness table there is still the Fili Shield issue, but I guess that is something that still needs to be fixed regardless. That's certainly something we can try out

Geeene commented 6 months ago

I actually have an idea for this one. You may have seen the logic to create a duplicate class for the lord to try to respect the forced promotion times for the lords. It is technically possible to do that for every playable character as well. We would have to drastically recreate class lists for all the effective pointers, but this allows us to do two things:

* We can set different promotions for different characters of the "same" class (e.g.  Bors promotes into a General while Barth promotes into a Paladin).

* We can set different movement ranges for different characters, instead of tying them to the entire class.

In theory, for the first one, we only need to duplicate unprompted classes, but the second one would require duplicating every class for every playable character. But I think that could be a more interesting option, because it more closely matches FE4's random promotion option.

From looking into this a bit recently, there is one issue with doing it like this, specifically since atleast fe8 doesn't have the ability to have a high enough class limit / from what I can tell unused ones that we could reuse.

Though this could also be an opportunity to try and integrate the Skill System which also includes teh class expansion to allow adding more classes / getting all those QOL improvements they contain.

I tried recently for a little bit and it failed during Textloading, but after doing some stuff to avoid those issues it was working fine (outside of some text issues)

Alternatively we could also just include the other things (Expanded Modular Save for class limit / QoL Patches) directly rather than adding the full skill system patch

lushen124 commented 6 months ago

From looking into this a bit recently, there is one issue with doing it like this, specifically since atleast fe8 doesn't have the ability to have a high enough class limit / from what I can tell unused ones that we could reuse.

Apparently 0x7F is the highest class value you can use in vanilla GBAFE, since it seems to only take into account 7 bits for the class ID instead of all 8 bits. I see a patch on FEU that unlocks it to all 255, but only for FE7 and FE8 so far (though I imagine FE6's shouldn't be too far off if we can understand how the patch actually works. I think the other thing that is probably worth doing is figuring out some way to let the player know what class characters promote into in-game so that it's a bit more fair, but this probably would require some ASM hacking, and if we're going that far, we can probably find a way to get per-character promotions without duplicating any classes. Class duplication is just the "easy" way, not necessarily the best or most elegant way. 🙂

Though this could also be an opportunity to try and integrate the Skill System which also includes teh class expansion to allow adding more classes / getting all those QOL improvements they contain.

I tried recently for a little bit and it failed during Textloading, but after doing some stuff to avoid those issues it was working fine (outside of some text issues)

Alternatively we could also just include the other things (Expanded Modular Save for class limit / QoL Patches) directly rather than adding the full skill system patch

I wouldn't mind integrating with the skills system, but I don't know enough yet about the skills patch to know how hard it would be. I know it's been requested, but I have it pretty low on the priority list. If you have it mostly working, by all means, add it to the project. I'd keep it an option though, and ideally the QoL/class limit patches separate from the skills, since I think there's merit to include one but not the other. We can probably work through the text issues you come across.