2 Replies Latest reply on Apr 22, 2018 3:23 AM by bristlez

    2 second help for a noob

    bristlez

      I found a script that does exactly what I need (move layers progressively in PS) but what I don't understand is how to change the movement from the Y axis to the X axis. What in this script is controlling the axis, and how to I change it to move horizontally?

       

      1. #target photoshop 
      2. app.preferences.rulerUnits = Units.PIXELS; 
      3. var doc =activeDocument 
      4. var moveAmt = -100 
      5. var moveCurrent = -100 
      6. var numLayers = doc.layers.length 
      7. for(var i=1;i<numLayers;i++){ 
      8.     doc.activeLayer = doc.layers[i] 
      9.     try
      10.         doc.activeLayer.translate(0,moveCurrent) 
      11.     } 
      12.     catch(e){} 
      13.     moveCurrent+=moveAmt 
      14.     } 

       

      Original: Progressively move layers PSCC 2015