Well you have not shown the Logic you did for this.
From the scratch, without having it tested, i maybe would do it like this.
You have your AQS (attack queueing system) which stores the attacks in a dynamic list with a first in first out logic.
When player attacks, send an entry to the AQS AttackList.
When your AI (or whatever) attacks do so as well.
The AQS will have the attacks chronological saved.
Then Fire the attack stored in the first index. If its finished remove the attack from AQS.
Then Fire the attack stored in the next index.
and so on.
However i not 100% sure if you remove the first index will result that the next index becomes the first automatically.
But you can tell me your current solution too
best regards