X-Git-Url: https://git.artsoft.org/?p=rocksndiamonds.git;a=blobdiff_plain;f=src%2Flibgame%2Fsetup.h;fp=src%2Flibgame%2Fsetup.h;h=367bbbc37c415e06ff8fe24e376e6820737a7b55;hp=8ec6b4d8dc14fd616eea7c3ee8ff06564ded463e;hb=1936db4e59f82c3814e89194eb8a882c69714dc7;hpb=17f6f3b42db10ad8c384ba5ebd1e6a7ecbfbe494 diff --git a/src/libgame/setup.h b/src/libgame/setup.h index 8ec6b4d8..367bbbc3 100644 --- a/src/libgame/setup.h +++ b/src/libgame/setup.h @@ -228,17 +228,19 @@ typedef struct hashtable SetupFileHash; ARTWORKCLASS_UNDEFINED) #define TREE_SORTING_DIR(ti) \ - (((ti)->parent_link ? 0 : \ - (ti)->in_user_dir ? 4 : \ - (ti)->sort_priority >= LEVELCLASS_CLASSICS_START ? 3 : \ - (ti)->sort_priority >= LEVELCLASS_TUTORIAL_START ? 2 : \ - 1) * 2 + \ - ((ti)->level_group ? 0 : 1)) + (((ti)->parent_link ? 0 : \ + (ti)->in_user_dir ? 4 * 200 : \ + (ti)->sort_priority >= LEVELCLASS_CLASSICS_START ? 3 * 200 + \ + (ti)->sort_priority % 100 : \ + (ti)->sort_priority >= LEVELCLASS_TUTORIAL_START ? 2 * 200 + \ + (ti)->sort_priority % 100 : \ + 1 * 200) + \ + ((ti)->level_group ? 0 : 100)) #define TREE_COLOR_DIR(ti, active) \ ((active) ? FC_YELLOW : \ - TREE_SORTING(ti) / 2 == 4 ? FC_GREEN : \ - TREE_SORTING(ti) / 2 == 2 ? FC_BLUE : \ + TREE_SORTING(ti) / 200 == 4 ? FC_GREEN : \ + TREE_SORTING(ti) / 200 == 2 ? FC_BLUE : \ FC_RED) #define TREE_SORTING(ti) \