Combine Buildings
Hello,
Posted is a trigger used to combine 8 of the same buildings and 1 center building, into 1 building itself.
The build is like this:
X X X
X Z X
X X X
When all of the X buildings have been upgraded or built to level 4 properly placed around the center building, they will combine into 1 big building. For some reason the trigger is not working. If you have any questions or need more information please ask! Any help?
Hello,
Posted is a trigger used to combine 8 of the same buildings and 1 center building, into 1 building itself.
The build is like this:
X X X
X Z X
X X X
When all of the X buildings have been upgraded or built to level 4 properly placed around the center building, they will combine into 1 big building. For some reason the trigger is not working. If you have any questions or need more information please ask! Any help?
-
Create Lumber Factory
-

Events
-


Unit - A unit Finishes an upgrade
-
-

Conditions
-


(Unit-type of (Triggering unit)) Equal to Lumber Mill Lvl 4
-
-

Actions
-


Set TempGroup = (Units within 196.00 of (Position of (Triggering unit)) matching ((((Unit-type of (Matching unit)) Equal to Repair Factory) or ((Point-value of (Matching unit)) Equal to 50)) and ((Custom value of (Matching unit)) Equal to 0)))
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




(Number of units in TempGroup) Greater than or equal to 1
-
-



Then - Actions
-




Set TempUnit = (Random unit from TempGroup)
-




Set TempPoint = (Position of TempUnit)
-
-



Else - Actions
-
-


Custom script: call DestroyGroup (udg_TempGroup)
-


Set TempGroup = (Units within 192.00 of TempPoint matching (((Unit-type of (Matching unit)) Equal to Lumber Mill Lvl 4) and ((Custom value of (Matching unit)) Equal to 0)))
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




(Number of units in TempGroup) Equal to 8
-
-



Then - Actions
-




Unit - Remove TempUnit from the game
-




Unit Group - Pick every unit in TempGroup and do (Unit - Remove (Picked unit) from the game)
-




Unit - Create 1 Dummy [Charm Transmute] for (Owner of (Triggering unit)) at TempPoint facing Default building facing degrees
-




Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
-




Hero - Create |cff8080c0[Item]|r|cffe38d1a Lumber Factory 6|r and give it to (Last created unit)
-




Hero - Order (Last created unit) to use (Last created item) on TempPoint
-
-



Else - Actions
-
-


Custom script: call DestroyGroup (udg_TempGroup)
-


Custom script: call RemoveLocation (udg_TempPoint)
-
-
Attachments
Last edited:





