I needed to both drag and click sprites for my moon gems game (
traviswalton.itch.io/moon-gems ). Took me a while to get it working nicely. I shared the mouse drag code here in case anyone finds it useful, maybe for a card game or something? :
github.com/TravisWalton... #solodev #indiedev #gamedev
GitHub - TravisWaltonGames/HTML5CanvasDrag: Simple drag and drop of sprites within a canvas
Simple drag and drop of sprites within a canvas. Contribute to TravisWaltonGames/HTML5CanvasDrag development by creating an account on GitHub.