FiendsOfTheElements / FF1Randomizer

A randomizer for Final Fantasy 1 on the NES.
http://finalfantasyrandomizer.com
GNU General Public License v3.0
82 stars 46 forks source link

EXP chests occasionally award maximum EXP #998

Closed highqualityshaun closed 1 year ago

highqualityshaun commented 1 year ago

in some flag configurations and some circumstances, EXP chests award the incorrect amount of EXP

gathering info from several sources (maple, Chadbert, LuffyDV, Serisan, Deadpulse) and compiling below

might be a result of the flag "deads gain exp" with EXP chests might be awarding 65535 experience or 65535 2 experience might vary based on emulator setup "In Bizhawk 2.7.0 with QuickNes core and FCEUX, I get level 10 after a total of 15312 EXP from the chests. Luffy was getting level 11 or level 31. (I need to get more info on Luffy's setup) However, when I used Retroarch 1.14.0 with QuickNES 1.0-WIP 75d501a. I get level 31 across the board with 65535 exp 2."

demonstrated in this clip: https://clips.twitch.tv/AmericanBoldGoatFloof-NcWxe_aEMd6_juM1 with the "DD week4 flagset" https://4-6-4.finalfantasyrandomizer.com/?s=00000000&f=m1f-l5G7MresPtWaAYuwUgjdWt.yKk-KM2zFw-.DWpasFv8RwI4GztGmzeeq3RkKPFAvbdX91oGglB99cJuG1hnHGYhkmbBBAGztEWcHP.hYcmI1xraHdnOp9OulyNef3puw4BZhuei.7Ged0ZLjSmwbdDxTBbBFA6LKr

Repro steps from Serisan:

Serisan's supposition is that there's an RNG value prior to entering combat any number of times in the seed So once you've entered combat and changed the combat RNG values at all, it's fixed. Closing the emu and reopening the same seed, New Game, chests provide expected xp value instead of 65535 or whatever that value This does not appear to be core dependent, Serisan was doing this on NesHawk core

possibly traced to the following method in the code: https://github.com/FiendsOfTheElements/FF1Randomizer/blob/af3936f9d66236c8ddc97ed0f856d21798be2ea8/FF1Lib/Hacks.cs#L604

wildham0 commented 1 year ago

Fixed in 4.7.3.