Commit graph

31 commits

Author SHA1 Message Date
Kurt
b280ffcfef style updates
should be pretty much it
2018-09-14 22:37:47 -07:00
Kurt
cb5e1239ae Refactoring
Extract game value limits
Rearrange GameVersion util logic extensions
add better gameversion fetch for generator (equivalent to pkmeditor)
2018-06-15 16:00:28 -07:00
Kurt
c3314f1b8e Remove Mirage Island met location from valid gen3
Although Pokémon Ruby, Sapphire, and Emerald include a location pointer
for "Mirage Island", any Wynaut caught here will simply display "Met on
Route 130" in their summary. This is because the player is technically
still on Route 130's map.

Can't get anything with that location ID as an egg or as wild
2018-06-12 16:41:44 -07:00
Kurt
79f0b3665f Differentiate C/XD cologne IDs
https://projectpokemon.org/home/forums/topic/45685-pokémon-xd-and-scent-bag/
Thanks Asia81!
2018-06-09 12:44:30 -07:00
Kurt
9b43677bb9 Refactoring
pull out some move data fetching to separate class
add methods to quickly fetch if the move is learnable via that method

eventual plan is this:
replace
'fetch all possible moves then look within' move validation
with:
'peek if learnable, and get info how' move validation

advantages:
- returns game the move was learned in and the level (if appropriate)
- infinitely less object creation (garbage collection)
- only looks for a given move, doesn't have to fetch everything before
checking
- faster than full fetch, can be made even faster by optimizing lookups.

subject to change :)
2018-06-08 20:10:41 -07:00
Kurt
5a3c8f4147 Remove trailing whitespace 2018-05-12 08:41:29 -07:00
Kurt
a1f2f8708a Refactoring
pass identifier on cloning pkm
remove unnecessary ref for passing Data (not modifying array reference)
const some magic numbers
2017-12-27 16:36:24 -08:00
Kurt
f9946368a0 Remove usage of LegalityAnalysis from PK*
CK3<->XK3 transfers to PK3 first now (no direct transfer legally)
2017-12-06 21:28:34 -08:00
Kurt
b8a5657d5a misc tweaks
pull out transfer locations to const references
add vc2 & crown beast/celebi met location suggesting
add vc2 crystal sensitive detection
add 2 more usum trainer stats (thanks holla!)
2017-11-22 21:45:30 -08:00
Kurt
a03ac10fc5 Misc refactoring
no functional change
2017-10-22 23:26:37 -07:00
Kurt
593f31ff02 hashset contains over array contains
faster++, reduces some linq ToArray() allocations
2017-09-30 14:08:35 -07:00
Kurt
68aa9aeec9 Relocate encounter data loading to separate files
shifts encounter data from Legal's split tables to individual files for
easier maintenance and initialization. Legal Core's init is so much
simpler now.

fix resource name typo
2017-07-25 00:28:43 -07:00
Kamron Batman
3168a2ae40 Fixes shiny check and adds negai boshi. Adds force-shiny 5th anniv. 2017-07-16 16:07:28 -07:00
Kurt
2a2f5669e4 Add wc3->pk3 conversion
fixes 10ANIV pikachu having Thunderbolt twice
un-duplicates CHANNEL event data
adds seed->PIDIV generator template for M1/2/4, CXD, Channel, and BACD

improve pkm converter to update nickname of hatched eggs. isn't perfect
(farfetch'd) but works better than before
2017-07-15 18:36:55 -07:00
Kamron Batman
51ae267cc8 Adds aura mew. Rearranges wondercard events to the right block. Fixes mews. Adds Negaiboshi. 2017-07-13 21:42:55 -07:00
Kamron Batman
152d8e102f Fixes WC3 eggs. 2017-07-07 08:27:16 -07:00
Kurt
a653363a16 Simplify wc3 checking
all branches did similar checks, so I pulled them out

Added TID bypass for PCNY incremental TID pkm
#1313
2017-07-06 20:22:54 -07:00
Kamron Batman
0a2245b55c Fixes various gen 3 event templates. (#1309)
* Fixes various gen 3 event templates.

* Adds more checks to PokePark 2005 eggs for DS Download Play.

* Fixes various gen 3 event checks. Still missing japanese events, but will add those another time.

* Adds 10 ANIV Celebi.

* Fixes PCJP 2003 eggs. Still doesn't use the exact formula though, but BACD-R is something to start with.
2017-07-06 09:45:41 -07:00
Kurt
420a07ba54 Fix off-by-one colo/xd met locations
add empty line as first line
shift ingame trade (254) down one to compensate for the offset
closes #1303

fix larvitar encounter speciesnum
2017-07-05 08:34:25 -07:00
Kurt
fd1c7419b1 Set fateful for xd pkm transferred away
Only way to know if it originated in XD is to check the matched
encounter data

Closes #1290
2017-07-04 13:24:18 -07:00
javierhimura
7f788e4167 Added Froslass to FutureEvolutionsGen3, a gen 3 Froslass will now return true when executing function InhabitedGeneration for generation 3 2017-07-04 20:37:55 +02:00
Kurt
b760509fcb Misc gen3 event updates
Add special ribbon detection (for wc3),
speed up seeds from IVs calc (flip top bit of seed to get the result for
other iteration)
Add a bunch of gen3 event data
2017-07-01 16:50:45 -07:00
Kurt
1c4a1af633 Misc updates
Detect channel, only detect Channel PIDIV for RS origin (only really
care about method1/2/4 being used when it shouldn't)
Channel does this weird thing called not setting the met level.

Refactor set suggested met location to a method that can suppress
popups.
2017-06-29 19:32:29 -07:00
Kurt
2546ddfd8e Misc gen3 related updates
detect gen3 event eggs better
2017-06-28 22:09:26 -07:00
Kurt
e635755dfd Add SID bypass for cxd random SID gifts
For XD Trade Gifts, the SID matches player's SID (not 0).
2017-06-26 20:29:22 -07:00
Kurt
7f318433ed Update gen3 fateful checks
met location FE doesn't propagate to future games, only obedience flag
2017-06-16 21:45:03 -07:00
Kurt
0cb17ccb42 Add c/xd ingame trades
as wc3 as it's the closest structure without creating a new
encountertrade subtype
2017-06-14 21:57:23 -07:00
Kurt
81534c4645 Update gen3 fateful encounter checks
Closes #1230
Colosseum pokemon do not get fateful encounter, all pkm from XD (except
the starters) are fateful.
Add requirement for National ribbon if shadow CK3 is transferred to XK3
and vice versa; actually check for national ribbon during CK3/XK3
(RibbonSet1 interface)
2017-06-14 21:07:42 -07:00
Kurt
5823425f42 Add PIDIV checking for encounters
Fixes HGSS egg moves, and improves encounter detail detection.
example: togepi from FRLG transferred up, old detection couldn't
differentiate the gift egg from a regular egg; however, PIDIVs can lend
a hand -- eggs don't have a PIDIV!

fixed shiny BACD spread detection (in regards to antishiny rerolls).
Shiny WISHMKR now detected correctly.
2017-06-03 00:12:05 -07:00
Kurt
82750de1b8 Add initial gen3 event detection
egg events supported, only some gen3 event distros supported
will eventually flag for PIDIV type mismatching

@kamronbatman
2017-05-29 00:48:25 -07:00
Evan Dixon
52c4fbbe97 Converted PKHeX.Core to .Net Standard
Refactored and rearranged things as needed to allow the change
2017-05-11 23:34:18 -05:00
Renamed from PKHeX/Legality/Tables3.cs (Browse further)