implement support for team mode
incorporate team modes, and add controller tests