Kurt
b9246ece37
Extract y2k datetime logic, also wardrobe tweak
...
swsh gonna have wardrobe, so rename class and relocate some logic in for
better docs
2019-09-15 22:12:32 -07:00
Kurt
229bb0d05d
Merge dualbuffer into sav4
...
SAV3 has two general save chunks and storage
SAV4 also has the hall of fame block, which is a third block; no mo
silly names !
2019-09-14 11:39:48 -07:00
Kurt
dc10c057a0
Use correct boxdata buffer when doing box manip
...
Closes #2386 ; guess I forgot to finish this.
2019-09-12 19:01:06 -07:00
Kurt
0d9c18e1c6
Minor clean
...
dual bounds check -> single check via uint cast
pkx: keep array reference for reuse in next check
format return to second line to stick out more; lines of code are cheap
:)
2019-09-11 22:17:16 -07:00
Kurt
40cbbaa695
Relocate to more appropriate util class
2019-09-11 18:39:49 -07:00
Kurt
c5ebbbbe15
Minor clean
...
Magic number -> const usage
default(T) -> default (c#7.x feature)
remove some unused stuff
fix indentation in some spots
2019-09-10 22:07:50 -07:00
Kurt
62d08d7c30
Misc clean
...
split some methods with optional parameters=null
add more xmldoc
replace some magic numbers -> enum/const references
consolidate common array operations (span soon maybe?)
2019-09-10 00:21:51 -07:00
Kurt
edf36e8a34
Fix sav4 checksum calc
...
DPPt have a footer that's 0x14 bytes; HGSS is only 0x10 (first u32 was
removed from struct).
2019-09-03 18:16:10 -07:00
Kurt
4b8082be23
Add Pokegear number editing (hgss)
...
Closes #2379
2019-09-02 21:24:49 -07:00
Kurt
b81a1e1e29
Refactoring
...
Increase abstraction for arbitrary slot get/set operations, and fracture
SAV4 behavior for each game type.
Adds: Undo/Redo of party slot changes
Fixes: Fixed Gen5 daycare slot 2 reading, and EXP reading
Fixes: Some slot color glitchiness
Fixed: Box layout editor now hides the flag label if no flags are
present
Fixed: Gen7 box flags are now shown (unknown purpose lol)
Changed: savefile objects are generally smaller (removed a few shared
offset fields)
2019-09-02 19:30:58 -07:00
Kurt
a133abc615
Add pokegear caller ID enum
...
#2379
Cheat as requested in issue not implemented yet; pending future changes
to split sav4.
2019-08-27 16:17:29 -07:00
Kurt
f0df115ccd
Fix box load on uninitialized box load
...
Closes #2376
probably will be rewritten at a later time; am reworking the slot info
messaging for drag/drop/display
2019-08-23 18:03:10 -07:00
Kurt
bf6c25eca7
Break up SlotChangeManager logic
...
A little bit cleaner when the logic is separated
Keep an abstraction of BoxEdit to cache the current box contents.
Already fetched to show sprites; any future fetches (for preview text /
hover sprite) can reuse the already fetched pkm data.
Should probably rewrite this stuff completely, but effort better spent
elsewhere
2019-08-20 19:50:28 -07:00
Kurt
4f3745e3c6
Change enumerate -> array fetch to force eval
...
https://projectpokemon.org/home/forums/topic/54426-pkhex-error/
trycatch will trip here rather than be uncaught when evaluated later
tbh I don't like pkhex's method chain (enumerable, bool, throws), but
this fixes the error.
2019-08-14 16:45:21 -07:00
Kurt
9c58903f55
Fix blank sav3 : sapphire init
...
lol it's been this way for 7+mo
Closes #2369 ty @CorvusAtrox !
2019-08-04 00:59:59 -07:00
Kurt
f462f49eec
Fix sav7 map data rw
...
https://projectpokemon.org/home/forums/topic/54197-issues-with-newest-version-of-pkhex/
2019-08-02 15:11:22 -07:00
Kurt
9ed47cc8fd
Minor tweaks, no functional change
2019-07-21 12:30:21 -07:00
Kurt
894237449b
Allow differentiation between SAV2 blanks
...
Choosing G/S will initialize as GS
Choosing C will initialize as C
calling via their own code (GSC/GS) will choose the most recent (crystal
if possible).
Closes #2359
2019-07-14 15:13:13 -07:00
Kurt
a608e0b252
Minor clean
...
Remove some unnecessary properties from SaveFile
Enumerate checksum flag results for GC memcard checking
Remove unnecessary checks on savefile type
Add some documentation
Decapitalize some method parameters
2019-07-14 15:06:45 -07:00
Kurt
839500a7ee
Fix medicine offset for AO
2019-07-13 17:43:29 -07:00
Kurt
82f305cd36
Fix dex gender set again
...
Closes #2356
update test case to actually set a genderless gender
2019-07-12 23:43:12 -07:00
Kurt
face8d64a9
Fix gen5 dexflag set
...
Add unit tests to check
Closes #2356
2019-07-11 00:13:52 -07:00
Kurt
c64ff5dd76
Fix sav5 behavior
...
Closes #2356 ty @Ammako
2019-07-10 00:19:59 -07:00
Kurt
cf0908a21e
Remove check for impossible conditions
...
#2354
SUBE is never < 0 with the latest change (blank saves behave same as
retail saves).
2019-07-08 10:03:53 -07:00
NotTsunami
e29da1a8e8
Remove check for impossible condition in XY Save ( #2354 )
...
XY can't be ORASDEMO
2019-07-07 22:58:33 -07:00
Kurt
15c44139c3
Fix record read offset
...
Closes #2353
first 100 are u32, second 100 are u16; shift accordingly
2019-07-07 14:54:38 -07:00
Kurt
8f88e630c2
Fix ORAS inventory class type
...
now no longer removes items from pouch
https://projectpokemon.org/home/forums/topic/53761-oras-item-problems-with-new-version/
2019-07-07 08:43:58 -07:00
Kurt
772a2715c0
Fix SecondsTo* read offset
...
copypasted from gen6's, oops
Thanks CreamatedReptile2018!
2019-07-07 08:43:04 -07:00
Kurt
f2ac29ff4e
Relocate some logic
...
slightly reduces savefile.cs footprint
2019-07-05 22:02:29 -07:00
Kurt
9a61f0de0f
Minor relocation of logic
...
and the gradual shift to full-oop continues
2019-07-05 21:39:47 -07:00
Kurt
c0eda5eb61
Add more dex bulk manip options
...
unused, not sure how an abstraction can work for all games (needs some
virtual methods to actually work, since 1-3 don't have langflags)
2019-07-05 18:49:43 -07:00
Kurt
aa94c70df2
Hide gen6 dex logic behind zukan class
...
Same as prior commit for gen5 & gen7
2019-07-05 18:04:36 -07:00
Kurt
adbb3e842a
Hide gen7 dex logic behind zukan class
...
Same as prior commit for gen5
2019-07-05 17:05:42 -07:00
Kurt
79a9269fbe
Hide gen5 dex logic in Zukan class
...
Didn't change any of the bulk modifications, but the data get/set is now
done via the Zukan object rather than raw data manipulation
2019-07-05 16:21:53 -07:00
Kurt
7f186048fb
Really fix dex lang flag offset style
...
c345688f6d
base(x) -> base(x - y) resulted in incorrect offsets for LGPE. Great.
Just make PokeDexLanguageFlags a shift offset instead of absolute;
update all usages.
Closes #2348
2019-07-05 12:16:09 -07:00
Kurt
599ec4ed45
Fix checksum offset fetch
...
#2348
2019-07-05 11:57:40 -07:00
Kurt
810f7271c6
Clear boxes after initialize
...
Closes #2349
2019-07-05 11:53:13 -07:00
pokecal
6b3d6999d1
update MailBoxEditor ( #2344 )
...
fixed FRLG offset, etc.
2019-07-04 21:48:18 -07:00
Kurt
5a8b421672
Add jp crystal eventflag offset
...
was pointing to an FF'd region, was added back via
e86b8c670f
Closes #2347
2019-07-04 15:07:37 -07:00
Kurt
c345688f6d
Fix dex lang bitflag offset write
...
LangFlags is expected to be less than 0x500 or whatever, zero indexed to
the start of the dex block; NOT an absolute position.
I don't feel like making every usage consistent (gen5, gui editors)
which use the absolute position, so just adjust in the zukan
constructors
2019-06-22 16:53:25 -07:00
Kurt
e81e5f31da
Remove shadow info index shift
...
Thanks @PP-theSLAYER !
https://projectpokemon.org/home/forums/topic/53405-bug-oddity-with-shadow-recognition/?do=findComment&comment=246125
2019-06-20 20:39:34 -07:00
Kurt
dc813da2f7
Add DisplayTID/SID getset
2019-06-19 17:49:56 -07:00
Matt
08835d5d97
Fix ORAS held items/personal reference ( #2329 )
2019-06-19 12:18:09 -07:00
Kurt
de77f949da
Prevent assert on non-exportable saves
2019-06-17 20:55:01 -07:00
Kurt
7225b2b87b
Add more sav1/2 option properties
...
Closes #2321
Closes #2322
no gui as SimpleTrainer is kinda getting overloaded; use linqpad or wait
for someone to make a GUI for the specific games
2019-06-09 14:15:42 -07:00
Kurt
455ab32722
Retain override version on clone
...
Also hide the pika friend label when YW features hidden #2283
2019-06-09 13:48:51 -07:00
Kurt
a30a00317f
Add missing trainer location overrides
...
Was missing from #2319
2019-06-08 20:19:39 -07:00
Kurt
1b028198ad
Split gen5-7 saves with inheritance ( #2319 )
...
refer to pull request comments for summary
2019-06-08 19:56:11 -07:00
Kurt
de774ed131
readonly ComboItem
...
create once, never modified after
2019-06-01 19:12:41 -07:00
Kurt
2b8ef9236a
use some explicit dex numbers as enum
2019-06-01 10:22:49 -07:00