Long time lurker... first time poster. Question about DLL

Just to clarify, I believe that phungus420 is asking you to comment each related change differently. For example, say you add two traits Populous (+2 pop when founding a city) and Warlike (+1 :) per rival you are at war with) by putting fields in CvPlayer:

Code:
	int m_iPopRushHurryCount;
	int m_iInflationModifier;

// JDHalfrack - Populous - start
	int m_iExtraFoundingPopulation;
// JDHalfrack - Populous - end

// JDHalfrack - Warlike - start
	int m_iWarHappiness;
// JDHalfrack - Warlike - end

This way if someone wants to merge the Warlike trait into their mod, they can easily spot all the changes that belong to it. Yes, it is a little extra burden when writing your code, but by using copy/paste and getting into the habit, it's really not much work. And if your intention is for others to use your code, it will greatly increase the likelihood that they do it and the amount that it will help. It will also minimize the questions you receive about how to merge your changes. :)

Everybody wins! :goodjob:

Similarly, in XML you'd use

Code:
<!-- JDHalfrack - Warlike - start -->
...
<!-- JDHalfrack - Warlike - end -->

I put the start/end part at the end of the comment for three reasons. First, it makes it easier for me to copy/paste/edit the end comment. Second, it makes the comments line up better. And third, it makes spotting the start/end part easier.
 
Personally, I tend to prefer NOT to comment XML EVER. Some places comments cause XML to go screwey, and if someone cannot build the XML for themselves, they probably cannot understand the DLL anyway, so the comments tend to just save a merger 30 seconds or so, at the risk of bizarre bugs which are hard to recognize and predict.
 
That's a good point. The SDK uses getChildElement() or some related function to get the XML values, and it will pick up comments if they are there I suspect. I use comments in the CIV4GameText XML files without trouble, but I agree to leave them out of the other XML files.
 
I use comments in the CIV4GameText XML files without trouble, but I agree to leave them out of the other XML files.
Yeah, I have quoted the crap out of the LeaderHeads XML file so I know exactly what each option does. But, I suppose if xienwolf says not to, I tend to believe that he knows best! So, I will go through and "over" comment the .cpp and .h files (the more explanation the merrier), but not the XML files at all.

Is it possible when I am done if someone could look over all the code to see that I am placing the code in the best possible location? Basically, I have some things in the CvCity file that may make more sense in cvPlayer.cpp.

Anyway, thanks for your help so far! :goodjob:

JD
 
How about writing up briefly your plan to implement each of the traits? For example:

Prosperous

+X population when founding a city

Add int field to CvPlayer.
Use in CvCity::init().

Warlike

+1 happy in each city per war

Add bool field to CvPlayer.
Add int field to CvPlayer to track number of current wars.
Update int field in CvPlayer::changeWar() [or whatever function does this]
Use in CvCity::happyLevel().
Add to happiness hover on city screen in CvGameTextMgr.
 
Okay, so here's a sample of what my posts whould look like (maybe :dunno:)...

Here are the XML tags I have defined already (iUnitStartExtraExperience is the only one which has no real code behind it). All things that need to be added will be preceeded by some sort of line that says "JDHalfrack" and will end the same way. We'll go through the coding in a moment. To begin with, though, you must define tags for this in the "CIV4CivilizationsSchema.xml" XML file. Do this by adding the following lines after the "FreePromotionUnitCombats" definition and before the "TraitInfo" definition:
Spoiler :
Code:
<ElementType name="FreePromotionUnitCombats" content="eltOnly">
  <element type="FreePromotionUnitCombat" minOccurs="0" maxOccurs="*"/>
</ElementType>
 
<!-- [COLOR="Green"]JDHalfrack XML Tag Definitions START HERE
     Created by: JDHalfrack
     Date created:  3/24/09
     Date moddified: N/A[/COLOR] -->
  
  
<!-- [COLOR="green"]iBuildingCostModifier changes the cost (as a percent) of producing buildings in the player's cities[/COLOR] -->
  <ElementType name="iBuildingCostModifier" content="textOnly" dt:type="int"/>
  
<!-- [COLOR="green"]iUnitCostModifier changes the cost (as a percent) of producing units in the player's cities[/COLOR] -->
<ElementType name="iUnitCostModifier" content="textOnly" dt:type="int"/>

<!-- [COLOR="green"]iUnitStartExtraExperience gives the player's created units extra experience points[/COLOR] -->
<ElementType name="iUnitStartExtraExperience" content="textOnly" dt:type="int"/>

<!-- [COLOR="green"]iCityStartExtraPopulation gives the player's cities extra population when founded[/COLOR] -->
<ElementType name="iCityStartExtraPopulation" content="textOnly" dt:type="int"/>

<!-- [COLOR="green"]iStartingGold gives the player gold when starting the game[/COLOR] -->
<ElementType name="iStartingGold" content="textOnly" dt:type="int"/>

<!-- [COLOR="green"]iUpgradeCostModifier changes the cost (as a percent) of upgrading the player's units[/COLOR] -->
<ElementType name="iUpgradeCostModifier" content="textOnly" dt:type="int"/>

<!-- [COLOR="green"]iPillageModifier changes the gold recieved (as a percent) when the player pillages another player's plots[/COLOR] -->
<ElementType name="iPillageModifier" content="textOnly" dt:type="int"/>

<!-- [COLOR="green"]bEnemiesCantPillageGold determines whether or not other players recieve gold when pillaging the player's plots[/COLOR] -->
<ElementType name="bEnemiesCantPillageGold" content="textOnly" dt:type="boolean"/>

<!-- [COLOR="green"]StartingTechs determines what techs (if any) a player starts with (not counting the techs a civilization normally starts with)[/COLOR] -->
<ElementType name="TechType" content="textOnly"/>
<ElementType name="bStartingTech" content="textOnly" dt:type="boolean"/>
<ElementType name="StartingTech" content="eltOnly">
  <element type="TechType"/>
  <element type="bStartingTech"/>
</ElementType>
<ElementType name="StartingTechs" content="eltOnly">
  <element type="StartingTech" minOccurs="0" maxOccurs="*"/>
</ElementType>

<!-- [COLOR="green"]SpecialistsPerCity determines what specialist (if any) and how many a player's cities start with when founded[/COLOR] -->
<ElementType name="iSpecialist" content="textOnly" dt:type="int"/>
<ElementType name="SpecialistsPerCity" content="eltOnly">
  <element type="iSpecialist" minOccurs="0" maxOccurs="*"/>
</ElementType>

<!--  [COLOR="green"]JDHalfrack XML Tag Definitions END HERE[/COLOR] -->
  
<ElementType name="TraitInfo" content="eltOnly">

Now in the same "CIV4CivilizationsSchema.xml" XML file, add the following tags in the "TraitInfo" section after the "FreePromotionUnitCombats" tag and before the "</ElementType>" line:
Spoiler :
Code:
<ElementType name="TraitInfo" content="eltOnly">
  <element type="Type"/>
  <element type="Description"/>
  <element type="ShortDescription"/>
  <element type="Help" minOccurs="0"/>
  <element type="iHealth"/>
  <element type="iHappiness"/>
  <element type="iMaxAnarchy"/>
  <element type="iUpkeepModifier"/>
  <element type="iLevelExperienceModifier"/>
  <element type="iGreatPeopleRateModifier"/>
  <element type="iGreatGeneralRateModifier"/>
  <element type="iDomesticGreatGeneralRateModifier"/>
  <element type="iMaxGlobalBuildingProductionModifier"/>
  <element type="iMaxTeamBuildingProductionModifier"/>
  <element type="iMaxPlayerBuildingProductionModifier"/>
  <element type="ExtraYieldThresholds"/>
  <element type="TradeYieldModifiers"/>
  <element type="CommerceChanges"/>
  <element type="CommerceModifiers"/>
  <element type="FreePromotions"/>
  <element type="FreePromotionUnitCombats"/>

  <!--  [COLOR="green"]JDHalfrack XML Tags START HERE[/COLOR] -->

  <element type="iBuildingCostModifier" minOccurs="0"/>
  <element type="iUnitCostModifier" minOccurs="0"/>
  <element type="iUnitStartExtraExperience" minOccurs="0"/>
  <element type="iCityStartExtraPopulation" minOccurs="0"/>
  <element type="iStartingGold" minOccurs="0"/>
  <element type="iUpgradeCostModifier" minOccurs="0"/>
  <element type="iPillageModifier" minOccurs="0"/>
  <element type="bEnemiesCantPillageGold" minOccurs="0"/>
  <element type="StartingTechs" minOccurs="0"/>
  <element type="SpecialistsPerCity" minOccurs="0"/>

  <!--  [COLOR="Green"]JDHalfrack XML Tags END HERE[/COLOR] -->
    
</ElementType>

After this, you are ready to create a "test" trait. In the ""CIV4TraitInfos.xml" XML file, create a trait somewhat similar to this:
Spoiler :
Code:
<TraitInfo>
  <Type>TRAIT_TEST</Type>
  <Description>TXT_KEY_TRAIT_TEST</Description>
  <ShortDescription>TXT_KEY_TRAIT_TEST_SHORT</ShortDescription>
  <iHealth>0</iHealth>
  <iHappiness>0</iHappiness>
  <iMaxAnarchy>-1</iMaxAnarchy>
  <iUpkeepModifier>0</iUpkeepModifier>
  <iLevelExperienceModifier>0</iLevelExperienceModifier>
  <iGreatPeopleRateModifier>0</iGreatPeopleRateModifier>
  <iGreatGeneralRateModifier>0</iGreatGeneralRateModifier>
  <iDomesticGreatGeneralRateModifier>0</iDomesticGreatGeneralRateModifier>
  <iMaxGlobalBuildingProductionModifier>0</iMaxGlobalBuildingProductionModifier>
  <iMaxTeamBuildingProductionModifier>0</iMaxTeamBuildingProductionModifier>
  <iMaxPlayerBuildingProductionModifier>0</iMaxPlayerBuildingProductionModifier>
  <ExtraYieldThresholds/>
  <TradeYieldModifiers/>
  <CommerceChanges/>
  <CommerceModifiers/>
  <FreePromotions/>
  <FreePromotionUnitCombats/>

  <!--  [COLOR="Green"]JDHalfrack XML Tags START HERE[/COLOR] -->
      
  <iBuildingCostModifier>-10</iBuildingCostModifier>
  <iUnitCostModifier>-20</iUnitCostModifier>
  <iUnitStartExtraExperience>1</iUnitStartExtraExperience>
  <iCityStartExtraPopulation>2</iCityStartExtraPopulation>
  <iStartingGold>300</iStartingGold>
  <iUpgradeCostModifier>-40</iUpgradeCostModifier>
  <iPillageModifier>50</iPillageModifier>
  <bEnemiesCantPillageGold>1</bEnemiesCantPillageGold>
  <StartingTechs>
    <StartingTech>
      <TechType>TECH_SAILING</TechType>
      <bStartingTech>1</bStartingTech>
    </StartingTech>
    <StartingTech>
      <TechType>TECH_ARCHERY</TechType>
      <bStartingTech>1</bStartingTech>
    </StartingTech>
  </StartingTechs>
  <SpecialistsPerCity>
    <!-- [COLOR="green"]Citizen[/COLOR] -->
    <iSpecialist>3</iSpecialist>
    <!-- [COLOR="green"]Priest[/COLOR] -->
    <iSpecialist>4</iSpecialist>
    <!-- [COLOR="green"]Artist[/COLOR] -->
    <iSpecialist>5</iSpecialist>
    <!-- [COLOR="green"]Scientist[/COLOR] -->
    <iSpecialist>6</iSpecialist>
    <!-- [COLOR="green"]Merchant[/COLOR] -->
    <iSpecialist>7</iSpecialist>
    <!-- [COLOR="green"]Engineer[/COLOR] -->
    <iSpecialist>8</iSpecialist>
    <!-- [COLOR="green"]Spy[/COLOR] -->
    <iSpecialist>9</iSpecialist>
    <!-- [COLOR="green"]Great Prophet[/COLOR] -->
    <iSpecialist>10</iSpecialist>
    <!-- [COLOR="green"]Great Artist[/COLOR] -->
    <iSpecialist>11</iSpecialist>
    <!-- [COLOR="green"]Great Scientist[/COLOR] -->
    <iSpecialist>12</iSpecialist>
    <!-- [COLOR="green"]Great Merchant[/COLOR] -->
    <iSpecialist>13</iSpecialist>
    <!-- [COLOR="green"]Great Engineer[/COLOR] -->
    <iSpecialist>14</iSpecialist>
    <!-- [COLOR="green"]Great Military Instructer[/COLOR] -->
    <iSpecialist>15</iSpecialist>
    <!-- [COLOR="green"]Great Spy[/COLOR] -->
    <iSpecialist>16</iSpecialist>
  </SpecialistsPerCity>
      
  <!--  [COLOR="green"]JDHalfrack XML Tags START HERE[/COLOR] -->
      
</TraitInfo>

Assign this new trait to a new leader or an existing leader. Obviously you would never use all of these options on one trait, but for testing purposes, it's easier than making 15 different traits. At this point, you can try to load the custom MOD and everything should work great. However, there is no coding yet to do anything with the new tags we created. But, it's nice to test it out.

I'll continue with the SDK coding in the next post.

JD
 
At this point, all we have done is add options we'd like to see added to traits. Until we add any codes, they don't really mean anything. So, to start with the coding, we need to make sure we can get the values from the XML files and that the other files in our source code can access the values from within the project. To do this, open CvInfos.h and find the CvTraitInfo class. In the "public:" section place the following lines after the last definition:
Spoiler :
Code:
[COLOR="Green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	Defines the functions required to get variables from the CvTraitInfo class   **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

DllExport int getBuildingCostModifier() const;
DllExport int getUnitCostModifier() const;
DllExport int getUnitStartExtraExperience() const;
DllExport int getCityStartExtraPopulation() const;
DllExport int getStartingGold() const;
DllExport int getUpgradeCostModifier() const;
DllExport int getPillageModifier() const;
DllExport bool getEnemiesCantPillageGold() const;
DllExport int isStartingTech(int i) const;
DllExport int getSpecialistsPerCity(int i) const;

[COLOR="Green"]/** CODE END **/
/*************************************************************************************************/[/COLOR]

Now go just a little farther down in the CvTraitInfo class and in the "protected:" section place the following lines after the last definition:
Spoiler :
Code:
[COLOR="Green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	Defines the variables used to store values obtained from traits              **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

int m_iBuildingCostModifier;	
int m_iUnitCostModifier;	
int m_iUnitStartExtraExperience;
int m_iCityStartExtraPopulation;
int m_iStartingGold;
int m_iUpgradeCostModifier;
int m_iPillageModifier;
bool m_bEnemiesCantPillageGold;
int* m_paiSpecialistsPerCity;
bool* m_pabStartingTech;

[COLOR="green"]/** CODE END **/
/*************************************************************************************************/[/COLOR]

I feel that both the function definitions and the variable definitions are self explanitory, so I did not comment on each one. However, if you are confused by any of the definitions, let me know, and I can help you sort them out.

Now that we have the definitions ready, open up CvInfos.cpp and find the CvTraitInfo section. Scroll to the "Default constructor" (right at the begining, and you'll notice there are a lot of variables being "reset" (m_iHealth(0), m_iHappiness(0), m_iMaxAnarchy(0), m_iUpkeepModifier(0), etc...). At the end of all of those, place the following lines:
Spoiler :
Code:
[COLOR="Green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	Sets the "base" values of each variable defined in CvInfos.h                 **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

m_iBuildingCostModifier(0),	
m_iUnitCostModifier(0),	
m_iUnitStartExtraExperience(0),
m_iCityStartExtraPopulation(0),
m_iStartingGold(0),
m_iUpgradeCostModifier(0),
m_iPillageModifier(0),
m_bEnemiesCantPillageGold(false),
m_pabStartingTech(NULL),
m_paiSpecialistsPerCity(NULL)

[COLOR="green"]/** CODE END **/
/*************************************************************************************************/ [/COLOR]
MAKE SURE YOU DO NOT COMMA THE LAST VALUE. If you place the code earlier, you will not have to comma the last value, but if you end with my code, you do NOT comma it.

Now scroll down a little to the "Default Destructor." Find all the "SAFE_DELETE_ARRAY" function calls right at the beginning. After the last SAFE_DELETE_ARRAY function call, paste the following:
Spoiler :
Code:
[COLOR="Green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	Deletes all arrays                                                           **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

	SAFE_DELETE_ARRAY(m_pabStartingTech);
	SAFE_DELETE_ARRAY(m_paiSpecialistsPerCity);

[COLOR="green"]/** CODE END **/
/*************************************************************************************************/[/COLOR]

Scroll farther down, and you'll find a set of functions, after the last function (probably "CvTraitInfo::isFreePromotionUnitCombat" if you haven't added any other functions to your files) place the following function list:
Spoiler :
Code:
[COLOR="green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	The actual functions used to obtain values from the CvTraitInfo class        **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

int CvTraitInfo::getBuildingCostModifier() const	
{
	return m_iBuildingCostModifier; 
}

int CvTraitInfo::getUnitCostModifier() const	
{
	return m_iUnitCostModifier; 
}

int CvTraitInfo::getUnitStartExtraExperience() const
{
	return m_iUnitStartExtraExperience;
}

int CvTraitInfo::getCityStartExtraPopulation() const
{
	return m_iCityStartExtraPopulation;
}

int CvTraitInfo::getStartingGold() const
{
	return m_iStartingGold;
}

int CvTraitInfo::getUpgradeCostModifier() const	
{
	return m_iUpgradeCostModifier; 
}

int CvTraitInfo::getPillageModifier() const	
{
	return m_iPillageModifier; 
}

bool CvTraitInfo::getEnemiesCantPillageGold() const	
{
	return m_bEnemiesCantPillageGold;
}

int CvTraitInfo::getSpecialistsPerCity(int i) const
{
	return m_paiSpecialistsPerCity ? m_paiSpecialistsPerCity[i] : -1; 
}

int CvTraitInfo::isStartingTech(int i) const
{
	return m_pabStartingTech ? m_pabStartingTech[i] : -1; 
}

[COLOR="green"]/** CODE END **/
/*************************************************************************************************/[/COLOR]
Once again, I think the functions are self-explanitory, so I did not comment each one.

We're almost done. the last thing to do is scroll to the "CvTraitInfo::read" function (it should be immediately following all of the stuff you just placed). This is where the actual values are read from the XML file. So here, we want to place the following lines after the last "pXML->" call and before the line "return true;":
Spoiler :
Code:
[COLOR="green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	This is the area that gets our initial values from the XML file              **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

	pXML->GetChildXmlValByName(&m_iBuildingCostModifier, "iBuildingCostModifier");
	pXML->GetChildXmlValByName(&m_iUnitCostModifier, "iUnitCostModifier");
	pXML->GetChildXmlValByName(&m_iUnitStartExtraExperience, "iUnitStartExtraExperience");
	pXML->GetChildXmlValByName(&m_iCityStartExtraPopulation, "iCityStartExtraPopulation");
	pXML->GetChildXmlValByName(&m_iStartingGold, "iStartingGold");
	pXML->GetChildXmlValByName(&m_iUpgradeCostModifier, "iUpgradeCostModifier");
	pXML->GetChildXmlValByName(&m_iPillageModifier, "iPillageModifier");
	pXML->GetChildXmlValByName(&m_bEnemiesCantPillageGold, "bEnemiesCantPillageGold" );
	pXML->SetVariableListTagPair(&m_pabStartingTech, "StartingTechs", sizeof(GC.getTechInfo((TechTypes)0)), GC.getNumTechInfos());
	if (gDLL->getXMLIFace()->SetToChildByTagName(pXML->GetXML(), "SpecialistsPerCity"))
	{
		pXML->SetSpecialists(&m_paiSpecialistsPerCity);
		gDLL->getXMLIFace()->SetToParent(pXML->GetXML());
	}
	else
	{
		pXML->InitList(&m_paiSpecialistsPerCity, GC.getNumSpecialistInfos());
	}

[COLOR="green"]/** CODE END **/
/*************************************************************************************************/[/COLOR]

At this point, you should be able to compile and run into no problems. The game should be able to load and it should be reading form the XML files. But, you won't be able to know this because we aren't doing anything with those values. We'll cover the "text" aspect of our XML values in the next post.

JD

EDIT: I'll get to the rest of this tonight.
 
:mischief:

Don't forget to include the Culture still produced by Non State religions in your trait Python to SDK conversion :deal: (it's found at the end of the Tstentom's Python Traits thread).

Seriously though, if you don't include it, I understand, but one can always remain hopeful. Though, I haven't come in here asking for help from EF or Xienwolf in a while, it's about that time again anyway... :lol:
 
Okay, I forgot one big thing about the "Specialists" functions. In order for any of that to work, one needs to define a function in CvXMLLoadUtility.h under the "int SetYields" function definition. So, after that definition, post the following:
Spoiler :
Code:
[COLOR="Green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	Defines the function needed to fill our "Specialist Array" from the XML file **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

	int SetSpecialists(int** ppiSpecialist);
	
[COLOR="green"]/** CODE END **/
/*************************************************************************************************/
[/COLOR]

Then, in CvXMLLoadUtility.cpp put the following after the SetYields Function:
Spoiler :
Code:
[COLOR="green"]/**************************************************************************************************/
/** MOD created by:	JDHalfrack                                                                   **/
/** Date created:	3/24/09                                                                      **/
/** Date moddified:	N/A                                                                          **/
/** Code Effect:	This function is needed to fill our "Specialist Array" from the XML file     **/
/**************************************************************************************************/
/** CODE START **/[/COLOR]

int CvXMLLoadUtility::SetSpecialists(int** ppiSpecialist)
{
	int i=0;
	int iNumSibs=0;
	int *piSpecialist;

	if (SkipToNextVal())
	{
		iNumSibs = gDLL->getXMLIFace()->GetNumChildren(m_pFXml);
		InitList(ppiSpecialist, GC.getNumSpecialistInfos());
		piSpecialist = *ppiSpecialist;
		if (0 < iNumSibs)
		{
			if (GetChildXmlVal(&piSpecialist[0]))
			{
				if(!(iNumSibs <= GC.getNumSpecialistInfos()))
				{
					char	szMessage[1024];
					sprintf( szMessage, "For loop iterator is greater than array size \n Current XML file is: %s", GC.getCurrentXMLFile().GetCString());
					gDLL->MessageBox(szMessage, "XML Error");
				}
				for (i=1;i<iNumSibs;i++)
				{
					if (!GetNextXmlVal(&piSpecialist[i]))
					{
						break;
					}
				}
				gDLL->getXMLIFace()->SetToParent(m_pFXml);
			}
		}
	}

	return iNumSibs;
}
[COLOR="green"]/** CODE END **/
/*************************************************************************************************/[/COLOR]

Sorry for that oversight... whoops! :blush:

JD
 
:mischief:

Don't forget to include the Culture still produced by Non State religions in your trait Python to SDK conversion :deal: (it's found at the end of the Tstentom's Python Traits thread).

Seriously though, if you don't include it, I understand, but one can always remain hopeful. Though, I haven't come in here asking for help from EF or Xienwolf in a while, it's about that time again anyway... :lol:

Just to make sure, you are wanting the ability to adjust the amount of culture provided per nonstate relgion? so you would want something like this:

<iCulturePerNonStateReligion>5</iCulturePerNonStateReligion>

In this example, for every non state religion, you get 5 culture per turn. That's what you're looking for, right?

JD
 
Oh, that'd work fine. Tsentom's Python only added 1 culture from non state, and that's all I'll use, so a simple boolean would work fine for me, but an integer based tag would work just as well, and provide for more moddability, so that would be great as well. One thing though, I don't want extra culture applied for when you run no state religion (free religion or otherwise). That would seem a bit overpowered to me. That's probably easy to take care of with an if pPlayer.getstatereligion() > 0{...} or whatever the SDK call for state religion is.
 
Is transfering the tsentsom python traits to SDK still being done, or has that project been put on indefinate hold/cancelled?
 
Is transfering the tsentsom python traits to SDK still being done, or has that project been put on indefinate hold/cancelled?

Well, these things take time, and I'm still learning. Truthfully, most of them are done, but not done well. Since starting this project, I have learned even more things that would have been nice to know before I started. That and the fact that I am currently involved in like 4 other projects for 3 different games... but this will get done some day (Hopefully sooner than later)!

Also, today is the first day of my Spring Break. So, I do have a little extra free time for about a week. But, I also have a lot of other projects around the house I am working on. So, we'll see!

JD
 
Top Bottom