rngchan / sun-moon-rng

Python tool for RNG manipulation in Pokemon Sun / Moon.
MIT License
25 stars 3 forks source link

Incorrect "seed after hatching" #22

Open jtovarnak opened 7 years ago

jtovarnak commented 7 years ago

Are you sure that seed after hatching is calculated correctly?

I wanted to try this method out, so I hatched 127 Magikarps and figured out my original seed. Run it through update_seed.py , got my current seed and put inside config file. Everything fine so far. Then I started playing around with different options in config and since I was getting expected (predicted by your program) result, it confirmed that I indeed have correct seed.

So I actually built a plan to hatch ~10 shinies in quickest way possible, using my current seed and then using "seed after hatching" to calculate next step. First egg matching my parameters was:

> Accept 208 eggs
> Reject 18 eggs
> Accept egg

Since I was breeding with Ditto I figured why not use Magikarp to speed the process up. So, my breeding Round #1 starts. Funny thing was that I actually also bred shiny Magikarp with correct IV spread along the way :) So, after 208 eggs with Magikarps, I swapped Magikarp parent for the pokemon I wanted to breed. I rejected another 18 eggs and accepted the next one. After I accepted that egg, I immediately removed both parents from daycare. I hatched the egg and it turned out as expected. At this point I saved the game. So, I proceeded to 2nd round in my plan - put Ditto back into nursery together with Magikarp, this time I was supposed to Accept 45 eggs, Reject 1 and then Accept again. Once again, I collected 45 Magikarps, swapped parent, rejected an egg, accepted another, took parents out of nursery and hatched the egg. And it wasn't what I expected! So I thought I might have done something wrong - I did soft reset to get to starting point of Round 2 again. Again, hatched 45 eggs, rejected 1, accepted 1, removed parents and hatched that egg - and I just confirmed that I did nothing wrong the first time, I was not getting what program predicted.

Just to be sure, here is what I was doing:

So, again I took "Seed after hatching: 2b304eabL 3f61c787L f36db708L 1f2ad75aL" and put it into config:

STATUS 3: 0x1f2ad75a
STATUS 2: 0xf36db708
STATUS 1: 0x3f61c787
STATUS 0: 0x2b304eab

So, using new seed I got 3 results for my next search:

IV Spread: (F, 31) / (M, 31) / (M, 31) / (R, 26) / (M, 31) / (M, 31)
Ability: 1
Nature: ADAMANT
Gender: F
Ball Inherited: F
Hidden Power Type: ELECTRIC
PID: a07d223fL
ESV: 2084
Shiny: Yes
Seed to hatch: 260a779dL 12576345L be88107eL 72c3f7a7L
Seed after hatching: dca40614L 8f8a9368L 331cbff6L c6c195baL
Sequence of actions to hatch:
(This one might not work, still working the details)
>Accept 44 eggs
>Reject 30 eggs
>Accept egg
(This one will work for sure, but is longer)
>Reject 1495 eggs
>Accept egg

IV Spread: (F, 31) / (M, 31) / (M, 31) / (R, 1) / (M, 31) / (M, 31)
Ability: 1
Nature: ADAMANT
Gender: F
Ball Inherited: F
Hidden Power Type: DARK
PID: a07d223fL
ESV: 2084
Shiny: Yes
Seed to hatch: 572ac1f7L 355aaebbL 9d2772abL be88107eL
Seed after hatching: dca40614L 8f8a9368L 331cbff6L c6c195baL
Sequence of actions to hatch:
(This one might not work, still working the details)
>Accept 44 eggs
>Reject 31 eggs
>Accept egg
(This one will work for sure, but is longer)
>Reject 1496 eggs
>Accept egg

IV Spread: (F, 31) / (M, 31) / (M, 31) / (R, 1) / (M, 31) / (M, 31)
Ability: 1
Nature: ADAMANT
Gender: M
Ball Inherited: F
Hidden Power Type: DARK
PID: a07d223fL
ESV: 2084
Shiny: Yes
Seed to hatch: 99ae9e87L 7bdd72f9L b3b8bd5cL 355aaebbL
Seed after hatching: dca40614L 8f8a9368L 331cbff6L c6c195baL
Sequence of actions to hatch:
(This one might not work, still working the details)
>Accept 45 eggs
>Reject egg
>Accept egg
(This one will work for sure, but is longer)
>Reject 1498 eggs
>Accept egg

Unfortunately this prediction was not correct. I tried "A45 - R1" twice to be sure I am not miscounting, then also "A44 - R31". Then I even checked some other easily checkable predictions (0IV in certain stat is easy to check for example), and those predictions were wrong as well. This concludes that the seed used for calculation is wrong.

So, the question is - what might have gone wrong? I am 100% sure that no eggs were produced after I collected an egg with my desired outcome. I didn't do anything else in the game either. Did I do something wrong with "Seed after hatching"? I was using it as "STATUS0 STATUS1 STATUS2 STATUS3" as seen in my example above, but maybe I should have converted it as "STATUS3 STATUS2 STATUS1 STATUS0"? Or maybe removing both parents from nursery changes seed as well? I know for sure that changing one parent is safe (hence the Magikarp as placeholder for hatching eggs). I'm also seeing that "Seed after hatching" is same for quite a few results - is that because of Masuda+Shiny Charm?

I really hope I just did something wrong or it's an issue that's easy to fix - it would be shame if I had to hatch 127 magikarps for every single "calculated" pokemon.

Besides that - great job, it is really helpful.

jtovarnak commented 7 years ago

So, I decide to do a bit of proper testing on this and here are my observations:

  1. "seed after hatching" is actually correct I was just converting it to status in wrong order using my previous example "Seed after hatching: 2b304eabL 3f61c787L f36db708L 1f2ad75aL":

    STATUS 3: 0x2b304eab
    STATUS 2: 0x3f61c787
    STATUS 1: 0xf36db708
    STATUS 0: 0x1f2ad75a

    I don't why I thought that you return seeds in results.txt in 0..3 order - after all 3..0 order makes sense in respect to how that external websites returns current seed after hatching 127 Magikarps. It makes it consistent. So, you can treat my original report as invalid.

  2. I actually had to hatch 127 Magikarps twice - during my first batch I had to go to Festival Plaza to make a trade. I didn't do anything else besides that and still, after having 127 numbers, I didn't get correct seed. Seed returned from the website and then run through update_seed.py was not giving me results I was getting through hatching. While it is possible that I could have made mistake, it is also possible that entering Festival Plaza and/or trading changes nursery seed! After I hatched another batch of 127 Magikarps I now have correct seed and can continue hatching :-)

All in all - everything is fine, you can mark this ticket as invalid.