Balcony placement and turn on/off attribute

207
3
07-15-2018 06:36 AM
DarioCvitkusic
New Contributor II

Hello,

i have two simple cga questions.

how i can place more balconies directly under the 1floor windows and add a enabled/diabled attribute for them?

regards 

Dario

0 Kudos
3 Replies
LR
by
Regular Contributor

You add a reference to a balcony rule in the same bit that references the window generation and use a case to control its generation, like this:

attr BalconyEnabled = true

Lot -->
   Window
   Balcony

Window -->
   ...

Balcony -->
   case BalconyEnabled == true: RuleForBalconyCreation
   else: NIL‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍

RuleForBalconyCreation -->
   ...
DarioCvitkusic
New Contributor II

Thank you, for the balcony the switch works fine but fot the details such as the red top ornament it wont. it just disapeared with this rule..

attr OrnamentTopEnabled = true

WindowOrnamentTop -->
case OrnamentTopEnabled == true: WindowOrnamentTop

s('1.2, 0.4, 0.3) center(x)
i(ornament1)
color("#ff0000")

else: NIL

0 Kudos
LR
by
Regular Contributor

That rule calls itself when the case is true, infinitely.

0 Kudos