I am interested in using the Floor Area Ratio (FAR) as a basis for generating building geometry. Say you have a 2.000 sqm lot with an allowed FAR of 0.75. I could then place a building with a total floor area of 1.500 sqm. Depending on the size of the footprint this would result in a given number of possible floors. For instance, a 300 sqm footprint would allow 5 floors.
In order to do so, I need to call the area of the lot (using the geometry.area function, I assume), as well as the are of the foot print. But I can't figure out how to get the areas of the lot and the footprint and then use it to calculate the possible number of floors for my extrude.
How do you do that?
I am new to CE (and to scripting altogether) but I kind of get the general works of it. I made a very crude script (see below) which hopefully gives and idea of where I want to go. It doesn't call the mentioned areas though, as I can't figure it out.
/** * File: FAR_rule.cga * Created: 30 Oct 2012 17:49:06 GMT * Author: nic */