modified the Ability class