refactored and added Player class and header