check if node has transform

I would like to check if some node n has transformation, which means

n.transform!=matrix3 1

Just using != doesn´t work, as far I have read it´s only avaible since max 2018 and I need my script to work with older versions of max.

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
barigazy's picture

...

Yup. With newer versions, you can compare matrix values
But for older versions you can try compare them as strings

n.transform as string != matrix3 1 as string

bga

SimonBourgeois's picture

Hi

maybe something like:

if n.rotation == (quat 0 0 0 1) and n.scale == [1,1,1]  then print "n has not been transformed"
else print "n has been transformed"

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.