• Topic Archived
You're browsing the GameFAQs Message Boards as a guest. Sign Up for free (or Log In if you already have an account) to be able to post messages, change how messages are displayed, and view media in posts.
  1. Boards
  2. Shining Force II
  3. How the RNG works to chose a Mithril weapon

User Info: Dan217

Dan217
1 year ago#1
When you are trying to get a specific weapon made by the blacksmith, the outcome is not truly random. Knowing this can make the process of getting what you want much easier.

The result is determined by how many squares you walk from leaving the dwarf town until you return to it. The result is locked upon stepping back onto the town.

The best way to exploit this is to walk in a straight line away from the town directly east, use a land mark to remember where you stopped, and then walk back into the town on the same straight line. The same distance will always yield the same result. All of the “rarest” drops can be attained within that straight line before you hit the mountains. Start with a fairly short random distance. If you don’t like the result, change your distance but remember what you you have tried already to save time.

The drops are in a recurring pattern based on steps taken. The more common drops are in blocks so for example, on our straight line you can imagine a common drop may occur 4 or 5 squares in a row followed by a uncommon drop for the next 2 squares. The rare drop will always be on just one square next to an uncommon drop.

After you figure out which square in a straight line yields a uncommon drop, repeat only one square at a time forward and backward from the uncommon until you find the rare.

I figured this out today and was able to get all the equipment I wanted very easily.

I’m writing this off my cell so if it’s isn't very clear hit me with questions. It’s been more than 20 years and I think we all knew in our hearts it wasn’t actual RNG so this solution is long over due.

If someone is more zealous than me, they could use this technique to map the specific place to walk to and from to get each item.

User Info: Raijinili

Raijinili
1 year ago#2
Good work.

How the Shining Force 2 RNG works is known. It's used by DarkKobold in their tool-assisted speedruns. I don't know of any one source for a thorough explanation of it, but you can read their comments here:
http://tasvideos.org/2566S.html
The RNG of SF2 is a 16-bit sequential loop. It can only change for one of three conditions: A call for a random value, a text box pause, or sitting in a menu. For the two ones that can be manipulated, the RNG advances one step per frame. To cycle through all 65,536 values of the RNG would take 18 minutes! Additionally, this also means I only get 1 chance to access the RNG per-character turn, which limits my ability to manipulate the enemy movements, attacks, and etc. While most worthwhile attacks/rounds are available within the first 60 frames, there are a few waits that are a few hundred frames long, unfortunately. I did my best to minimize wait time in menus.


and here:
https://forums.shiningforcecentral.com/viewtopic.php?p=388476&sid=0f5dc2ea7a365ca90bf4d7b1d15f2863#p388476
In SitD and SF1 (LOGI), the RNG can be directly manipulated via the controller. The controller has 8 buttons, and there for each button is a bit, making a 1 byte number, and that value gets added to the RNG. The RNG is 2 bytes, or 16 bits.

In SF2 and SFCD, the RNG moves only when:
1. A menu is open.
2. A text box is up (Character speaking)
3. The RNG needs a new number.

The RNG in those is consecutive. It travels through all 65536 values, in a special order, and uses that value to determine outcome.


There's a quote from them here, but I can't find the source:
https://gamefaqs.gamespot.com/boards/563341-shining-force-ii/58959828
The RNG calculation for SF2 is IDENTICAL, line for line, to SF1. The function for both games is:
R2 = remainder((R1 * 13 + 7)/65536)
R1 = R2

Now, for both games, this may get executed 1-100 times in 1 frame. Thus, to figure out what happens at execution 55, you just need to know R1 before the frame, and execute the previous formula 55 times.

In Shining Force 1, R1 could easily be manipulated by controller input, the frame before the next set of RNG calculations. Thus, nearly any one of the 65536 possible values could be achieved.

In Shining Force 2, R1 can only be manipulated by the player by opening a menu. Additionally, the exact same formula executes once per frame that the menu is open. Thus, the value you may want, which is one out of 65536 possibilities, may take that many frames to get to. Thus, the perfect value could be as many as 18 minutes away!


u/confirmSuspicious posted at least two videos on manipulating RNG for:
- Power Water: https://www.reddit.com/r/speedrun/comments/9v72z9/shining_force_2_power_water_rng_manipulation/
- Dwarven Village: https://www.reddit.com/r/speedrun/comments/9vqdqc/shining_force_2_rng_manipulation_dwarven_village/

User Info: Elrick75

Elrick75
1 year ago#3
Good to know. I knew walking different number of steps resulted in different drops but I didn't know it was consistent where a rare was beside an uncommon.
My top 10: Phantasy Star IV, Shining Force II, Chrono Trigger, Final Fantasy Tactics, Monster Rancher, FFVI, FE:A, ToG f, Tactics Ogre:LUCT, Breath of Fire II

User Info: DeanWhipper

DeanWhipper
1 year ago#4
Great, now I want to start a new game to try this.

Thanks guys
Is this even legal? http://www.youtube.com/watch?v=3Fxhiq93TTg

User Info: CloudCarry

CloudCarry
1 year ago#5
Yeah we speedrun the game and have put a lot of work into it. I was not able to verify your method of walking out of the town. Basically in order to manipulate the rng we save the game and reset. This is since it resets to 0 or the default position. It's 100% consistent and the result does depend on your inputs. Whether or not you use the turbo code or not will change your patterns that you get as well.

What we're trying to do in the 2nd to last staircase before the blacksmith is use that dwarf location in that room to keep track of where the rng location is. For example, if you hold start and C after saving at the priest in the dwarven village, reset the game as you are still holding start and c, the dwarf patterns are the same no matter what. So we can use that to our advantage. If I were to wait for the sega logo to appear before holding start and C, this would step the RNG in an increment of 1 it gives us an entirely different, entirely consistent dwarf pattern.

Your inputs once you reach the blacksmith have to be pretty good, all of the mithrils would already need to be on a promoted-class user. We avoid the rng moving once we're in that menu so scrolling down and holding A or C isn't enough to change it.

Since in the speedrun we only care about spears and lances (most importantly valkyrie for the attack spell cast it gives), I only bothered to make setups for those with turbo code on, but, but you can copy the methods used in casual play. We can pull 4 gisarmes, for example if you wanted, but there's some variations that aren't possible. For our purposes the sweet spot is 3 valkyries and 1 mist javelin.

User Info: CloudCarry

CloudCarry
1 year ago#6
Here I posted an update because I was just redoing some of the late game anyway, you can get full context from this thread: https://www.reddit.com/r/speedrun/comments/ezmb16/shining_force_2_dwarven_village_rng_manipulation/
  1. Boards
  2. Shining Force II
  3. How the RNG works to chose a Mithril weapon
  • Topic Archived

GameFAQs Q&A