exch-bms2 / beatoraja

Cross-platform rhythm game based on Java and libGDX.
GNU General Public License v3.0
627 stars 146 forks source link

Improved difficulty table management (to download new tables without downloading all tables) #726

Closed wcko87 closed 1 year ago

wcko87 commented 1 year ago

Issue

In the current version of beatoraja, if you want to add a new difficulty table, you need to download all table data again from the beatoraja config. This can be quite slow, especially if you have existing large tables like 発狂難易度データベース(仮), which will be downloaded again each time you press "load difficulty table".

Pressing F2 in music select can be used to refresh a table, but it can't be used to load a new table.

This pull request adds functionality to load only new tables, or load only the selected tables from the config.

New table management interface

https://user-images.githubusercontent.com/27341392/209510202-103ddec7-776d-4ebd-86e0-56dfcbef62f4.mp4

Main changes:

  1. Change ListView to TableView so that table load status can be displayed.
    • rename EditableListView.java to EditableTableView.java
    • bmsroot in ResourceConfigurationView.java now uses normal ListView instead of EditableListView (because EditableListView no longer exists, and bmsroot does not use EditableListView functions anyway).
  2. Add multi-selection capability to the table view.
    • because multi-selection is possible, moveSelectedItemDown() and moveSelectedItemUp() have been updated to support moving multiple items at the same time.
    • moveSelectedItemTop() and moveSelectedItemBottom() have not been updated as these methods are not used.
  3. "Load difficulty table" button removed from bottom of config. It is moved to the resource tab and renamed to "Reload all tables".
  4. "Load new tables": Download only tables that have not been downloaded yet.
  5. "Load selected tables": Download only the selected tables (multi-selection possible).
  6. "Check table status": Used to update the status and name of local tables in the table view.
  7. Table name is displayed in table view if the table is loaded. If the table is not loaded, it will display "not loaded".

Remarks

My Japanese translations for the new buttons may not be very good or natural:

Please tell me if there are any comments or issues with the new interface.