Mod Component Request Thread

I'd like to see two mods:

1) Civs choose random religions. Removing religion preference for each leader is not good enough, apparently it just makes civs choose in alpha order...

2) A script to take from a large pool of wonders (e.g. >50) and randomly choose 6/7 (or whatever) from each era to be included in the game. This would include base game + modded wonders.
 
I'd like to see a diplo mod that allowes civs to trade single influence tiles of thier cities
of course the city from which you can trade must have at least one tile next to a tile that is owned by the other civ in order to make the other city the controller of that tile
also the tile is chosen randomly from all possible tiles that fit the requirements, you only can chose the city which will give up one of its tiles

and I don't even know what worth to give a single tile (depending on the city - maybe 1/x of the worth of that city with x being the number of tiles controlled by the city)
 
I've been trying to make a simple mod that make civs lose 1 point of Happiness for each tile of Fallout in their territory. This would make nukes slightly scarier, both to be hit by and to use on a wide scale. If nothing else, it would at least be a reason to actually clean up fallout in a timely manner even on less important cities.
Since Fallout is considered a Feature, I tried to go about this by setting InBorderHappiness to -1 in the Features table. But that doesn't seem to do anything. You can see in the Civilopedia that the value is changed to -1, but the Happiness is not actually reduced. Tried out -2 (just in case -1 was a special value) and that didn't do anything either.
So I suspect lua coding will be needed, but that stuff's beyond me. Can anyone help?
 
I've been trying to make a simple mod that make civs lose 1 point of Happiness for each tile of Fallout in their territory. This would make nukes slightly scarier, both to be hit by and to use on a wide scale. If nothing else, it would at least be a reason to actually clean up fallout in a timely manner even on less important cities.
Since Fallout is considered a Feature, I tried to go about this by setting InBorderHappiness to -1 in the Features table. But that doesn't seem to do anything. You can see in the Civilopedia that the value is changed to -1, but the Happiness is not actually reduced. Tried out -2 (just in case -1 was a special value) and that didn't do anything either.
So I suspect lua coding will be needed, but that stuff's beyond me. Can anyone help?

a) Loop through all tiles.
b) Check ownership.
c) Check feature.
d) if Owner = someplayer and Feature = Fallout then set OwnerHappiness = OwnerHappiness - 1
e) repeat each turn
 
edit: Actually, forget what I said earlier. After finding a nice tutorial and using the magic of the Live Tuner, insight dawned and I've figured out what to do. The following should do the trick:
Spoiler :
Code:
function adjustForFallout()
for i = 0, Map.GetNumPlots()-1, 1 do
	local pLoopPlot = Map.GetPlotByIndex(i)
	if pLoopPlot:GetFeatureType()==FeatureTypes["FEATURE_FALLOUT"] then
		local OwnerID = pLoopPlot:GetOwner()
		if OwnerID ~= -1 then
			local Owner = Players[OwnerID]
			if Owner:IsEverAlive() then
				Owner:SetHappiness(Owner:GetHappiness()-1)
			end
		end
	end
end
end

Events.ActivePlayerTurnStart.Add(adjustForFallout)
Sadly I can't seem to find an efficient way to cycle only tiles with an owner, nor a way to adjust listed Unhappiness. But this will do nicely. Thanks for the help.

That sounds decent enough, except that I don't know a thing about lua coding. Looking through other people's code usually helps me a lot, but not so much with lua. How do I get the code to run at the correct time? Why is it all functions? What exactly do I loop through and which things exactly do I check? (To the uninitiated like me the Lua reference at the Modiki is scant little help.)
 
I don't know if these have been suggested, because there are 17 pages of suggestions, but these are some that have occurred to me.

- Yields for clearing jungle, like 20:c5gold: or something
- Production to food for all plantations, e.g. a banana plantation on a hill would get 4:c5food: instead of 3:c5food: 1:c5production:
 
I don't know if these have been suggested, because there are 17 pages of suggestions, .
yeah alot to look at there

i just want a mod that will let me walk on the ice and work with gobel warming mod so that if the ice melts when you walk on it your unit dies not not some crazy error...
i will to try and do it my self and have and seems i have no clue what i'm doing have not modded any civ but civ3 and that a long time ago.. any help would be great...

thanks
 
Does anyone know if it is possible to change the way city names are drawn from the civ's list when a new city is built? For example, if I build New York City, and rename it to, say, Metropolis, the next city I build will be named New York City again. If anyone knows of a way to avoid getting repeated names after renaming a city, that would be most appreciated.
 
Defence Value for AI:

not sure if you've come up with this before but...

maybe I can call it a defense resource, though its not technically a resource.

An in-game invisible number accumulated by forts or terrain that can be measured and calculated by the AI so it may build forts on the land as if its going to get more resource. No effect on players since we can use forts and citadels.

maybe default 1 defense value on a tile, +1 point for each defense bonus (per 25%), im sure workers may build a fort on a 1 food, hammer and gold tile if the tile has 2 defense value.

the way how the numbers be placed:
~ 1 def value default at all tiles.
~ +1 if it has hills or forest
~ +1 if its adjacent to city (AI tends to group units together)
~ +1 if its adjacent to 2 or more mountains

this defense value can also be used for...

- marking suggestions to put where a fort be. Now you can see the fort icon on the screen.

- if you want to make forts effecting more for players. maybe giving a defense bonus for cities. it may make tall empires more powerful, but forts do give a drawback of the production of the land. maybe like, +0.5 city strength per fort, or less. or an effect from defensive buildings.

- if you really want an accumulating value that builds up till later, maybe we can have an event that gives reinforcements to your units, more generals or healing them like a promotion. It should be something interesting.

- and if the AI starts to build forts, maybe we can have Civ abilities or other bonuses you can get that deals with forts and citadels. Maybe each existing civ can be more defensive than others.

its only an untried idea to get the AI to make forts, i dont really have the exact details now, thanks.
 
Not sure if this has been requested, but would love to see a Mod allowing Turtle Ships to enter Ocean tiles.

Many thanks in advance!
 
Not sure if this has been requested, but would love to see a Mod allowing Turtle Ships to enter Ocean tiles

A nice simple one to learn how to create a mod :)

Required XML would be

Code:
<GameData>
  <Unit_FreePromotions>
    <Delete UnitType="UNIT_KOREAN_TURTLE_SHIP" PromotionType="PROMOTION_OCEAN_IMPASSABLE"/>
  <Unit_FreePromotions>
</GameData>

or SQL

Code:
DELETE FROM Unit_FreePromotions
  WHERE UnitType='UNIT_KOREAN_TURTLE_SHIP'
  AND PromotionType='PROMOTION_OCEAN_IMPASSABLE';
 
A nice simple one to learn how to create a mod :)

Required XML would be

Code:
<GameData>
  <Unit_FreePromotions>
    <Delete UnitType="UNIT_KOREAN_TURTLE_SHIP" PromotionType="PROMOTION_OCEAN_IMPASSABLE"/>
  <Unit_FreePromotions>
</GameData>

or SQL

Code:
DELETE FROM Unit_FreePromotions
  WHERE UnitType='UNIT_KOREAN_TURTLE_SHIP'
  AND PromotionType='PROMOTION_OCEAN_IMPASSABLE';

First of all, many thanks for your reply and help. I am a hopeless tech-idiot. Is there a file I would actually open up and edit? Would I have to create a new one?

Sorry, I'm truly that illiterate. Any dummy-type step by step guidance would be greatly appreciated!

Many thanks in advance.
 
city screen specialist buildings sorted by specialist type and slot number:

factory
windmill
workshop
university
laboratory
public school
...


or even better (but quite hard to implement i assume):

dont show any slots for buildings
but a specialist section
with available number of slot controls per each specialist type shown

=== specialists ===
:c5science: scientists :c5citizen: :c5rangedstrength: :c5rangedstrength:
:c5production: engineers :c5citizen: :c5citizen:
...
==============

*:c5rangedstrength: means empty slot
great people images can be used to identify specialist types

ps:
this section could be merged with the great people progress section btw

=== specialists ===
:c5science: scientists :c5citizen: :c5rangedstrength: :c5rangedstrength:
||||||||||||||||_____________ (+3/15)
:c5production: engineers :c5citizen: :c5citizen:
|||||||||||||||||||||||||||||||__ (+6/3)
:c5gold: mrchants :c5rangedstrength:
|||______________________ (+0/-)
...
==============
 
Ton of posts here -

Is there a mod (preferably LUA) that lets a unit spawn barbarians?

I'd like to have a privateer spawn pirate ships (the act itself kills your own). So i can harass other players.

Likewise something similar for a ground unit (SpecOps) that can train guerrillas in enemy territory.

And I need the AI to know how to use it too.

Thanks.
 
here is a good idea that seems doable..... upon completion of future techs have a window that lets you select it's benefit like in religions.
 
When a holy city is conquered, its religion no longer shows up in the religion info panels.

Can this be fixed by mod components?

I've not seen this effect the stats for religion in BPI, although that's only reporting back a percentage of followers, so I'd guess the info is still there to pluck out :confused:
 
When a holy city is conquered, its religion no longer shows up in the religion info panels.

Can this be fixed by mod components?

The fix is so simple it's easier to hack the core files directly.

In the ReligionOverview.lua file, locate the functions RefreshWorldReligions() and RefreshBeliefs() and change the line "if (pPlayer:IsAlive()) then" to "if (pPlayer:IsEverAlive()) then" in each of them (about the 10th line after the function declaration)
 
Thank-you... I'll likely create an altered lua file as part of my mod as a holy city conquest (or two) is inevitable in my scenario. A city state has a holy city and is set at permanent war with a much stronger city state. For the sake of scenario players, I really should mod it in (hopefully, the functions you mentioned loop through all players and not just major civs... have not looked at it yet). I'll post the mod file as a mod component should anyone else wish to install it (with due credit for your advice.)

Am I right that setting VFS true and using the same file name as the original will replace it when the mod is activated?
 
Back
Top Bottom