I was just wondering how you kill a unit by bring a unit to another unit. like lets say a tank touches a marine and the tank dies how do you do that? plz help me!
You need to use the 'move location' action. Then just simply make a 'bring unit to location kill unit at location'.
[url=http://www.maplantis.org]If you want a dynamic Tank death system where if it touches any Marine at any location it will die, then this is what you do:
1. Create a Location and name it "TankLoc".
2. Create the trigger:
Trigger |
Conditions: |
¤ Always. |
Actions: |
¤ [MOVE LOCATION] Center location labeled 'TankLoc' on Terran Siege Tank owned by Current Player at 'Anywhere'. |
¤ Preserve trigger. |
This trigger moves the location TankLoc onto the Terran Siege Tank.
Next you need the kill trigger:
Trigger |
Conditions: |
¤ [BRING] All players brings at least 1 Terran Marine to 'TankLoc'. |
Actions: |
¤ [KILL UNIT]Kill all Terran Siege Tank for Current Player. |
¤ Preserve trigger. |
The move location action only moves the location to one Siege Tank on the map.[/url]
And you might want to use Hypertriggers if you want the unit to die immediatly, so they don't have a chance to get away within the normal 2 seconds per trigger fire.
so then can i move the tank around and when it touches a marine it will die then?
only if you control one tank.
if you have more than one tank, only the leftmost one will die if it touches a marine.
Bottom leftmost to be exact. The action to center location on a unit or any action where there is more than one unit possible to have it happen to it then it will happen to the unit furthest to the bottom left. So in your case you would want to center it on the marine (am I correct) and then say if the tank goes inside the location that is following the marine, then kill all tanks in that location, that way it doesnt just kill the tank on the bottom left.
There are two ways to go about this; centering on the tank and centering on the marine. If there is only one marine, then:
(EDIT'd with Falk's suggestion below.) Current player commands atleast 1 marine: Move location 1x1 on marine, kill all tanks at 1x1, preserve trigger.
And like everyone else said, it centers on the left-most marine in the parent location. If there is only one tank, then:
Always: Move location 2x2 on tank., preserve trigger.
If player brings atleast 1 terran marine to 2x2: kill all tanks at 2x2, preserve trigger.
I hope that cleared things up for you.
Hmm you wouldnt want to use the always condition, you would want to use something that would stop if the unit the location is following died, otherwise, if the marine died the location would go to a seemingly random place and kill any tanks that go there, so don't use the always condition and make it so that one of the triggers for killing the tanks is that there is also a marine in the location.