The game is Trick or Treat Beat, hosted on Cartoon Network's site.
You can find it here: https://www.cartoonnetwork.com/games/cc/trickortreatbeat/
The candy collecting and the costume-based abilities you remember, flight and rock-breaking among them, are the core of it.