Refactoring Coin plugin and adding support for "heads or tails?"