Pieces of eight are a currency from the Trouble Brewing minigame, and are used to buy rewards from Honest Jimmy's House of Stuff. A player can receive up to 100 pieces each game from just resources. Each resource deposited (i.e. buckets of water, bowls of coloured water, etc.) counts as 1 Piece of Eight at the end of the game. Each rum deposited for your team counts as 2 extra pieces for each person on your team at the end of the game.
Contrary to popular belief, the amount received at the end of a game is not dependent on who is winning. The score is more for keeping track of how many rather than who has the most, but it may still be used as such.
The amount of pieces it takes to complete a full outfit in Old School Runescape takes approximately 8 hours to achieve, as the average amount gained is 100+ and each match is 25 minutes long.