Class ProductionChain

A production chain handles the building of buildings required to
produce a resource.

Production chains use the list of production lines and the available
AbstractBuilding subclasses to figure out all ways of producing a certain
resource and finding the right ratio of them to produce just enough of
the resource. The result is a tree that can be used to produce the
required resource.

Each subtree reserves a portion of the total capacity of the buildings
of the relevant type. This is a logical classification and doesn't affect
the actual buildings in any way. Some subtrees can import the required
resource from other islands using a mechanism similar to the previous one
but in that case it acts as if the resource was produced without any
subtrees. The imported amounts are added up over time and saved as an
owed resource in the exporting settlement's resource manager (these
restrictions are again just logical without affecting the way the
settlements work in any way). That storage is realized by organizing
DomesticTrade missions that transfer the resources to the right
settlements.