Array of subclass

You are mixing up classes and object instances.
Can you show what “castAbility” method looks like ?