- Reduce the amount of GroundItem objects created by mutating objects
instead of creating merged copies
- Reduce the amount of stream transformations required by using
LinkedHashMap and sorting the ground items before collection
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
Color hidden ground items gray when in item highlight mode to show
different between non-hidden and hidden items.
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
- Reduce amout of iterations per frame by pre-collecting the ground
items on game tick
- Collect ground items in ground item plugins and pre-compute some
easy-to-get values
- Replace the looping over all tiles with looping over collected ground
items
- Change GroundItemOverlay logic to support single list of items instead
of multi-dimensional array
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
When native window decorations are enabled (e.g when custom window
chrome is disabled), to reduce code complexity, but to maintain current
usability (e.g prevent adding new UI elements in order to position the
icons somewhere) move the title toolbar icons to sidebar.
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
Due to flaw in logic, the save event in mouseReleased was never
triggered when overlay position was reset. It is not possible anymore to
go through the logic again/not worth and so save the overlay data
immediately.
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
To remove the need for restarting plugins or reloading configurations
when plugins are loaded and then their confifguration changes, load
session configuration in advance.
Closes: #1121
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
SwingUtil adds a click event to focus the frame, but the frame isn't
fully built when the icon is created. Click after the icon was made and
before the frame was built caused a crash. Moved icon creation to after
the frame is built, should resolve the problem.