Fixed bug where selection index in attack template would always be 0