The way you explain could be done this way:
Add Global variable "Groups"
system every 0.05 seconds
set variable Groups to : choose(1,2,3)
set group1 deactivated
set group2 deactivated
set group3 deactivated
-- If variable groups is 1
set group1 activated
-- If variable groups is 2
set group2 activated
-- If variable groups is 1
set group3 activated
It would probably be much easier to call a function on attack with a parameter set to choose(1,2,3) and base the attack on the parameter, but well..