Copy link to clipboard
Copied
Batchplay not working for me? I updated to PS 24.1.1 Mac
Weird. My plug in has been working for weeks. Now it no longer works after several mac updates. I have not touched my plug in. No errors.
Mac Ventura 13.1 ( Mac M1 Max)
Adobe Ps 24.1.1
In Debug mode I get all my usual console.log messages. No errors.
Do I need to change something in the MANIFEST.JSON after my Ps/Mac updates?
{
"id": "LacyStudioCanvasPro1",
"name": "Canvas Pro 1.2",
"version": "2.1.0",
"main": "index.html",
"host": [{
"app": "PS",
"minVersion": "24.1.1",
"data": {
"apiVersion": 2
}
}],
"manifestVersion": 4,
"entrypoints": [
{
"type": "command",
"id": " ",
"label": "Reload Plugin"
},
{
"type": "panel",
"id": "CanvasPro1:",
"minimumSize": {"width": 300, "height": 950},
"maximumSize": {"width": 300, "height": 1350},
"preferredDockedSize": {"width": 300, "height": 950},
"preferredFloatingSize": {"width": 300, "height": 950},
"label": {"default": "Canvas Pro 1"},
"icons": [
{
"width": 23, "height": 23, "path": "icons/dark.png",
"scale": [ 1, 2 ],
"theme": [ "darkest", "dark", "medium" ]
},
{
"width": 23, "height": 23, "path": "icons/light.png",
"scale": [ 1, 2 ],
"theme": [ "lightest", "light" ]
}
]
}
],
"icons": [
{
"width": 48, "height": 48, "path": "icons/plugin.png", "scale": [ 1, 2 ],
"theme": [ "darkest", "dark", "medium", "lightest", "light", "all" ],
"species": [ "pluginList" ]
}
]
}
Oh, I see my problem; I added one line -- ONE line, to my batchplay
//Delete Hidden Layers
{"_obj": "delete","_target": [{"_ref": "layer","_enum": "ordinal","_value": "hidden"}],"_isCommand": false },
So, my batchplay was working on the file I was testing because there was a hidden layer. That was what I was testing, so that was what was working.
Days later, I open another random image file WITHOUT a hidden layer and my batchplay doesn't do anything because Delete Hidden Layers is one of the
...Copy link to clipboard
Copied
Hi, @contactzero! I tried to write several batchPlay functions - everything works for me. Windows
Try asking a similar question here - Adobe Creative Cloud Developer Forums
Copy link to clipboard
Copied
Oh, I see my problem; I added one line -- ONE line, to my batchplay
//Delete Hidden Layers
{"_obj": "delete","_target": [{"_ref": "layer","_enum": "ordinal","_value": "hidden"}],"_isCommand": false },
So, my batchplay was working on the file I was testing because there was a hidden layer. That was what I was testing, so that was what was working.
Days later, I open another random image file WITHOUT a hidden layer and my batchplay doesn't do anything because Delete Hidden Layers is one of the first commands in a long series of array elements. So I found out Batchplay aborts the sequence if one element fails.
So, I'll wrap the Delete Hidden Layers in a separate batch play with Try...
- Back to testing
Copy link to clipboard
Copied
Also,
I since updating Mac OS or Ps to latest version, I have to change {mergeVisible}, which is no longer working, to {flattenImage}.
-Good grief
Copy link to clipboard
Copied
Everything should work.
Check the state of the document (if an invisible layer is selected, then mergeVisible will not work).