ComponentDefinition.instances strange behavior. Bug?
-
I have two ComponentDefinitions (d1 and d2) in model. Each of them has one instance. Strange thing begins, when I make a new Component of the both instances and then explode it. Then d1 and d2 instances returns me array of length 2.
d1.instances -> #[#Sketchup::ComponentInstance:0x6ba89c4]
d2.instances -> #[#Sketchup::ComponentInstance:0x9bc96e4]Using mouse I select both instances, make Component of them and explode it.
d1.instances -> [#Sketchup::ComponentInstance:0x6ba89c4, #Sketchup::ComponentInstance:0x9bc2164]
d2.instances -> [#Sketchup::ComponentInstance:0x9bc96e4, #Sketchup::ComponentInstance:0x9bc1fd4]but there is no any new instances in model, outliner does not show them too. Is it a bug or I misunderstand something? Maybe there is some purge function for d.instances or something?
-
Because after exploding you have instances in your model and in the definition of the instance you just exploded. Remember that definitions doesn't disappear when they are unused - you need to purge them.
-
Thanks!
Advertisement