X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Finit.c;h=1c71531876003765be3eeb0d8d96608b40426c4d;hb=cd6f61d38f82d71a0bc9bb7425e097b18f09203b;hp=44b0a5cbb10da6c37d001c37d0818bad679d1abe;hpb=7bcc6aa833d64b21f78793dd00ed4c1356b98d05;p=rocksndiamonds.git diff --git a/src/init.c b/src/init.c index 44b0a5cb..1c715318 100644 --- a/src/init.c +++ b/src/init.c @@ -333,6 +333,8 @@ static int getFontBitmapID(int font_nr) special = game_status; else if (game_status == GAME_MODE_PSEUDO_TYPENAME) special = GFX_SPECIAL_ARG_MAIN; + else if (game_status == GAME_MODE_PSEUDO_TYPENAMES) + special = GFX_SPECIAL_ARG_NAMES; if (special != -1) return font_info[font_nr].special_bitmap_id[special]; @@ -1695,6 +1697,7 @@ static void InitGraphicInfo(void) IMG_BACKGROUND_TITLE_INITIAL, IMG_BACKGROUND_TITLE, IMG_BACKGROUND_MAIN, + IMG_BACKGROUND_NAMES, IMG_BACKGROUND_LEVELS, IMG_BACKGROUND_LEVELNR, IMG_BACKGROUND_SCORES, @@ -4909,6 +4912,8 @@ static void InitGlobal(void) global.anim_status = global.anim_status_next = GAME_MODE_LOADING; global.use_envelope_request = FALSE; + + global.user_names = NULL; } static void Execute_Command(char *command) @@ -5181,6 +5186,9 @@ static void Execute_Command(char *command) static void InitSetup(void) { + LoadUserNames(); // global user names + LoadUserSetup(); // global user number + LoadSetup(); // global setup info LoadSetup_AutoSetup(); // global auto setup info @@ -5901,7 +5909,7 @@ static void InitOverrideArtwork(void) static char *getNewArtworkIdentifier(int type) { - static char *leveldir_current_identifier[3] = { NULL, NULL, NULL }; + static char *last_leveldir_identifier[3] = { NULL, NULL, NULL }; static boolean last_override_level_artwork[3] = { FALSE, FALSE, FALSE }; static boolean last_has_level_artwork_set[3] = { FALSE, FALSE, FALSE }; static boolean initialized[3] = { FALSE, FALSE, FALSE }; @@ -5936,16 +5944,15 @@ static char *getNewArtworkIdentifier(int type) else artwork_current_identifier = setup_artwork_set; - /* 2nd step: check if it is really needed to reload artwork set ------------------------------------------------------------ */ // ---------- reload if level set and also artwork set has changed ---------- - if (leveldir_current_identifier[type] != leveldir_identifier && + if (last_leveldir_identifier[type] != leveldir_identifier && (last_has_level_artwork_set[type] || has_level_artwork_set)) artwork_new_identifier = artwork_current_identifier; - leveldir_current_identifier[type] = leveldir_identifier; + last_leveldir_identifier[type] = leveldir_identifier; last_has_level_artwork_set[type] = has_level_artwork_set; // ---------- reload if "override artwork" setting has changed -------------- @@ -5959,7 +5966,7 @@ static char *getNewArtworkIdentifier(int type) artwork_current_identifier)) artwork_new_identifier = artwork_current_identifier; - *(ARTWORK_CURRENT_IDENTIFIER_PTR(artwork, type))= artwork_current_identifier; + *(ARTWORK_CURRENT_IDENTIFIER_PTR(artwork, type)) = artwork_current_identifier; // ---------- do not reload directly after starting ------------------------- if (!initialized[type])