script I made:
if (setTRSPreserveUVs == true) {
setTRSPreserveUVs false}
else if (setTRSPreserveUVs == false) {
setTRSPreserveUVs true}
the error:
// Error: string setTRSPreserveUVs; //
// Error: Syntax error //
// Error: if (setTRSPreserveUVs == true) { //
// Error: Invalid use of Maya object "setTRSPreserveUVs". //
// Error: //
// Error: Syntax error //
so this is the wrong command to toggle preserve uv's as just running it in the script editor does nothing but tell me it has invalid syntax.
any ideas? i know the script is too basic and simple to possibly function, but it'd be nice to know where i have gone wrong.
thanks!
Replies
This is all you need:
The above queries the current value of preserve UVs via the optionVar and then uses that setTRSPreserveUVs function to set it to the inverse of that.