fixed bug where emitted team was always 0