Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Religions
- -- Author: BigOz
- -- DateCreated: 22-Mar-15 2:44:56 PM
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishCatholicism()
- if Game.GetElapsedGameTurns() == 0 then
- function CreateCatholicHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- -- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- -- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- -- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- Network.SendFoundReligion(iPlayer, iReligion, sCustomName, iBelief1, iBelief2, iBelief3, iBelief4, iHolyCityX, iHolyCityY);
- Network.SendEnhanceReligion(iPlayer, iReligion, sCustomName, iBelief5, iBelief6, iHolyCityX, iHolyCityY);
- end
- function FoundCatholicism()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Vatican City" then
- CreateCatholicHolyCity(pCity, "RELIGION_CHRISTIANITY", "BELIEF_CATHOLIC_PANTHEON",
- "BELIEF_CATHOLIC_FOUNDER", "BELIEF_CATHOLIC_FOLLOWER_1", "BELIEF_CATHOLIC_FOLLOWER_2", "BELIEF_CATHOLIC_ENHANCER", "BELIEF_CATHOLIC_BONUS");
- print ("okay, Vatican is the Catholic holy city")
- return pCity
- end
- end
- end
- end
- end
- local pCatholicPlot = FoundCatholicism():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishCatholicism)
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishOrthodoxy()
- if Game.GetElapsedGameTurns() == 0 then
- function CreateOrthodoxyHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- end
- function FoundOrthodoxy()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Constantinople" then
- CreateOrthodoxyHolyCity(pCity, "RELIGION_ORTHODOXY", "BELIEF_ORTHODOX_PANTHEON",
- "BELIEF_ORTHODOX_FOUNDER", "BELIEF_ORTHODOX_FOLLOWER_1", "BELIEF_ORTHODOX_FOLLOWER_2", "BELIEF_ORTHODOX_ENHANCER");
- print ("okay, Constantinople is the Eastern Orthodoxy holy city")
- return pCity
- end
- end
- end
- end
- end
- local pOrthodoxyPlot = FoundOrthodoxy():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishOrthodoxy)
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishSunni()
- if Game.GetElapsedGameTurns() == 0 then
- function CreateSunniHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- end
- function FoundSunni()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Cairo" then
- CreateOrthodoxyHolyCity(pCity, "RELIGION_ISLAM", "BELIEF_SUNNI_PANTHEON",
- "BELIEF_SUNNI_FOUNDER", "BELIEF_SUNNI_FOLLOWER_1", "BELIEF_SUNNI_FOLLOWER_2", "BELIEF_SUNNI_ENHANCER");
- print ("okay, Cairo is the Sunni Islamic holy city")
- return pCity
- end
- end
- end
- end
- end
- local pSunniPlot = FoundSunni():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishSunni)
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishShia()
- if Game.GetElapsedGameTurns() == 0 then
- function CreateShiaHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- end
- function FoundShia()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Marrakech" then
- CreateOrthodoxyHolyCity(pCity, "RELIGION_ZOROASTRIANISM", "BELIEF_SHIA_PANTHEON",
- "BELIEF_SHIA_FOUNDER", "BELIEF_SHIA_FOLLOWER_1", "BELIEF_SHIA_FOLLOWER_2", "BELIEF_SHIA_ENHANCER");
- print ("okay, Marrakech is the Shia Islamic holy city")
- return pCity
- end
- end
- end
- end
- end
- local pShiaPlot = FoundShia():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishShia)
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishJudaism()
- if Game.GetElapsedGameTurns() == 0 then
- function CreateJudaismHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- end
- function FoundJudaism()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Warsaw" then
- CreateOrthodoxyHolyCity(pCity, "RELIGION_JUDAISM", "BELIEF_JEWISH_PANTHEON",
- "BELIEF_JEWISH_FOUNDER", "BELIEF_JEWISH_FOLLOWER_1", "BELIEF_JEWISH_FOLLOWER_2", "BELIEF_JEWISH_ENHANCER");
- print ("okay, Warsaw is the Jewish holy city")
- return pCity
- end
- end
- end
- end
- end
- local pJudaismPlot = FoundJudaism():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishJudaism)
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishDruidism()
- if Game.GetElapsedGameTurns() == 0 then
- function CreateDruidismHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- end
- function FoundDruidism()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Edinburgh" then
- CreateOrthodoxyHolyCity(pCity, "RELIGION_BUDDHISM", "BELIEF_DRUIDISM_PANTHEON",
- "BELIEF_DRUIDISM_FOUNDER", "BELIEF_DRUIDISM_FOLLOWER_1", "BELIEF_DRUIDISM_FOLLOWER_2", "BELIEF_DRUIDISM_ENHANCER");
- print ("okay, Edinburgh is Druidic holy city")
- return pCity
- end
- end
- end
- end
- end
- local pDruidismPlot = FoundDruidism():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishDruidism)
- --------------------------------------------------------------
- -- Find Berlin player and found Christianity in their city, returning the city
- function EstablishPaganism()
- if Game.GetElapsedGameTurns() == 0 then
- function CreatePaganismHolyCity(pCity, religion, pantheonBelief, founderBelief, followerBelief, followerBelief2, enhancerBelief)
- local iPlayer = pCity:GetOwner()
- local iReligion = GameInfoTypes[religion]
- -- Optional extra beliefs
- local iBelief4 = followerBelief2 and GameInfoTypes[followerBelief2] or -1
- local iBelief5 = enhancerBelief and GameInfoTypes[enhancerBelief] or -1
- Game.FoundPantheon(iPlayer, GameInfoTypes[pantheonBelief])
- Game.FoundReligion(iPlayer, iReligion, nil, GameInfoTypes[founderBelief], GameInfoTypes[followerBelief], -1, -1, pCity)
- Game.EnhanceReligion(iPlayer, iReligion, GameInfoTypes[followerBelief2], GameInfoTypes[enhancerBelief]);
- end
- function FoundPaganism()
- for iPlayer=0, GameDefines.MAX_CIV_PLAYERS - 1 do
- local pPlayer = Players[iPlayer]
- if (pPlayer:IsEverAlive()) then
- for pCity in pPlayer:Cities() do
- -- City exists and has the proper name?
- if pCity ~= nil and pCity:GetName() == "Moscow" then
- CreateOrthodoxyHolyCity(pCity, "RELIGION_CONFUCIANISM", "BELIEF_PAGAN_PANTHEON",
- "BELIEF_PAGAN_FOUNDER", "BELIEF_PAGAN_FOLLOWER_1", "BELIEF_PAGAN_FOLLOWER_2", "BELIEF_PAGAN_ENHANCER");
- print ("okay, Moscow is Pagan holy city")
- return pCity
- end
- end
- end
- end
- end
- local pPaganismPlot = FoundPaganism():Plot()
- end
- end
- Events.SequenceGameInitComplete.Add(EstablishPaganism)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement