Commit Graph

52 Commits

Author SHA1 Message Date
berichan
7fe8bcb53e bulk-remove bushes, closes #311 2021-04-12 19:29:17 +01:00
Charlie U
8fd348448a
Add checkbox to enable/disable moving field editor on mouse drag (#467) 2021-03-22 15:27:29 -07:00
Kurt
0798aa5a97 Add batch editor
Similar to PKHeX's batch editor, probably with some stubbed functionality.

Example to change Oak Trees to apple trees:
=ItemId=60000
.ItemId=60001
;
=ExtensionItemId=60000
.ExtensionItemId=60001

Example to unbury all items:
=IsBuried=True
.IsBuried=False
.IsDropped=True
2021-03-21 11:51:57 -07:00
Kurt
75c176c028 Fix: Replace All items using a copy of the tile
The field array will get mutated, so make sure that our item reference isn't one of the field tiles.
2021-02-28 18:41:25 -08:00
Kurt
5b46d3ddaf Update FieldItemEditor.cs 2021-02-15 19:52:13 -08:00
Kurt
d47158587c Add tile replacement to Field Item Editor
hold ctrl+alt(+shift for full map) to replace all items on the map that you tap, with the item from the editor.

don't mix & match field items (trees) with regular items, cuz we can't verify size matching for those. Field Items return "unknown size".
2021-02-05 09:15:52 -08:00
Kurt
f427ca647e Update FieldItemEditor.cs 2021-01-23 23:52:24 -08:00
Kurt
2670a6c751 Add placed design dump/load
https://github.com/kwsch/NHSE/issues/443#issuecomment-765915667
2021-01-23 10:58:58 -08:00
Kurt
83169b8738 Bump language version to c#9 2020-12-24 23:53:40 -08:00
Kurt
de3ee7ba41 Rotate terrain tile on ctlr-shift click
Closes #290
2020-06-01 20:47:04 -07:00
Kurt
2b3225fd4b Update FieldItemEditor.cs
Closes #282
2020-05-31 17:27:13 -07:00
Kurt
c571fbb20a Add remove trees option
Closes #273
2020-05-31 15:24:59 -07:00
Kurt
25262478ae Add sensitive scaling for field item map
if ppl have something other than 100% scale somehow
Closes #248
2020-05-25 09:39:22 -07:00
Kurt
0d64fa65d8 Fix building snap misaligning view
field item coordinates need to be even, not odd
do the same "even" clamp

(we do this so that we can sync the terrain tile view to the field item view)
2020-05-25 08:36:07 -07:00
Kurt
0e70d823a5 Synchronize acre-view comboboxes
Closes #236
2020-05-20 18:10:21 -07:00
Kurt
a1cc4de611 Add bulk spawner for field items
Closes #235
2020-05-20 13:22:50 -07:00
Kurt
4e1b5ab87f Snap to building location on index change
Closes #231
2020-05-17 09:14:59 -07:00
Kurt
6b678ac704 Add snap to grid for field items, upgrade handle extensions: delete tile
Setting a field item with the snap active will align it to the major gridlines. This will prevent the user from setting un-interactable objects (rocks, trees) unintentionally.

Having the auto-handle extension tiles will now delete all associated tiles when issuing a delete command on an extension tile, rather than just deleting the extension tile.
2020-05-16 12:03:21 -07:00
Kurt
a4b4a3c24a Add water flower button
control: all water states
shift: all map (instead of current viewport)

Closes #230
2020-05-16 11:30:25 -07:00
Kurt
3061442f77 Add localized color name display
Closes #223
2020-05-15 13:08:47 -07:00
Kurt
b0870c865a Add design tile clear button for terrain editor
not visualized, but still exposed for mass clear

Closes #208
2020-05-13 12:43:04 -07:00
Kurt
797cd0e16d Update FieldItemEditor.cs 2020-05-12 15:23:25 -07:00
Kurt
6fe7e4e53a Add road tile detail copy
Copies only the road portion of the terrain tile, not the ground detail.
Closes #203
2020-05-12 15:22:39 -07:00
Kurt
5a22c0e58a Add missing terrain event handlers 2020-05-12 10:34:56 -07:00
Kurt
4792d675eb Don't update map hover coordinates on mouse-button down
right click drag on map should do nothing, and now does nothing
2020-05-11 23:18:07 -07:00
Kurt
60faecdc69 Refactoring
move files, abstract some logic for later reuse
2020-05-11 22:14:27 -07:00
Kurt
6ae1c9724b add click-drag on acre picturebox to move the viewport
hold control to drag the viewport faster

does not move items; that would probably have to be a toggle -- if ever implemented
2020-05-10 14:13:45 -07:00
Kurt
dd92b9ea73 Update FieldItemEditor.cs 2020-05-09 22:11:40 -07:00
Kurt
8beb1c426c Add view option to read root instead of a clicked extension
enabled by default

viewing an extension will calculate where the root node is (based on the extension values) and load it instead, only if the item ID matches. bounds check to be 100% safe from ppl placing random/bad extension tiles
2020-05-09 22:09:36 -07:00
Kurt
000da2cbb6 Misc tweaks
Fix bottom acre row labeling for MapAcre stuff
Don't close png dropdown on checkbox click
Don't change map reticle position on map right click (only left click)
2020-05-09 20:11:22 -07:00
Kurt
826ba00fcd Allow toggling png export
why not; I guess if you don't want the items/reticle and want dat clean "here's my terraforming work"
2020-05-09 17:32:15 -07:00
Kurt
d1b7032b79 Save background and foreground (full map picture)
yay pretty
2020-05-09 17:25:42 -07:00
Kurt
a12278d148 Add outside/field template tracker editing 2020-05-09 17:13:31 -07:00
Kurt
74bf1d4cef Merge acre editor into field item editor 2020-05-09 17:03:58 -07:00
Kurt
8661f7c0cc Use Item Editor instead of property grid
Closes #151
2020-05-08 13:27:29 -07:00
Kurt
a9810c7d03 Merge Field Item back into Item
Different means of expression for the 8 byte item structure's FreeParam

Will be expanding the ItemEditor so that it has a checkmark to toggle Extension Item editing behavior.

Removes IHeldItem as there's no need to abstract it.
2020-05-08 12:20:24 -07:00
Kurt
203a7c1627 Add more removal options
- remove flowers
- remove shells
- remove branches

Closes #163

rename plazaX/Y to match internal field name
2020-05-05 17:17:59 -07:00
Kurt
a3357c27c5 Clamp acre jump to valid bounds 2020-05-03 20:50:45 -07:00
Kurt
4a49caf6da Add layer2->layer1 check (isSupported), add logic for isActive
isActive: indicates if the tile is animated (eg: bonfire has fire or is extinguished)
isSupported: layer2 tile checks beneath it (layer1) to see if there's something to hold it up on that layer (sanity check)

Dunno how to handle the isActive set-on-save. I saw there was an isActive flag in my plaza, assumedly left there from a radio or something. NHSE does not change flag state at this time.
2020-05-03 16:29:28 -07:00
Kurt
3ec69afe6b Show terrain tile type, add slider for transparency adjust 2020-05-02 23:57:43 -07:00
Kurt
adf9b43bc0 Add transparency slider for buildings 2020-05-02 23:25:14 -07:00
Kurt
928e699168 misc performance improvements
Preallocate the terrain-building objects and reuse

changed:
- grid alternates with a slightly-darker to help indicate the larger 2x2 tile grid.
- put plaza & buildings behind the gridlines
2020-05-02 23:02:37 -07:00
Kurt
5b5d1b2bce Save terrain and buildings on close too 2020-05-02 20:10:11 -07:00
Kurt
4690cfe167 Refactoring: Field Item Editor + buildings/terrain
Extracts logic from the building & terrain & field item editors for reuse / separation of concerns

Have FieldItemEditor select between Items & Terrain so that you can change the popup menu mode (view set delete)

Not sure how I want to show the terrain names...
2020-05-02 20:05:09 -07:00
Kurt
1dbf1e9338 Put all "remove {X}" into dropdown button list
Clamp hover coordinates to sane values
2020-05-02 15:52:44 -07:00
Kurt
ef065f889b Add checkbox to toggle auto-extension behavior, clamp map bounds 2020-05-02 14:41:32 -07:00
Kurt
c25cd262d4 Add automatic delete/set of extension tiles from root
Setting a root tile: will fill in the extension tiles
Deleting a root tile: will delete all extension tiles (it assumes extension tiles are valid)

Add checkbox to prevent overwriting tiles that aren't none (eg if you set a 4x4 and it'd overlap with a 2x2, the program would play a sound indicating that the requested operation was disallowed).

Closes #136 -- multi-select with the current drawing setup isn't really feasible. Bulk set/delete addresses the underlying request.
2020-05-02 00:20:44 -07:00
Kurt
d930b02489 Show buildings/plaza on field item editor
Building sizes not to scale, but should assist in representing layout for now

Extract terrain color to separate class
2020-05-01 16:46:38 -07:00
Kurt
33b9e7f170 Show terrain map behind field item view
Adds a transparency slider to have the field items fade so you can see the underlying terrain tile.

Not really optimized (allocates every time), but it should be fine for now.

Make the None item transparent, so that the entire map bleeds through (clear clarity).
2020-04-28 21:08:57 -07:00
Kurt
c9a86cbff9 Add program translation
jp/en/zh -- only english has been translated (duh)
keep in mind this translates the text in the program, not the internal flag names.

not sure if other languages need to be supported; from PKHeX's experience, only spanish is updated (besides jp/zh), as most users speak english or are fine using the program in english.

pls localize villager names and item names for non-english :P -- preferrably automated from raw game dumps
2020-04-21 14:26:18 -07:00