Balancing combat between two objects

I have a battle scene with 6 units on each side, but one side always wins 6-0, and I realised that it’s if their For Each loop comes first in the Events list.

This is what my events look like:

How can I balance these out so that they each have an equal chance?

Also, the events are written so that when a unit from Team A collides with a unit from Team B, they both stop and reduce each other’s health variable (both 100) every 2 seconds, with a number between 50 and 100.
The other issue here is that the last unit from the dominant team (by Event order) always seems to be the one who mops up the rest of the units, going from his first collision+combat to the rest, even though the other units should’ve already reduced the enemy unit’s health by that point.

(I’d upload the full scene/event for someone to debug, but I can’t separate it from my other bigger scenes in the project, which I’d rather not post publicly right now.)

Your first event resets the attack cooldown, so your second event never triggers the attack action. I’d give each object an internal cooldown to manage its attack (some object variable that is has a -1*TimeDelta() applied). But you could also just give the second event a separate cooldown timer.

The damage system is weird too, you are not subtracting 50-100 every 2 seconds, when the timer is greater than 2 seconds you start subtracting 50-100 each frame until the other unit is dead and then reset the timer, or am I misreading it? :confused:

I’ve had another play around with the timers, and created separate timers for each team. However, that means that it’ll be reset for all units on that team regardless of what they’re doing, so not sure how that’ll affect the balance…

It seems to work for now, but the issue now is in the way I’ve set up collision.

I can’t, for the life of me, seem to stop units on the same team from crowding on top of each other.
I’ve set up a collision->move away condition and action, but it seems to get ignored.
This means that the units from the same team pile on top of each other, all ‘colliding’ with multiple enemies, which means that when one of the enemy units is killed, all other enemies in collision with the one attacker get killed as well.
I can’t seem to separate them.

I realised I could just move all of this to a separate project, and have uploaded the project here. If someone could take a look for me, I’d be incredibly grateful. (32.2 KB)