C++/Lua Request Thread

You are both stars and thank-you :)!!

EDIT: One quick question - I presume that when using this code, if a slinger is created by an event, it will also create a duplicate?
 
erm. William, run your code. The small oops with no 'then' or 'end' for the one 'return' aside, I get infinite units everywhere. I made a slight update to my version perhaps since you posted your latest.
 
You are both stars and thank-you :)!!

EDIT: One quick question - I presume that when using this code, if a slinger is created by an event, it will also create a duplicate?

Any of the units listed on the 'key' side of the pair (ie, [GameInfoTypes.UNIT_SLINGER] = ) will get duplicated regardless of how the unit is created. This includes purchasing, constructing in a city, or an lua-method that creates the unit.
 
I have this code here written by LeeS and Troller0001. The code works like this: When a policy tree is finished, a unique promotion is granted to military units for 10 turns, and it varies by game speed. It seems to work before, but it doesn't seem to work anymore. FireTuner's not helping, there's no error messages from this code.

Do you know what's up?

Code:
local bBranchFinished = {} --data setting into this table moved to bottom and is based on correct conditions at game reload or game start
local iOurCiv = GameInfoTypes.CIVILIZATION_AUTOBOTS --I assumed this civilization would be the autobots, since the other one were the decepticons;
local iPolicyTurns = 0
local iPolicyPromotion = GameInfoTypes.PROMOTION_POLICY_TREE_COMPLETE

--Whoward's GameSpeed Scaling Factor
local fTrainFactor = GameInfo.GameSpeeds[PreGame.GetGameSpeed()].TrainPercent / 100.0
local iStandardTurns = 10
local iBoostTurns = math.floor(iStandardTurns * fTrainFactor + 0.5) --NOTE: not sure why there is a +0.5 here; it simply ALWAYS adds half a turn extra on every game speed :confused:
local bExcludeIdeologyBranches = true


function PolicyTreeFinishedAttackBoost(iPlayer, ePolicy)
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iOurCiv then
		local bAddPromotion = false
		print("The Autobots have arrived; they've adopted another policy!")
		for PolicyBranch in GameInfo.PolicyBranchTypes() do
			local bBranchIsAnIdeology = false
			local iPolicyBranch = PolicyBranch.ID
			if (PolicyBranch.FreePolicy == nil) or (PolicyBranch.FreePolicy == "NULL") then
				bBranchIsAnIdeology = true
			end
			if bBranchIsAnIdeology then
				if not bExcludeIdeologyBranches then
					if pPlayer:GetLateGamePolicyTree() == iPolicyBranch then
						if bBranchFinished[iPolicyBranch] == false then
							bBranchFinished[iPolicyBranch] = true
							bAddPromotion = true
							iPolicyTurns = iPolicyTurns + iBoostTurns
						end
					end
				end
			else
				if pPlayer:IsPolicyBranchFinished(iPolicyBranch) and (bBranchFinished[iPolicyBranch] == false) then
					print("The Autobots have Finished a Policy Branch for the first time! Surely Social Policies will be useful when fighting the Decepticons!!")
					bBranchFinished[iPolicyBranch] = true
					bAddPromotion = true
					iPolicyTurns = iPolicyTurns + iBoostTurns
				else
					print("This policy branch has already been finished before")
				end
			end
		end
		if bAddPromotion then
			for pUnit in pPlayer:Units() do --loop through every unit of our player
				if pUnit:IsCombatUnit() then
					pUnit:SetHasPromotion(iPolicyPromotion,true)
					print("Promotion granted to our unit!")
				end
			end
		end
	end
end

function PolicyBranchCombatBoostCounter(iPlayer)
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iOurCiv then
		if iPolicyTurns == 0 then
			--print("It has been too long since we have last finished a social policy tree. Rip Extra Combat damage")
			for pUnit in pPlayer:Units() do
				pUnit:SetHasPromotion(iPolicyPromotion,false)
			end
		elseif iPolicyTurns > 0 then
			iPolicyTurns = iPolicyTurns - 1
		end
	end
end

--Whoward's IsCivInPlay
function IsCivInPlay(iCivType)
  for iSlot = 0, GameDefines.MAX_MAJOR_CIVS-1, 1 do
    local iSlotStatus = PreGame.GetSlotStatus(iSlot)
    if (iSlotStatus == SlotStatus.SS_TAKEN or iSlotStatus == SlotStatus.SS_COMPUTER) then
      if (PreGame.GetCivilization(iSlot) == iCivType) then
        return true
      end
    end
  end
  
  return false
end


if (IsCivInPlay(iOurCiv)) then
	for iPlayer = 0, GameDefines.MAX_MAJOR_CIVS - 1 do
		local pPlayer = Players[iPlayer]
		if pPlayer ~= nil then
			if pPlayer:GetCivilizationType() == iOurCiv then
				for PolicyBranch in GameInfo.PolicyBranchTypes() do
					local bBranchIsAnIdeology = false
					local iPolicyBranch = PolicyBranch.ID
					if (PolicyBranch.FreePolicy == nil) or (PolicyBranch.FreePolicy == "NULL") then
						bBranchIsAnIdeology = true
					end
					if bBranchIsAnIdeology then
						bBranchFinished[iPolicyBranch] = (pPlayer:GetLateGamePolicyTree() == iPolicyBranch)
					else
						bBranchFinished[iPolicyBranch] = pPlayer:IsPolicyBranchFinished(iPolicyBranch)
					end
				end
			end
		end
	end
	iPolicyTurns = iBoostTurns
	GameEvents.PlayerAdoptPolicy.Add(PolicyTreeFinishedAttackBoost)
	GameEvents.PlayerDoTurn.Add(PolicyBranchCombatBoostCounter)
end
 
I have this code here written by LeeS and Troller0001. The code works like this: When a policy tree is finished, a unique promotion is granted to military units for 10 turns, and it varies by game speed. It seems to work before, but it doesn't seem to work anymore. FireTuner's not helping, there's no error messages from this code.

Do you know what's up?

Code:
local bBranchFinished = {} --data setting into this table moved to bottom and is based on correct conditions at game reload or game start
local iOurCiv = GameInfoTypes.CIVILIZATION_AUTOBOTS --I assumed this civilization would be the autobots, since the other one were the decepticons;
local iPolicyTurns = 0
local iPolicyPromotion = GameInfoTypes.PROMOTION_POLICY_TREE_COMPLETE

--Whoward's GameSpeed Scaling Factor
local fTrainFactor = GameInfo.GameSpeeds[PreGame.GetGameSpeed()].TrainPercent / 100.0
local iStandardTurns = 10
local iBoostTurns = math.floor(iStandardTurns * fTrainFactor + 0.5) --NOTE: not sure why there is a +0.5 here; it simply ALWAYS adds half a turn extra on every game speed :confused:
local bExcludeIdeologyBranches = true


function PolicyTreeFinishedAttackBoost(iPlayer, ePolicy)
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iOurCiv then
		local bAddPromotion = false
		print("The Autobots have arrived; they've adopted another policy!")
		for PolicyBranch in GameInfo.PolicyBranchTypes() do
			local bBranchIsAnIdeology = false
			local iPolicyBranch = PolicyBranch.ID
			if (PolicyBranch.FreePolicy == nil) or (PolicyBranch.FreePolicy == "NULL") then
				bBranchIsAnIdeology = true
			end
			if bBranchIsAnIdeology then
				if not bExcludeIdeologyBranches then
					if pPlayer:GetLateGamePolicyTree() == iPolicyBranch then
						if bBranchFinished[iPolicyBranch] == false then
							bBranchFinished[iPolicyBranch] = true
							bAddPromotion = true
							iPolicyTurns = iPolicyTurns + iBoostTurns
						end
					end
				end
			else
				if pPlayer:IsPolicyBranchFinished(iPolicyBranch) and (bBranchFinished[iPolicyBranch] == false) then
					print("The Autobots have Finished a Policy Branch for the first time! Surely Social Policies will be useful when fighting the Decepticons!!")
					bBranchFinished[iPolicyBranch] = true
					bAddPromotion = true
					iPolicyTurns = iPolicyTurns + iBoostTurns
				else
					print("This policy branch has already been finished before")
				end
			end
		end
		if bAddPromotion then
			for pUnit in pPlayer:Units() do --loop through every unit of our player
				if pUnit:IsCombatUnit() then
					pUnit:SetHasPromotion(iPolicyPromotion,true)
					print("Promotion granted to our unit!")
				end
			end
		end
	end
end

function PolicyBranchCombatBoostCounter(iPlayer)
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iOurCiv then
		if iPolicyTurns == 0 then
			--print("It has been too long since we have last finished a social policy tree. Rip Extra Combat damage")
			for pUnit in pPlayer:Units() do
				pUnit:SetHasPromotion(iPolicyPromotion,false)
			end
		elseif iPolicyTurns > 0 then
			iPolicyTurns = iPolicyTurns - 1
		end
	end
end

--Whoward's IsCivInPlay
function IsCivInPlay(iCivType)
  for iSlot = 0, GameDefines.MAX_MAJOR_CIVS-1, 1 do
    local iSlotStatus = PreGame.GetSlotStatus(iSlot)
    if (iSlotStatus == SlotStatus.SS_TAKEN or iSlotStatus == SlotStatus.SS_COMPUTER) then
      if (PreGame.GetCivilization(iSlot) == iCivType) then
        return true
      end
    end
  end
  
  return false
end


if (IsCivInPlay(iOurCiv)) then
	for iPlayer = 0, GameDefines.MAX_MAJOR_CIVS - 1 do
		local pPlayer = Players[iPlayer]
		if pPlayer ~= nil then
			if pPlayer:GetCivilizationType() == iOurCiv then
				for PolicyBranch in GameInfo.PolicyBranchTypes() do
					local bBranchIsAnIdeology = false
					local iPolicyBranch = PolicyBranch.ID
					if (PolicyBranch.FreePolicy == nil) or (PolicyBranch.FreePolicy == "NULL") then
						bBranchIsAnIdeology = true
					end
					if bBranchIsAnIdeology then
						bBranchFinished[iPolicyBranch] = (pPlayer:GetLateGamePolicyTree() == iPolicyBranch)
					else
						bBranchFinished[iPolicyBranch] = pPlayer:IsPolicyBranchFinished(iPolicyBranch)
					end
				end
			end
		end
	end
	iPolicyTurns = iBoostTurns
	GameEvents.PlayerAdoptPolicy.Add(PolicyTreeFinishedAttackBoost)
	GameEvents.PlayerDoTurn.Add(PolicyBranchCombatBoostCounter)
end

without the current state of the mod to look at it is impossible to say which of numerous mistakes might be making the lua script no longer appear to work correctly.
 
Without actually looking at the code myself, I'd suggest:

Did you rename the promotion or anything recently? This happened to me in a similar situation where I had a promotion that worked fine, then renamed it at some point and forgot to update the .Lua to the correct name, causing said similar problem.

Just a thought.
 
Without actually looking at the code myself, I'd suggest:

Did you rename the promotion or anything recently? This happened to me in a similar situation where I had a promotion that worked fine, then renamed it at some point and forgot to update the .Lua to the correct name, causing said similar problem.

Just a thought.

I tried that out, but the name of the promotion is still the same.
But still, that's a good way to find errors.
 
Use this version of the code. It works a little better than the previous version. The previous version was actually working. It was just not working as you expected it to.
Spoiler :
Code:
-- AutobotsUA
-- Author: Admin
-- DateCreated: 6/15/2016 2:29:42 PM
-- Thanks to Troller and LeeS for writing this up.
--------------------------------------------------------------
local bBranchFinished = {} --data setting into this table moved to bottom and is based on correct conditions at game reload or game start
local iOurCiv = GameInfoTypes.CIVILIZATION_AUTOBOTS --I assumed this civilization would be the autobots, since the other one were the decepticons;
local iPolicyTurns = 0
local iPolicyPromotion = GameInfoTypes.PROMOTION_POLICY_TREE_COMPLETE

--Whoward's GameSpeed Scaling Factor
local fTrainFactor = GameInfo.GameSpeeds[PreGame.GetGameSpeed()].TrainPercent / 100.0
local iStandardTurns = 10
local iBoostTurns = math.floor(iStandardTurns * fTrainFactor + 0.5) --NOTE: not sure why there is a +0.5 here; it simply ALWAYS adds half a turn extra on every game speed :confused:
local bExcludeIdeologyBranches = true


function PolicyTreeFinishedAttackBoost(iPlayer, ePolicy)
	print("PolicyTreeFinishedAttackBoost executed")
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iOurCiv then
		local bAddPromotion = false
		print("The Autobots have arrived; they've adopted another policy!")
		for PolicyBranch in GameInfo.PolicyBranchTypes() do
			local bBranchIsAnIdeology = false
			local sBranchName = Locale.ConvertTextKey(PolicyBranch.Description)
			local iPolicyBranch = PolicyBranch.ID
			if (PolicyBranch.FreePolicy == nil) or (PolicyBranch.FreePolicy == "NULL") then
				bBranchIsAnIdeology = true
			end
			if bBranchIsAnIdeology then
				if not bExcludeIdeologyBranches then
					if pPlayer:GetLateGamePolicyTree() == iPolicyBranch then
						if bBranchFinished[iPolicyBranch] == false then
							bBranchFinished[iPolicyBranch] = true
							bAddPromotion = true
							iPolicyTurns = iPolicyTurns + iBoostTurns
						end
					end
				end
			else
				if pPlayer:IsPolicyBranchFinished(iPolicyBranch) and (bBranchFinished[iPolicyBranch] == false) then
					print("The Autobots have Finished a Policy Branch (" .. sBranchName .. ") for the first time! Surely Social Policies will be useful when fighting the Decepticons!!")
					bBranchFinished[iPolicyBranch] = true
					bAddPromotion = true
					iPolicyTurns = iPolicyTurns + iBoostTurns
				else
					if pPlayer:IsPolicyBranchFinished(iPolicyBranch) then
						print("This policy branch " .. sBranchName .. " has already been finished before")
					else
						print("This policy branch " .. sBranchName .. " has not been completed yet")
					end
				end
			end
		end
		if bAddPromotion then
			for pUnit in pPlayer:Units() do --loop through every unit of our player
				if pUnit:IsCombatUnit() then
					pUnit:SetHasPromotion(iPolicyPromotion,true)
					print("Promotion granted to our unit!")
				end
			end
		end
	end
end

function PolicyBranchCombatBoostCounter(iPlayer)
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iOurCiv then
		print("PolicyBranchCombatBoostCounter executed as part of PlayerDoTurn: AutoBotPlayer detected")
		print("iPolicyTurns = " .. iPolicyTurns)
		if iPolicyTurns <= 0 then
			--print("It has been too long since we have last finished a social policy tree. Rip Extra Combat damage")
			for pUnit in pPlayer:Units() do
				pUnit:SetHasPromotion(iPolicyPromotion,false)
			end
			iPolicyTurns = 0
		elseif iPolicyTurns > 0 then
			iPolicyTurns = iPolicyTurns - 1
			for pUnit in pPlayer:Units() do
				if pUnit:IsCombatUnit() then
					if not pUnit:IsHasPromotion(iPolicyPromotion) then
						pUnit:SetHasPromotion(iPolicyPromotion,true)
						print("Promotion granted to our unit!")
					end
				end
			end
		end
	end
end

--Whoward's IsCivInPlay
function IsCivInPlay(iCivType)
  for iSlot = 0, GameDefines.MAX_MAJOR_CIVS-1, 1 do
    local iSlotStatus = PreGame.GetSlotStatus(iSlot)
    if (iSlotStatus == SlotStatus.SS_TAKEN or iSlotStatus == SlotStatus.SS_COMPUTER) then
      if (PreGame.GetCivilization(iSlot) == iCivType) then
        return true
      end
    end
  end
  
  return false
end


if (IsCivInPlay(iOurCiv)) then
	print("The Autobots are in Play")
	local bWeHaveCompletedABranch = false
	for iPlayer = 0, GameDefines.MAX_MAJOR_CIVS - 1 do
		local pPlayer = Players[iPlayer]
		if pPlayer ~= nil then
			if pPlayer:GetCivilizationType() == iOurCiv then
				for PolicyBranch in GameInfo.PolicyBranchTypes() do
					local bBranchIsAnIdeology = false
					local iPolicyBranch = PolicyBranch.ID
					if (PolicyBranch.FreePolicy == nil) or (PolicyBranch.FreePolicy == "NULL") then
						bBranchIsAnIdeology = true
					end
					if bBranchIsAnIdeology then
						if (pPlayer:GetLateGamePolicyTree() == iPolicyBranch) then
							bBranchFinished[iPolicyBranch] = true
							bWeHaveCompletedABranch = true
						else
							bBranchFinished[iPolicyBranch] = false
						end
					else
						if pPlayer:IsPolicyBranchFinished(iPolicyBranch) then
							bBranchFinished[iPolicyBranch] = true
							bWeHaveCompletedABranch = true
						else
							bBranchFinished[iPolicyBranch] = false
						end
					end
				end
			end
		end
	end
	if bWeHaveCompletedABranch then
		iPolicyTurns = iBoostTurns
	end
	GameEvents.PlayerAdoptPolicy.Add(PolicyTreeFinishedAttackBoost)
	GameEvents.PlayerDoTurn.Add(PolicyBranchCombatBoostCounter)
else
	print("The AutoBots are not in Play this game")
end
	

print("AutobotsUA.lua loaded to the end and is active")
  • There was nothing remaining in the previous version to take the promotion away from the units when the 'counter' had expired, and there was nothing in the previous version to add the promotion to new units when correct to do so.
  • The previous version was also setting the counter to '10' on game start or reload even when the player had not completed any policy branches.
  • Setting the counter to '10' on game loading was intentional in order to avoid more complicated methods of persisting data over saves and loads, but was not coded as well as it could have been. It is now only set to give the basic '10' turns on game loading when the player has already completed a policy branch or has already picked an ideology when the game loads from a save or when a new game is started.
    • in the case of starting a new game the player should never have a policy branch completed or have an ideology picked, so the way this works should never matter for a new game being started
 
Hmmm. Let's argue for the sake of making it so multiple copies of the same Civ aren't redundant because their unique ability will only trigger for one of them, that instead the ability allows the Dummybuildings to stack for each copy of the Civ in play.

I plan to use this code for at least 2 different Civilizations. For the first Civ, multiple copies, especially if it's the only Civ in game is redundant from the start because their UA already makes the effects of the Dummybuilding moot (unless there's at least 1 different Civ, in which case they'll be hurting somethin' fierce), but for the second one I'd feel that their UA stacking repeatedly would be important. In either case, I don't want to half-a$$ it, so I'd like it if the Dummybuildings could indeed stack with one another for multiple Declarations of Friendship.

Okay, that should be doable, though I have one question:
I looked for the definition of your dummy in your .zip, which uses 'CityCountUnhappinessMod'. I'm not entirely sure what this does, though I'd assume that it doesn't 'naturally' stack, as in, stack with multiple copies of the same building (E.g. Tourism does not 'naturally' stack, while +base faith does 'naturally' stack).

Give me some time (as in, I'll probably do it this evening) to edit.


EDIT: There you go

Spoiler :

Code:
local iAmerica = GameInfoTypes.CIVILIZATION_AMERICA
local 	tWashingtonIDs = {}
local tDummyBuilding = {GameInfoTypes.BUILDING_AMERICA_FRIENDSHIP_DUMMYBUILDING_1,GameInfoTypes.BUILDING_AMERICA_FRIENDSHIP_DUMMYBUILDING_2,GameInfoTypes.BUILDING_AMERICA_FRIENDSHIP_DUMMYBUILDING_4,GameInfoTypes.BUILDING_AMERICA_FRIENDSHIP_DUMMYBUILDING_8,GameInfoTypes.BUILDING_AMERICA_FRIENDSHIP_DUMMYBUILDING_16,GameInfoTypes.BUILDING_AMERICA_FRIENDSHIP_DUMMYBUILDING_32}
--this allows the bonus to 'stack' to a maximum of 63 Washingtons (which 'coincedentally' is the absolute modded maximum! yay for bits!)
--The idea here is that each dummy is defined (in XML) with the bonus for _X number of Washingtons (meaning that _BUILDING_1 means the bonus for 1 Washington, _BUILDING_2 the bonus for 2 Washingtons, etc.)
local bWashingtonWasFound = false

function toBits(num)--UltimatePotato's toBits (with minor changes)
    -- returns a table of bits, least significant first.
	t={} -- will contain the bits
    while num>0 do
        local rest=math.fmod(num,2)
        t[#t+1]=rest
        num=(num-rest)/2
    end
	
	for i=1,8,1 do
		if(t[i]==nil)then
			t[i]=0
		end
	end

    return t
end


local function OnPlayerDoTurn(iPlayer)
	local pPlayer = Players[iPlayer]
	if pPlayer:IsAlive() then
                local iNumWashingtonDoF = 0
                for iWashington,_ in pairs(tWashingtonIDs) do --loop through our tWashingtonIDs table
                     
                     if pPlayer:GetDoFCounter(iWashington) >= 1 then	     
                          iNumWashingtonDoF  = iNumWashingtonDoF + 1
                     end
                end
                local tDummies = toBits(iNumWashingtonDoF) --use of this function allows us to get maximum Washingtons for the minimum amount of dummies
                local pTheirCapital = pPlayer:GetCapitalCity()
                for i=1,6,1 do
		      pTheirCapital:SetNumRealBuilding(tDummyBuilding[i] , tDummies[i])
                end
	end
end

for iPlayer = 0, GameDefines.MAX_MAJOR_CIVS - 1, 1 do
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() == iAmerica then
		tWashingtonIDs[iPlayer] = iPlayer --store the ID of this Washington in the tWashingtonIDs-table
                bWashingtonWasFound = true
	end
end

if bWashingtonWasFound then
     GameEvents.PlayerDoTurn.Add ( OnPlayerDoTurn )
end
 
Oh, bueno! I'll be sure to give some feedback after I've tested it to see if it works properly.
 
Hello. I've what I hope is a simple request. I need to be able to choose a random great work of art/artifact in a given city, and move it to the city of another player. What I'm missing is whatever functions or calls within the City class I need to get those great works (since I think most of the great work related functions aren't on the lua reference; pCity:GetNumGreatWorksInBuilding comes to mind). I can probably do most everything else, once I have the way to get the great works in the first place, except probably whatever I need to call to then move that great work to another city. Ideally, there would be ways of telling if there is a valid great work of art/artifact in the city, and if a city has room for another great work of art/artifact, that take less time and resources than getting the whole list of works to choose from or anything like that.

Thanks in advance for any help!
 
Hello. I've what I hope is a simple request. I need to be able to choose a random great work of art/artifact in a given city, and move it to the city of another player. What I'm missing is whatever functions or calls within the City class I need to get those great works (since I think most of the great work related functions aren't on the lua reference; pCity:GetNumGreatWorksInBuilding comes to mind). I can probably do most everything else, once I have the way to get the great works in the first place, except probably whatever I need to call to then move that great work to another city. Ideally, there would be ways of telling if there is a valid great work of art/artifact in the city, and if a city has room for another great work of art/artifact, that take less time and resources than getting the whole list of works to choose from or anything like that.

Thanks in advance for any help!

Try this thread where William Howard has extracted all the available LUA methods for cities, player, etc., and printed out the names of the various methods, what parameters they take, what kind of data they give, etc., as if it were xml "code" to make it both up to date and searchable. He has also has the same data as spreadsheets, if I recall.

http://forums.civfanatics.com/showthread.php?t=558353
 
Most of the code you'll need to borrow is in CultureOverview.lua

The function to swap works is Network.SendSwapGreatWorks() - the details of the parameters can be found in CultureOverview.lua
 
My god, I love you guys. That's exactly what I needed. And the function I need for moving a great work without swapping another with it I believe is Network.SendMoveGreatWorks.
 
Well, I'm bringing my civ 5 projects to a close, but to do so I'm going to need one final request dump :crazyeye:

  • Sources of deer worked by a city owned by CIVILIZATION_SENSHI_NENETS cause unfilled Great Work of Music slots within the city to act as if they were filled. (To do this, at least by my illogical reckoning, you'd count the number of Deer worked by a city and the number of Great Work of Music slots within the city, find the smaller number, and add that many copies of a dummy building into that city)
  • Over time, sources of Deer may appear on Snow tiles controlled by CIVILIZATION_SENSHI_NENETS
  • Whenever UNIT_SENSHI_TADIBYA is expended, check the tile it was expended on for IMPROVEMENT_SENSHI_SPAWNDEER. If it's there, add a source of deer to the tile and remove the improvement from it. Alternatively, this search could take place at the start of a player's turn
  • Whenever UNIT_SENSHI_SAMOYED is expended, check the tile it was expended on for IMPROVEMENT_SENSHI_MOVEDEER. If it's there, remove any resource from the tile, and check for the closest unimproved, non-Snow land tile within the territory of CIVILIZATION_SENSHI_NENETS and spawn a source of Deer there. If no such tile is available, do nothing. In both cases, remove IMPROVEMENT_SENSHI_MOVEDEER from the original tile.
  • When a unit controlled by CIVILIZATION_SENSHI_EVENKS is defeated, if it was on an unimproved or pillaged tile, spawn an IMPROVEMENT_SENSHI_BUGADYL on the tile.
  • If a unit begins a turn on IMPROVEMENT_SENSHI_BUGADYL, it takes a significant amount of damage and the improvement is removed
  • When a civilian unit begins its turn stacked with UNIT_SENSHI_REINDEER_ARCHER, it gains the Woodsman promotion. Otherwise, remove the promotion.
  • When a Missionary or Inquisitor belonging to CIVILIZATION_SENSHI_EVENKS begins its turn on an IMPROVEMENT_SENSHI_SHEVENCHEDEK, it receives the Medic I promotion if it does not already have it. This promotion is permanent.

It's a lot, and if anything is convoluted, illogical or impossible, just let me know. Still, if it gets done I'll be incapable of expressing the full extent of my gratitude ;)
 
Well, I'm bringing my civ 5 projects to a close

Does this mean no Lorraine? :(

Sources of deer worked by a city owned by CIVILIZATION_SENSHI_NENETS cause unfilled Great Work of Music slots within the city to act as if they were filled. (To do this, at least by my illogical reckoning, you'd count the number of Deer worked by a city and the number of Great Work of Music slots within the city, find the smaller number, and add that many copies of a dummy building into that city)

That would mostly work, except note that you'd need to use binary logic for tourism, since multiply copies of the same building don't stack their tourism outputs.

Over time, sources of Deer may appear on Snow tiles controlled by CIVILIZATION_SENSHI_NENETS

You mean something like X% chance per tile per turn?

Whenever UNIT_SENSHI_TADIBYA is expended, check the tile it was expended on for IMPROVEMENT_SENSHI_SPAWNDEER. If it's there, add a source of deer to the tile and remove the improvement from it. Alternatively, this search could take place at the start of a player's turn
Whenever UNIT_SENSHI_SAMOYED is expended, check the tile it was expended on for IMPROVEMENT_SENSHI_MOVEDEER. If it's there, remove any resource from the tile, and check for the closest unimproved, non-Snow land tile within the territory of CIVILIZATION_SENSHI_NENETS and spawn a source of Deer there. If no such tile is available, do nothing. In both cases, remove IMPROVEMENT_SENSHI_MOVEDEER from the original tile.

Do these units create these improvements? If not, these could be troublesome; the GreatPersonExpended event doesn't give tile coordinates.

When a unit controlled by CIVILIZATION_SENSHI_EVENKS is defeated, if it was on an unimproved or pillaged tile, spawn an IMPROVEMENT_SENSHI_BUGADYL on the tile.

Haven't tested this, but:
Code:
GameEvents.UnitPrekill.Add(function(iPlayer, iUnitID, iUnitType, iX, iY, bDelay, iKillingPlayer)
	if Players[iKillingPlayer] and Players[iPlayer].type == GameInfoTypes.CIVILIZATION_SENSHI_EVENKS then
		local pPlot = Map.GetPlot(iX, iY)
		if pPlot:GetOwner() == iPlayer and (pPlot:GetImprovementType() == -1 or pPlot:IsImprovementPillaged()) then
			pPlot:SetImprovementType(GameInfoTypes.IMPROVEMENT_SENSHI_BUGADYL)
			pPlot:SetImprovementPillaged(false)
		end
	end
end)
I'm assuming you only want this to happen in Evenk territory; if not, remove the "pPlot:GetOwner() == iPlayer and " from the fourth line.

If a unit begins a turn on IMPROVEMENT_SENSHI_BUGADYL, it takes a significant amount of damage and the improvement is removed

Code:
GameEvents.PlayerDoTurn.Add(function(iPlayer)
	for pUnit in Players[iPlayer]:Units() do
		local pPlot = pUnit:GetPlot()
		if pPlot:GetOwner() ~= iPlayer and pPlot:GetImprovementType() == GameInfoTypes.IMPROVEMENT_SENSHI_BUGADYL then
			pUnit:ChangeDamage(50,pPlot:GetOwner())
			pPlot:SetImprovementType(-1)
		end
	end
end)
Similarly, I assume you don't want this to happen if the unit is on a bugadyl in its own civ's territory; if I'm wrong, delete the "pPlot:GetOwner() ~= iPlayer and ", and probably the ",pPlot:GetOwner()" as well. Also I interpreted "a significant amount of damage" as 50; you may or may not wish to adjust this.

When a civilian unit begins its turn stacked with UNIT_SENSHI_REINDEER_ARCHER, it gains the Woodsman promotion. Otherwise, remove the promotion.

Code:
GameEvents.PlayerDoTurn.Add(function(iPlayer)
	for pUnit in Players[iPlayer]:Units() do
		if not pUnit:IsCombatUnit() then
			local pPlot = pUnit:GetPlot()
			local bStackedWithReindeer = false
			for i = 0, pPlotGetNumUnits()-1 do
				if pPlot:GetUnit(i):GetUnitType() == GameInfoTypes.UNIT_SENSHI_REINDEER_ARCHER then
					bStackedWithReindeer = true
					break
				end
			end
			if bStackedWithReindeer then
				pUnit:SetHasPromotion(GameInfoTypes.PROMOTION_WOODSMAN, true)
			else
				pUnit:SetHasPromotion(GameInfoTypes.PROMOTION_WOODSMAN, false)
			end
		end
	end
end)

I suggest using a mod-specific promotion that's identical to Woodsman, rather than Woodsman itself, to avoid compatibility issues with any other mod that gives Woodsman to civilian units (as this script would take it away unless they happen to be stacked with a Reindeer Archer).

When a Missionary or Inquisitor belonging to CIVILIZATION_SENSHI_EVENKS begins its turn on an IMPROVEMENT_SENSHI_SHEVENCHEDEK, it receives the Medic I promotion if it does not already have it. This promotion is permanent.

Code:
GameEvents.PlayerDoTurn.Add(function(iPlayer)
	for pUnit in Players[iPlayer]:Units() do
		if (pUnit:GetUnitType() == GameInfoTypes.UNIT_MISSIONARY or pUnit:GetUnitType() == GameInfoTypes.UNIT_INQUISITOR) and pUnit:GetPlot():GetImprovementType() == GameInfoTypes.IMPROVEMENT_SENSHI_SHEVENCHEDEK then
			pUnit:SetHasPromotion(GameInfoTypes.PROMOTION_MEDIC, true)
		end
	end
end)
 
Does this mean no Lorraine? :(

Wasn't in the cards, unfortunately. Still, there's always civ 6 wink wink nudge nudge

although I'm rather fond of the icon I randomly decided to do

That would mostly work, except note that you'd need to use binary logic for tourism, since multiply copies of the same building don't stack their tourism outputs.

Oh man, that's a shame... I guess I could just make 36 dummy buildings unless you know a better way

You mean something like X% chance per tile per turn?

Yeah. I guess maybe a 5% chance would be the most ideal, considering it's Snow of all things.

Do these units create these improvements? If not, these could be troublesome; the GreatPersonExpended event doesn't give tile coordinates.

They do.

Spoiler :
Haven't tested this, but:
Code:
GameEvents.UnitPrekill.Add(function(iPlayer, iUnitID, iUnitType, iX, iY, bDelay, iKillingPlayer)
	if Players[iKillingPlayer] and Players[iPlayer].type == GameInfoTypes.CIVILIZATION_SENSHI_EVENKS then
		local pPlot = Map.GetPlot(iX, iY)
		if pPlot:GetOwner() == iPlayer and (pPlot:GetImprovementType() == -1 or pPlot:IsImprovementPillaged()) then
			pPlot:SetImprovementType(GameInfoTypes.IMPROVEMENT_SENSHI_BUGADYL)
			pPlot:SetImprovementPillaged(false)
		end
	end
end)
I'm assuming you only want this to happen in Evenk territory; if not, remove the "pPlot:GetOwner() == iPlayer and " from the fourth line.



Code:
GameEvents.PlayerDoTurn.Add(function(iPlayer)
	for pUnit in Players[iPlayer]:Units() do
		local pPlot = pUnit:GetPlot()
		if pPlot:GetOwner() ~= iPlayer and pPlot:GetImprovementType() == GameInfoTypes.IMPROVEMENT_SENSHI_BUGADYL then
			pUnit:ChangeDamage(50,pPlot:GetOwner())
			pPlot:SetImprovementType(-1)
		end
	end
end)
Similarly, I assume you don't want this to happen if the unit is on a bugadyl in its own civ's territory; if I'm wrong, delete the "pPlot:GetOwner() ~= iPlayer and ", and probably the ",pPlot:GetOwner()" as well. Also I interpreted "a significant amount of damage" as 50; you may or may not wish to adjust this.



Code:
GameEvents.PlayerDoTurn.Add(function(iPlayer)
	for pUnit in Players[iPlayer]:Units() do
		if not pUnit:IsCombatUnit() then
			local pPlot = pUnit:GetPlot()
			local bStackedWithReindeer = false
			for i = 0, pPlotGetNumUnits()-1 do
				if pPlot:GetUnit(i):GetUnitType() == GameInfoTypes.UNIT_SENSHI_REINDEER_ARCHER then
					bStackedWithReindeer = true
					break
				end
			end
			if bStackedWithReindeer then
				pUnit:SetHasPromotion(GameInfoTypes.PROMOTION_WOODSMAN, true)
			else
				pUnit:SetHasPromotion(GameInfoTypes.PROMOTION_WOODSMAN, false)
			end
		end
	end
end)

I suggest using a mod-specific promotion that's identical to Woodsman, rather than Woodsman itself, to avoid compatibility issues with any other mod that gives Woodsman to civilian units (as this script would take it away unless they happen to be stacked with a Reindeer Archer).



Code:
GameEvents.PlayerDoTurn.Add(function(iPlayer)
	for pUnit in Players[iPlayer]:Units() do
		if (pUnit:GetUnitType() == GameInfoTypes.UNIT_MISSIONARY or pUnit:GetUnitType() == GameInfoTypes.UNIT_INQUISITOR) and pUnit:GetPlot():GetImprovementType() == GameInfoTypes.IMPROVEMENT_SENSHI_SHEVENCHEDEK then
			pUnit:SetHasPromotion(GameInfoTypes.PROMOTION_MEDIC, true)
		end
	end
end)

Thanks for all this! Much appreciated ;)
 
Spoiler :
Code:
------------------------------------------------------------------------------------------------------------------------------------------------
--Senshi Deer and Music Slots
------------------------------------------------------------------------------------------------------------------------------------------------

include("CityNearbyMapDatas.lua")

local tBuildingsWithGreatWorkSlotsOfType = {}
local sMusicType = "GREAT_WORK_SLOT_MUSIC"
local sLitType = "GREAT_WORK_SLOT_LITERATURE"
local sArtType = "GREAT_WORK_SLOT_ART_ARTIFACT"
local iCulturePerGreatWork = GameDefines.BASE_CULTURE_PER_GREAT_WORK
local iTourismPerGreatWork = GameDefines.BASE_TOURISM_PER_GREAT_WORK

----------------------------------------------------------------------------------------------------------------------------
--You need to make the buildings listed here in your xml
--Change the names as desired in the xml but make sure you update these names
--All of the Tourism Dummies Must belong to their own building-class and must be the default building within the class
----------------------------------------------------------------------------------------------------------------------------

local iRequiredCivilization = GameInfoTypes.CIVILIZATION_SENSHI_NENETS
local iCultureDummy = GameInfoTypes.BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE
local tTourismMakerDummies = { [1] = GameInfoTypes.BUILDING_DUMMY_TOURISM_1,
	[2] = GameInfoTypes.BUILDING_DUMMY_TOURISM_2,
	[4] = GameInfoTypes.BUILDING_DUMMY_TOURISM_4,
	[8] = GameInfoTypes.BUILDING_DUMMY_TOURISM_8,
	[16] = GameInfoTypes.BUILDING_DUMMY_TOURISM_16,
	[32] = GameInfoTypes.BUILDING_DUMMY_TOURISM_32,
	[64] = GameInfoTypes.BUILDING_DUMMY_TOURISM_64,
	[128] = GameInfoTypes.BUILDING_DUMMY_TOURISM_128 }

--==============================================================================================================================================
--You should not really need to make changes below this line
--==============================================================================================================================================

for Building in DB.Query("SELECT ID, BuildingClass, GreatWorkSlotType, GreatWorkCount FROM Buildings WHERE GreatWorkCount > 0") do
	if not tBuildingsWithGreatWorkSlotsOfType[Building.GreatWorkSlotType] then
		tBuildingsWithGreatWorkSlotsOfType[Building.GreatWorkSlotType] = {}
	end
	tBuildingsWithGreatWorkSlotsOfType[Building.GreatWorkSlotType][Building.ID] = {BuildingClass = GameInfoTypes[Building.BuildingClass], GreatWorkCount = Building.GreatWorkCount}
end
function ReturnNumberGreatWorksOfTypeInCity(pCity, sGreatWorkType)
	local iNumberGreatWorksOfType, iNumberEmptySlots = 0, 0
	if pCity:GetNumGreatWorks() > 0 then
		for Building,DataTable in pairs(tBuildingsWithGreatWorkSlotsOfType[sGreatWorkType]) do
			if pCity:IsHasBuilding(Building) then
				iNumberGreatWorksOfType = iNumberGreatWorksOfType + pCity:GetNumGreatWorksInBuilding(DataTable.BuildingClass)
				iNumberEmptySlots = iNumberEmptySlots + (DataTable.GreatWorkCount - pCity:GetNumGreatWorksInBuilding(DataTable.BuildingClass))
			end
		end
	end
	return iNumberGreatWorksOfType, iNumberEmptySlots
end
function SetUnFilledCityMusicSlotsEffects(iPlayer, pPlayer, pCity, iNumberEmptySlots, iNumberDeer)
	local iEffectAmount = 0
	if iNumberEmptySlots > 0 then
		if iNumberEmptySlots > iNumberDeer then
			iEffectAmount = iNumberDeer
		else
			iEffectAmount = iNumberEmptySlots
		end
	end
	pCity:SetNumRealBuilding(iCultureDummy, (iEffectAmount * iCulturePerGreatWork))
	local iTourismValue = iEffectAmount * iTourismPerGreatWork
	--print("tTourismMakerDummies cancel")
	for k,v in pairs(tTourismMakerDummies) do
		pCity:SetNumRealBuilding(v, 0)
	end
	if iTourismValue > 0 then
		if iTourismValue > 255 then
			iTourismValue = 255
		end
		local iPow = 1
		while (iTourismValue > 0) do
			if (iTourismValue % 2 == 1) then
				pCity:SetNumRealBuilding(tTourismMakerDummies[iPow], 1)
			end
			iPow = iPow * 2
			iTourismValue = math.floor(iTourismValue / 2)
		end
	end
end

function SenshiNenetsEmptytMusicSlots(iPlayer)
	local pPlayer = Players[iPlayer]
	if pPlayer:GetCivilizationType() ~= iRequiredCivilization then return end
	print("GreatWorksSlotsInCitiesUtilities processing turn for player " .. iPlayer .. " who is being used as " .. pPlayer:GetName())
	for pCity in pPlayer:Cities() do
		local tNearbyDatas = GetCityMapDatas(pCity, "Resources")
		local iNumberDeer = GetNumCityWorkingResourcePlots(tNearbyDatas, GameInfoTypes.RESOURCE_DEER)
		local iNumberGreatWorksOfType, iNumberEmptySlots = ReturnNumberGreatWorksOfTypeInCity(pCity, sMusicType)
		SetUnFilledCityMusicSlotsEffects(iPlayer, pPlayer, pCity, iNumberEmptySlots, iNumberDeer)
	end
end
GameEvents.PlayerDoTurn.Add(SenshiNenetsEmptytMusicSlots)

print("SenshiNenetsEmptytMusicSlots.lua loaded to the end")
You will need:
  1. To define the dummy buildings and their building-classes for the Tourism Dummies and the Culture Dummy. Define the Tourism dummies as like shown in this thread except be sure to specify that the Dummy building is the default from within its class. For extra insurance you might want to call the Tourism Dummies and thier classes something like BUILDING_DUMMY_TOURISM_1_SENSHI, etc., instead of just BUILDING_DUMMY_TOURISM_1. Just be sure that what is in the XML matches with the lua here:
    Code:
    local tTourismMakerDummies = { [1] = GameInfoTypes.BUILDING_DUMMY_TOURISM_1,
    	[2] = GameInfoTypes.BUILDING_DUMMY_TOURISM_2,
    	[4] = GameInfoTypes.BUILDING_DUMMY_TOURISM_4,
    	[8] = GameInfoTypes.BUILDING_DUMMY_TOURISM_8,
    	[16] = GameInfoTypes.BUILDING_DUMMY_TOURISM_16,
    	[32] = GameInfoTypes.BUILDING_DUMMY_TOURISM_32,
    	[64] = GameInfoTypes.BUILDING_DUMMY_TOURISM_64,
    	[128] = GameInfoTypes.BUILDING_DUMMY_TOURISM_128 }
  2. Also you need to make a dummy for the Culture that a great work provides. You need to make this dummy building yield 1 Culture per turn. Then just rename in the lua as needed here
    Code:
    local iCultureDummy = GameInfoTypes.BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE
  3. You need the CityNearbyMapDatas.lua file found in this handler. Grab the "mod" from the linked handler, and add the CityNearbyMapDatas.lua file to your mod, and set it as ImportIntoVFS=true
  4. Make sure to set all of the dummy buildings with
    Code:
    <NeverCapture>true</NeverCapture>
    UltimatePotato shows to do this for the Tourism dummies but you also need to do this for the Culture Dummy.
  5. I would make the xml as follows for the needed dummies (to address issues #1, #2, and #4, excepting issues of renaming slightly):
    Spoiler :
    Code:
    <GameData>
    	<BuildingClasses>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_1</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_1</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_1</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_2</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_2</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_2</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_4</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_4</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_4</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_8</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_8</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_8</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_16</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_16</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_16</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_32</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_32</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_32</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_64</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_64</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_64</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_DUMMY_TOURISM_128</Type>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_128</Description>
    			<DefaultBuilding>BUILDING_DUMMY_TOURISM_128</DefaultBuilding>
    		</Row>
    		<Row>
    			<Type>BUILDINGCLASS_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</Type>
    			<Description>TXT_KEY_BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</Description>
    			<DefaultBuilding>BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</DefaultBuilding>
    		</Row>
    	</BuildingClasses>
    	<Buildings>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_1</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_1</BuildingClass>
    			<TechEnhancedTourism>1</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_1</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_2</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_2</BuildingClass>
    			<TechEnhancedTourism>2</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_2</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_4</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_4</BuildingClass>
    			<TechEnhancedTourism>4</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_4</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_8</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_8</BuildingClass>
    			<TechEnhancedTourism>8</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_8</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_16</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_16</BuildingClass>
    			<TechEnhancedTourism>16</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_16</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_32</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_32</BuildingClass>
    			<TechEnhancedTourism>32</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_32</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_64</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_64</BuildingClass>
    			<TechEnhancedTourism>64</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_64</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_DUMMY_TOURISM_128</Type>
    			<BuildingClass>BUILDINGCLASS_DUMMY_TOURISM_128</BuildingClass>
    			<TechEnhancedTourism>128</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_DUMMY_TOURISM_128</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    		<Row>
    			<Type>BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</Type>
    			<BuildingClass>BUILDINGCLASS_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</BuildingClass>
    			<TechEnhancedTourism>128</TechEnhancedTourism>
    			<GreatWorkCount>-1</GreatWorkCount>
    			<FaithCost>-1</FaithCost>
    			<Cost>-1</Cost>
    			<PrereqTech>NULL</PrereqTech>
    			<Description>TXT_KEY_BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</Description>
    			<MinAreaSize>-1</MinAreaSize>
    			<NeverCapture>true</NeverCapture>
    			<HurryCostModifier>0</HurryCostModifier>
    			<IconAtlas>CITIZEN_ATLAS</IconAtlas>
    			<PortraitIndex>5</PortraitIndex>
    		</Row>
    	</Buildings>
    	<Building_YieldChanges>
    		<Row>
    			<BuildingType>BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE</BuildingType>
    			<YieldType>YIELD_CULTURE</YieldType>
    			<Yield>1</Yield>
    		</Row>
    	</Building_YieldChanges>
    	<Language_en_US>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_1">
    			<Text>Tourism 1</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_2">
    			<Text>Tourism 2</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_4">
    			<Text>Tourism 4</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_8">
    			<Text>Tourism 8</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_16">
    			<Text>Tourism 16</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_32">
    			<Text>Tourism 32</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_64">
    			<Text>Tourism 64</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_DUMMY_TOURISM_128">
    			<Text>Tourism 128</Text>
    		</Row>
    		<Row Tag="TXT_KEY_BUILDING_SOME_CULTURE_DUMMY_THAT_ADDS_1_CULTURE">
    			<Text>1 Culture</Text>
    		</Row>
    	</Language_en_US>
    </GameData>
 
Back
Top Bottom