gender: take top 4 bits of gr:
31 = 0x1F = 1
63 = 0x3F = 3
127 = 0x7F = 7
191 = 0xBF = 11
See the pattern? If we change the compares from >= to >, we -1. All
numbers match except for the 25/75 ratio pkm... which unveils the
problem.
Simplify the calc for these using the logic above, which fixes the error
and makes the code easier to read!
Thanks SystemError for assisting :)
easy modification which isn't 'random' resulting in a slightly higher
chance of retaining the current gender if possible. threshold values can
change genders (1f:7m), but is slicker overall
Checks.cs initially started out small, but over the years it has grown
to handle multiple types of checks. With all these checks next to
eachother, it's hard to see the overall groups. Splitting them up
(potentially further?) allows for more focused maintenance &
understanding.
Not sure if I'm happy with the overall bandaids used (checks no longer
done within LegalityAnalysis so variable repointing is excessively
used), but I'm happier the way it is now compared to the huge Checks.cs
Add safari min flawless IVs to reroll (can expand if #2025 is required
for egg group15)
Use EV/IVTotal (faster, not linq array based)
Fix missing pumpkaboo form regression, Closes#2026
Relocate swapbits to appropriate class, unneeded in PKM.cs
continued simplification
core.cs is pretty much the following:
misc one-off junk
moveset fetch
encounter table fetch
evo chain fetch
might eventually move things around a bit further for cleanliness so
that misc meta junk is the only thing that remains in core.
update handling that checked for this case to instead check for
equivalence to ability1 instead of 0
was generating a PGF with ability[1] = 0, which is not correct. Just fix
the binaries to behave and get rid of all the workarounds since future
tables don't have missing values.
stored as wc3's, make "Version" from IVersion rather than int so that
"WasXD" recognizes it.
Update handling for fateful encounter trade-away cases.
#1970
amount of pkm obj classes is pretty high, move the static utility
classes to another folder
breaks usage of pkm.ShowdownText; removes a dependency from PKM.
previous hurdle a year ago was propertyinfo fetching not looking at the
base class's properties; dig deeper for all properties to mimic existing
code for netframework
end result is batch editing now possible without gui
1123c24b0c
had addressed the loading, however, it did not address the saving
update pkx to not create a new array every time IsPKM is called
(possibly a lot)
reference PKHeX.Core, main window loads assemblies & initializes
providing an ISaveProvider and the menustrip control (to insert controls
into)
pretty rough but should allow for inserting external control buttons &
allowing it to edit the UI a little
example: https://github.com/kwsch/PKHeXPluginExample
feedback is appreciated
Closes#1933
if not allowed to be genderless, flag as invalid gender
only permit valid genders after genderless is ruled out
(both done by checking the low bit)
Store 4g giratina held item for enc->pkm legality
revise usages of GetSaneGender
Rearrange some logic
Better handle impossible version encounters (gen4)
gen 1-5 done, stuck on 659 - bunnelby egg...?
Adds IV count sorting
Adds Itemless & Illegal deleting
Adds Max level modding, item clearing. Handle egg cases sensitively.
remove final sortby for reversal case as the incremental integer
prevents further ordering.
Any suggestions? Keep in mind that some modifications can be done by the
Batch Editor scripts; smart deletions & sorts are highest value
additions ;)
hold control when triggering the sort
sneaky linq to reverse a sort by:
* re-doing the initial sort, then
* reversing the sorted pkm data by using a throwaway increment
* re-doing the final sort
Nest item choices into separated groups (based on their overall
function).
Adds 3 more deletion options: eggs, untrained, or not-matching-savefile.
Adds 1 more modification option: Max Friendship of current handler