- Joined
- Jun 27, 2010
- Messages
- 3,253
I am trying to make a unit to train 5 workers, create a unqiue mine(if race requires) and replace it with the respective town hall. However I stumbled upon two issues.
1.I cant find what is wrong with the trigger, but when I buy a unit it creates 4 more, and then - it creates 5 town halls.
2. The wisps cannot enter the entangled gold mine, and the acolytes cannot enter the haunted gold mine. They are a copy, but I haven't removed any abilities and classifications.
1.I cant find what is wrong with the trigger, but when I buy a unit it creates 4 more, and then - it creates 5 town halls.
2. The wisps cannot enter the entangled gold mine, and the acolytes cannot enter the haunted gold mine. They are a copy, but I haven't removed any abilities and classifications.
-
Manage Picked Race
-

Events
-


Unit - A unit Sells a unit
-
-

Conditions
-


Or - Any (Conditions) are true
-



Conditions
-




(Unit-type of (Selling unit)) Equal to |cff0000ffRace Pick|r (Alliance)
-




(Unit-type of (Selling unit)) Equal to |cffff0000Race Pick|r (Horde)
-
-
-
-

Actions
-


Set SellingPicker = (Selling unit)
-


Set SoldFromPicker = (Unit-type of (Sold unit))
-


Unit - Order SellingPicker to train/upgrade to a SoldFromPicker
-


Unit - Order SellingPicker to train/upgrade to a SoldFromPicker
-


Unit - Order SellingPicker to train/upgrade to a SoldFromPicker
-


Unit - Order SellingPicker to train/upgrade to a SoldFromPicker
-


-------- For the Ones with Unique Gold Mine ---> --------
-


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



If - Conditions
-




SoldFromPicker Equal to AssosiatedWorker[4]
-
-



Then - Actions
-




Set StarterTempLoc = (Position of SellingPicker)
-




Set PickNearbyMineStarter = (Units within 1000.00 of StarterTempLoc matching ((Unit-type of (Matching unit)) Equal to Gold Mine))
-




Unit - Change ownership of (Random unit from PickNearbyMineStarter) to (Owner of SellingPicker) and Change color
-




Unit - Replace (Random unit from PickNearbyMineStarter) with a Entangled Gold Mine using The new unit's max life and mana
-




Custom script: call RemoveLocation(udg_StarterTempLoc)
-
-



Else - Actions
-
-


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



If - Conditions
-




SoldFromPicker Equal to AssosiatedWorker[3]
-
-



Then - Actions
-




Set StarterTempLoc = (Position of SellingPicker)
-




Set PickNearbyMineStarter = (Units within 1000.00 of StarterTempLoc matching ((Unit-type of (Matching unit)) Equal to Gold Mine))
-




Unit - Change ownership of (Random unit from PickNearbyMineStarter) to (Owner of SellingPicker) and Change color
-




Unit - Replace (Random unit from PickNearbyMineStarter) with a Haunted Gold Mine using The new unit's max life and mana
-




Custom script: call RemoveLocation(udg_StarterTempLoc)
-
-



Else - Actions
-
-


-------- Now the Town Hall -----> --------
-


For each (Integer A) from 1 to 12, do (Actions)
-



Loop - Actions
-




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





If - Conditions
-






SoldFromPicker Equal to AssosiatedWorker[(Integer A)]
-
-





Then - Actions
-






Unit - Replace SellingPicker with a AssosiatedTownHall[(Integer A)] using The new unit's max life and mana
-






Skip remaining actions
-
-





Else - Actions
-
-
-
-
-
