public T GetBehaviour <T>() where T : Behaviour { return(Behaviours.OfType <T>().FirstOrDefault()); }
public IEnumerable <DamageBehaviour> OffensiveDamageBehaviours() { return(Behaviours.OfType <DamageBehaviour>() .Where(behaviour => behaviour.Flags.HasFlag(BehaviourFlags.Offensive)) .OrderBy(behaviour => behaviour.ModifierType)); }