A little more patience, almost done.
I need to test it for bugs and evtl leave you some comments, so you don’t get completely lost.
i did not fully test everything, so you might encounter some bugs.
i did not fully explain everything in the comments, but i hope they help a little.
but this example should have most of everything you need:
Advanced Draggable Shape Painter
Comes at a good timing:
This is worth implementing