[PYTHON] zCivics

Zebra 9

Emperor
Joined
May 17, 2006
Messages
1,554
Location
Middle of Cyberspace
zCivics MOD COMP v0.3

Type: PYTHON MOD COMP
Version: 0.3
Langages Used: Python
By: Zebra 9
Multiplayer Compatible: Shouldn't affect MP games

Description:
This is a very simple Python MOD COMP that allows anyone to set units or buildings to require a certain civic, as well as letting you set a civic to require a certain religion. This is a zModule, so for usage check out zModular Python

Download Here

Enjoy!

Usage:
You can set several settings on civics. These include:
Civics can require other civics
Civics can require religions
Civics can be blocked by leaders
Civics can be blocked by civs
Civics can be locked when selected​

You can also make Units, Buildings, Technologies, and Projects require Civics.

This is all accomplished by using the zCivics.zCnfg file located in your MODs Assets/zConfig directory.

This file is similar to an ini file so with that in mind it shouldn't be too hard.

So now to the usage. To set information on a civic use code like:
Code:
[Civic]
	Type = Civic's Type Tag
	Civic = The type tag of a civic that is required, you can have as many of these as you want
	Religion = The type tag of a religion that is required, you can have as many of these as you want
	Leader = The type tag of a leader that blocks this civic, you can have as many of these as you want
	Civ = The type tag of a civ that blocks this civic, you can have as many of these as you want
	Lock = Either True or False
[/]

To set info on units, buildings, techs, and projects.
Code:
[Unit]
	Type = The type tag of the unit
	Civic = The type tag of a civic that is required, you can have as many of these as you want
	Allow Continue = Either True or False
[/]
[Building]
	Type = The type tag of the building
	Civic = The type tag of a civic that is required, you can have as many of these as you want
	Allow Continue = Either True or False
[/]
[Project]
	Type = The type tag of the project
	Civic = The type tag of a civic that is required, you can have as many of these as you want
	Allow Continue = Either True or False
[/]
[Tech]
	Type = The type tag of the tech
	Civic = The type tag of a civic that is required, you can have as many of these as you want
	Allow Trade = Either True or False
[/]

So if you have any questions let me know.
 
Very interesting and useful :)
I already have couple of ideas with this modcomp :)
 
Good use of the GameUtils file. :cool:

Have you ever thought of useing INI files to control your mods?
Somthing as simple as
Code:
[Civics]
CIVIC_THEOCRACY = RELIGION_CHRISTIANITY
CIVIC_SLAVERY = RELIGION_BUDDISM

[Units]
UNIT_INQUISITOR = CIVIC_THEOCRACY
UNIT_SLAVE = CIVIC_SLAVERY

[Buildings]
BUILDING_INQUISITION = CIVIC_THEOCRACY

could be used to allow the non-code inclined an easy access to your mods.

Not sure exactly how familar you are with python, but if you haven't checked it out, look at the ConfigParser module in the Python Library Referense Manual. INI is a real easy file format to work with, especially in python and it keeps people from having to mess with the py files. :)
 
Yea, I want to start using that. It seems like it would be alot easier to explain.
Just added the Lock functionality.:cool:
 
hey zebra,

a civic prerequisite for civics functionality would be pretty neat. for example the ability to make free religion require free speech, or something like that.

nice work on this :goodjob:
 
Yea, I want to start using that. It seems like it would be alot easier to explain.
Just added the Lock functionality.:cool:
This is cool to have.

Regarding the Lock Functionality, can I request for the next version a different type of Lock Functionality?

In the Warlords Alexander's Conquests scenario his titles are portrayed as civics and they are locked. The only way they can be changed is by fulfilling certain requirements. Would it be possible for you to set up such a system so that we too can lock civics and have them changed only when certain conditions are met?
 
This is cool to have.

Regarding the Lock Functionality, can I request for the next version a different type of Lock Functionality?

In the Warlords Alexander's Conquests scenario his titles are portrayed as civics and they are locked. The only way they can be changed is by fulfilling certain requirements. Would it be possible for you to set up such a system so that we too can lock civics and have them changed only when certain conditions are met?
Yes, that is possible. Not sure if I would want to do that in this MOD COMP maybe in a different one.

Couple of Questions...


Say for the building prereq. If you swtich civics after you build the building, does it cease to opperate?

2nd question was, does any of this appear in the pedia.
No the building still opperates. No, I realy should see about setting the pedia to display this info.
 
I don't know if it's BtS compatable, if it isn't I'll let you know and update it. :thumbsup:

Yes, I know how to do that. I'll have it up very soone. ;)
 
About the improvement thing. I spent most of today working on it only to find out that it can be done in the CIV4BuildInfos.xml. :D
 
Have you thought about an option to require a certain other civic to be able to use another civic. For example, to use universal suffrage you must use emancipation?
 
I'm pretty sure they at least build them (I saw them do it in my game). As long as the building is beneficial to them...
I wonder though, if they actually take these special units or buildings into their consideration for choosing a certain civic?
 
Back
Top Bottom