xna-cncnet-client icon indicating copy to clipboard operation
xna-cncnet-client copied to clipboard

Enhancement: Show "Custom" game mode if a map is added to the Maps/Custom/ folder while the client is running

Open alexlambson opened this issue 3 years ago • 4 comments

I noticed that the Custom gamemode doesn't appear if the Maps/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 the Custom maps list and game mode dropdown.

Reproduction:

  • Move or delete all files from Maps/Custom
  • Start the client
  • Start a multiplayer lobby. Custom should not be an available game mode.
  • Use /downloadmap HASH to download a map, or add a .map file to Maps/Custom/ using your Operating System.
  • Open the game mode drop down again.

Expected: Custom is added to the game mode dropdown after a successful map download or adding a .map file to the Maps/Custom folder. The newly added map is listed as an option in the Custom map list.

Actual: Custom remains hidden even though there are maps in the folder now.

alexlambson avatar Jul 27 '22 18:07 alexlambson

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.

Metadorius avatar Jul 27 '22 18:07 Metadorius

I can give it a shot after work if everyone else is okay with adding this. I think we'd only need it for Custom

alexlambson avatar Jul 27 '22 18:07 alexlambson

Yeah previously everyone else agreed it would be a nice addition. Non-custom maps are loaded from a pre-made list anyway.

Metadorius avatar Jul 27 '22 18:07 Metadorius

I'll definitely give it a shot then

alexlambson avatar Jul 28 '22 04:07 alexlambson