- Joined
- Dec 2, 2016
- Messages
- 733
-
AntiTeamKill
-
Events
-
Unit - A unit Is issued an order targeting an object
-
-
Conditions
-
Actions
-
For each (Integer A) from 1 to 10, do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(BaseRegionsForTeamKill[(Integer A)] contains (Targeted unit)) Equal to True
-
(Issued order) Equal to (Order(attack))
-
BasesInUse[(Integer A)] Equal to True
-
Bases[(Integer A)] Not equal to (Owner of (Triggering unit))
-
-
Then - Actions
-
Unit - Order (Triggering unit) to Stop
-
-
Else - Actions
-
-
-
-
-
-
Starting Events
-
Events
-
Time - Elapsed game time is 0.00 seconds
-
-
Conditions
-
Actions
-
Set BaseRegionsForTeamKill[1] = Base1 <gen>
-
Set BaseRegionsForTeamKill[2] = Base2 <gen>
-
Set BaseRegionsForTeamKill[3] = Base3 <gen>
-
Visibility - Disable black mask
-
-
So on game start, I set BaseRegionsForTeamKill index to each base region. Base 1 = a region, 2 3 etc
But I just tested with some friends, and the building gets destroyed even though it's claimed. Any idea what the issue could be? Is the building being destroyed before the trigger can fire?
And regarding all the variables in the first trigger, they are all correct and have the player stored. I know because my claim base trigger works, and I have another bit of code that cancels construction if the base is claimed and someone not the owner builds. That works good. Just the team kill doesn't.