Trigger actions without hitting keys

Following problem:

I have a game piece which represents a unit of warriors with 30 layers that each represent one warrior.
On layer 1, there is one warrior, on layer 30 there are 30 warriors.

Now I want to count the current warriors (I have a dynamic property “Quantity”, so this is no problem) in the unit and dependent on the result want to have performed several actions (or key strokes).

Unfortunately the Trigger Action trait seems not to be usable for this problem as it always needs an own performed keystroke.

That I want to avoid, because whether hitting the keystroke for the trigger or hitting the keystroke for the desired action would be no difference at all. It should be automatically.
Anyone an idea ?