- Joined
- Jun 27, 2010
- Messages
- 2,763
Hi everyone, in my map there is a leaderboard that shows structure count of each player.
Adds when player begins construction
Subtracts when buildings gets destroyed or cancels constructions
It works with the first two fine, but then with "cancels cosntruction" it actually substracts (all + 1)
So i added
My question is how do I soolvee this problem, and how to check if the progress of a construction is 100% or not
Adds when player begins construction
Subtracts when buildings gets destroyed or cancels constructions
It works with the first two fine, but then with "cancels cosntruction" it actually substracts (all + 1)
So i added
-
Set Score_Buildings[TempInt] = (Score_Buildings[TempInt] - 1)
My question is how do I soolvee this problem, and how to check if the progress of a construction is 100% or not
-
Add Building
-
Events
-
Unit - A unit Begins construction
-
-
Conditions
-
Actions
-
Set TempInt = (Player number of (Owner of (Triggering unit)))
-
Set Score_Buildings[TempInt] = (Score_Buildings[TempInt] + 1)
-
Leaderboard - Change the value for (Player(TempInt)) in Leaderboard to Score_Buildings[TempInt]
-
-
-
Cancel Building
-
Events
-
Unit - A unit Cancels construction
-
-
Conditions
-
Actions
-
Set TempInt = (Player number of (Owner of (Triggering unit)))
-
Set Score_Buildings[TempInt] = (Number of units in (Units owned by (Player(TempInt)) matching (((Matching unit) is A structure) Equal to True)))
-
Set Score_Buildings[TempInt] = (Score_Buildings[TempInt] - 1)
-
Leaderboard - Change the value for (Player(TempInt)) in Leaderboard to Score_Buildings[TempInt]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
And - All (Conditions) are true
-
Conditions
-
Score_Buildings[TempInt] Equal to 0
-
Workers_Count[TempInt] Equal to 0
-
-
-
-
Then - Actions
-
Leaderboard - Change the color of the label for (Player(TempInt)) in Leaderboard to (100.00%, 100.00%, 100.00%) with 0.00% transparency
-
Leaderboard - Change the color of the value for (Player(TempInt)) in Leaderboard to (100.00%, 100.00%, 100.00%) with 0.00% transparency
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(AllyOf[TempInt] slot status) Not equal to Is playing
-
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Score_Buildings[TempInt] Equal to 0
-
-
Then - Actions
-
Leaderboard - Change the color of the label for (Player(TempInt)) in Leaderboard to (67.00%, 93.00%, 87.00%) with 0.00% transparency
-
Leaderboard - Change the color of the value for (Player(TempInt)) in Leaderboard to (67.00%, 93.00%, 87.00%) with 0.00% transparency
-
-
Else - Actions
-
-
-
Else - Actions
-
-
-
-
Destroed Building
-
Events
-
Unit - A unit Dies
-
-
Conditions
-
((Triggering unit) is A structure) Equal to True
-
-
Actions
-
Set TempInt = (Player number of (Owner of (Triggering unit)))
-
Set Score_Buildings[TempInt] = (Score_Buildings[TempInt] - 1)
-
Leaderboard - Change the value for (Player(TempInt)) in Leaderboard to Score_Buildings[TempInt]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
And - All (Conditions) are true
-
Conditions
-
Score_Buildings[TempInt] Equal to 0
-
Workers_Count[TempInt] Equal to 0
-
-
-
-
Then - Actions
-
Leaderboard - Change the color of the label for (Player(TempInt)) in Leaderboard to (100.00%, 100.00%, 100.00%) with 0.00% transparency
-
Leaderboard - Change the color of the value for (Player(TempInt)) in Leaderboard to (100.00%, 100.00%, 100.00%) with 0.00% transparency
-
-
Else - Actions
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(AllyOf[TempInt] slot status) Not equal to Is playing
-
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Score_Buildings[TempInt] Equal to 0
-
-
Then - Actions
-
Leaderboard - Change the color of the label for (Player(TempInt)) in Leaderboard to (67.00%, 93.00%, 87.00%) with 0.00% transparency
-
Leaderboard - Change the color of the value for (Player(TempInt)) in Leaderboard to (67.00%, 93.00%, 87.00%) with 0.00% transparency
-
-
Else - Actions
-
-
-
Else - Actions
-
-
-