How do I use an array in a variable?
I have a script which looks for a layer named "Car" and gets its position value. However, I also need it to look for other names and case variations, just in case "Car" doesn't exist. eg - "CAR" "Truck" "TRUCK", etc
The line in question is this…
var pos = app.project.activeItem.layer("Car").transform.position.value;
What's the correct syntax for changing that line into an array that would look for all possible variations above?
I tried this, but it's obviously wrong because it doesn't work…
var pos = app.project.activeItem.layer(["Car","CAR","Truck","TRUCK"]).transform.position.value;