what is the full dot syntax to get color component of an item/object

what is the full dot syntax to get color component of an item/object

durga_ghosal1
Not applicable
27 Views
3 Replies
Message 1 of 4

what is the full dot syntax to get color component of an item/object

durga_ghosal1
Not applicable

[ FlexSim 19.0.4 ]

0 Likes
Accepted solutions (1)
28 Views
3 Replies
Replies (3)
Message 2 of 4

benjamin_w2
Not applicable
Accepted solution

Hi @Durga Ghosal,

Here is an example:

Object obj = Model.find("Processor1");
return obj.color.r;  //Returns the red component of the color.

I hope this helps!

0 Likes
Message 3 of 4

durga_ghosal1
Not applicable

To get the color. The old syntax was getcolorcomponent(item,1)

0 Likes
Message 4 of 4

durga_ghosal1
Not applicable

I got the syntax.

Object item;

double val = item.color.r;

Thanks

0 Likes