Refactored the Mario class