iBrushC / animextras

An open source Blender addon that adds extra animation functionality.
MIT License
167 stars 24 forks source link

New scene will keep the previous scene's onion skin information #10

Open Pravahati opened 3 years ago

Pravahati commented 3 years ago

I was trying out the addon on a test scene and then went to create a new (empty) scene. The previous scene's onion skin would appear when I'd select an object and then disappear once the object was deselected. It worked for both a Cube and Suzanne, and neither are animated. Interestingly, once I created an Empty the onion skin became visible at all time, even when nothing was selected or I went in Edit Mode. image Once I created another new scene, the onion skin would revert to its previous behavior of "I am only visible when you select an object"

Closing and restarting Blender did the trick but it might be good to automatically clear whatever cache there is once a new scene is opened

iBrushC commented 3 years ago

This is probably due to the data being stored in the script instead of blender's data. I'll see what I can do to fix it.

lucianomunoz commented 3 years ago

I can confirm this bug

schroef commented 3 years ago

I tried adding a @persistent function and calling clear_onion action. That still doesnt seem to do the trick. I think one of those handlers is never ended, i tried calling that finish function inside the draw_mesh class, but it doesnt help.