mirror of
https://github.com/kwsch/PKHeX
synced 2025-02-17 05:48:44 +00:00
Update Overworld8RNG.cs
because archit wants it
This commit is contained in:
parent
ebb4e2a56a
commit
34bb0f1fc0
1 changed files with 7 additions and 2 deletions
|
@ -10,7 +10,7 @@
|
||||||
flawless = 0;
|
flawless = 0;
|
||||||
|
|
||||||
int ctr = 0;
|
int ctr = 0;
|
||||||
const int maxAttempts = 10_000;
|
const int maxAttempts = 50_000;
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
var seed = Util.Rand32();
|
var seed = Util.Rand32();
|
||||||
|
@ -33,10 +33,15 @@
|
||||||
if (GetIsShiny(pk.TID, pk.SID, pid))
|
if (GetIsShiny(pk.TID, pk.SID, pid))
|
||||||
pid ^= 0x1000_0000;
|
pid ^= 0x1000_0000;
|
||||||
}
|
}
|
||||||
else if (shiny == Shiny.Always)
|
else if (shiny != Shiny.Random)
|
||||||
{
|
{
|
||||||
if (!GetIsShiny(pk.TID, pk.SID, pid))
|
if (!GetIsShiny(pk.TID, pk.SID, pid))
|
||||||
pid = GetShinyPID(pk.TID, pk.SID, pid, 0);
|
pid = GetShinyPID(pk.TID, pk.SID, pid, 0);
|
||||||
|
|
||||||
|
if (shiny == Shiny.AlwaysSquare && pk.ShinyXor != 0)
|
||||||
|
return false;
|
||||||
|
if (shiny == Shiny.AlwaysStar && pk.ShinyXor != 0)
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
pk.PID = pid;
|
pk.PID = pid;
|
||||||
|
|
Loading…
Add table
Reference in a new issue