Addaction merely launches a script, so the addaction part is easy - its just as usual.
The tricky part is the script. For what you're describing I think you may need dialogues - tutes in the Ed Depot.
Alternatively you could just have the script give you a few more addactions, each one allowing you a new loon of a particular type. When you add the loon (created using createUnit) you also trigger a removeAction command to remove the actions.