Refactored some cloud code.  Added leaderboardFunctions module