making player class serializable