1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

How to add free buildings to all cities?

Discussion in 'Civ5 - Creation & Customization' started by Watsonnn, Jul 8, 2018.

  1. Watsonnn

    Watsonnn Chieftain

    Joined:
    Jul 5, 2018
    Messages:
    4
    Gender:
    Male
    I have seen a similar post on here regarding this topic but on a slightly different matter.

    I want to know how to get a wonder/building (pyramids) to create free buildings (granaries) in all cities. I have tried the <FreeBuidling> approach but that is more for traits so removes buildings when captured and I think creates them in cities settled after the creation of the building.

    Thanks
     
  2. LeeS

    LeeS Imperator

    Joined:
    Jul 23, 2013
    Messages:
    5,735
    Location:
    Illinois, USA
    <FreeBuilding> is in fact the way to do it. See the definition of BUILDING_CN_TOWER in the xml files for Buildings and Wonders. It has
    Code:
    <FreeBuilding>BUILDINGCLASS_BROADCAST_TOWER</FreeBuilding>
    Within the <Buildings> table, the specification for <FreeBuilding>:
    1. must be done by the CLASS of the Building
    2. Ignores any and all terrain, resource. and technology prerequisites
    3. provides the specified CLASS of building for free in every city belonging to the owner of the Wonder/Building so long as the Wonder/Building that is giving the FreeBuilding does not become obsolete, destroyed, or captured. The free building is given in existing cities and in all newly-founded or newly-captured cities.
    This behavior is different than that which is implemented by the similarly-named column <FreeBuilding> in table <Traits>.
     
  3. Ryika

    Ryika Lazy Wannabe Artista

    Joined:
    Aug 30, 2013
    Messages:
    9,396
    So you want to add the building ONLY in cities that are yours the moment the wonder is created but not in future cities? That's not possible in XML.

    You could do it with Lua though.
     

Share This Page