Commit graph

18 commits

Author SHA1 Message Date
Kurt
e8d5252b8c Reject moves introduced by gsc in pk1/vc1 cases
Closes #2005
(no tutor moves are new moves, just beam moves)
2018-06-14 18:52:43 -07:00
Kurt
5579c4c80d Tidy up MoveLevelUp
use the Learn objects from prior commits for adding a range of moves
2018-06-13 22:03:58 -07:00
Kurt
39daa6c65d Split GetIsLevelUp to individual versions
static the GameVersion reference as we're excessively using it in the
switch cases, for clearer reading
2018-06-12 22:15:06 -07:00
Kurt
b9652a835d Weaken gen2 egg species checks for pre-evos in gen1
VC can inhabit both gens

Add Tradeback setting setter for legality tests
Add GBCartEra setting setter for legality tests

Thanks @iiippppk !
2018-06-12 18:46:31 -07:00
Kurt
64a64b8ce1 Add special handling for gen1 encounter move fetch
Begin splitting of GetMovesLevelUp per-gen into per-version
2018-06-12 18:35:56 -07:00
Kurt
ca9f21fa49 Fix base move count vs inherit check
Closes #1990
Thanks @iiippppk !
2018-06-10 20:26:59 -07:00
Kurt
c9181963f2 handle pichu array->interface when adding egg list
egg fetch returns array, need to add to the collection
force everything as readonly to prevent adds outside of the constructor

Closes #1988
Thanks @iiippppk !
2018-06-10 19:07:55 -07:00
Kurt
e105f2b589 Refactoring
fix b2w2 egg base levelup reference (not bw, b2w2!), doesn't really
matter much except for better indication (possibly?)
remove some unnecessary linq ToArray() calls
continue relocating code out of Core
2018-06-10 17:55:03 -07:00
Kurt
d94fc65367 Refactoring
continued reduction in Core size, simplify/clean up usages
2018-06-10 14:45:25 -07:00
Kurt
3f1195a2d4 Refactoring
Remove duplication of levelup fetch
relocate some stuff to a more appropriate area
2018-06-10 10:44:05 -07:00
Kurt
021ac7c54f Refactoring
where!contains -> except
relocate special tutor
2018-06-09 16:04:06 -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
a89c0c3312 Rename egg game->version
add more gameversions (soon)
2018-03-30 21:37:01 -07:00
Kurt
999427f484 Update gen2 egg generator
Level = Level is equivalent to Level = 0

update EggInfoSource to use Level instead of LevelMin (LevelMin returns
Level, just be clear on usage)
update VerifyCurrentMoves so that only gen1/2 do the gen1/2 move update
methods. Recently extended all encounters to have a generation property;
we only care about gen1/2 here.

https://projectpokemon.org/home/forums/topic/43655-pokemon-crystal-egg-mark-as-not-legit/
2018-01-30 20:36:22 -08:00
Kurt
a75614ed77 Modify eggmove fetch
fetch is exclusively done with version already known; there are cases
where version can change for eggs so it's safer this way.

version change reference (gen6+):

212a489335
2017-10-19 21:20:47 -07:00
Kurt
387d9375c3 Refactor split gender breeding logic
Inherit Levelup moves & hidden ability (gen5) issues addressed
2017-09-14 18:52:34 -07:00
Kurt
6fe926d1f6 Refactoring
readability++
2017-09-04 13:48:10 -07:00
Kurt
d1aa02fb31 Refactoring
split up current move parsing a little
2017-09-01 23:15:57 -07:00