Refactoring of Character class to improve inheritance