XML - Trying to troubleshoot a mod showing up in list but seemingly not loading.

Galgus

Emperor
Joined
Aug 22, 2012
Messages
1,705
As the title says, I'm trying to find out if the mod isn't working due to the XML or some other error.

It's a fairly simple mod with XML largely copied from other text.

I don't think the XML is the problem, but I'm posting it and the Modinfo folder here in hopes that better modders might see what is wrong.
______________________________________________________________

?xml version="1.0" encoding="utf-8"?>
<!-- Created by ModBuddy on 6/25/2015 6:31:14 PM -->
<GameData>

<Traits>
<Update>
<Where Type="TRAIT_CULTURE_FROM_KILLS" />
<Set FaithFromKills="100" />
<Set CultureFromKills="500" />
</Update>
</Traits>

<Language_en_US>
<Update>
<Where Tag="TXT_KEY_TRAIT_CULTURE_FROM_KILLS" />
<Set Text="Gains [ICON_CULTURE] Culture and [ICON_PEACE] Faith for the empire from each enemy unit killed." />
</Update>

<Update>
<Where Tag="TXT_KEY_POLICY_BRANCH_HONOR_HELP" />
<Set Text="[COLOR_POSITIVE_TEXT]Honor[ENDCOLOR] improves the effectiveness of one's army in a variety of ways.[NEWLINE]-------[NEWLINE]Adopting Honor provides:[NEWLINE][ICON_BULLET]Gain [ICON_CULTURE] Culture for each unit killed equal to five times the [ICON_STRENGTH] combat strength of the killed unit.[NEWLINE][ICON_BULLET]Military Units get +33% [ICON_STRENGTH] combat strength VS Barbarians.[NEWLINE][ICON_BULLET]Get notifications when new Barbarian Encampments spawn in revealed territory.[NEWLINE][ICON_BULLET]Unlocks building the Statue of Zeus.[NEWLINE]-------[NEWLINE]Adopting all policies in Honor provides:[NEWLINE][ICON_BULLET]Gain [ICON_GOLD] Gold for each killed unit equal to five times the [ICON_STRENGTH] combat strength of the killed unit.[NEWLINE][ICON_BULLET]Can purchase Great Generals with [ICON_PEACE] Faith starting in the Industrial Era." />
</Update>

</Language_en_US>

<Policies>

<Update>
<Where Type="Policy_Honor" />
<Set CultureFromBarbarianKills="0" />
<Set CultureFromKills="500" />
</Update>

<Update>

<Where Type="Policy_Honor_Finisher" />
<Set GoldFromKills="500" />

</Update>

</Policies>

</GameData>
_________________________________________________________

<?xml version="1.0" encoding="utf-8"?>
<Mod id="2c528ffb-0a2b-4309-8591-5f375b925c4c" version="1">
<Properties>
<Name>Aztec and Honor kill bonus buff</Name>
<Stability>Alpha</Stability>
<Teaser>Increases the culture gain from Honor's slain barbarian bonus, the gold gain from the Honor finisher, and the Aztec's trait fro</Teaser>
<Description>Increases the culture gain from Honor's slain enemy bonus and makes it apply to all enemies, the gold gain from the Honor finisher, and the Aztec's trait from 100% of enemy combat strength to 500%.

Also adds a 100% faith gain based on slain enemy combat strength to the Aztec's trait.</Description>
<Authors>Galgus</Authors>
<HideSetupGame>0</HideSetupGame>
<AffectsSavedGames>1</AffectsSavedGames>
<MinCompatibleSaveVersion>0</MinCompatibleSaveVersion>
<SupportsSinglePlayer>1</SupportsSinglePlayer>
<SupportsMultiplayer>1</SupportsMultiplayer>
<SupportsHotSeat>1</SupportsHotSeat>
<SupportsMac>1</SupportsMac>
<ReloadAudioSystem>0</ReloadAudioSystem>
<ReloadLandmarkSystem>0</ReloadLandmarkSystem>
<ReloadStrategicViewSystem>0</ReloadStrategicViewSystem>
<ReloadUnitSystem>0</ReloadUnitSystem>
</Properties>
<Dependencies />
<References />
<Blocks />
<Files>
<File md5="8C45210E5D0BB1968627BAC523F08952" import="0">Aztech and Honor XML/Aztec and Honor.xml</File>
</Files>
<Actions>
<OnModActivated>
<UpdateDatabase>Aztech and Honor XML/Aztec and Honor.xml</UpdateDatabase>
</OnModActivated>
</Actions>
</Mod>
 
As the title says, I'm trying to find out if the mod isn't working due to the XML or some other error.

It's a fairly simple mod with XML largely copied from other text.

I don't think the XML is the problem, but I'm posting it and the Modinfo folder here in hopes that better modders might see what is wrong.
______________________________________________________________

Spoiler :
Code:
?xml version="1.0" encoding="utf-8"?>
<!-- Created by ModBuddy on 6/25/2015 6:31:14 PM -->
<GameData>

	<Traits>
		<Update>
			<Where Type="TRAIT_CULTURE_FROM_KILLS" />
			<Set FaithFromKills="100" />
			<[COLOR="Red"]Set[/COLOR] CultureFromKills="500" />
		</Update>
	</Traits>

	<Language_en_US>
		<Update>
			<Where Tag="TXT_KEY_TRAIT_CULTURE_FROM_KILLS" />
			<Set Text="Gains [ICON_CULTURE] Culture and [ICON_PEACE] Faith for the empire from each enemy unit killed." />
		</Update>

		<Update>
			<Where Tag="TXT_KEY_POLICY_BRANCH_HONOR_HELP" />
			<Set Text="[COLOR_POSITIVE_TEXT]Honor[ENDCOLOR] improves the effectiveness of one's army in a variety of ways.[NEWLINE]-------[NEWLINE]Adopting Honor provides:[NEWLINE][ICON_BULLET]Gain [ICON_CULTURE] Culture for each unit killed equal to five times the [ICON_STRENGTH] combat strength of the killed unit.[NEWLINE][ICON_BULLET]Military Units get +33% [ICON_STRENGTH] combat strength VS Barbarians.[NEWLINE][ICON_BULLET]Get notifications when new Barbarian Encampments spawn in revealed territory.[NEWLINE][ICON_BULLET]Unlocks building the Statue of Zeus.[NEWLINE]-------[NEWLINE]Adopting all policies in Honor provides:[NEWLINE][ICON_BULLET]Gain [ICON_GOLD] Gold for each killed unit equal to five times the [ICON_STRENGTH] combat strength of the killed unit.[NEWLINE][ICON_BULLET]Can purchase Great Generals with [ICON_PEACE] Faith starting in the Industrial Era." />
		</Update>

	</Language_en_US>

	<Policies>
		
		<Update>
			<Where Type="[COLOR="red"]Policy_Honor[/COLOR]" />
			<Set CultureFromBarbarianKills="0" />
			<[COLOR="red"]Set[/COLOR] CultureFromKills="500" />
		</Update>
		
		<Update>

			<Where Type="[COLOR="red"]Policy_Honor_Finisher[/COLOR]" />
			<Set GoldFromKills="500" />
			
		</Update>
		
	</Policies>
  
</GameData>
_________________________________________________________

<?xml version="1.0" encoding="utf-8"?>
<Mod id="2c528ffb-0a2b-4309-8591-5f375b925c4c" version="1">
  <Properties>
    <Name>Aztec and Honor kill bonus buff</Name>
    <Stability>Alpha</Stability>
    <Teaser>Increases the culture gain from Honor's slain barbarian bonus, the gold gain from the Honor finisher, and the Aztec's trait fro</Teaser>
    <Description>Increases the culture gain from Honor's slain enemy bonus and makes it apply to all enemies, the gold gain from the Honor finisher, and the Aztec's trait from 100% of enemy combat strength to 500%.

Also adds a 100% faith gain based on slain enemy combat strength to the Aztec's trait.</Description>
    <Authors>Galgus</Authors>
    <HideSetupGame>0</HideSetupGame>
    <AffectsSavedGames>1</AffectsSavedGames>
    <MinCompatibleSaveVersion>0</MinCompatibleSaveVersion>
    <SupportsSinglePlayer>1</SupportsSinglePlayer>
    <SupportsMultiplayer>1</SupportsMultiplayer>
    <SupportsHotSeat>1</SupportsHotSeat>
    <SupportsMac>1</SupportsMac>
    <ReloadAudioSystem>0</ReloadAudioSystem>
    <ReloadLandmarkSystem>0</ReloadLandmarkSystem>
    <ReloadStrategicViewSystem>0</ReloadStrategicViewSystem>
    <ReloadUnitSystem>0</ReloadUnitSystem>
  </Properties>
  <Dependencies />
  <References />
  <Blocks />
  <Files>
    <File md5="8C45210E5D0BB1968627BAC523F08952" import="0">Aztech and Honor XML/Aztec and Honor.xml</File>
  </Files>
  <Actions>
    <OnModActivated>
      <UpdateDatabase>Aztech and Honor XML/Aztec and Honor.xml</UpdateDatabase>
    </OnModActivated>
  </Actions>
</Mod>
  1. Always preserve the capitalization format as used by Firaxis. In many places it will not matter, but in other places it matters 100%. Don't try to remember where it does or does not matter -- use tag names, column names, table-names, etc., exactly as Firaxis did.
    • Policy_Honor
    • Policy_Honor_Finisher
  2. There can only be one occurance of <Set Something="Something" />within one pair of <Update> -- </Update> commands.
    • This is acceptable:
      Code:
      	<Traits>
      		<Update>
      			<Where Type="TRAIT_CULTURE_FROM_KILLS" />
      			<Set FaithFromKills="100" CultureFromKills="500" />
      		</Update>
      	</Traits>
    • What you had is not. There are two places I saw where you made this mistake.
Additional about formatting on the forum, use the
Code:
 wraps around your chunks of quoted game-XML. Makes it much easier to read. In the advanced view for creating forum posts the '#' sign Button will automatically give [code] wraps around a selected section of text you are adding to a post.
 
Thanks!

I'll be sure to remember capitalization, format updates properly, and use the code view on forums.
 
Back
Top Bottom