-
-
Notifications
You must be signed in to change notification settings - Fork 98
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhancement: Show "Custom" game mode if a map is added to the Maps/Custom/ folder while the client is running #352
Comments
Yeah this would be a good improvement, I actually suggested that too some time before. Could set up a file watcher that would update the custom map list. |
I can give it a shot after work if everyone else is okay with adding this. I think we'd only need it for |
Yeah previously everyone else agreed it would be a nice addition. Non-custom maps are loaded from a pre-made list anyway. |
I'll definitely give it a shot then |
- Add a file watcher that will detect when a map is added or deleted, then update the game mode dropdown according to the new map list - Add and use `CustomMapsDirectory` field to `MapLoader` to avoid hard coded strings. - Add `GetLoadedMapBySha1` to remove some duplicate `GameModeMaps.Find()`. - Add a function `RefreshGameModeDropdown` to modify the dropdown after client is loaded. The function is a bit complicated due to doing inline modifications to the items and keeping the selected mode. Issue: CnCNet#352
- Add a file watcher that will detect when a map is added or deleted, then update the game mode dropdown according to the new map list - Add and use `CustomMapsDirectory` field to `MapLoader` to avoid hard coded strings. - Add `GetLoadedMapBySha1` to remove some duplicate `GameModeMaps.Find()`. - Add a function `RefreshGameModeDropdown` to modify the dropdown after client is loaded. The function is a bit complicated due to doing inline modifications to the items and keeping the selected mode. Issue: CnCNet#352 PR: CnCNet#358
- Add a file watcher that will detect when a map is added or deleted, then update the game mode dropdown according to the new map list - Add and use `CustomMapsDirectory` field to `MapLoader` to avoid hard coded strings. - Add `GetLoadedMapBySha1` to remove some duplicate `GameModeMaps.Find()`. - Add a function `RefreshGameModeDropdown` to modify the dropdown after client is loaded. The function is a bit complicated due to doing inline modifications to the items and keeping the selected mode. Issue: CnCNet#352 PR: CnCNet#358
… then update the game mode dropdown according to the new map list - Add and use `CustomMapsDirectory` field to `MapLoader` to avoid hard coded strings. - Add `GetLoadedMapBySha1` to remove some duplicate `GameModeMaps.Find()`. - Add a function `RefreshGameModeDropdown` to modify the dropdown after client is loaded. The function is a bit complicated due to doing inline modifications to the items and keeping the selected mode. Issue: CnCNet#352 PR: CnCNet#358
… then update the game mode dropdown according to the new map list - Add and use `CustomMapsDirectory` field to `MapLoader` to avoid hard coded strings. - Add `GetLoadedMapBySha1` to remove some duplicate `GameModeMaps.Find()`. - Add a function `RefreshGameModeDropdown` to modify the dropdown after client is loaded. The function is a bit complicated due to doing inline modifications to the items and keeping the selected mode. Issue: CnCNet#352 PR: CnCNet#358
- Address review fedback - Use safe path everywhere - Remove maps if they are renamed and their file extension changes Issue: CnCNet#352 PR: CnCNet#358
- Address review fedback - Use safe path everywhere - Remove maps if they are renamed and their file extension changes Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback - Use safe path everywhere - Remove maps if they are renamed and their file extension changes - Remove unnecessary file watcher filters - sha1 -> SHA-1 Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback to fix comments, make handlers private, and switch one-liners to expressions - Switch MapSharer to download zip to a temp directory to avoid race condition with map file watcher. Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback to fix comments, make handlers private, and switch one-liners to expressions - Switch MapSharer to download zip to a temp directory to avoid race condition with map file watcher. - Add https://mapdb.cncnet.org/search/ to `downloadmap` help message Issue: CnCNet#352 PR: CnCNet#358
… then update the game mode dropdown according to the new map list - Add and use `CustomMapsDirectory` field to `MapLoader` to avoid hard coded strings. - Add `GetLoadedMapBySha1` to remove some duplicate `GameModeMaps.Find()`. - Add a function `RefreshGameModeDropdown` to modify the dropdown after client is loaded. The function is a bit complicated due to doing inline modifications to the items and keeping the selected mode. Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback - Use safe path everywhere - Remove maps if they are renamed and their file extension changes - Remove unnecessary file watcher filters - sha1 -> SHA-1 Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback to fix comments, make handlers private, and switch one-liners to expressions - Switch MapSharer to download zip to a temp directory to avoid race condition with map file watcher. - Add https://mapdb.cncnet.org/search/ to `downloadmap` help message Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback to fix comments, make handlers private, and switch one-liners to expressions - Switch MapSharer to download zip to a temp directory to avoid race condition with map file watcher. - Add https://mapdb.cncnet.org/search/ to `downloadmap` help message Issue: CnCNet#352 PR: CnCNet#358
- Address review feedback to fix comments, make handlers private, and switch one-liners to expressions - Switch MapSharer to download zip to a temp directory to avoid race condition with map file watcher. - Add https://mapdb.cncnet.org/search/ to `downloadmap` help message Issue: CnCNet#352 PR: CnCNet#358
I noticed that the
Custom
gamemode doesn't appear if theMaps/Custom
folder was empty at client start, even if I use/downloadmap
and it downloads successfully or I add a map file to the folder using my OS.Perhaps we should add some kind of file-watcher to the
Maps/Custom
folder to constantly check if we need to update theCustom
maps list and game mode dropdown.Reproduction:
Maps/Custom
Custom
should not be an available game mode./downloadmap HASH
to download a map, or add a.map
file toMaps/Custom/
using your Operating System.Expected:
Custom
is added to the game mode dropdown after a successful map download or adding a.map
file to theMaps/Custom
folder. The newly added map is listed as an option in theCustom
map list.Actual:
Custom
remains hidden even though there are maps in the folder now.The text was updated successfully, but these errors were encountered: