Help Pls: CTD when clicking to build UU in my mod

Small Ashram

Chieftain
Joined
Mar 9, 2009
Messages
6
Location
Leuven, Belgium
Hi Everyone,

first post!

firstly thanks for all the contributions to these forums which have immensely improved my gameplay, or so i thought until last week as i found myself bottom of the power heap playing Boudica :crazyeye: obviously took a step backwards there

at the weekend i tried to build my own mod for the first time: Lakedaimonia (Sparta) so not exactly original! read umpteen tutorials and by last night got most of it dialled. had a few problems like black flags but all sorted now.

Despite having to work on several files and make sure they all properly reference it was not too bad as i have done a lot of programming, have an eye for errors and i can usually fix bugs pretty quick.

however, i can't for the life of me work out what is causing civ4bts to CTD when i click to build the UU. (as soon as the UU becomes available after building the UB, wouldn't you?!?!?)

it happens every time and without mercy, so at least "reproducable"!

i attach here a zipped file of the mod in progress - can anyone possibly give some clues what i should be looking for? a solution would be even better of course ;)

best regards, Sam
 

Attachments

I'd say a start would be the unit's art defines. check that out thoroughly
 
I assume its an ArtDefines error, but your artdefine looks clean; but the button is strange.
<button>,Art/Interface/Buttons/Units/spartiate.dds</button>
try
<button>Art/Interface/Buttons/Units/spartiate.dds</button

Shiggs beat me to it...
But yea, the its probably the artdefines, check your units civilopedia entry, does that come out looking right?

Welcome to the Forums, Small Ashram :beer:.
 
thanks mechaerik - i thought it was strange to have the comma in there but from looking at other examples it seemed to be normal. will give it a go.
 
Yeah, that comma bug gets everyone when they first start modding. The comma is only for unit art in the original Art0.fpk file the shipped with the game. Leaving it in with added units causes a CTD for some reason. Also what's really weird, is that default game units will work fine without that comma, so there really is no reason for it to be there in any case.
 
sounds like a winner to me, must eat before trying though...

not the sort of thing that's obvious to the uninitiated but makes perfect sense now

thanks for your superb responses :) Sam
 
actually you can use comma's on non FireAxis buttons, but the proper way to do it is like how merchaerik said;

<button>Art/Interface/Buttons/Units/spartiate.dds</button>

but you can actually do this also;

<button>, ,Art/Interface/Buttons/Units/spartiate.dds</button>

the comma's are normally only used for buttons within an atlas though. All of my custom buttons within my mod that actually use an atlas are like this;

<button>, ,Art/Interface/Buttons/Units/whatever_atlas.dds,5,10</button>

once you play around with enough xml errors you'll get the hang of it all...
 
Back
Top Bottom