Error "null is not an object" when trying to run scripts
I bought BG Renderer Pro from aescripts.com
Since switching to a new machine, the script won't even load. When I try to Window>BG Renderer, I get "Unable to execute script at line 94. null is not an object"
Lloyd from aescripts said "You have a permissions issue with your macOS user account. AE needs to be able to read and write from the home folder. If that is blocked then you will get these types of errors. A common situation that causes this is when AE is installed from a different user account. "
I re-installed Ae, the script; I chowned and chmodded my home folder ... nothing works.
I suggest you take a look at the script; chances are that your AE copy is not in english and some effects that are applied inside the script are called with a non-universal name/parameter index, thus resulting in AE not recognizing those effects. You have 2 options:
- change the language of your AE copy, by going into the folder Languages, then change the name (just the name) of the text file, inside the folder, from your language to the corresponding letters for english (I believe it's EN_en, basically match the lower and upper case position);
- edit the script ( this can be a long process depending on how many lines you need to change):
Go inside the script folder, open up the script that you've installed (you should just be able to double click on it) and look at line 94 or whaterver line that give you issues; if it contains the english name of an effect, you have to change it; you can do so in two ways:
- using the actual effect name the your AE copy uses; simply go on the internet and look up what english name corresponds to your language effect name, then change it;
- using the corresponding effect on this list, which would make it work on any language; to do so you have to go to:
then look up to the effect name in your script and change it with the general name of the column "Match Name" of that web page.
Once you've done that, you may have to change also the effect parameter name; once again, if you want to have the script work on any language, you have to use number as indexes; check this guide to understand how to implement it:
The index of the effect can be easily obtained by pressing alt+left click on the stopwatch for the effect parameter you want to know the index of, and look at the expression panel: you should see a line saying the name of the layer, the name of the effect followed by an index in parenthesys such as thisLayer.effect("Fast blur").(1) or something like that. You take that index number and replace the name of the parameter in the script with that number (e.g.: in the script, something like: effect("Fast blur")("blurriness") becomes effect("Fast blur")(1)). This is the long way but gives the best results.
By far, the easiest option is to change the language, though be aware that you don't just change the language, but also the effects order in the effect panel and also the workspace changes a bit.
Or you can simply ask the seller; if it cares about the customer, it will change the script for you.