Commit graph

2152 commits

Author SHA1 Message Date
suloku
1dc5831921 Added Honey Tree Editor for DP and Pt savegames. (#1029) 2017-04-06 17:39:36 -07:00
Kurt
b789478a25 Add friend safari cheat macro
Thanks @suloku !
#330
resx stop being goofy
2017-04-04 18:58:32 -07:00
wwwwwwzx
015bdc606b Misc gen4 legality checking fixes (#1025)
* Fix hgss safari zone encounters

* Add fishing slots at night (hgss)

* Fix Japanese Special Character (gen 4)

* Add gen4 ball with HA legality checking (gen7)

Males can pass the ball with HA females ONLY when they have the same
pokedex number

* Add safari ball with HA checking (gen7)

* Fix ball legality checking for shedninja

Poke Ball only

* Map Unicode Chinese characters to in-game chars

Chinese species names in sun/moon were remapped by GF.

* Add nickname legality check for east asia language

Can not give Chinese or Japanese kanji nickname to pkm.

* Remove hiding nickname textbox for chs/cht

Since remapping and legality checking are implemented, There will be no
strange character or misunderstanding.
2017-04-03 20:02:40 -07:00
Kurt
65fab7542e Cap coins/bp for gen3
Closes #1022
2017-04-02 14:08:11 -07:00
Kurt
3ae6256459 Refactoring
Adds game selection subform for RSEFRLG/Memcard game selection
Backs up entire memory card instead of just gci when loading from
memcard
Reduce string usage (easier dialog translation if that ever happens)

Does the memory card store date last saved? Could be used to autodetect
the last saved game and load directly instead of selecting.
2017-04-02 13:42:42 -07:00
Kurt
a8ce39d310 Fix button anchors for event flag editor
Form can't be widened anyway; maybe in the future.
2017-04-02 11:34:37 -07:00
javierhimura
ab67bf0d60 Split memory card files extension for bin and raw files.
Raw is the extension used by Dolphin and Bin is used by Wii Devolution, both have the exact internal format and size
2017-04-02 17:36:50 +02:00
javierhimura
699dadcccb The UI was checking wrong if a pokemon is shadow or purified
The internal data of GC games for purification for shadow pokemon does not have values from 0-non shadow to 100-total shadow, it have values sarting from the initial shadow hearth gauge to 0-non shadow.
2017-04-02 17:10:40 +02:00
javierhimura
a38e923e83 Load pokemon savegames directly from gamecube memory card files. This files can be saved again in the same memory card file or exported as a gci file with only the savegame.
Do not allow to resize memory cards nor create a new memory card from a gci files
If the MC contains multiple save files the program ask the user what game he want to edit
2017-04-02 16:53:46 +02:00
Kurt
5b204dfff6 Misc simplifications
only species outside of the NohatchFromEgg is manaphy; if it's a
recognized encounter it's okay. Safer to check generally than having to
update explicitly if there's a mew egg (lol)
remove HGSS check for BugContest, simpler to express as cant be
BugContest without HGSS anyway (implied)

pull out strings from trainer7 (localization cantidate), identify common
operations (getBits from ListBox), use |= instead of +=
2017-03-31 01:12:49 -07:00
pokecal
2f149a539d Add Gen7 Mega unlock
This checkbox just unlock the MegaButton in battle.
I have tested wildPokemon battle, not checked about InternetBattle.
2017-03-31 03:21:05 +09:00
Kurt
288aee8c3b performance tweak
only do the flicker hack if the combobox is actually visible
delay form appearing until initial files are loaded
2017-03-29 22:23:18 -07:00
Kurt
f2c072bc8a Fix gen2 slot set
Fixes #1007
Closes #1008 with a slightly different implementation of the validation
check; other fixes for legality incorporated. Thanks @javierhimura !

Note for the Electrode encounter: both PIDIVs should be method 1 (not
J/K) thus only one is kept in the array.
2017-03-29 17:43:17 -07:00
Kurt
7feb5a8451 Add Pickup item record
This only applies to Pickup/honey gather ability procs

179 is incremented if some value is >10000, which is immediately after
photos rated (119)
184 is incremented if GetSelectRankRoyal == 3 (after 159 and 137)

other pairs: 5,137

eh just check Savedata::IncRecord usages
2017-03-29 00:58:19 -07:00
pokecal
f69e4a0c81 Add G7BattleTree Supers Unlock
Not checked for legality(e.g.MaxStreaks)
2017-03-27 11:04:25 +09:00
Kurt
d17c92c2a8 Merge pull request #995 from pokecal/pokecal-patch-2
Add controls of G7Stamp,BallThrow
2017-03-26 14:12:02 -07:00
pokecal
dce4b839b1 Add controls of G7Stamp,BallThrow
Some function has already included in SAV7, but no controls?
Add function about BallThrow Flags.
2017-03-27 04:50:38 +09:00
javierhimura
aecd3f9738 Fix error loading save from gen 2 when pokeball does not have elements 2017-03-26 18:24:02 +02:00
Kurt
7d45b5c4fb Fix levelup egg pre-relearnmove check
Closes #991
2017-03-25 19:57:41 -07:00
Kurt
047d7a0ae5 Add more event recognition
Transferred events 4->5+ now recognized (met location checks for
transfer value)
Re-mapped gen3 AbilityNumber to gen6 style (1/2/4)
Add gen3 egg hatch location suggestion, gen3/4 met level
2017-03-24 22:41:45 -07:00
Evan Dixon
056318d108 Altered the order of operations in language changes
Fixes a bug where language changes would not apply in new implementation of legality string translation
2017-03-24 13:18:14 -05:00
Evan Dixon
a80a2489a4 Refactored implementation of #959 2017-03-24 12:59:45 -05:00
Kurt
e779498aae Cap gen6 boxes unlocked at 30
Closes #975
Doesn't hide the 31st box from the editor, only prevents
adding&selecting 31 from the dropdown for unlocked count.
2017-03-23 18:17:22 -07:00
Kurt
121a821180 Fix clickOT order of operations
Closes #976
subregion was set first, but changing the country caused it to reset the
subregion to 0/existing value.

thus, load country first then subregion (why not move 3DSReg first 👍
)
2017-03-23 18:10:14 -07:00
Tsunamical
0f3b316baa Fix Typo in NetUtil 2017-03-23 01:37:59 -04:00
Kurt
9104dd5f98 Cleanup
Add gen5 hidden ability check for pkm that shouldn't have hidden ability
(wonder if there's any pkm that can be encountered in wild / grotto)

time to extract more strings
2017-03-22 19:43:31 -07:00
Kurt
38bcfe30cc Add setting for unset changes notification
opt in setting
resx too goofy

Closes #970
2017-03-22 18:02:05 -07:00
Kurt
38ee35d3e4 Merge pull request #968 from pokecal/pokecal-patch-1
fix gen4dex forms
2017-03-22 08:48:48 -07:00
pokecal
5b85c4dfdc fix gen4dex forms
mismatch of formFlag and languageFlag also fixed.
full editing of DexUpgrade added.
DP,with SetToSavOption,some mons otherLangDexFlag will be edit.
2017-03-22 17:01:02 +09:00
Kurt
eb8b9602b2 Add pkm modified & unset alert
Same for save edited check on closing, this will alert the user if View
is called without the data being Set first.
2017-03-21 23:25:17 -07:00
Kurt
503a9b9d71 Finish legality string translation feature
Same " = " separator as the main form translation, uses the cache style
in GameStrings to only load once.

Closes #959, feel free to discuss there.
2017-03-21 21:40:33 -07:00
Kurt
68fe715774 Add party data editing for batch editor
functions properly for games without a party (RS BOX) by checking if a
party exists
if there's ever a game that doesn't have a box, it'll work for that too
:P
2017-03-21 19:27:45 -07:00
ReignOfComputer
6f7c8e73a0 Dump Single Box (#962)
* Dump Single Box

Probably can be better optimized or something. The code works, the thing
is I can't seem to edit the Menu Items to add this in as it causes the
view to go haywire. VS can be silly sometimes. For your consideration :)

Related:
https://projectpokemon.org/forums/forums/topic/40358-how-to-export-all-pokemon-in-boxes-as-pk7/

* Manual Design Edit of Main
2017-03-21 00:21:03 -07:00
Kurt
3027eadb8d Refactory legality strings
For future translation feature as per #959
3 helper methods provided to facilitate the localization (import /
export / update)

I decided to simplify some duplicate-function sections
2017-03-21 00:18:44 -07:00
pokecal
e3b501d2ee Upgrade with NationalDexMode (#960)
Just edit dex. Events unchanged.
2017-03-20 20:14:37 -07:00
Kurt
127d2c2aaa static analysis fixes
fixes the friend safari form checks (if else were chained incorrectly)
argumentorder of some unused sections (BV date, canlearnmachinemove)
2017-03-20 00:03:31 -07:00
Kurt
deac1724c7 Add gen4/5 event concatenated binaries
events now show up in the event browser too

pcd(4)/pgf(5) will be used for encounter matching by the legality check.
2017-03-19 16:19:59 -07:00
Kurt
ab88f5b4e2 Fix application path detection
Launching from args sets the Environment.CurrentDirectory to that of the
files that launched the program; instead we want the
Application.StartupPath (where the exe is, which is where our backup
files are).

Closes #948
2017-03-19 10:42:48 -07:00
Kurt
a099d18c9c Alpha 3-5 legality checking
Incorporates files from #190
Skeleton added for future implementations; currently missing gifts,
encounter info, and the fine tuning that follows.
Basically sets up areas for future implementation... feel free to submit
pull requests filling in the EncounterStatic/EncounterTrade blocks with
the basic info. I'll probably focus on gen5->4->3 in terms of priority.

Encounter slots need to be marked up for encounter slot legality (yay
32bit RNG), and will be used for PIDIV detection too.

XD/C is not in this round of implementation. Pretty much every pkm 3-5
will show up as invalid until this round of dev is finished.
2017-03-18 16:50:34 -07:00
Kurt
9106896909 Update 170318
Updates event binaries
Clear AllowGBCartEra if not gen2.

lookin at u 3-5, 4/7 over 50%! /cryptic
2017-03-17 22:27:59 -07:00
Kurt
7d77455b54 Don't set count MaxInputLength regardless of mode
Closes #941
2017-03-17 00:52:48 -07:00
Kurt
5423390863 Misc tweaks
Remove duplicated SAV pkm set method (byte[] instead of PKM, was unused.
All it did was getPKM(decryptPKM(data)).)

Tweak Seen/Caught count expression body to use the HasPokeDex bool, as
GB(A) games did not use the PokeDex int offset. Things were simpler back
then :)

Remove unnecessary toarrays

fix 3->4 items being deleted even if they were valid
be nice and allow held item to transfer 4->5 if it can still be held

invert purification values, heart gauge is [-100,0] not [0,100]
2017-03-16 21:20:16 -07:00
Kurt
9da79379f8 Pokédex refactoring
Add ability to get SeenCount & CaughtCount
switch gen1/2/3 get/set to use int species (since that's all they end up
using), removes the need to create a pk6 template for setting the flag
via the dex editor.
2017-03-14 22:41:15 -07:00
Kurt
b98954e20b Add stamp value fetching, fashion info
lowest 4 bits are used for something else; stamps are bits 4-18
exposes wardrobe (fashion item list) as a tuple (IsOwned, IsNew)
reduce nesting in tr7, add comment on fashion bitflag setup, inb4
someone sets it the array to 01 and crossdresses ;)
2017-03-14 00:45:14 -07:00
Kurt
e5c516e828 Properly hide joyful tab
Now populates for emerald saves
2017-03-13 09:10:50 -07:00
Kaphotics
a3e62f6344 Merge pull request #938 from pokecal/pokecal-patch-4
tip for stats,value about Refresh,small fix.
2017-03-13 09:01:20 -07:00
ReignOfComputer
b7a5a861bc Fix Dump Boxes Naming (#937)
Off-by-one error.
2017-03-13 09:00:41 -07:00
pokecal
e5f10fe65e new value about pokeRefresh 2017-03-13 17:22:27 +09:00
pokecal
1e4c4b8f53 add tooltip for stats
tip for stats name(show long name), stats value(seconds, show how long it means)
2017-03-13 17:21:08 +09:00
pokecal
5cf36df360 Fix inBox
include 0
2017-03-13 17:20:48 +09:00
Kurt
cc5b065a39 Force validation when exporting data
Apply same logic to PKM exporting; the existing setup was manually
triggering validation by changing focus; now just call the
ValidateChildren method on the form.

Closes #936
Thanks @Storm-Eagle20 !
2017-03-12 17:01:48 -07:00
Kurt
fe66a65464 Misc updates
Closes #860 by adding in prompt for Gen1 saves to determine if the save
originated from VC. Will disable Gen2 legality sources when checking pk1
files.

--

Fixes froslass/gallade evolution tree pruning movesets. For whatever
reason, the level argument of the Evolution is not 0 when using the
item; I manually edited the evos_sm.pkl binary to set the 2 evolutions
from [XX] -> 00.

Fixes gen1 ingame trades slipping through the getEncounter12 preference.
Gen2 has set TIDs, so check if TID is set.

Loosens checks for Gen7 trades (including prior transfers) as trading
between games clears the memory.

Add 3 more g7 trainer stat records too.

Thanks Holla!

--

Add getMoves(100) optimization as gen7 learnsets can grab 1->100, better
than looping over the range every time it's checked.
2017-03-12 16:36:23 -07:00
Kurt
ff2dc1356b Add more g7 trainer stats
A little bit of clarification provided for some
Thanks tastymeatball!
2017-03-11 10:40:55 -08:00
Kurt
bcbebf73ff Refactor qr server fetch & add notification 2017-03-10 20:35:18 -08:00
Kurt
08a7f818f2 Add 8 more g7 trainer stat records
Thanks tastymeatball & Holla!
2017-03-10 17:50:57 -08:00
Kurt
0715f133d2 Add misc info editor for gen3
Closes #193
If there's more offsets found, this would be the place to edit oddball
stats.

Also threw in BP/Coin (& Rival Name FRLG only) editing.
2017-03-09 19:38:57 -08:00
ReignOfComputer
ad8f661863 Add PanelScroll Value Check (#931)
Prevents ArgumentOutOfRangeException.
2017-03-08 23:32:52 -08:00
ReignOfComputer
13aa01ff99 Check for Null Event Constant Difference before Clipboard Export (#930)
Prevents ArgumentNullException.
2017-03-08 23:31:22 -08:00
Kurt
e9ea53ef8c Move wallpaper red check to BoxWallpaper
Add gen3-5 wallpaper checks
Rearrange and simplify general sprite layering logic to reduce some
comparisons
2017-03-08 21:50:34 -08:00
pokecal
6da4b3d41c Fix, stop using alt-ShinyIcon outside the box (#929)
with no filter for slot value, the alt-icon will be used for PKM-QR icon, team, and others.
2017-03-08 14:59:07 -08:00
pokecal
57c9b78108 replace RareIcon when wallpaper is red (#928)
* use alt-redstar when wall is red

* add rare_icon_alt

* add rare_icon_alt

* Add files via upload
2017-03-08 08:46:25 -08:00
Kurt
0a1a30eb5a Update 170308
Tweak batch editor behavior to show Any first (used by any pk* type),
sort alphabetically too. Highlights the propertytype text if the
property is not present for the type.
2017-03-08 00:16:34 -08:00
Kurt
baac850409 Gen4 dex fixes
Fix form1 offset for getter
move formNames into check (only fetch if forms exist for the dex
entries)
Add all forms to seen side when seen is toggled (behaves like gender)
2017-03-07 23:52:47 -08:00
Kurt
ea47d958ca Misc tweaks
Fix exceptions / insufficient behavior in pokedex4
change gen2 tutor name to be consistent with other gen variable names
replace gen2 trade checkresult with nothing as all properties are
already checked.
2017-03-07 23:41:05 -08:00
Kurt
4874c174d8 Add gen4 pokedex editor
Fixes the setDex implementation for gen4
why u have to be so weird gen4
hgss has 0x1C extra form flags in the first form array... unused?
2017-03-06 22:43:46 -08:00
Kurt
c1ab0699d3 Fix forme set
Don't think this matters but use the correct method.
2017-03-05 20:57:05 -08:00
Kurt
199257fabd Re-add selectionlength
only use it when repopulating move legality
skip repopulation when clicking moves or met location since it's updated
at the end of the respective method
2017-03-05 20:00:27 -08:00
Kurt
5ecf01e481 Add gen5 pokedex editor
Cloned and modified from XY's editor

might as well simplify the dex setting for gen5. / -> >>, % -> &
2017-03-05 17:34:30 -08:00
Kurt
8550253842 Add gen3 pokedex editor
Uses SimplePokedex form since the pokedex is currently simple
2017-03-05 16:40:57 -08:00
Kurt
664eb05b65 Update 170305
Update changelog
Throw in 2 more trainer stats, thanks tastymeatball!
2017-03-05 12:41:25 -08:00
Kurt
27e2888345 Add more g7 stats
30 in this batch :O
thanks tastymeatball!
2017-03-05 11:41:12 -08:00
Kurt
19600263bd Fix 'complete dex' macro seen bit setting
Only set if the gender allows for it
Could possibly check the enabled state instead but this is more obvious

Closes #772
2017-03-04 17:32:07 -08:00
Kurt
a76b549a49 Switch MessageBox usage to util
Use the WinFormsUtil implementation of alert/prompt
2017-03-04 17:21:33 -08:00
Kurt
529f8d1348 Misc profiling improvements
ResetBoxes reduce method calls for new blank/setting, just set data.
160ms->4ms

ComboBox Validation calling SelectedText.Length=0 no longer needed 3y
after it was originally added.
268ms->0ms

speeds up main thread by a third of a second (wowww), but the
selectedtext removal makes the program snappier during regular use
(loading/modifying)
2017-03-04 09:38:39 -08:00
Kurt
33359b1526 Add more g7 stats
Thanks tastymeatball!
2017-03-03 21:18:18 -08:00
Kurt
5c7ef42b54 Update reflection property fetching
Closes #919

Properties fetched would return PKM.cs properties (not declared in XK3
or PK3), such as Hidden Power Type.

The setter for Hidden Power type is unused everywhere, but was called
via reflection on transfer away from xk3/ck3 format. This caused IVs to
be tampered with in most cases.

By only fetching Declared properties (ie, within XK3.cs only), only the
'real' shared properties will be transferred. Extending this to the
batch editor, we can use this Declared-only filtering to grab more pkm
formats. While things are being updated, throw in pk1/pk2/bk4/ck3/xk3
formats to the dropdown.
2017-03-02 21:00:41 -08:00
pokecal
77dd8d1829 add Vivillon FormValue
This code will not change the value, even if the value is illegal.
2017-03-03 04:22:18 +09:00
pokecal
6ede0b3bce add Vivillon Form
I first tried to put the control in same position as Gen6, but there is no space.
2017-03-03 03:52:11 +09:00
Evan Dixon
0eda87fdf6 Averted potential null reference exception 2017-03-02 09:40:33 -06:00
Evan Dixon
beed20cfdf Reloading settings doesn't work right 2017-03-02 09:37:54 -06:00
Evan Dixon
0946b00075 Delete settings if corrupt 2017-03-02 09:28:33 -06:00
Evan Dixon
91459f66a7 Made clickonce less intrusive to normal builds 2017-03-01 14:50:38 -06:00
Kurt
9df18d2bd1 Tweak gen3 sav load to force version prompt
Hold Control when opening the save file
Closes #887
2017-02-28 23:23:58 -08:00
pokecal
405a1ee897 Add files via upload 2017-02-28 15:38:18 +09:00
Kurt
3bb8973d0f Add legality check indication to report window
Closes #899
2017-02-27 18:25:22 -08:00
Kurt
7ab80944fb More g7 stat records
Thanks tastymeatball!
2017-02-27 18:14:20 -08:00
Kurt
b87f1fc8db Remove showdown import button clicks
Button not visible -> onClick method not called; just call the method
directly.

(import a set on the Met tab via the tools dropdown, with shiny. won't
import a shiny pkm).
2017-02-27 08:59:20 -08:00
Kurt
58a89377af Add more g7 stat records
Thanks tastymeatball!
2017-02-26 18:33:56 -08:00
Kaphotics
5874a8bfa6 Merge pull request #892 from ReignOfComputer/gen-7-item-checks
Gen 7 Item Legality Checks
2017-02-26 09:35:37 -08:00
ReignOfComputer
4072f0d2ca Shortcut Max Level
IMO this is useful, for your consideration :)
2017-02-27 00:08:28 +08:00
ReignOfComputer
b3ceb93ece Gen 7 Item Legality Checks
For https://github.com/kwsch/PKHeX/issues/891.
2017-02-26 23:55:22 +08:00
Kurt
bff6a62bbd Fix german pumpkaboo forme errors
Exception thrown due to medium form ("M") getting set to gender, then
screwing with the updateForm method (returning -1 for current form if
the gendersymbols are unicode). Fix both sources of error.
2017-02-25 15:52:57 -08:00
Kurt
6ddcdee9cf Fix dragging battle team slot sprite refresh
Refresh the image if the team slot indication needs updating
(true->false, false->true), else stay lazy and just set the image.

Could just refresh the image regardless but muh negligible speed
2017-02-24 20:26:28 -08:00
Kurt
82de3e5d12 Set max entry to count textbox
Converting to string be lazy instead of computing log10 for digits :)
#884
2017-02-24 18:45:53 -08:00
Kurt
a8ba8aeeae Refactor met location fetching for box report
Array length is checked before accessing
2017-02-23 16:39:03 -08:00
LegoFigure11
3ab2d303f8 Update Main.cs 2017-02-22 19:15:30 +11:00
LegoFigure11
33f1dd3221 Add .gci in the supported file type dropdown 2017-02-22 17:23:20 +11:00
Michael Scire
d1039e20f3 WC7 description support for cards with >1 item 2017-02-20 21:46:25 -08:00
Kurt
f860bd31c7 Add minimum size check for opening files
0bytes -> exception, just use pk2 stored (min size)
2017-02-15 08:29:47 -08:00
Kurt
0f45adda89 Handle skipped gens
Expand InhabitedGeneration to actually check if it can inhabit
generation instead of if species can exist on generation
misc behavior tweaks
2017-02-15 00:11:12 -08:00
Kurt
dcb30e61a8 Add Festival Plaza name changing
Closes #854
2017-02-14 19:09:10 -08:00
Kurt
2e9f8e19ea Menu sprite distortion fix
Closes #858 by adding in updated Steelix sprite, uses ripped files
re-saved in paint.net
Thanks @sora10pls !
2017-02-14 18:54:46 -08:00
Kurt
f9cc9c10ca Tweak suggestion behavior
Prefer lowest level wild encounter; expand suggestion for evolved pkm.
Add click event to Current Level (for gen1+ pkm since Met Location not
visible).
Add Nickname CheckIdentifier to change incorrect identifiers in Nickname
check.
2017-02-14 17:33:57 -08:00
Kurt
a5e09bfe31 Fix legal move selection allowing future moves
Initially populated with a filtered list, was unfiltered when
repopulated for legal moves. Just split legal/illegal, have the main
form choose which one is the stored list.

Remove unnecessary linq for other forms
2017-02-13 21:20:10 -08:00
Kurt
6722afef76 Misc behavior updates
Closes #855
2017-02-13 20:42:39 -08:00
Pol Eyschen
19b53e10e9 Tabs -> Spaces & Typo 2017-02-13 19:55:02 +01:00
SPoF
cf9bf85bb4 Add Framework check for non-windows OS
GetFrameworkVersion() throws an System.NullReferenceException since
there is no Registry on non-windows systems.

Fixed by checking the OS under which the program runs. If it's not
Windows, check the CLR Version instead of querying the (non-existant)
registry.
2017-02-13 13:06:54 +01:00
Kurt
578f05cd2e Initial Gen1 legality checks (WIP)
Have only tested pk1 format so far; there's still a few cases that are
unhandled (move discrepancies between games, trade gifts, event mew,
tmhm).

pls no report bugs unless you are very detailed (include WHY it is
wrong).
2017-02-12 17:00:03 -08:00
Kurt
22e49928c5 Tweak nickname language update behavior
Closes #849
2017-02-12 09:59:49 -08:00
Kurt
cbccc6a28b Add rby encounters
Includes fishing slots
todo on trades/static encounters; feel free to pull request (look at
tables6/7 for ref).
2017-02-12 09:52:31 -08:00
Kurt
d248cdd280 Simplify batch editing
changes IV3 to faster variant used elsewhere,
sort properties alphabetically,
simplify 'any' intersection,
un-duplicate database filtering
un-duplicate box/folder per-pkm processing

-25 lines, a little bit of reorganization since the form has grown since
its initial inception
2017-02-10 23:54:36 -08:00
Kurt
1233a29661 Hide multiplayer icon (or/as) for X/Y saves. 2017-02-09 22:55:04 -08:00
Kurt
3dc5e9d579 Add legality suggestion commands to batch editor
Closes #842
Adds in ability for custom properties
Suggestables are called via $suggest
Only properties supported are Met_Location, Moves, and RelearnMoves
2017-02-09 22:45:58 -08:00
Kurt
fa145ec510 Add nickname clearing for batch editor
.IsNicknamed=False
results in the species name being applied.
Closes #839
2017-02-09 20:52:24 -08:00
Kurt
2f76d83add Add VC extension to openfiledialog filter
So crowded, put all files at the top for default behavior
2017-02-09 20:19:38 -08:00
Kurt
3b0485414d Move xorpad decryption out of winforms
simplify logic a little, fix a few issues
nobody uses powersaves & xorpads anymore tho
2017-02-09 00:44:38 -08:00
Evan Dixon
bd4b400626 Cleanup
Whoops.
2017-02-07 23:13:33 -06:00
Evan Dixon
6504d5305a Fixed settings not saving when form closes
Should resolve #833.

This is why I prefer if statement logic to return statements littered everywhere.
2017-02-07 23:12:18 -06:00
Kurt
2f5b5790db Add xy trainer nickname
Closes #283
2017-02-07 16:25:13 -08:00
Kurt
2ecf1c1c7b Improve file loaded transfer preference
use last char of file extension if available. edge case for pk[m]
considered:
pk[m] => 0x6D, -0x30 = 61d, &7 = 5, which prefers 6 instead of 7+ :)

adds a check for transferred pkm not having their CurrentHandler being
flagged as the save file (impossible for a transferred PKM to be still
handled by the OT).
2017-02-06 22:19:10 -08:00
Kurt
2b606dfc32 Cleanup
fixes qr7 import
2017-02-06 21:36:00 -08:00
Kurt
fbc56ace6d Add more g7 stat records
Thanks skywalker25 & Holla!
2017-02-05 21:50:06 -08:00
Kurt
065795cdbe Add database IdentifierContains filter 2017-02-05 14:38:39 -08:00
Kurt
ac818424f2 Delay pkm file loading via cmd args to end
Closes #828
2017-02-05 13:24:39 -08:00
Kurt
77c25c41d3 Add legality indication for exported QRs
only appears if the legality was checked (ie checking supported)
2017-02-05 12:55:17 -08:00
Kurt
f64d31c557 Faster G7TID generation
#823

generate a random T7SID instead of brute forcing a pair
2017-02-05 10:57:42 -08:00
Kaphotics
77a68c23b9 Merge pull request #823 from ReignOfComputer/f/g7tid-generator
G7TID Generator
2017-02-05 10:35:32 -08:00
ReignOfComputer
2d0b216b33 G7TID Generator
Thought it'd be good to add a way to generate a TID/SID based on desired
G7TID. Using code from my repo at
https://github.com/ReignOfComputer/Reverse-G7TID-Calculator, thanks to
@PP-theSLAYER and @SciresM. For your consideration to add :)
2017-02-06 00:08:49 +08:00
ReignOfComputer
c7e570b92d Add Check for Bad Ability Length 2
Forgot to save, again.
2017-02-05 23:23:17 +08:00
ReignOfComputer
2de7da80b0 Add Check for Bad Ability Length
Prevents System.ArgumentOutOfRangeException: StartIndex cannot be less
than zero.
2017-02-05 23:23:02 +08:00
Kurt
7e23d13a78 Simplify egg sprite fetch
Call ChangeOpacity directly instead of layering with partial
transparency.
2017-02-04 23:42:55 -08:00
Kurt
f25adad211 Misc tweaks
allow qr for gens 1-3, change draginfo cursor type to object.
need to figure out how I can get it out of main
2017-02-04 23:11:48 -08:00
Kurt
5d3e167496 Box slot legality r3
Closes #814 thanks @JortonMV !
Closes #818 thanks @egzonqj !
(both were instrumental in regards to this commit, much appreciated)

Refactors to move the slot image generation per the save file to an
extension method, instead of having 4 methods (2 in main, getQuickFiller
& getSlotFiller, and 2 in box viewer, same names).

Uses the legality marker unscaled in the bottom left corner of the
sprite.
Fielded a few ideas in IRC (a commented-out line that tinted the sprite
red remains in the src), but the folks in IRC preferred the indicator.

When toggling the legality indicator, the box viewer has to be updated
as well as the main box slots.
2017-02-04 20:39:42 -08:00
Kurt
25f6b5259b Refactoring
Add documentation for PKM/PKX, move some code around
2017-02-04 18:27:28 -08:00
Kaphotics
23c4f1e700 Merge pull request #802 from Tsunamical/class-fixes
Class consistency fixes
2017-02-04 14:59:24 -08:00
Kurt
c930b7eb7e Relocate box load/dump/verify to extensions
now with shiny new documentation
2017-02-04 14:58:30 -08:00
Kurt
9e24a3a26c Fix gen1/2 coin set & gen2 TM capping
now writes coin count correctly (uint != ushort) and TMs are capped at
99; HMs shouldn't be allowed beyond 1 but oh well.
2017-02-04 12:13:54 -08:00
Tsunamical
66e669a42b Change NetUtil to a static class
NetUtil simply can be static, which brings it inline with the other
NetUtil.
2017-02-04 11:18:48 -05:00
Kurt
53eb8f9f57 Manually defining nickname from another lang
Don't automatically flag as Nicknamed if the pasted text
2017-02-03 21:48:43 -08:00
Kaphotics
b9efca759f Merge pull request #811 from ReignOfComputer/f/gen7-stat-clarity
Add Clarity to Gen 7 Stats
2017-02-02 22:00:49 -08:00
Evan Dixon
da4df453de Added "Any CPU" build configurations
Prefer 32-bit is enabled, so there will be no functional difference from before, except that any of the assemblies can be referenced by a 64-bit process.
2017-02-02 23:41:58 -06:00
ReignOfComputer
98b785fdf7 Add Clarity to Gen 7 Stats
Reference:
https://projectpokemon.org/forums/forums/topic/40020-why-are-there-two-pokemon-caught-in-trainer-stats/#comment-209810
2017-02-03 12:38:21 +08:00
Kurt
c0e5db6bb0 Add party-only form legality checks
Closes #806
2017-02-02 19:27:48 -08:00
ReignOfComputer
614b15f1b7 Catch MissingMethodException and Direct Users to .NET Framework 4.6 Install (#797)
* Catch MissingMethodException and Direct Users to .NET Framework 4.6 Install

* Revised .NET Framework Warning Message

* Check .NET Framework Version on Launch

* Check .NET Framework Version on Launch

* No Locale for Microsoft Download Center
2017-02-02 19:14:48 -08:00
Kurt
115a8da8f2 Add C-Gear skin incomplete alert
Closes #790
2017-01-31 20:12:51 -08:00
Kurt
40456702a9 Misc tweaks
Fixes marking set #798
sleep deprivation ftw
2017-01-31 19:35:18 -08:00
ReignOfComputer
b7a29c1017 Refresh Visiblity of Legality (#795)
This clears any legality markings when loading Pokemon from generations
not covered by checks. Should fix issue
https://github.com/kwsch/PKHeX/issues/794.
2017-01-31 18:48:33 -08:00
ReignOfComputer
2467fd95ad Fix Fishing Stat Record (#784)
Should be 007 not 006.
2017-01-31 04:13:29 -08:00
Kurt
2fb56a99bf Bump .NET to 4.6
Farewell XP support. :godmode:
2017-01-30 20:45:34 -08:00
Evan Dixon
ebb53457cf Removed whitespace 2017-01-30 22:30:53 -06:00
Evan Dixon
18f08b93a3 Made FileNotFoundException check more specific 2017-01-30 22:27:08 -06:00
Kurt
26925ad528 Add default/illegal fashion payloads
User selects which payload they want to apply
closes #780
2017-01-30 18:32:18 -08:00
Kurt
1454433483 Misc legality updates
Add ゲーフリ to valid 151 OTs
Revise logic for split-forme egg moves (Closes #777)
Save config on closing instead of option change
Remove geolocation setting for 6->7 and associated legality check, move
geolocation validity check higher (Closes #776)
2017-01-30 17:49:28 -08:00
Kurt
9c788d1c8a Fix coins OverflowException
cap to 9999 before casting
Closes #775
Thanks @ThunderRemix
2017-01-29 21:41:42 -08:00
Kurt
9506b3bbe1 Fix cloning overflow
use the count of slots in a box, not 30 hardcoded
Thanks Wanderer1391!
2017-01-29 17:50:06 -08:00
Kurt
3da9bcd0df update SM dex iterator
#772
sneak in misc changes to PKM.cs, to snazzify HPType calc and to allow
markings to be converted from g7 format to g6
2017-01-29 16:55:35 -08:00
Kurt
6a63137ca6 Fix forme display
Closes #771
2017-01-29 10:45:02 -08:00
Philipp Joram
0ac5d57224 Fix tabs for bag pouches not showing on Linux/Mono
Passing a height of 0 lets the TabControl dissapear, making it
impossible to switch tabs between different pouches.

To fix this, use the same approach as for the width and pass the height
of the first icon.
2017-01-29 14:18:35 +01:00
Kurt
30ec9011c8 Misc updates
Remove safari hidden ability check for gen7 origin pkm
load template data on any save load, causes the legality triangle to
appear on supported games
2017-01-29 00:02:32 -08:00
Kurt
5cc8d1de5c Fix clickLegality calling
existing logic put mnuLLegality back into mnuL, causing the getSlot call
to return -1 (not from a box/party slot, ie read from tabs).

new logic should have the intended behavior
2017-01-28 15:20:11 -08:00
Kurt
340b57ee60 More UI improvements
Hold Control when right clicking a Box/Party/etc slot to get the
Legality menu item to appear.

Improve the SD card locked check when saving for multiple exception
types.
2017-01-28 13:07:44 -08:00
Kurt
5ae027c934 Misc user protections
trycatch SD card readonly check
Remove All medals now clears gen7 flags (for improper transfers)
2017-01-28 10:50:36 -08:00
Kurt
ab5a0a7a3a Fix PID auto-update past gen
Closes #766
2017-01-28 10:36:57 -08:00
ReignOfComputer
fa9fba464b Fix Missing PK1->PK7 Geolocations (#764) & dll missing
* Check for Missing Code Library with Error Message

If PKHeX.Core (or other external dependency) is missing, display an
error message at launch.

Closes #763

* Fix Missing PK1->PK7 Geolocation
2017-01-28 09:48:00 -08:00
Kurt
b86321c142 Expand pk6/pk7 checks
As per comments on 75d460e
2017-01-27 23:33:36 -08:00
Kurt
1922a2145f Add BP wondercard type
Closes #758
2017-01-27 09:09:31 -08:00
Kurt
e5d9381c58 Add basic VC legality checks
I may use VC and VC1 a little too interchangeably; things would have to
be updated if GSC were ever released anyway. Usage of VC is for generic
stuff while VC1 allows VC2 to slip by.

no shiny mew 🌵
memories + geolocation, gee thanks bank.

Would need to be updated with gen1 legality checking to add moves/finer
encounter details, but this will do for now. Please don't report things
marked 'legal' that have invalid moves/levels.
2017-01-26 21:35:26 -08:00
Kurt
08adb4c2cb Disable super training flags on format!=6
Closes #752
2017-01-26 08:45:23 -08:00
Kurt
37b3e58979 Add batch editor smart ability instruction
$0 or $1 or $2 for ability 1/2/4 (just think of it with 012345...).
Will set the hidden ability for every mon (AbilityNumber=4 and
Ability=PInfo.Abils[2])

#749 as promised
2017-01-25 23:03:57 -08:00
Kurt
f282711e35 Cleanup
Use S/M met locations for Pokémon GO origin
Changing to VC1 or GO now autofills met location
Un-alphabetize RGBY games and move to end of games list (+go)
Mark unused region names (Kanto string appears twice in text bank 3,
30013 is used)
Move hypertraining stat toggling to pkm object

shift 1->7 logic to repeat less operations
add more 1->7 logic pertaining to memories
add RefreshAbility method (0 based input, not 1/2/4)
2017-01-25 22:51:52 -08:00
Kurt
f1c2a74aed Add write protection alert on save load
#750
2017-01-25 20:11:53 -08:00
Kurt
0d5694dc8e Manually redefine app settings file
http://stackoverflow.com/questions/6436157/configuration-system-failed-to-initialize

delete C:\Users\{username}\AppData\Local\ProjectPokémon\ if still having
issues
Closes #747
2017-01-25 19:39:35 -08:00
Kurt
b370c26542 Fix g6 multiplayersprite clearing
Closes #743, thanks @PrometheusG !
2017-01-25 08:51:05 -08:00
Kurt
0a19b8b59b Split gen1/2 shininess
an attempt was made
2017-01-24 21:28:29 -08:00
Kurt
eebf3fbac3 Add gen1 shininess editing
Since it's the same as gen2's checks, and gen1->7 is now possible...
2017-01-24 21:01:32 -08:00
Kurt
608c570352 Add more trainer stats
Thanks Holla!
2017-01-24 19:50:35 -08:00
Michael Scire
5a23fda752 Add support for VC/Horohoro game ID markings 2017-01-24 07:12:14 -08:00
Kurt
bcb5f5f2bb Minor cleanup
extrabytes setting moved to another method, fixes all resharper problems
2017-01-22 23:05:54 -08:00
Kurt
eaa233bdd8 gen4 wondercard updates continued
Don't set Slot to 3 for an empty slot
Move slot check comparison to PCD class
Allow PCD->PGT 'swap' override to just set the slot
Update alert message to indicate source type first

#730
2017-01-20 19:35:56 -08:00
Kurt
4f99ef6c09 Set Slot id to 3 if no pcd found
Closes #730
Adds ability to set a PCD to a PGT slot (grabs the PGT from card)
2017-01-20 08:43:44 -08:00
Kurt
088f9a9aa7 Gen7 update
Never added wc7 extensions; drag&drop use MysteryGift extension instead
of hardcoded .wc6
2017-01-19 23:48:31 -08:00
Kurt
ed52aa31e1 Fix set import shortly after starting program
CB_Form is not yet initialized with items, do a little sanity checking
before setting index to 0.
Closes #729
2017-01-18 23:18:14 -08:00
Kurt
e13b473979 Enable poke finder camera version changing
Closes #727
2017-01-18 20:01:58 -08:00
Kurt
469e0940c2 Add gen7 hall of fame editor 2017-01-16 22:40:28 -08:00
Kurt
97227fdfe9 More simplification
Extrabytes index selection done in setPKMFormatMode

if (visible) is bad, why do I forget? If the control is not shown (ie
another tab) but possible to be visible it'll return false. Use enabled
instead.
2017-01-14 16:59:57 -08:00
Kurt
3f218968c5 Refactoring & fixes
Fix blank sav creation for gens 1-3 (data vs Data references, version
overrides)
Fix main form init with gen2 first (check for altform usage like all
other gens)
Use GameVersion specific blank fetch instead of generation ID
2017-01-14 16:43:16 -08:00
Kurt
12c46d18a8 Disable custom exception handling for debug mode
VS wouldn't break at the line that threw the exception; only have the
custom exception handling for release builds (ie the CI server & posted
builds).

makes it easy to debug again
2017-01-14 16:41:27 -08:00
Kurt
e321c48871 Refactoring
Add blank save creation to Core SaveUtil methods.
Simplify main form resource usage (remove redundant qualifiers)
2017-01-14 13:10:36 -08:00
Kurt
c075ff3c47 Enhance clone detection for gen1/2
Would only return unique species as PID is not used, use IV values as
unique identification.
2017-01-14 12:10:42 -08:00
Kurt
e83ed49eea Add gender-skin mismatch confirmation
Closes #718
2017-01-12 18:29:44 -08:00
Kurt
f4797e06a0 More refactoring
More extension methods for other types of images
2017-01-11 22:28:35 -08:00
Kurt
db5e084ef9 Further refactoring
Move System.Drawing usage out of Core to WinForms, as System.Drawing is
not in .NET Core/Standard. Simple methods to return resource name
strings have been added instead.
2017-01-11 17:55:42 -08:00
Kurt
1d1179465a Add typo null check
Updating legality with an invalid move name causes SelectedValue to
equal null. Use the util function that has null check for combobox &
selectedvalue.
2017-01-10 20:59:31 -08:00
Kurt
c1e613280b Hide save buttons if no save has been loaded
buttons enabled by default => only show button panel if the save is
valid AND at least one enabled.
2017-01-10 20:01:33 -08:00
Kurt
c9e721fc5b Update settings load
bad settings files cause exceptions, silently delete them
move language init out of loadconfig (want it to happen regardless of
config errors, so load config value instead)
2017-01-09 19:15:46 -08:00
Kurt
1fcdffc654 Add pkm value indication
Grab an example PKM (from main window) to get the current value to
assist users in creating their modification scripts.

Added 3 tooltips for hovering over property/type/value controls
2017-01-08 21:06:15 -08:00
Kurt
51352c3c13 Remove more find-replace errors
yay for unsaved changes
2017-01-08 17:14:39 -08:00
Kurt
1e3a46d760 Find replace is bad 2017-01-08 15:27:00 -08:00
Evan Dixon
87dffcfe57 Updated build paths
to be more consistent with PKHeX.Core
2017-01-08 08:35:23 -06:00
Evan Dixon
1acfdf8f92 Removed "Any CPU" build configuration
Since the solution level one didn't build the dependencies and the project level one built as x86 anyway
2017-01-08 08:28:28 -06:00
Kurt
7da6f1ab1d Cleanup 2017-01-08 00:14:34 -08:00
Kurt
595c7eb4c5 Split winforms to separate project
resources still are associated with winforms, eh
program still runs fine and I've replicated the mono build options. lmk
if this breaks stuff
2017-01-07 23:54:09 -08:00