public static bool IsPathOpenForSourceForwardBlockSolid(OCAction action, OCActionArgs args) { OCMap map = (OCMap)GameObject.FindObjectOfType(typeof(OCMap)); CharacterController charController = args.Source.GetComponent <CharacterController>(); return (map.IsPathOpen (args.Source.transform , charController.height , OCMap.PathDirection.ForwardBlockSolid ) ); }