[GS] Dreamlands: Resource: Zebras (ALMOST solved by Hemmelfort, not me) Thanks a lot!

Alqamar Alaswad

Chieftain
Joined
Mar 5, 2019
Messages
78
Location
Madrid
After all these days and all the help I have had from you (including, but not only, @LeeS , @isau, @Hemmelfort , and many others) I have been able to write all the files I think I need to add a new resource (Zebras) to the game.

However, for the love of heavens I am unable to find what is wrong... the code seems to work perfectly, the mod is loading, there are no errors... but the civilopedia page is still showing "LOC_RESOURCE_DRE_RES_ZEBRAS_NAME" instead of the name and the text for the Civilopedia itself is nowhere to be found. Additionally, the icon for the resource is not showing anywhere and it seems like the resource itself is not being added to the map.

I am using Amatheria's resource atlases as a placeholder, but I have created an atlas with a single icon which I think the game is reading, but not using.

Could you please take a look at my files? I have attached the XML files and the logs.

This is a screenshot of the mod folder file structure:
upload_2019-4-27_8-15-56.png
 

Attachments

[1564664.749] [Localization] ERROR: NOT NULL constraint failed: LocalizedText.Language
[1564664.749] [Localization]: While executing - 'insert into LocalizedText('Tag', 'Text', 'Gender') values (?, ?, ?);'
[1564664.749] [Localization]: In XMLSerializer while inserting row into table insert into LocalizedText('Tag', 'Text', 'Gender') with values (LOC_DRE_RES_RESOURCE_ZEBRAS_NAME, Zebras, Masculine:no_article, ).
[1564664.749] [Localization]: In XMLSerializer while updating table LocalizedText from file DRE_RES_Resources_Text.xml.
[1564664.749] [Localization] ERROR: NOT NULL constraint failed: LocalizedText.Language
 
Thanks, Infixo.

So, it looks like the problem is in DRE_RES_Resources_Text.xml?

(Update)

I found some typing mistakes. I keep working on it.
 
Last edited:
I'm completely baffled. It should work, but it isn't. Could you please take a look at the entire mod? It is quite small, because it only contains (so far...) a single new resource.

My mod files:

Thanks a lot for your time and help. :)
 

Attachments

Catastrophe! I have edited manually the UISomething.blp file in my mod folder and now the game will crash before even beginning...

I edited it because I found five references to files that didn't exist...
 
Code:
INSERT INTO IconTextureAtlases   
       (Name,                                       IconSize,   IconsPerRow,   IconsPerColumn,       Filename)
VALUES  ('ICON_ATLAS_DREAMLANDS_RESOURCES',               256,       8,               8,                   'Dreamlands_Resource_Atlas_256.dds'),
       ('ICON_ATLAS_DREAMLANDS_RESOURCES',               64,           8,               8,                   'Dreamlands_Resource_Atlas_64.dds'),
       ('ICON_ATLAS_DREAMLANDS_RESOURCES',               50,           8,               8,                   'Dreamlands_Resource_Atlas_50.dds'),
       ('ICON_ATLAS_DREAMLANDS_RESOURCES',               38,           8,               8,                   'Dreamlands_Resource_Atlas_38.dds');
You have only 256 version, others are missing.

Later in the file you are using ICON_RESOURCE_DREAMLANDS_RESOURCES_ZEBRAS_FOW which is not defined.
 
Let me check... I will leave a note here, Hemmelfort. :)

@Hemmelfort :

Everything is working fine, except that FOW Zebras look the same, on the map, as discovered Zebras. Now I only have to discover how to turn horses (the 3d Models) into Zebras, understood what happened when I used Sukritact's dds file as a model (I fed it to the Asset Editor, and it inverted the transparent layer and made it a black layer), understood... a lot of other things.

But I think I am on the right track. Thanks a lot, you all!
 
Last edited:
Back
Top Bottom