I just checked 2 python plugins I developed that both worked fine in R19, but in R20 and R21, one of them doesn't show up. I copied the 2 plugins, without changing anything, from the R19 plugin location to the plugin folders in both R20 and R21. I checked the python console and there were no errors displayed. One of the plugins just goes unnoticed by C4D in both R20 and R21.
Any ideas why?
it's a bit difficult without having your code,
Could you share your code ?
we have this email if you don't want to share it in public : [email protected]
(I moved this topic to Cinema 4D Development categories)
I'll check one more thing before I send it.
I noticed C4D R20 & R21 both use python:
'2.7.14 (default, May 3 2018, 18:05:57) [MSC v.1500 64 bit (AMD64)]'
While R19, where my plugin works, uses python:
'2.7.9 (default, Apr 20 2015, 08:46:13) [MSC v.1700 64 bit (AMD64)]'
This is probably the reason, but why?
the Python revision is pretty much the last thing I would look into, as it seems unlikely that it is the culprit. The first thing I would check is: Does the plugin register? You talk about not showing up, which does not necessarily mean that the plugins have not been registered. The register functions (e.g. c4d.plugins.RegisterObjectPlugin) all return a boolean indicating the success of the registration. Alternatively you could look into the plugin manager.
I checked the plugin manager in all 3:
R19: the plugin is in the list.
R20: not in the list
R21: not in the list
If it is not in the list in R20 and R21 does that mean it didn't register?
the plugin manager shows you two things.
When your file does not show up at all, this probably means it either does not have the correct extension or does not lie within the search path for plugins. Other culprits could be some weird encoding mishap (save the file again with a good editor in UTF-8 encoding) or no read access for Cinema in this path.
I forgot the basic, but where did you installed you plugins ?
Did you add the folder into the preferences for plugins directory ?
It is definitely in the correct installation location, in the user data plugins folder that C4D sets up, since I can see another working plugin in the same location show up in both the plugin manager and in the UI.
Again, I am simply copying the plugin folder from the R19 location to the R20 and R21 location. Nothing else is changing. It could be an encoding issue that R19 and its version of python handles, but that R20 & R21 don't. I was looking into that last night before you mentioned it. I'll keep checking that.
before I would chase down any weird encoding problems, I would really make sure that my pyp file is not being executed. So put something like this into your pyp file:
if __name__ == "__main__":
print "my plugin is executed as the main module"
I just did some tinkering and found out that if you do not do any registration calls in a pyp file Cinema (R20) crashes. All this lets me think that Cinema actually does not see your file at all, because if the file would be executed c4d would either crash, throw an exception or load the plugin.
I would double check that you have both read access to the plugin pyp file path and plugin folder path, i. e. if that file/folder is not hidden and the user with which you run c4d has reading permissions.
As i said, hard to say without your code.
side note :
you should not install your plugins in any of cinema4D's folder. (preferences or main directory)
But choose any directory you want on your disk and add this directory into the plugins search paths (preferences of cinema4D --> plugins section)
You can use the preferences folder only to store the preferences of your plugin.
I will considered this thread as solved tomorrow if you have nothing to add.