I used a free, ready to use script for jigsaw puzzles in Ren'py and modify things to my need, I could never make a script myself, it is beyond my understanding.
Glad you like the idea :)