Hallo,
ich habe dein Script jetzt nicht wirklich verstanden, aber wir haben da was im Wiki:
-
Für Drag & Drop in vordefinierte Bereiche mit dem Drag&Drop-API:
https://wiki.selfhtml.org/wiki/JavaScript/Drag_%26_Drop -
Für freies Drag & Drop
https://wiki.selfhtml.org/wiki/JavaScript/Tutorials/Drag_and_Drop
Gruß
Jürgen