Use the arrow keys to rotate the cannon you're in or to make it rotate faster. Then press spacebar to shoot! You can hit anywhere on a barrel to enter it.
Collect every gem in a level to receive a gold medal. The number of gold medals you have received is displayed in the bottom left. To unlock a costume, you need to have the amount of gold shown next to that costume.
Whenever your on a winning streak and have not died yet the levels you completed will show a happy face on them.