Troubles in civ5 modding

kanaanpal99

Chieftain
Joined
Aug 16, 2013
Messages
20
Hello everyone, i have made a mod; The Palestinian Civilization (and i am working on a middle east pack); every thing worked right ... my unique unit; the FEDAYEEN, replaces the infantry, at the beginning , i left it look like the default infantry, but i have decided to reskin it. I have made a skin for it following some tutorials ... but when i launch the game , load the mod, start a game with the palestinian civ at the modern era, after the loading (dawn of man), the game crashes... Thank you ...



My mod's Build and project file:
 

Attachments

  • Palestine.rar
    1.5 MB · Views: 36
I haven't figured out why, but the game crashes only when it tries to display your new unit (which is why it crashes on modern era start).

Problems that I did notice so far: Your textures currently replace the vanilla infantry's. You'll need to rename them and modify the .gr2 (in IndieStone Nexus Buddy v0.1a change the material's Base Texture Map to your diff and SREFMap to your sref; no path is necessary). [You should probably also revise the .fxsxml accordingly, but I'm not sure it matters.]

Check your logs:
In Civilization_CityNames, Gaza is already used by Byzantium, so you should update the CivilizationType for that row. Jerusalem already exists as a city state, so you need to delete it [from MinorCivilization_CityNames] or else you get TXT_KEY_ etc. displayed instead of the name of your capital.

EDIT: In UnitsFedayeen.sql, you're missing a closing parentheses.

Also, it doesn't matter at all for the operation of the mod, but why are your unit art files under your XML folder?
 
ok i will start step by step, witch files do i have to rename ?


EDIT: i have corrected the errors ... but i don't think it is done, what shall i do next?
 
Note I made several edits (that I didn't signify), you might want to check the post again.

ok i will start step by step, witch files do i have to rename ?
Infantry_sref.dds and Infantry_diff.dds will overwrite the originals in VFS unless you have a unique name.
 
EDIT: i have corrected the errors ... but i don't think it is done, what shall i do next?
The crash probably has something to do with the model. I was (unrealistically) hoping that when you resaved the .gr2 in Nexus Buddy, it would fix the problem.
 
Infantry_sref.dds is now Fedayeen_sref.dds , Infantry_diff.dds is now Fedayeen.dds
i have closed the parenthese
i tested , and the game still crashes
 
I don't know why you're getting that crash. Nexus Viewer is able to render the model just fine...
EDIT: Found it! It has nothing to do with the model. It looks like you don't have an entry in ArtDefine_UnitInfoMemberInfos. You need to add the following to UnitsFedayeenArt.xml:
Code:
	<ArtDefine_UnitInfoMemberInfos>
		<Row>
			<UnitInfoType>ART_DEF_UNIT_FEDAYEEN</UnitInfoType>
			<UnitMemberInfoType>ART_DEF_UNIT_MEMBER_FEDAYEEN</UnitMemberInfoType>
			<NumMembers>12</NumMembers>
		</Row>
	</ArtDefine_UnitInfoMemberInfos>

...

Let's again fix the easy stuff. Gotta check your logs. Here are the pertinent ones (in database.log):
Code:
[545515.125] columns Language, Tag are not unique
[545515.125] While executing - 'insert into Language_en_US('Tag', 'Text') values (?, ?);'
[545515.125] In XMLSerializer while inserting row into table insert into Language_en_US('Tag', 'Text') with  values (TXT_KEY_CITY_NAME_GAZA, Gaza, ).
[545515.125] In XMLSerializer while updating table Language_en_US from file XML/NewText/Cities.xml.
[545515.125] columns Language, Tag are not unique
[545515.875] near "FROM": syntax error

Looks like you didn't fix Gaza and Jerusalem. You want to change the Gaza entry in Palestine.xml to:
Code:
		<Update>
			<Where CityName="TXT_KEY_CITY_NAME_GAZA" />
			<Set>
				<CivilizationType>CIVILIZATION_PALESTINE</CivilizationType>
			</Set>
		</Update>
And you also want to add (before <Civilization_CityNames>):
Code:
	<MinorCivilization_CityNames>
		<Delete MinorCivType="MINOR_CIV_JERUSALEM" />
	</MinorCivilization_CityNames>

And that SQL is still not right. I think this is what you were going for:
Code:
UPDATE Units SET CombatClass='UNITCOMBAT_RIFLEMAN' WHERE TYPE='UNIT_FEDAYEEN' AND EXISTS (SELECT * FROM UnitCombatInfos WHERE Type='UNITCOMBAT_RIFLEMAN');
...but I don't see what it's for, since there's no UNITCOMBAT_RIFLEMAN in BNW or vanilla (was there one in G+K?)
 
i thank you very much for your help man, but yesterday i fixed this with a friend... "Bamington" on steam
and this mod is for Vanilla, so there is no city state named jerusalem
 
Top Bottom