View Full Version : Adding Units and CTD, help!
Greetings to all, I'm new to the forums and I've been having a hell of a great time w/ the game for the past year or so. Now I'm trying my hand at modding. :duel:
I've added a number of new units in my game(downloaded and integrated from other mods),I think I"ve followed all the rules diligently but... I can run the game, even go into the battle map w/ all the new units in clear
view. The problem I'm having is that on the Campaign Map after about 4 or 5 turns, the game CTD's. One other thing is that I cannot seem to play Custom Battles w/ the new units, or any unit for that matter,the game CTD.
The only files that I messed w/ are: (hope I get this right) :dizzy2:
descr_strat
descr_model_battle
export_units
export_descr_units
export_descr_units_enums
export_descr_buildings
I'm at a total loss since there is no error log if it is a CTD. The only other thing I was able to notice is that the CTD happens during the transition from the rebels turn to my new turn.
Thanks in advance for all the help and my deapest gratitude and thanks to those that made the guides, tutorial and the tools, it actually made modding
fun. Keep up the good work. ~D
Since the game doesn't give an error message ( I presume you have the 'show_err' thing added to your shortcut ) when the game starts, the error must be linked to something that happens in the campaign. Also, since you can use the new units you have added in a custom battle, that part of the modding went OK too. If you had messed that, then the game would choke in a custom battle.
So....the most likely culprit will be the editing of descr_strat, or in descr_buildings.
It should be easy enough to pin it down.
I presume you edited descr_building in order to allow your new units to be built in the campaign map. Make a backp of your edited file, and then put a stock file back in ( I presume you DO have a backup of the stock file.... )
Then run a campaign and see if you get an error.
If it still crashes, then most likely, it's the changes you made to the descr_strat file.
Some event will be happening to trigger the crash...maybe a unit is being built or a building constructed that triggers the crash. Without knowing what changes you have made, thats about as much as I can give you.
Thanks for the quick response.Yes, I did have back-up's and "-show_err" ( It's a law to be a cool modder ~D ).
By the way, I cannot play the Custom Battles but in the Campaign I can go into the battle w/ any unit. It CTD in Custom battle, I can see the Unit Cards and when i launch it,CTD. Why is this the case, I was under the impresion that if I cannot run them in Custom Battle, I should not be able to run them in the Campaing.
I only added one unit in descr_strat as a starting unit, carthaginian archers, I've removed it and still got the same CTD after 4 turns.
I did put the original file back in to search for the error,thankfully there was no error, when i placed the units and attach it to the building, played the game, CTD after 4 or so turns.
It seems to be something in the Campaign,how can I track it down?I also presume that it could be due to the units/building that are being built that turn,either by me or the AI.
Would there be a compatability issue w/ the descriptions in unit and building
descr? I just copy pasted the names on there proper queue.
:dizzy2:
First off....If your newly added unit is not working in custom battles, you have something wrong with it. You are probably getting the CTD in the campaign when someone builds it!
what have you added to the files to make your new unit?
There should be an entry in descr_model_battle, plus one in export_units. The stuff in the descriptions won't cause a CTD as long as you actually have a correct entry in each.
Can you post back with copies of what you have added to the files for these bits to make your new unit. You really need to be able to use a new unit in a custom battle without a CTD . That will confirm that the units are not to blame and narrow things down a bit.
I do not have the copy of the files right of the bat, i'll get back to you w/ those.
But just for add info. I was using some the units from drathmod 5.3(carthage, greece, gauls etc.. ) trying to incorporate them my game. I simply copied and pasted the neccessary scripts on there associated files. I added the entries on the bottom of the neccessary files. units in decr_units, building queue, models in descr_model battle, export units aswell. I just added the info on the unit_enums.
Thanks again. ~;)
Bwain - It seems that my back-up was somehow compromised thus i had to re-instal everything. ~:confused:
Now I', trying to add those units one at a time, instead of batches and so far so good. I'm able to play them in the Custom battles now. Hopefully, there should be no more error in the Campaign Map as well. One quick question though, in model_battle i placed the pathway data>sprites> but in my data folder its data>SPRITES, is this case sensitive? :dizzy2:
Regretably, I was not able to find out the root of my problems. I just hope its smooth sailing from here on. Thank again for all the help! ~D
vBulletin® v3.7.1, Copyright ©2000-2025, Jelsoft Enterprises Ltd.