Can I make harbors buildable only in coastal cities?

criZp

Emperor
Joined
Jul 19, 2013
Messages
1,963
Location
Nidaros, Norway
Districts do have a "NoAdjacentCity" entry, but no "AdjacentCity" entry. Wonders do have an "AdjacentDistrict" entry, which I figured does definely not do anything for the districts.

My plan was to make a mod where all cities that reach 10 population get a trade capacity, and that building a shipyard in a harbor would grant another trade capacity in addition to the production bonus (the shipyard trade capacity also requiring 10+ population in the city). However, the harbor should only be buildable by the coastal cities. Together with buffs to coastal yields (done in part by increased base yields and in part by the buffed lighthouse), this should make coastal settlements actually worthwhile, beyond the eureka for sailing and the vulnerability to naval attack.

I also tried to look at the acropolic and the mbanza, which have placement restrictions. But these restrictions are done through ValidTerrains and ValidFeatures entries, so that was no help.

Would be awesome if any of you guys knew some trick to make this work.
 
Districts do have a "NoAdjacentCity" entry, but no "AdjacentCity" entry. Wonders do have an "AdjacentDistrict" entry, which I figured does definely not do anything for the districts.

My plan was to make a mod where all cities that reach 10 population get a trade capacity, and that building a shipyard in a harbor would grant another trade capacity in addition to the production bonus (the shipyard trade capacity also requiring 10+ population in the city). However, the harbor should only be buildable by the coastal cities. Together with buffs to coastal yields (done in part by increased base yields and in part by the buffed lighthouse), this should make coastal settlements actually worthwhile, beyond the eureka for sailing and the vulnerability to naval attack.

I also tried to look at the acropolic and the mbanza, which have placement restrictions. But these restrictions are done through ValidTerrains and ValidFeatures entries, so that was no help.

Would be awesome if any of you guys knew some trick to make this work.

Probably only with LUA coding, because I tried this a lot and cant find a solution. Only works for buildings, because they can pre-require another building.
 
Top Bottom