[Solved] Builder action and resource issues

PurpleSkua

Chieftain
Joined
Jul 19, 2017
Messages
11
Alright, two icon-related problems in one here. They seem similar enough that it would be better to do this than make two posts, sorry if I'm wrong on that.

I've got a unique improvement for a modded civ, and the icon for this improvement works fine in all cases except the builder action, in which it's using both the improvement icon and the next door icon for a building squashed in to the space of one icon. I tried putting the improvement icon at the end of the atlas as a workaround, but it just wound up using too small a size and making it all pixelated. Every other icon in the atlas works fine with no issues. Any ideas what's going on?



The other part is the unique resource produced by the improvement - it works fine everywhere except the Reports screen. I have the icon available in 256, 64, 50, 38, and 22 - am I missing one that should be used here?


Above: reports screen showing icon not working.
Below: Civilopedia screen showing it working.
 
I don't know for your other issues, but you need a font icon for the report screen.

Look at FontIcons.xml in the game's file for the code, like

Code:
      <IconTextureAtlases> <!-- FONT ICONS -->
        <Row Name="ICON_GCO_ATLAS_FONT_ICON_BASELINE_4" Baseline="4" IconSize="22" IconsPerRow="11" IconsPerColumn="25" Filename="GCO_FontIcons.dds"/>
        <Row Name="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Baseline="6" IconSize="22" IconsPerRow="11" IconsPerColumn="25" Filename="GCO_FontIcons.dds"/>
        <Row Name="ICON_GCO_ATLAS_FONT_ICON_BASELINE_8" Baseline="8" IconSize="22" IconsPerRow="11" IconsPerColumn="25" Filename="GCO_FontIcons.dds"/>
    </IconTextureAtlases>

    <IconDefinitions> <!-- FONT ICONS -->
        <Row Name="Wounded"             Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="20"/>
        <Row Name="Kill"                 Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="90"/>
        <Row Name="Death"                 Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="92"/>
        <Row Name="Prisoners"             Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="91"/>
        <Row Name="SlaveClass"             Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="89"/>
        <Row Name="lowerClass"             Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="88"/>
        <Row Name="RESOURCE_LEATHER"     Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="67"/>
        <Row Name="RESOURCE_PLANTS"     Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="70"/>
        <Row Name="RESOURCE_WOOD"         Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="71"/>
        <Row Name="RESOURCE_MATERIEL"     Atlas="ICON_GCO_ATLAS_FONT_ICON_BASELINE_6" Index="79"/>
    </IconDefinitions>

and the FontIcons.dds in the assets for the format.

follow the game's naming convention for the ResourceType and the <IconDefinitions> (RESOURCE_[your_resource]) and the UI will pick the correct font icon.
 
For anyone else that stumbles across this with the same issue, apparently it was being caused by having too many sizes of the icon available. I originally had all of the icons for the mod in one big atlas, but splitting it up so that the improvement icon had its own atlas with only the sizes it needed stopped this weird bug. Same applied to leader icons, which were doing the same thing.
 
Top Bottom