This format won't be supported cleanly, so let's just try to allow language detection to work as best as it can without storing metadata in the SK2 bytes.
now that stadium saves all expose registered teams, can just call from the parent class
rental sk2's have no TID; add that to the requirement to not get flagged for missing OT
Closes#3009
Make QRPK7 implement IEncounterable and remove hardcoded PKHeX strings
Let force hatching for WC3 eggs try to hatch from the savefile's language, then revert to english if failed to set an OT.
Readonly slots
Things could be expanded on to use interfaces and wrappers for a "SlotReference" and properties for readonly.
But that's kinda unnecessary
Detects the language of the currently loaded save file, and passes that info to the blank sav creator
Use a trainer name of "1337" instead of PKHeX for any Japanese save file, because Gen1/2(/3?) character tables don't have regular ascii chars.
Introducing a new PKM format: SK2
Split ICaughtData2 off of PK2 so it can be shared with SK2 when type-checks occur
Add conversion for PK2<->SK2
Split the split-buffer handling for GBPKM to GBPKML (what a name), so that I can reuse shared accessor logic for SK2.
Move Home8 location to Locations.cs for documentation
Move FestaFacility to correct folder
Remove unnecessary public modifier on interface method
Pass the program's Version to any loaded plugins, if they wanted to check compatibility...?
SWSH is the first common savefile type that has different revisions after official patches. We want to indicate in the Program Title which revision we're currently editing, because people still are not editing latest-format saves and complaining y no urshifu.
Use short descriptions to indicate revision (Base, IoA, CT), rather than magic numbers (v0/v1) or 1.X or 1.X.Y+, because GameFreak can't follow semver rules.
go away ranch platinum update, i might handle you another time
* Fix broken hidden power power calculation
* Fix broken Gen 2 Hidden Power calculation
* Add parentheses
* WIP UI
* Finalize UI, only show on gens 1-5
* Inline some logic to reduce allocations
* Add unit tests for both hidden power calculation cases
Co-authored-by: Kurt <kaphotics@gmail.com>
Change Ability array to IReadOnlyList, add method to check ability index in personal data
Suppress some message warnings
Change EvolutionChain short-circuit for VC to jump from gen6 directly down to gen2. There aren't any notradeback 1 situations, so a notradeback1 will always start with g=1, so no need for the other if-continue.
Simplify pk5 conversion
precompute result size
set Gen5 as lumped group for common encounters
remove linq usage (besides Sum call, whatever)
GetEncounters now only filters the in-game static encounters rather than the dreamworld too, as those are already filtered by separate arrays.
Get the variable rather than indexing into the array each time
Simplify some expressions in sav7 for readability
Make SAV_EventFlags use comboitem explicitly by type rather than an anonymous type with same member names
* Added PokeWalker Courses, Watts, and Steps editing
* Use util method for getting bitflags
* Keep old cheat method
Change signature so that the default value passed is to unlock all; can pass 0 instead to lock all
* Pass reference to derived sav4-type object
Wev'e already type-tested once, capture the reference and pass it into the appropriate load/save methods.
* Add control anchoring for window resizing
Also widen the labels for localization (longer strings possibly)
Also clamp give all for TMs to 1 instead of whatever the giveall value is, like for prior games' HMs
reuse the "free space" bool; no real benefit in increasing the amount of abstraction (even though that's my current urge for legality)
Because we pass in a reference to the raid block, rather than obtain the reference from the to-be-edited save file object (which was cloned), we need to restore the unmodified data to the save file instead of copying the modified save data.
Bad explanation, but we've edited the origin save data. Revert to original.
Co-Authored-By: sciresm <sciresm@users.noreply.github.com>
Co-Authored-By: Matt <sora10pls@users.noreply.github.com>
Co-Authored-By: Archit Date <architdate@gmail.com>
Closes#2826
It doesn't find it in the SM table, but didn't return -1
rework logic flow to return when found, rather than after loop finishes.
Also fix display off-by-1 since we're not using zero indexing for our entry numbers.
Thanks @Ammako !
all but egg exposed it; now, just make egg expose it and remove the unnecessary interface
we still need to Set generation for non-eggs/mgift, so have a separate Settable interface for internal purposes.
Unfinished text edits aren't pushed until after the combobox changes index
#2820
can't tell the numericupdown to finalize entry, even with a Focus() call to the combobox (to change focus from the numericupdown).
* AV means 覚醒値(Japanese), Awakening values(English), not the Species strength
* OT means おや(Japanese), Original Trainer(English), not the Trainer
* L_RHeightMin min means minimum not minute
* delete received items with the delete key
mass selection of received items for mass deletion as well
improved index selection on deletion
* tab indexing for the form
Loading the window and assigning the datasource fired the index changed event, changing the first block (array) to the (selected index of type), which was bool1. Exporting the save caused a bad block type write, yielding a bad size.
Only add the event after the constructor is finished, so that it only fires via user interaction.
Similarly reported but not exactly noticed in #2658Closes#2663
Gonna update the release with a hotfix
Cuts out about half the size; there's still a bunch of apply-value logic but it's not really big enough for a separate class.
Rename BallRandomizer->BallApplicator
Typing in the key to the combobox should immediately start filtering. We can't put the block type first, as we can't quickly fetch a block by key.
So, just trim off everything but the key when we start ordering things. They're already in order by ascending key -- the known blocks have already been pulled to the top and can be sorted without modification.
Now matches Interface declaration style (iAccessorGenGame), and is consistently named with the other accessors already using the same naming style
plus they are now ordered in the file tree :)
no functional change
Not done for Array types or Object types
muh reflection, such spooky
mark Offset as non-browsable so it doesn't show up in propertygrid if the block is being edited by a grid :)
I imagine a struct-type-sensitive array property grid edit could be done via Buffer.BlockCopy to a dest array, but there's so few Array blocks... so meh
Uses reflection to grab a list of defined constants (block keys), and a list of defined block reader classes.
Show name of block in red for a more prominent hint that this block is somewhat editable :)
since battle subway can have a maximum of 9999 for your record, it's silly to limit it to 100.
i also included some tab indexing so people can navigate the window with a keyboard, and a minor fix to the "record" labels so you can read them.
Record ID const declaration for reuse
Change 255->300 for streak max
Set record as well (ignore currently set value if modified via dropdown)
Closes#2649
Not sure if Money and BP can get a similar record-set treatment.
Apparently my copypaste of the class didn't delete all the old unused controls. Ha!
Move non-gui logic to core as separate classes, in case ppl wanted to reuse them in their own projects.
Didn't enable it; there's some side effects from properties that used to be null in PKHeX.Core
there's probably more, but just handling a few.
Closes#2642
Show Type in DropDown
Show Value in TextLabel
Export Value as filename after Key, helps show value
Import filename ignore content after Key (import accounting for value in export filename)
Option to denote block start more clearly with an ASCII string (BLOCK XXXX)
Option to omit block type info
Option to omit blocks that aren't an array type
#2635