Limited Religions

I just checked BUG 4.4's Python folder, and I don't see that they use/change CvGameUtils.py file. So, there shouldn't be any changes need to be made, except copying the CvGameUtils.py from Limited Religion to BUG's Python folder.

Out of curiousity, what is WoC version? If I want to merge it with another mod, should I use Standard or WoC? What are the differences?
 
I just checked BUG 4.4's Python folder, and I don't see that they use/change CvGameUtils.py file. So, there shouldn't be any changes need to be made, except copying the CvGameUtils.py from Limited Religion to BUG's Python folder.

Out of curiousity, what is WoC version? If I want to merge it with another mod, should I use Standard or WoC? What are the differences?

Check out this link to answer your questions concerning WoC:

http://forums.civfanatics.com/showthread.php?t=285856
 
Ok. Then I am sure the one I need (and use) is the Standard one.

I posted a thread in BUG forum about this issue, and what I've done to merge the mod. It was suggested something may be firing onTechAcquired even twice. Do you have any idea what possibly may be the cause of it? As far as I know I did not add another onTechAcquired event at all.
 
I assuming the line of code that gives religion to a player is the following:
Code:
pPlayer.foundReligion(i,i,True)

It exists in onTechAcquired event in CvEventManager.py, and I found that it also exists in foundReligionCallback in CvScreenInterface.py. What does foundReligionCallback do, and why it also call that same line of code that gives religion to a player? Or, am I wrong in my assumption?
 
I assuming the line of code that gives religion to a player is the following:
Code:
pPlayer.foundReligion(i,i,True)

It exists in onTechAcquired event in CvEventManager.py, and I found that it also exists in foundReligionCallback in CvScreenInterface.py. What does foundReligionCallback do, and why it also call that same line of code that gives religion to a player? Or, am I wrong in my assumption?

The code in the foundReligionCallback in the CvScreenInterface.py file alows the human player to receive the religion selected from the popup menu. It has to be there or it won't work. The code in the onTechAcquired function allows the computer to select a religion for you or the AI player in all other scenarios.
 
Ok. Then I am sure the one I need (and use) is the Standard one.

I posted a thread in BUG forum about this issue, and what I've done to merge the mod. It was suggested something may be firing onTechAcquired even twice. Do you have any idea what possibly may be the cause of it? As far as I know I did not add another onTechAcquired event at all.


Remember you wanted to limit each civ to founding two religions?

Since I want to allow a civ to be limited to founding 2 religions.

I think that is the cause. I would remove the untested change I recommended. That way you will go back to founding only one religion per civ, as the mod was originally intended.
 
Actually, I did revert to the original code already (limit only 1 religion found per civ) since I found the issue somehow I got two religions when discovering a tech. So far, I am at loss and about to give up :(

Never give up! If you can post your mod, I'll look at it and see what I can do.
 
I am working with TAM mod, but the problem exists only when BUG mod is involved. Basically if TAM mod + LR modcomp, no issue. BUG mod + LR modcomp, regardless of TAM mod is in the equation or not, getting 2 religion from a tech. The BUG mod I am using is version 4.4.

I am attaching my merge of BUG mod + LR modcomp. Thanks for sticking around to help :)
 

Attachments

  • BUG Mod 4.4.zip
    2.8 MB · Views: 92
I am working with TAM mod, but the problem exists only when BUG mod is involved. Basically if TAM mod + LR modcomp, no issue. BUG mod + LR modcomp, regardless of TAM mod is in the equation or not, getting 2 religion from a tech. The BUG mod I am using is version 4.4.

I am attaching my merge of BUG mod + LR modcomp. Thanks for sticking around to help :)

I believe you are correct! So. What you need to do is run the WoC version of Limited Religions. This file tested OK. :king:


Orion Veteran :cool:
 

Attachments

  • BUG_LR.zip
    2.5 MB · Views: 109
Thank you very much, OrionVeteran. I am going to check this one out. I owe you one :)

EDIT: Just a quick questions. So with the WoC version, you simply copy this modcomp into the OrionMods folder, so there's no need to change CvEventManager.py? I noticed that EntryPoints\CvScreenInterface.py still needs to be merged, as well as XML files copied to XML folders. I am still checking the files for any needed changes. But if you can confirm what I have found out, that'd be great.

EDIT 2: I tested it, and it worked great. I also made a modified version so it allows up to 2 religions to be found per civ, which works awesome too! :)
 
Thank you very much, OrionVeteran. I am going to check this one out. I owe you one :)

EDIT: Just a quick questions. So with the WoC version, you simply copy this modcomp into the OrionMods folder, so there's no need to change CvEventManager.py? I noticed that EntryPoints\CvScreenInterface.py still needs to be merged, as well as XML files copied to XML folders. I am still checking the files for any needed changes. But if you can confirm what I have found out, that'd be great.

EDIT 2: I tested it, and it worked great. I also made a modified version so it allows up to 2 religions to be found per civ, which works awesome too! :)

The only files that needed to be merged with a virgin copy of BUG4.4 is the CvScreensInterface.py file and the init.xml file. All the rest were copy and paste. Now you understand why I use WoC modules. ;)

Orion Veteran :cool:
 
Just so you know, one problem you will have with doing this all in Python is that AIs will not know to put less value on techs they're considering researching if the religion in them has already been founded, or if they're no longer eligible to found one themselves. (One of several reasons I did this in the SDK when I did it a year and a half ago, heh.)
 
Just so you know, one problem you will have with doing this all in Python is that AIs will not know to put less value on techs they're considering researching if the religion in them has already been founded, or if they're no longer eligible to found one themselves. (One of several reasons I did this in the SDK when I did it a year and a half ago, heh.)

6 of the 7 religious techs enable the possibility for the AI to produce a new wonder. In your mod, the AI now puts "less value" on those techs. Hmmm. Sounds like a huge exploit to allow you to build those wonders the AI now skips over. I say No! :nono: Those religious techs are just as valuable to the AI, whether a religion is received or not.

Respectfully,

Orion Veteran :cool:
 
Those religious techs are just as valuable to the AI, whether a religion is received or not.

Umm... no... they are valuable by precisely their full amount (which includes the values of units, wonders, religions, and everything else that is unlocked, added together), minus the religion which cannot be founded.

Every new ability, every benefit, in the game has a value. They are actually coded numerically (in the XML for units and in the SDK for everything else) in a variety of ways. One can debate the correctness of those values, but it is silly to say that a tech is still worth 100% as much overall when ONE of the benefits of the tech, not all of them, no longer applies. Please keep in mind, each tech that is chosen to research also comes at the cost of not choosing other techs as the current one. Perhaps losing the religion puts that other tech they were eyeing just over the top... Or perhaps the value of the wonders still outweighs any other option they have and they will research it anyway. Both are possible, but the AI should be free to decide this for itself as intelligently as a human would.

(Techs with wonders are actually valued more highly numerically by the AIs in my mod than in vanilla and other mods btw; I had a heated discussion with some people in the Better BTS AI forum about that a few months ago heh.)

It is not a game-breaking drawback to your component, but it is not ideal. AIs still think they're getting religions, in addition to everything else, with these techs, and are planning their research accordingly. It affects not only their current research but their directed path, up to one or two tech columns deeper in with the vanilla code, I forget.

Since this particular feature was not one of my more recent things, the code has been available this whole time over in my MongooseSDK thread btw (look for ReligionMod down near the bottom, and in the source). Merging SDK components is certainly more complicated of course; just pointing out the option. :)
 
SDK is out of my league at the moment. So, I am content with just Python/XML fix. Perhaps I may look at it when I have more time to spend.

For all intent and purpose, it's so that religions are more spread out among the players instead of gobbled by one particular civ. This creates an interesting diplomatic situation when you are playing against 18+ civs. No more, everyone loves everyone else (except sometimes there's the black sheep who got kicked around by the rest) kind of situation.
 
For all intent and purpose, it's so that religions are more spread out among the players instead of gobbled by one particular civ. This creates an interesting diplomatic situation when you are playing against 18+ civs. No more, everyone loves everyone else (except sometimes there's the black sheep who got kicked around by the rest) kind of situation.

Yep, that's precisely why I did this back when I did, too. Separately from diplomatic considerations, and perhaps even more importantly, I found the potential gold income from owning more than a couple of Shrines to be overwhelmingly powerful as well.

Plus it pretty much pre-determines the research order / tech path the person going for all the religions has to follow for the first third of the game, and I didn't like that; the many options and decisions that exist in the tech tree should always be available.

(Also edited my previous post to be a little more clear, and to add some information. :))
 
hey o"v,

i just wanted to note that i tried this mod once in mp, and it broke the game,
though it was a long time ago, so maybe since then its better.

just thought of mentioning this part.

thanks :)

Its better, but not completely fixed. The multiplayer problem is under choose religions. For some crazy reason, the popup to select the religion comes up on the wrong player's turn to select a religion. The correct civ still gets the religion, but doesn't get to pick the religion. :crazyeye: Again, this happens only in multiplayer. Single player works perfectly. I'm going to address this issue in the python forum, as I really want to squash this bug.
 
Top Bottom