Adding new Font Icons - anybody managed it?

whoward69

DLL Minion
Joined
May 30, 2011
Messages
8,699
Location
Near Portsmouth, UK
In Civ5 you added new Font Icons (the things that look like [ICON_MY_NEW_RESOURCE]) via a dds file, a ggxml file and then adding to the IconFontTextures and IconFontMapping database tables.

Well, the two database tables no longer exist in Civ:BE, so there is either a new way, or we've taken a huge step backwards and can no longer add Font Icons.

There is a new table, FontIcons, that contains a single field that references a new format file, and that file looks like it contains the info from the old database tables and the ggxml file, but I can't make it work.

The dds file (and a ggxml file just-in-case) along with the new format xml file are loaded into the VFS, and SQLiteSpy is telling me the reference to the new format xml file is in the database, but still nadda ... [ICON_HAPPY_FACE] appears in game as [ICON_HAPPY_FACE] and not as :)

So anybody out there cracked adding new font icons yet?
 
I take it then that nobody is trying to add new resources ...
 
I don't really have any experience on this front, but have you looked into XML\Terrain\CivBEResources.xml ?

It has entries like this, which among other things define IconStrings like [ICON_TITANIUM]:

Code:
<Row>
	<Type>RESOURCE_TITANIUM</Type>
	<TechReveal>TECH_ENGINEERING</TechReveal>
	<Description>TXT_KEY_RESOURCE_TITANIUM</Description>
	<Civilopedia>TXT_KEY_RESOURCE_TITANIUM_TEXT</Civilopedia>
	<Help>TXT_KEY_RESOURCE_TITANIUM_HELP</Help>
	<ResourceClassType>RESOURCECLASS_STRATEGIC</ResourceClassType>
	<Hills>true</Hills>
	<Flatlands>true</Flatlands>
	<NoRiverSide>true</NoRiverSide>
	<ArtDefineTag>ART_DEF_RESOURCE_TITANIUM</ArtDefineTag>
	<AltArtDefineTag>ART_DEF_RESOURCE_TITANIUM_MARSH</AltArtDefineTag>
	<ArtDefineTagHeavy>ART_DEF_RESOURCE_TITANIUM_HEAVY</ArtDefineTagHeavy>
	<AltArtDefineTagHeavy>ART_DEF_RESOURCE_TITANIUM_HEAVY_MARSH</AltArtDefineTagHeavy>
	<IconString>[ICON_TITANIUM]</IconString>
	<IconAtlas>RESOURCE_ATLAS</IconAtlas>
	<PortraitIndex>6</PortraitIndex>
</Row>
 
New resources are in my plans, but I haven't got to that point yet, nice to see I'll be running into issues when I do get there ;)
 
Do we know where these DDS files are normally placed?

Also, random, but any tips on an X to DDS converter? There are plenty of DDS to X converters, but very little in the way of the reverse (I found something called x2y, but it outputs DDS files at 0 bytes / empty despite converting to other filetypes correctly).
 
Ok so after cracking my head over this issue since last night, finally found this thread, thanks to whoward69 for discovering the issue. This really sucks.

In any case, one way of overcoming this is to use the LooseFilesOverridePAK method I guess. I detailed it in my reply to whoward69's reference post here. Since the original fonticon.dds and fonticon.xml has quite a few leftover spots, I suppose we can actually use it for any additional font icons we need. I'm going to test out this method over the weekend.

On a related note, I don't particularly like the LooseFilesOverridePAK method as it requires the user to do some "techy" editing, and lots of mod users unfortunately aren't that tech savvy. Has anyone developed an installer before to edit the .ini and copy over the files? I haven't explored installers before, but I think the copying files part should be easy, but I'm stumbling at the .ini editing part. Perhaps a Powershell or VBscript?
 
Top Bottom