I thought the new buildings that SS 6.0 added were an awesome idea, and I want to include some new building ideas I have into my version of the Retrofit Mod/Grand Unit AddOn Mod, which is my favorite by far.
As I understand it though, the export_descr_buildings file is based on a spreadsheet, and any modification to the number of buildings causes the game to CTD, similar to the export_units_descr.txt. Yet, it seems my game will CTD even though the number of buildings stays constant.
Here's what I've tried so far:
Adding new building lines= CTD
Adding a new upgrade to an existing building line = CTD
Adding a new upgrade to an existing building line while removing an upgrade to an existing building line = works just fine
Adding new building lines while removing upgrades to an existing building line = CTD
Adding new building lines while removing existing building lines = CTD
A building line would be something like small church --> church --> abbey, etc.
I am curious as to how those people in Stainless Steel managed to add so many buildings. How do you add new building lines to an existing export_descr_building.txt? Is there a spreadsheet somewhere in the game files that I can manipulate?
Any help is appreciated.
Edit: Well, after downloading Ultimate Docudemons, I've been playing around with the spreadsheets and exported an export_descr_building.txt with the new buildings that I want. Of course, if I put it into my mod folder, I get the same CTD. Now I know where the spreadsheet is coming from, I guess...but how do I get the game to read my new spreadsheet?
Last edited by hitokiri2486; October 20, 2008 at 10:37 PM.
Re: adding new buildings to export_descr_buildings
I think they did a tutorial in the "Tools, Tutorials and Resources" forum.
It is not only the EDB but one file in the data\text folder (export_buildings.txt) and data\export_descr_buildings_enums.txt as well.
Re: adding new buildings to export_descr_buildings
The tutorial you mentioned I think is the one I found in the Scriptorium, but it's based off of Rome:Total War. Since R:TW and M2TW use the same engine and the same .txt files, I assumed that whatever works in RTW works in M2TW.
I did modify all three text files: export_buildings.txt, export_descr_buildings_enums.txt, and export_descr_buildings.txt, but I still get a CTD when starting up the game. My error log does not help me in this regard, since it says absolutely nothing about the files that I've edited. I'm assuming I'm going over some soft-coded limit on the # of buildings described, but I don't know how to fix that...I know it's possible because other mods like Stainless Steel have done so.
Is there something I'm missing here?
Edit: Actually, here's another question. Do I need to have my M2TW game unpacked in order to do this anyway?
Last edited by hitokiri2486; October 21, 2008 at 02:25 PM.
Re: adding new buildings to export_descr_buildings
Thanks for confirming my suspicions, Nakharar.
I was wondering about the pack mounting in my log.txt...and I knew that the data files in vanilla M2TW have to be "unpacked" in order to see/manipulate them. Should've connected the two earlier, but oh well. I'll unpack it now and see how it goes.
When I put in my new files, it's okay to just leave them in the mod folder, correct? I don't need to replace any vanilla files, even if I have the [io] file_first command in my mod's .cfg?
Edit:
So, I unpacked the vanilla files and tried running the mod again...no good. Same CTD still, the game doesn't seem to accept my newly modded files. I tried putting my modded files into the vanilla folder, but that didn't work either. Could it be the [io] file_first command in my mod's .cfg?
Last edited by hitokiri2486; October 21, 2008 at 03:31 PM.
Re: adding new buildings to export_descr_buildings
That's not the problem, it is clearly reading the files first because it is crashing. You probably forgot to edit the strings.bin files in the text folder. If the game engine can't find a name in one of these files, it says that it has encountered an unspecified error.
Dominion of the Sword, a Medieval II: Total War Supermod Under the patronage of Archaon. Proud member of the House of Siblesz
My friend died from chain letters. If you don't post this again 100 times, he will come and kill you in your sleep!
Re: adding new buildings to export_descr_buildings
I was under the impression that the strings.bin files in the text folder get updated whenever you modify the .txt files themselves.
i.e., after I extracted the strings.bin files using one of the tools on these forums, I went to export_buildings.txt and edited it. Therefore, the changes should be reflected in its bin file when the game starts up, correct?
My CTD isn't that dread "unspecified error" message, anyway...there's simply no error message at all. The splash screen for Retrofit Mod shows up for a few seconds, and then the screen flickers black and goes straight to the desktop. No error message at all. My error and trace logs show nothing related to the building files that I've changed.
I've seen this type of CTD before, when I replace units in export_descr_units.txt but forget to also replace them in export_descr_buildings.txt. However, in those cases an error log will tell me that that's exactly what happened. Here, the only thing I'm doing is adding additional buildings, and those buildings should be reflected in all three text files concerned with buildings. Yet, I still CTD, and on my error logs I get nothing at all...??
Re: adding new buildings to export_descr_buildings
Right, you don't get the "unspecified error" popup on this error, but it goes into the log. (CA seems to like to do things weird like that sometimes.) Sometimes, you have to delete the old strings.bin files to have the engine convert the text files. If you didn't delete them, it would explain your problems.
Dominion of the Sword, a Medieval II: Total War Supermod Under the patronage of Archaon. Proud member of the House of Siblesz
My friend died from chain letters. If you don't post this again 100 times, he will come and kill you in your sleep!
Re: adding new buildings to export_descr_buildings
Nope, doesn't seem to work.
Here is my error log:
17:35:24.624 [system.rpt] [always] CPU: SSE2
17:35:24.624 [system.rpt] [always] ==== system log start, build date: Aug 3 2007 version bld-medieval2-kingdoms-104 (45562) ===
As you can see, it's completely empty. I also ran a trace log, which was a lot bigger, but it dealt with various things like .tgas that were missing from the retrofit folder but were found in the vanilla folder. I did see that the packs were still being mounted despite me unpacking everything, so I tried putting the packs into the Recycling Bin and seeing if that did anything...unfortunately, the game continues to CTD.
Edit: Do I even need the data packs anymore now that I've unpacked everything? I'm tempted to just delete it all...
So, deleting the export_buildings bin.strings file does not help me...is there anything else that I could have done wrong?
By the way, thanks for all the help to everyone who's replied: Azim, gigantus, Nakharar; I appreciate y'all taking the time to respond to my somewhat n00bish questions.
Last edited by hitokiri2486; October 21, 2008 at 04:54 PM.
Re: adding new buildings to export_descr_buildings
Did you unpack for the first time? When you unpack the game data files, there are a couple of files you have to delete because they are time stamped and the game engine won't accept them if they have any changes. I can't remember the names of the files off the top of my head, but I'm sure you could find them in the tutorials section or on the wiki.
Dominion of the Sword, a Medieval II: Total War Supermod Under the patronage of Archaon. Proud member of the House of Siblesz
My friend died from chain letters. If you don't post this again 100 times, he will come and kill you in your sleep!
Re: adding new buildings to export_descr_buildings
Azim: Yes, I've already deleted descr_geography_new.db and descr_geography_new.txt.
Mythic_Commodore: Thanks for the reply, I've looked at your tutorials before for making units so your name is familiar to me. Your tutorials are well written, but the problem I'm having is not how to make a building--I already know how to do that--but rather how to get that building to show up in the game. Even though I have a modified EDB, EDB-enums, and export_buildings.txt, I keep on getting a CTD that doesn't show up in the log files and doesn't come with an "unspecified error" message.
My guess right now is perhaps I need to modify the original vanilla files as well in order for this to work? Does that sound like a reasonable solution to anyone? Or is there anything else I may have possibly missed?
This is quite the riddle...
My thanks, of course, for all the advice I've received so far~
match with the description in export_buildings.txt
if you see the cultures in the X building are all, exept mesoamerican (example)
in the export_buildings all cultures must have a description, exept mesoamerican culture, if you remove/add a culture, make sure that culture has the description: example
Spoiler Alert, click show to read:
{sultans_racing_track_middle_eastern}Sultan's Racing Track {sultans_racing_track_middle_eastern_desc}The love of the horse extends right through to the ruling class in Islam, and the Sultan’s Race Track is a place capable of staging races worthy of royalty. The track itself is not remarkable, but the quality of horses taking to the track truly is. This in turn leads to a better cut of cavalry unit that can be mustered in the city, and more enthralling races. {sultans_racing_track_middle_eastern_desc_short}A Sultan's Race Track allows cavalry recruitment in a city, and the ability to stage races. It also improves public happiness.
if not it must have this:
Spoiler Alert, click show to read:
{sultans_racing_track_southern_european_desc}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{sultans_racing_track_southern_european_desc_short}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
it may look confusing but here's a resume:
cultures in EDB building entry, MUST have a description in export_buildings
all non-included cultures in EDB entry, must have the ''DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE''
hope this helps
Last edited by Swagger; October 21, 2008 at 08:02 PM.
Re: adding new buildings to export_descr_buildings
You might indeed well have, Swagger, and I probably read it too! Congratulations for doing what I am apparently unable to do.
You're right, adding buildings is a simple act of messing around with text files, but getting them to show up in my mod is apparently deceptively hard.
Here's the thing: I now know I can get extra buildings to show up just fine in vanilla M2TW. I just did it 5 minutes ago. I'm assuming that's what you've done, Swagger, and what the tutorials that Mythic_Commodore wrote are based on.
My problem has been getting these new buildings to show up in Retrofit/Grand Unit AddOn mod. I think I've hit the solution, so I want to run this by anyone who's reading this and has some skill (aka, everyone who's posted so far besides me).
Since I successfully added one extra building to vanilla, how about I add the rest of those buildings to vanilla. Then, I add those buildings to the Retrofit/GUAM. So both Vanilla and the mod have the exact same building tree. I make sure I have the [io] file_first = true command in my preferences just for good measure, and run the game.
Now, please, someone tell me this will work.
I hope someone doesn't tell me that this is what everyone's been trying to say the entire time, because then I would feel very silly. But it's probably true.
@Swagger: I understand what you're trying to say, but I'm not sure if that'll cause a CTD. In Vanilla, for example, I was able to add the Highways building tonight. But I have descriptions for Highways for all factions in export_buildings.txt, while in export_descr_buildings.txt only Byzantium can build Highways--yet the game runs fine and I can see the highways in the game.
Also, as an update: since I successfully added highways and imperial barracks to Vanilla, I tried doing the same in Retrofit/GUAM --- didn't work, even with the modded vanilla files. I feel like a higher power doesn't want me to mess with Retrofit/GUAM. Maybe Candelarius is actually divine...
I wonder, if I can add buildings in vanilla and not in my mod folders, could I just move all my mod data into my vanilla data folder? So that the vanilla game become Retrofit/GUAM?
Last edited by hitokiri2486; October 21, 2008 at 08:41 PM.
Re: adding new buildings to export_descr_buildings
I did see that the packs were still being mounted despite me unpacking everything, so I tried putting the packs into the Recycling Bin and seeing if that did anything...unfortunately, the game continues to CTD.
Ahem, if you got one file missing in your unpacked version the game cannot find it in the packs, hence it will crash.
Unspecified errors could be the model_db file or map files, but error in the EDB or related files are usually indicated. Sure you didn't mod something else?
Re: adding new buildings to export_descr_buildings
@ Gigantus: I am positive that there are no files missing in my unpacked version of the game, for two reasons.
1) I can play vanilla m2TW just fine, and I can add buildings to vanilla m2TW just fine
2) I can play Retrofit/GUAM just fine as well--until I try adding buildings, that's when things break down.
If I was missing files, I wouldn't be able to do one or both of those things, correct? At least that's what I thought.
Also, I have had no unspecified errors this whole time, because I have not been modding the MDB or map files at the same time as I've been trying to add buildings. Errors in the EDB or related files are indeed usually indicated--but they're not in my error or trace logs, despite the game CTDing. The fact that there's nothing in my logs can only mean one thing: my EDB is free of errors.
So then why doesn't Retrofit/GUAM start up with my new EDB/export_buildings.txt/EDB-enums?
And yet Vanilla m2TW WILL start up with my new EDB/export_buildings.txt/EDB-enums?!
Granted, I have modded before in the past. I've changed the unit rosters in Retrofit/GUAM, I added a few new regions to the vanilla map in Retrofit/GUAM, and I added Ireland as a faction in Retrofit/GUAM, but this was all several months ago, it's nothing recent, and I've always been able to play. Yet modding my EDB screws everything up only in Retrofit/GUAM and not Vanilla--it's the most irrational CTD I've ever seen.
Re: adding new buildings to export_descr_buildings
Can you give us samples of what you have done so far in the EDB files?
I take you took either
a)the original files, modded them and added them back
or
b) modded the Retro or GUAM files and added them back
and made no other changes?
{mercenary_barracks_name}Mercenary Barracks
{mercenary_barracks}Mercenary Barracks
{mercenary_barracks_desc}DO NOT TRANSLATE
{mercenary_barracks_desc_short}DO NOT TRANSLATE
{mercenary_barracks_northern_european}Mercenary Barracks
{mercenary_barracks_northern_european_desc}Gathering and maintaining a feudal army can be time-consuming, difficult, and incredibly expensive; oftentimes, it is far easier to recruit soldiers who are paid by coin rather than fief, particularly in large empires where loyalty is always in short supply. This mercenary barracks is a place for recruiting those who fight to make their living, and often serves as an effective way to bolster one's army with well-armed and well-trained troops.
{mercenary_barracks_northern_european_desc_short}Barracks to recruit and house mercenaries.
{mercenary_barracks_greek}Mercenary Barracks
{mercenary_barracks_greek_desc}Gathering and maintaining a feudal army can be time-consuming, difficult, and incredibly expensive; oftentimes, it is far easier to recruit soldiers who are paid by coin rather than fief, particularly in large empires where loyalty is always in short supply. This mercenary barracks is a place for recruiting those who fight to make their living, and often serves as an effective way to bolster one's army with well-armed and well-trained troops.
{mercenary_barracks_greek_desc_short}Barracks to recruit and house mercenaries.
{mercenary_barracks_mesoamerican_desc}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_mesoamerican_desc_short}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_middle_eastern_desc}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_middle_eastern_desc_short}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_eastern_european_desc}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_eastern_european_desc_short}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_southern_european_desc}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
{mercenary_barracks_southern_european_desc_short}DO NOT TRANSLATE - NOT MEANT FOR THIS CULTURE
Note: this building works in vanilla m2TW with these lines of code, but not in Retrofit/GUAM.
Any help will be appreciated; I'll try and see if I can attach the entire EDB and export_buildings.txt to this thread as well.
Sorry for the double post, but I have attached the EDB to this thread. The export_buildings.txt exceeds the 1 MB limit for that file type (it's 1.16 MB)
On a side note, is there perhaps a specific format with the EDB? Like, similar with the MDB where you have to have two spaces after a 0; so for example, in the EDB there has to be a space after the word "plugin" otherwise the whole thing crashes horribly on you?
Edit: BIG NEWS, I got it to work!
And it seems to be a very superficial reason. I restored Retrofit?GUAM to what it was before I started modding EDB. Then I ran the game (and of course it ran fine). Then, I added the modified EDB, AND IT WORKED.
This has never happened before, and the only reason I can think of that it would happen now is because I unpacked the original game files. Is this seriously all that was needed? That I had to run the mod normally once with the vanilla files unpacked, and then I could add buildings to my heart's content?
So far things are okay, I hope I don't jinx myself (*cross fingers), but I would like to give a tremendous thank you to everyone who responded to my posts, you really helped me understand the EDB better and the importance of unpacking files. I'd give you all rep if I could but...well, I'm just a peasant and I have no rep to give.
Again, thank you--and we'll meet when I have another modding problem again, haha~
Last edited by Amroth; October 22, 2008 at 03:52 PM.
Reason: dp