Completely refactored the Cup infrastructure. Some things aren't working yet, but we're getting there.