Mechanized Assault & eXploration Reloaded



#1 Oct 11, 2016 3:50 am
mdooligan mdooligan Offline
Approved Member
Registered since: Dec 07, 2008
Posts: 36


Subject: Control the order of maps in map selection window
As it is, the order of the maps in the map selection window is "disk order", whichever random way your OS/filesystem drivers store and retrieve the maps on the physical device.

I'm not particularly happy with this situation. I want my favorite maps on the first page, and all the rest after that.

After some look at src/ui/graphical/menu/windows/windowmapselection/windowmapselection.cpp, I came up with a plan: I made a list of known maps, and put it in a list, new file src/ui/graphical/menu/windows/windowmapselection/maplist.h.

Then I write routine in the cpp::void cWindowMapSelection::loadMaps() that caselessly compares the filenames and sorts them according to my list. So, if you want to change the order, you just tweak maplist.h and re-compile.

I works beautifully. If you'd like to see my dirty hack, just let me know.
Miven Dooligan
Peace and cheer
↑  ↓

Pages (1): 1


All times are GMT +01:00. Current time: 6:55 pm.