]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/menu/xonotic/dialog_multiplayer_create_mapinfo.c
Make Centerprint Panel title coherent with other panel dialogs
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / xonotic / dialog_multiplayer_create_mapinfo.c
index 31ea3e084bbe8f67623e7bd3f2c3bf1fa4922267..e5dec8fff5478e8948d14539f259cfec3026cd35 100644 (file)
@@ -43,10 +43,10 @@ void XonoticMapInfoDialog_loadMapInfo(entity me, float i, entity mlb)
                strunzone(me.currentMapFeaturesText);
        }
        me.currentMapBSPName = strzone(MapInfo_Map_bspname);
-       me.currentMapTitle = strzone(MapInfo_Map_title);
-       me.currentMapAuthor = strzone(MapInfo_Map_author);
+       me.currentMapTitle = strzone(strdecolorize(MapInfo_Map_title));
+       me.currentMapAuthor = strzone(strdecolorize(MapInfo_Map_author));
        me.currentMapDescription = strzone(MapInfo_Map_description);
-       me.currentMapFeaturesText = strzone((MapInfo_Map_supportedFeatures & MAPINFO_FEATURE_WEAPONS) ? _("Full item placement") : _("MinstaGib only"));
+       me.currentMapFeaturesText = strzone((MapInfo_Map_supportedFeatures & MAPINFO_FEATURE_WEAPONS) ? _("Full item placement") : _("InstaGib only"));
        me.currentMapPreviewImage = strzone(strcat("/maps/", MapInfo_Map_bspname));
 
        me.frame.setText(me.frame, me.currentMapBSPName);
@@ -54,7 +54,10 @@ void XonoticMapInfoDialog_loadMapInfo(entity me, float i, entity mlb)
        me.authorLabel.setText(me.authorLabel, me.currentMapAuthor);
        me.descriptionLabel.setText(me.descriptionLabel, me.currentMapDescription);
        me.featuresLabel.setText(me.featuresLabel, me.currentMapFeaturesText);
-       me.previewImage.src = me.currentMapPreviewImage;
+       if(draw_PictureSize(me.currentMapPreviewImage) == '0 0 0')
+               me.previewImage.src = "nopreview_map";
+       else
+               me.previewImage.src = me.currentMapPreviewImage;
 
        for(i = 0; i < GameType_GetCount(); ++i)
        {