Platyping's Python

You mean Bach? I can see it, you mean you cannot see it? Strange :crazyeye:
 
Great ideas a gain :goodjob:.

Promotions that would do the following (1 free given to a settler)
*Free specific building in the city it constructs
*The state religion founded in the city
*Population bonus in the city
*Culture bonus
*Protected (adds a military unit to the settler to protect it)

The religion one has already been done (not in promotion form though), but cant seem to get it to work in my mod

Tsentom did a wonder with parts of these effects.
 
would be good if you have some ideas what effects to give it lol.

Thinking of effects for a name is bigger headache than thinking of a name to for an effect
 
Here are a couple of ideas that you could use for it:
1)reduces war weariness
2)improves attitude with enemies
3)provides a free medic promotion in the city
4)allows for more military drafting
5)increases espionage against enemies.
 
1 and 3 are XML stuff
2 and 5 done, trying not to repeat similar effects
4 is the only one I been experimenting how to do :shake:
 
Disables Building of Military Units:
Code:
	def cannotTrain(self,argsList):
		pCity = argsList[0]
		eUnit = argsList[1]
		bContinue = argsList[2]
		bTestVisible = argsList[3]
		bIgnoreCost = argsList[4]
		bIgnoreUpgrades = argsList[5]
## Arc De Triomphe Start ##
		pPlayer = gc.getPlayer(pCity.getOwner())
		bc_Triomphe = gc.getInfoTypeForString("BUILDINGCLASS_ARC_DE_TRIOMPHE")
		if pPlayer.getBuildingClassCount(bc_Triomphe) == 1:
			if gc.getUnitInfo(eUnit).isMilitaryProduction() == true:
				return True
## Arc De Triomphe End ##
		return False

For dacubz145. Never test, let me know if doesn't work. Make sure you set python callback to 1

Edit: Changed from checking unit combat class to militaryproduction. Forgot missiles have no combat class
 
Simple and easy:

Pergamon Altar
Spoiler :

Civ4ScreenShot0032.jpg


The idea is from the word Giant.
Well, giant... the more you kill, the faster your GG grow, while making your rivals smaller and smaller.

If the rival's GG point is 0, it will go negative. It does not drop to previous level.
So from 0/60 it will become -2/60 which means he will now need 62 GG points to get a GG.

Artwork taken from PIE mod


Wonder of Suprise:

Nazca Lines
Spoiler :

Nazca.jpg


Since nobody knows the purpose of nazca lines, I obviously dunno what it should give.
Thus, it ends up as a wonder that gives benefits which nobody knows until it is built.
And even after it is built, nobody knows what it will end up after several era advances.
Ancient era = 1 benefit, future era = 7 benefits.

Thus, it may end up giving purely 14 happiness or maybe 8 food, 8 production, 6 health.
Totally random wonder each game.

Artwork taken from History Rewritten mod


JS Bach, Peragon Altar, Nazca Lines updated into Megapack

P.S.
Any module making tutorial lying around? Megapack now 4MB time to shrink its size...
 
Thanks again.

Looking for beta testers for this:

AI build projects automatically

Purpose: Get rid of current system which is done under def AI_chooseProduction

Old System:
1) Forces AI to build under certain circumstances, interrupting normal AI decisions
2) Extra python codes for no real benefits = extra performance lags, especially as AI are chosing production every turn, this command is activated every turn.
3) AI may be doing something important like building a wonder, yet this will force it to change.
4) Even after we force AI to start building the project, AI may switch away from completing the project.

New System:
1) Codes only activated when project finished. Thus, once in a lifetime. Less performance issues. In fact, there is only 1 real line of code.
2) AI "sees" the project as another Internet project, so it won't make funny decisions such as switching from a wonder that is 3 turns away to completion.
3) Since AI sees the project as another Internet, it will not switch away from it unnecessary.

Thus, this is to bluff AI to build the project "willingly and happily"

How it works/supposed to work:
There are 3 useless projects added, all buildable with Masonry.
Each of them has Internet effects, which are removed immediately when built.
Thus, it bluffs AI to build the projects willingly, thinking they are awesome Internets.
But once it is build, they get no benefits.

Need to test 4 things:
1) Each of them has iTechShare 1, which means you get all Techs known by ANY known player.
So to prove that the project is useless, you should NOT get any free techs which you don't have, but others have.
2) Internet still works, having iTechShare 2, which means you get all Techs known by any 2 known players.
Thus, you should still get free techs known by any 2 other players.
3) Leave 1 or 2 of the useless projects alone, and see if the AI build them happily
4) Doesn't matter whether Internet is built first, or useless project built first.

Notes:
Internet cost and prereq tech adjusted for easy testing.
Because the useless projects are using iTechShare, wordings for iTechShare are removed, and manually added into Internet's civilopedia
Treaty of Versailes is set as a Team Project, whereas the other 2 are World Projects to see if it works for both types.
In other words, each player can build 1 Treaty each
 
Channel Tunnel
Spoiler :

Civ4ScreenShot0013-3.jpg


Mechanics:
Number of Tiles Unit can Move on Route = Greater of these 2:
A) 60 / iFlatMovement (6 For Railroad)
B) 60 * Moves / iMovement (20 For Railroad)

For unit with 1 movement, A = 10, B = 3.
Therefore, it can move 10 tiles.

For unit with 2 movement, A = 10, B = 6.
Therefore, it can move 10 tiles.

What Channel does is reduce iMovement of Railroad to 10.
For unit with 1 movement, A = 10, B = 10.
Therefore, it can move 10 tiles.

For units with 2 movement, A = 10, B = 12.
Therefore, it can move 12 tiles.

Thus, for modders, if you modified iMovement for Railroads, you have to modify channel codes to get what you want.
Else, channel may end up being OP, allowing units to move 60 tiles for instance

What it does
It places a 2nd Channel Tunnel at a coastal city of other players.
Friendly ones are considered first, followed by pleased ones.
The others are considered when there isn't any friendly or pleased ones.
Civs without coastal cities are out of consideration.
Coastal city chosen is most cultural one out of all coastal cities of chosen player.

No additional movement benefit for controlling both Channel Tunnels

Idea adopted from dacubz145
 
Yup, the original CT is a coastal building.
The 2nd CT only considers players with coastal cities according to Attitude.
Even if the rival is friendly but if he doesn't have any coastal city, he is out of the question.

If there is no other player in the map with coastal city besides the builder, 2nd CT will not be built
 
dear platyping

thank for for your intriguing & entertaining contributions, and also for encouraging me to use code more!

keep up the good work
 
Glad to hear they are entertaining :goodjob:

The neglected World Wonder:

Catacombs of Kom el Shoqafa
Spoiler :

Civ4ScreenShot0011-2.jpg


Let's rest in peace.... together :evil:

Seriously, out of the 7 Ancient Wonders, 7 Medieval Wonders and 7 New Wonders, this is the one and only real world wonder that never appears in any mod or any Civ series. And the fact that it is still standing today makes it look more saddening. Pretty strange how a real world wonder is never seen, while others like Himeji Castle, Eiffel Tower which are never on world wonder lists are so popular.

Since this is a mass burial tomb, for mass burial, you need to drag someone to die together... Thus, whenever a unit died defending a city, there is a chance to bury the attacker with you lol :lol:

Chance depends on how badly damaged the attacker is:
0~24% => 0%
25~49% => 10%
50~74% => 20%
75~99% => 30%

Because it is a real world wonder, its powers are extended to all cities :goodjob:

Difference between Neuschwanstein and Catacombs:
Neuschwanstein deals fixed 20% damage to attackers always.
Catacombs has % chance to instant kill attackers who are damaged.
Unless attacker is badly damage, catacombs does nothing at all

Neuschwanstein affects wonder city only.
Catacombs affects all cities.

Edit: Adjusted Burial Chance, since 40% seems too high.

Because I did not find it in any mod, obviously I can't find an exact artwork for it. This is the closest I find :egypt:


Megapack updated with Channel Tunnel, Reichstag, Catacombs.
To Date: 41 Wonders, 15 Projects
 
That could decide some wars, if the both players are on the same tech level.
Nice idea.
For the Reichstag it would be more appropriate if there was no limit after it was lost (but that would be too difficult to code, and doesn't really make sense gameplay wise).
 
Hmm, you mean keep the no limit effects even if Reichstag is razed?
Yeah, pretty hard to code unless Reichstag is a project, then will never be razed lol.
I am really curious why no one ever bothered with the catacombs :shake:

Knossos Labyrinth:
Replaced button with real Knossos pic
Prerequired Tech switched to Engineering from Philosophy which never makes sense
 
Hmm I didn't try BUG before, since there are bug, bat, bbai etc so many versions so I not sure which to make it compatible with.

So for simplicity sake, I make it compatible for normal BTS.
Anyway I started moding 40 days ago :D so I didn't know BUG doesn't use the default python files.
I can take a look at bug codes and see what is the difference if you can tell me which is the most popular version to try.

By the way, I downloaded 4 mods to "loot" wonder art and names :hammer:
Realism Invictus, History Rewritten, PieAncientEuropeIV and Invasion of Kuwait
All of them have CvEventManager, and some of them dont have BUG. 95% is definitely an overstatement :egypt:

Edit:
Hmm I do see BUG in some of them, but they still have CvEventManager as well as CvGameUtils. Does BUG stops the access to these 2 files?
 
Back
Top Bottom