added option to choose special ability function