• Civilization 7 has been announced. For more info please check the forum here .

RFC Classical World

the whole section starting with "if iReligion == con.iChristianity:" is the removal of Hellenism or Manichaeism. if you don't want the removal to happen then omit that whole section. you can also change the chance of it happening by changing the number following "if rndNum <= 66:"
 
Thats the thing though. I tested it and omitted the whole section but Christianity still displaced it, so this line does not affect displacement. Maybe it was something you put in while trying to make it work or something, but with the Christianity section removed Hellenism and Manichaeism will still normally be displaced around half the time.
 
Tried the Antigonids again. Is it normal that none of the successors start at war with each other? Also, I have a -2 malus with the two other successors due to religious persecution (in 320 BC). What's up with that?

EDIT: Antigonid UHVs a bit scrambled:

7 Wonder goal fails at 250 BC, so I believe it's been inverted with the palace goal. However, before 249 BC I had built a palace in Pella.
 
To make this game even more interesting, let's put some Passes in China.

Throughout Chinese history, some geographically important points usually played a very big role. They are called the "Passes", which are the must-pass places when you try to move or feed your troops. The hold and loss of a Pass could mean win or loss of a war.

Below are some of the Passes considered critical in ancient China:
http://en.wikipedia.org/wiki/Hangu_Pass
http://en.wikipedia.org/wiki/Yumen_Pass
http://en.wikipedia.org/wiki/Yanmen_Pass

The way to put a pass in the game is quite easy, as we have in this mod the best invention of all mods so far: the impassible forests, it's enough by adding two of them beside one tile of passible plain/hill.

As an experiment, I added all Passes I can think of in the save file attached (along with some other adjustments like waterways, coastlines, Xinjiang terrain and so on).
 

Attachments

  • Qin Shi Huang BC-0320.CivBeyondSwordSave
    251 KB · Views: 65
As an update on trying to learn how displacement works, I removed all of this:
Spoiler :
def spreadReligion(self, city, iReligion, textKey=False):

if city is None or city.isNone():
return -1

# do not spread the religion if the city already has it, or the owner is using Persecution civic
if city.isHasReligion(iReligion) or gc.getPlayer(city.getOwner()).getCivics(4) == con.iTheocracyCivic:
return -1

if iReligion == con.iChristianity:

if city.isHasReligion(con.iHellenism) and not city.isHolyCityByType(con.iHellenism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Hellenism')
if rndNum <= 66:
city.setHasReligion(con.iHellenism, False, False, False)

if city.isHasReligion(con.iManichaeism) and not city.isHolyCityByType(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)

if iReligion == con.iIslam:

if city.isHasReligion(con.iZoroastrianism) and not city.isHolyCityByType(con.iZoroastrianism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Zoroastrianism')
if rndNum <= 66:
city.setHasReligion(con.iZoroastrianism, False, False, False)

if city.isHasReligion(con.iManichaeism) and not city.isHolyCityByType(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)


# show the message about Jewish refugess if the religion is Judaism
if iReligion == con.iJudaism:
city.setHasReligion(iReligion, True, False, False)
if not textKey:
textKey = "TXT_KEY_MINOR_EVENT_JEWS"
szText = localText.getText(textKey, (city.getName(), ))
CyInterface().addMessage(city.getOwner(), False, con.iDuration, szText, "AS2D_BUILD_JEWISH", InterfaceMessageTypes.MESSAGE_TYPE_MAJOR_EVENT, gc.getReligionInfo(iReligion).getButton(), ColorTypes(con.iWhite), city.getX(), city.getY(), True, True)
else:
city.setHasReligion(iReligion, True, True, True)
return True


def removeReligion(self, city, iReligion):

if city is None: return -1
elif city.isNone(): return -1
elif not city.isHasReligion(iReligion): return -1

city.setHasReligion(iReligion, False, True, True)
return True


def onReligionSpread(self, iReligion, iOwner, city):

if iReligion == con.iChristianity:

if city.isHasReligion(con.iHellenism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Hellenism')
if rndNum <= 66:
city.setHasReligion(con.iHellenism, False, False, False)

if city.isHasReligion(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)

if iReligion == con.iIslam:

if city.isHasReligion(con.iZoroastrianism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Zoroastrianism')
if rndNum <= 66:
city.setHasReligion(con.iZoroastrianism, False, False, False)

if city.isHasReligion(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)

if city.isHasReligion(con.iBuddhism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iBuddhism, False, False, False)

if city.isHasReligion(con.iHellenism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iHellenism, False, False, False)



And religions were still displaced. Hellenism and Mani were still removed by Christianity and Islam. I am really confused; I have no idea what is really controlling this! I'm almost certain that Religions.py is the correct file too. I was only able to stop displacement by deleting nearly all the contents of the file.

And I just discovered that when I got 80% on the victory screen it was not a glitch. It says to raise it in CvVictoryScreen.py

And I found it. It seems that there are multiple instances that say what Christianity displaces, including this one I didn't notice.

Spoiler :
def onUnitSpreadReligionAttempt(self, argsList):
'Unit tries to spread religion to a city'
pUnit, iReligion, bSuccess = argsList


if bSuccess:
city = gc.getMap().plot(pUnit.getX(), pUnit.getY()).getPlotCity()
iPlayer = pUnit.getOwner()
if iPlayer >= con.iNumPlayers: return
iStateReligion = -1
if gc.getPlayer(iPlayer).getStateReligion() >= 0:
iStateReligion = gc.getPlayer(iPlayer).getStateReligion()

# Satavahana UP
if iPlayer == con.iSatavahana and iReligion in [con.iHinduism, con.iBuddhism] and city.getOwner() != con.iSatavahana:
apCityList = PyPlayer(iPlayer).getCityList()
for pyCity in apCityList:
pyCity.GetCy().changeCulture(con.iSatavahana, 20, True)

if iReligion == con.iChristianity:


if city.isHasReligion(con.iHellenism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Hellenism')
if rndNum <= 66:
city.setHasReligion(con.iHellenism, False, False, False)
for iBuildingLoop in range(gc.getNumBuildingInfos()):
if iBuildingLoop < con.iPlague:
if city.getNumRealBuilding(iBuildingLoop):
if gc.getBuildingInfo(iBuildingLoop).getPrereqReligion() == con.iHellenism:
city.setNumRealBuilding(iBuildingLoop, 0)

if city.isHasReligion(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)
for iBuildingLoop in range(gc.getNumBuildingInfos()):
if iBuildingLoop < con.iPlague:
if city.getNumRealBuilding(iBuildingLoop):
if gc.getBuildingInfo(iBuildingLoop).getPrereqReligion() == con.iManichaeism:
city.setNumRealBuilding(iBuildingLoop, 0)

if iReligion == con.iIslam:

if city.isHasReligion(con.iZoroastrianism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Zoroastrianism')
if rndNum <= 66:
city.setHasReligion(con.iZoroastrianism, False, False, False)
for iBuildingLoop in range(gc.getNumBuildingInfos()):
if iBuildingLoop < con.iPlague:
if city.getNumRealBuilding(iBuildingLoop):
if gc.getBuildingInfo(iBuildingLoop).getPrereqReligion() == con.iZoroastrianism:
city.setNumRealBuilding(iBuildingLoop, 0)

if city.isHasReligion(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)
for iBuildingLoop in range(gc.getNumBuildingInfos()):
if iBuildingLoop < con.iPlague:
if city.getNumRealBuilding(iBuildingLoop):
if gc.getBuildingInfo(iBuildingLoop).getPrereqReligion() == con.iManichaeism:
city.setNumRealBuilding(iBuildingLoop, 0)






This is the bare minimum the file can have in order for displacement to work.
Spoiler :
# Religions

from CvPythonExtensions import *
import Consts as con

# globals
gc = CyGlobalContext()
localText = CyTranslator()


class Religions:


#######################################
### Main methods (Event-Triggered) ###
#####################################


def removeReligion(self, city, iReligion):

if city is None: return -1
elif city.isNone(): return -1
elif not city.isHasReligion(iReligion): return -1

city.setHasReligion(iReligion, False, True, True)
return True


def onReligionSpread(self, iReligion, iOwner, city):

if iReligion == con.iChristianity:

if city.isHasReligion(con.iHellenism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Hellenism')
if rndNum <= 66:
city.setHasReligion(con.iHellenism, False, False, False)

if city.isHasReligion(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)

if iReligion == con.iIslam:

if city.isHasReligion(con.iZoroastrianism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Zoroastrianism')
if rndNum <= 66:
city.setHasReligion(con.iZoroastrianism, False, False, False)

if city.isHasReligion(con.iManichaeism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iManichaeism, False, False, False)

if city.isHasReligion(con.iBuddhism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iBuddhism, False, False, False)

if city.isHasReligion(con.iHellenism):
rndNum = gc.getGame().getSorenRandNum(100, 'remove Manichaeism')
if rndNum <= 66:
city.setHasReligion(con.iHellenism, False, False, False)

Now to test using it in the base game I've changed Hellenism to Hinduism as well as a few others to fit the original religions as well as reorganized the religions in the Consts file and removed the new religions. I've made a separate mod that is specifically for testing the python but I can't get displacement to work. Do you know how displacement could work in the base game of Beyond the Sword? It also seems if any python file is removed from the python folder, displacement stops working. I don't get that though?
 
OK, I just downloaded the latest version of this mod, and installed it the way that I normally would, and I get a couple of odd results. First, by using the WBSave 320BC map as a shortcut, I am automatically forced to "start game now!", which starts with me as the Antigonids. Otherwise, if I try to load the mod normally, thru BtS, the scenario folder is blank, and so I can't choose any scenarios or players. Any suggestions, or something I'm not doing right? The configuration that I'm using used to work for the version that I got about November of last year, but the newest version (as of Sept of this year), is not working. Help?
 
OK, I just downloaded the latest version of this mod, and installed it the way that I normally would, and I get a couple of odd results. First, by using the WBSave 320BC map as a shortcut, I am automatically forced to "start game now!", which starts with me as the Antigonids. Otherwise, if I try to load the mod normally, thru BtS, the scenario folder is blank, and so I can't choose any scenarios or players. Any suggestions, or something I'm not doing right? The configuration that I'm using used to work for the version that I got about November of last year, but the newest version (as of Sept of this year), is not working. Help?

Yeah, got the same error when running from shortcut. However, to make a mod with scenarios actually have the scenarios in it, you need to put it in the folder where you have all the core files (C:, Program Files or whatever), in the "Mods" folder,not the "My Documents" version with "MODS".
 
Try to put your game in English, Byzman. I had the same when my game was in french, and in english, it runs.
 
sprt, Chess was invented in India in IV century AD. Do you think it could be a good idea to represent them somehow in the mod?
 
Left: Amaravati has achieved Legendary Culture...and 20000% walls!

Right: Just in time :D
 

Attachments

  • 2014-11-05_00001.jpg
    2014-11-05_00001.jpg
    376.2 KB · Views: 179
  • 2014-11-05_00002.jpg
    2014-11-05_00002.jpg
    373.3 KB · Views: 167
In the last four games I played (regular download), the following civs didn't spawn (320 BC map): Tibet, Tang, Arabs.
 
Is sprt still around? Activity plummeted here :(
 
Well, at least the game is in a pretty good state. We'll see if the holiday season brings him back.

I don't think the game is at a good state. Playing past 400 AD with any of the greek civ has a bug which rename and relabeled as the Huns civ.
 
Download, and copy-paste these files in your RFCCW / assets / python folder. (Please keep a copy from your original files somewhere, just in case..).


I managed to correct the Huns bug, and the bug with the Antigonids' 2nd and 3rd UHVs not triggering.

I tested the 320 BC map, UHVs work fine!
For the Huns, I started a 220 AD game, since it was closer to the Huns spawn date. It worked too!
 

Attachments

  • bugFreeFiles.rar
    48.3 KB · Views: 75
Thank you, thank you, I downloaded and copy-paste the files I tested it and work great. No more hun bug lol. :D

Thank you for fixing the bug Sitalkas
 
Here! This will correctly spawn Attila as a Hun and not as a Numidian!
 

Attachments

  • Barbs.rar
    9.1 KB · Views: 50
Top Bottom