Closed hu-po closed 3 years ago
clicking the Run button in the Execute Panel is causing Blender to fudge the context in some way? I've tried smaller versions of the scripts and run them from the text editor's run button and they work fine, it's when you use the zpy Run function that things go wrong
Object selection does not change bpy.context.active_object
selection != active object is what I've found so far. This snippet clears both selection and active object, then sets again. Works to select the object but doesn't seem to fix the problem with the make objects real operator.
Might have found a clue here. There seems to be a difference between "active" and "selected"
Also hitting Play button on the script does not cause this:
To properly run the "run" script, a zpy user has to click the "Run" button under the ZPY panel. If they click the "Run" button in the Blender script panel, it will not save and reset the scene, resulting in simulation drift. We should provide a warning, or simply make the "run" button in the blender script also a valid option.