Prepared code to work with multiple players