Pedestal --> extrude(world.y, ((Num_Pedestal_Floors * Upperfloor_Height) + (Groundfloor_Height - Upperfloor_Height))) PedBuildingVolume3D PedBuildingVolume3D --> case (Groundfloor_Height != (Num_Pedestal_Floors * Upperfloor_Height) + (Groundfloor_Height - Upperfloor_Height)) : #pedestal height is NOT equal to height of just the ground floor # the 3d volume will be split into smaller 3d volumes ! 1 ground floor volume will be created. split(y) {Groundfloor_Height : Volume("GF") | ~1 : PedAllUpperFloors} else: Volume("GF1") Towers PedAllUpperFloors --> # the rest of the volume is not split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : Volume("UF")}* Towers Volume(volumeType) --> case volumeType == "GF1" : case ((split.index == 0) && (NumFlrsComm >= 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) CommReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix >= 1)): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) MixReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff >= 1)): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) OffReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff == 0)): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) ResReporting MassReporting else: NIL case volumeType == "GF" : case ((split.index == 0) && (NumFlrsComm >= 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) CommReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix >= 1)): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) MixReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff >= 1)): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) OffReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff == 0)): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) ResReporting MassReporting else: NIL case volumeType == "UF" : case (((split.index + 1) <= (NumFlrsComm - 1)) && (NumFlrsComm > 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case (((split.index + 1) > (NumFlrsComm - 1)) && (NumFlrMix > 0) && ((split.index + 1) <= ((NumFlrsComm + NumFlrMix) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case (((split.index + 1) > ((NumFlrsComm - 1) + (NumFlrMix - 1))) && (NumFlrOff > 0) && ((split.index + 1) <= ((NumFlrsComm + NumFlrMix + NumFlrOff) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.index + 1) > (NumFlrsComm + NumFlrMix + NumFlrOff) - 1): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL else: NIL Towers --> case xLength > zLength : split(x) {theLength/2 : Tower1 | ~1 : Tower2 } else : split(z) {(theLength/2) : Tower1 | ~1 : Tower2 } Tower1 --> setback(FSetbackT1) { street.front : Concrete | remainder : T1Sub1 } T1Sub1 --> setback(BSetbackT1) { street.back : Concrete | remainder : T1Sub2 } T1Sub2 --> setback(LSetbackT1) { street.left : Concrete | remainder : T1Sub3 } T1Sub3 --> setback(RSetbackT1) { street.right : Concrete | remainder : Tower1Extrude } Tower1Extrude --> extrude(world.y, (Tower1_Floors * Upperfloor_Height)) T1BuildingVolume3D T1BuildingVolume3D --> # the volume is split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : T1Volume}* T1Volume --> case (split.index <= (NumFlrComm1 - 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case ((split.index > (NumFlrComm1 - 1)) && (NumFlrMix1 > 0) && ((split.index) <= ((NumFlrComm1 + NumFlrMix1) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case (((split.index) > ((NumFlrComm1 + NumFlrMix1) - 1)) && (NumFlrOff1 > 0) && ((split.index) <= ((NumFlrComm1 + NumFlrMix1 + NumFlrOff1) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.index) > (NumFlrComm1 + NumFlrMix1 + NumFlrOff1) - 1): else: comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL Tower2 --> setback(FSetbackT2) { street.front : Concrete | remainder : T2Sub1 } T2Sub1 --> setback(BSetbackT2) { street.back : Concrete | remainder : T2Sub2 } T2Sub2 --> setback(LSetbackT2) { street.left : Concrete | remainder : T2Sub3 } T2Sub3 --> setback(RSetbackT2) { street.right : Concrete | remainder : Tower2Extrude } Tower2Extrude --> extrude(world.y, (Tower2_Floors * Upperfloor_Height)) T2BuildingVolume3D T2BuildingVolume3D --> # the rest of the volume is not split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : T2Volume}* T2Volume --> case (split.index <= (NumFlrComm2 - 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case ((split.index > (NumFlrComm2 - 1)) && (NumFlrMix2 > 0) && ((split.index) <= ((NumFlrComm2 + NumFlrMix2) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case (((split.index) > ((NumFlrComm2 + NumFlrMix2) - 1)) && (NumFlrOff2 > 0) && ((split.index) <= ((NumFlrComm2 + NumFlrMix2 + NumFlrOff2) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.index) > (NumFlrComm2 + NumFlrMix2 + NumFlrOff2) - 1): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL Simple_Com --> color(ComColor) set(material.opacity,OpacityVal) Simple_Mix --> color(MixColor) set(material.opacity,OpacityVal) Simple_Off --> color(OffColor) set(material.opacity,OpacityVal) Simple_Res --> color(ResColor) set(material.opacity,OpacityVal)
Solved! Go to Solution.
Reporting --> report("Vol." + myUsageAttribute, geometry.volume) report("GFA." + myUsageAttribute, geometry.area(bottom))
Pedestal --> extrude(world.y, ((Num_Pedestal_Floors * Upperfloor_Height) + (Groundfloor_Height - Upperfloor_Height))) PedBuildingVolume3D PedBuildingVolume3D --> case (Groundfloor_Height != (Num_Pedestal_Floors * Upperfloor_Height) + (Groundfloor_Height - Upperfloor_Height)) : #pedestal height is NOT equal to height of just the ground floor # the 3d volume will be split into smaller 3d volumes ! 1 ground floor volume will be created. split(y) {Groundfloor_Height : Volume("GF") | ~1 : PedAllUpperFloors} else: Volume("GF1") Towers PedAllUpperFloors --> # the rest of the volume is not split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : Volume("UF")}* Towers Volume(volumeType) --> case volumeType == "GF1" : case ((split.index == 0) && (NumFlrsComm >= 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) CommReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix >= 1)): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) MixReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff >= 1)): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) OffReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff == 0)): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) ResReporting MassReporting else: NIL case volumeType == "GF" : case ((split.index == 0) && (NumFlrsComm >= 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) CommReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix >= 1)): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) MixReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff >= 1)): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) OffReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff == 0)): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) ResReporting MassReporting else: NIL case volumeType == "UF" : case (((split.index + 1) <= (NumFlrsComm - 1)) && (NumFlrsComm > 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case (((split.index + 1) > (NumFlrsComm - 1)) && (NumFlrMix > 0) && ((split.index + 1) <= ((NumFlrsComm + NumFlrMix) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case (((split.index + 1) > ((NumFlrsComm - 1) + (NumFlrMix - 1))) && (NumFlrOff > 0) && ((split.index + 1) <= ((NumFlrsComm + NumFlrMix + NumFlrOff) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.index + 1) > (NumFlrsComm + NumFlrMix + NumFlrOff) - 1): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL else: NIL Towers --> case xLength > zLength : split(x) {theLength/2 : Tower1 | ~1 : Tower2 } else : split(z) {(theLength/2) : Tower1 | ~1 : Tower2 } Tower1 --> setback(FSetbackT1) { street.front : Concrete | remainder : T1Sub1 } T1Sub1 --> setback(BSetbackT1) { street.back : Concrete | remainder : T1Sub2 } T1Sub2 --> setback(LSetbackT1) { street.left : Concrete | remainder : T1Sub3 } T1Sub3 --> setback(RSetbackT1) { street.right : Concrete | remainder : Tower1Extrude } Tower1Extrude --> extrude(world.y, (Tower1_Floors * Upperfloor_Height)) T1BuildingVolume3D T1BuildingVolume3D --> # the volume is split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : T1Volume}* T1Volume --> case (split.index <= (NumFlrComm1 - 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case ((split.index > (NumFlrComm1 - 1)) && (NumFlrMix1 > 0) && ((split.index) <= ((NumFlrComm1 + NumFlrMix1) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case (((split.index) > ((NumFlrComm1 + NumFlrMix1) - 1)) && (NumFlrOff1 > 0) && ((split.index) <= ((NumFlrComm1 + NumFlrMix1 + NumFlrOff1) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.index) > (NumFlrComm1 + NumFlrMix1 + NumFlrOff1) - 1): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL Tower2 --> setback(FSetbackT2) { street.front : Concrete | remainder : T2Sub1 } T2Sub1 --> setback(BSetbackT2) { street.back : Concrete | remainder : T2Sub2 } T2Sub2 --> setback(LSetbackT2) { street.left : Concrete | remainder : T2Sub3 } T2Sub3 --> setback(RSetbackT2) { street.right : Concrete | remainder : Tower2Extrude } Tower2Extrude --> extrude(world.y, (Tower2_Floors * Upperfloor_Height)) T2BuildingVolume3D T2BuildingVolume3D --> # the rest of the volume is not split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : T2Volume}* T2Volume --> case (split.index <= (NumFlrComm2 - 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case ((split.index > (NumFlrComm2 - 1)) && (NumFlrMix2 > 0) && ((split.index) <= ((NumFlrComm2 + NumFlrMix2) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case (((split.index) > ((NumFlrComm2 + NumFlrMix2) - 1)) && (NumFlrOff2 > 0) && ((split.index) <= ((NumFlrComm2 + NumFlrMix2 + NumFlrOff2) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.index) > (NumFlrComm2 + NumFlrMix2 + NumFlrOff2) - 1): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL Simple_Com --> color(ComColor) set(material.opacity,OpacityVal) Simple_Mix --> color(MixColor) set(material.opacity,OpacityVal) Simple_Off --> color(OffColor) set(material.opacity,OpacityVal) Simple_Res --> color(ResColor) set(material.opacity,OpacityVal)
Pedestal --> extrude(world.y, ((Num_Pedestal_Floors * Upperfloor_Height) + (Groundfloor_Height - Upperfloor_Height))) PedBuildingVolume3D PedBuildingVolume3D --> case (Groundfloor_Height != ((Num_Pedestal_Floors * Upperfloor_Height) + (Groundfloor_Height - Upperfloor_Height))) : #pedestal height is NOT equal to height of just the ground floor # the 3d volume will be split into smaller 3d volumes ! 1 ground floor volume will be created. split(y) {Groundfloor_Height : Volume("GF") | ~1 : PedAllUpperFloors} else: split(y) {Groundfloor_Height : Volume("GF")} report("NUMFLRS",NumFlrs) Towers PedAllUpperFloors --> # the rest of the volume is not split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : Volume("UF")}* NIL Towers Volume(volumeType) --> case volumeType == "GF" : case ((split.index == 0) && (NumFlrsComm >= 1)): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) report("SPLITTOT", split.total) CommReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix >= 1)): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) report("SPLITTOT", split.total) MixReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff >= 1)): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) report("SPLITTOT", split.total) OffReporting MassReporting case ((split.index == 0) && (NumFlrsComm == 0) && (NumFlrMix == 0) && (NumFlrOff == 0)): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top | all: NIL } set(material.opacity,OpacityVal) report("SPLITTOT", split.total) ResReporting MassReporting else: NIL case volumeType == "UF" : case ((split.total <= Num_Pedestal_Floors) && (((split.index + 1) <= (NumFlrsComm - 1)) && (NumFlrsComm > 1))): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } report("SPLITTOT", split.total) CommReporting MassReporting case ((split.total <= Num_Pedestal_Floors) && ((split.index + 1) > (NumFlrsComm - 1)) && (NumFlrMix > 0) && ((split.index + 1) <= ((NumFlrsComm + NumFlrMix) - 1))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } report("SPLITTOT", split.total) MixReporting MassReporting case ((split.total <= Num_Pedestal_Floors) && ((split.index + 1) > ((NumFlrsComm - 1) + (NumFlrMix - 1))) && (NumFlrOff > 0) && ((split.index + 1) <= ((NumFlrsComm + NumFlrMix + NumFlrOff) - 1))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } report("SPLITTOT", split.total) OffReporting MassReporting case ((split.total <= Num_Pedestal_Floors) && (split.index + 1) > (NumFlrsComm + NumFlrMix + NumFlrOff) - 1): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } report("SPLITTOT", split.total) ResReporting MassReporting else: NIL else: NIL Towers --> case xLength > zLength : split(x) {'.5 : Tower1 | '.5 : Tower2 } # I expected this split to split the polygon at the top of the pedestal, but it appears to else : # also split the top of the first floor of the pedestal and extrudes from both location, why? split(z) {'.5 : Tower1 | '.5 : Tower2 } Tower1 --> setback(FSetbackT1) { street.front : Concrete | remainder : T1Sub1 } T1Sub1 --> setback(BSetbackT1) { street.back : Concrete | remainder : T1Sub2 } T1Sub2 --> setback(LSetbackT1) { street.left : Concrete | remainder : T1Sub3 } T1Sub3 --> setback(RSetbackT1) { street.right : Concrete | remainder : Tower1Extrude } Tower1Extrude --> extrude(world.y, (Tower1_Floors * Upperfloor_Height)) T1BuildingVolume3D T1BuildingVolume3D --> # the volume is split into upper floor volumes, as many times as possible ('*' sign) split(y) {~Upperfloor_Height : T1Volume}* T1Volume --> case ((split.total <= Tower1_Floors) && (split.index <= (NumFlrComm1 - 1))): comp(f){side: Simple_Com | bottom: FloorBottom | top : Top } CommReporting MassReporting case ((split.total <= Tower1_Floors) && ((split.index > (NumFlrComm1 - 1)) && (NumFlrMix1 > 0) && ((split.index) <= ((NumFlrComm1 + NumFlrMix1) - 1)))): comp(f){side: Simple_Mix | bottom: FloorBottom | top : Top } MixReporting MassReporting case ((split.total <= Tower1_Floors) && (((split.index) > ((NumFlrComm1 + NumFlrMix1) - 1)) && (NumFlrOff1 > 0) && ((split.index) <= ((NumFlrComm1 + NumFlrMix1 + NumFlrOff1) - 1)))): comp(f){side: Simple_Off | bottom: FloorBottom | top : Top } OffReporting MassReporting case ((split.total <= Tower1_Floors) && ((split.index) > (NumFlrComm1 + NumFlrMix1 + NumFlrOff1) - 1)): comp(f){side: Simple_Res | bottom: FloorBottom | top : Top } ResReporting MassReporting else: NIL
Reporting --> report("Vol." + myUsageAttribute, geometry.volume) report("GFA." + myUsageAttribute, geometry.area(bottom))