add game finishing logic and fix player serializer