I have a map that moves units to a specific point after they are created and gives control to another player. My current trigger works fine for all the units I've tested it on but when I try to create units with the warp gate, the unit moves to the point and dies. I figured this was because it went out of range of the pylon before being fully warped in. I am trying to create a trigger so the units finish warping in and then move/assign control. Does anyone have some advice at what I should be looking at to achieve this. I've tried most everything I can think of, but with no success.
I'm still fairly new with working with the map editor, but have been learning fast. Thanks
I'm pretty sure you will just need a "Wait for Condition" action. Basically, you should do this:
1) warp a unit
2) wait until this unit is fully warped
3) issue order to the warped unit
If I understood well, for now you just have steps 1 and 3 in your trigger. So what you seek is to wait before the unit is entirely warped. In that case, just add the following action in between:
Wait for (Conditions) checking every 1 second
Unit (last created unit) is under construction = FALSE
(alternatively, you can check for "Unit progress (percent)" > 99%... This condition will check the production queue of the warp gate, while the other checks if the unit is done)
I don't know why your unit is dying while warping though, they usually can't move when they warp so I don't see why it would be cancelled (unless of course the pylon gets destroyed before the warping process finished). Be sure to check you don't have a trigger killing units somewhere, destroying your units when it shouldn't.
Ok, I was able to get it working. I had to create a trigger that once the unit's health reach's 100% is would move and transfer control. It's almost like there is no 'build progress' for warped units. They appear to be created and revive to 100% health.
thanks for the help, at least I knew I was thinking on the right track.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
I have a map that moves units to a specific point after they are created and gives control to another player. My current trigger works fine for all the units I've tested it on but when I try to create units with the warp gate, the unit moves to the point and dies. I figured this was because it went out of range of the pylon before being fully warped in. I am trying to create a trigger so the units finish warping in and then move/assign control. Does anyone have some advice at what I should be looking at to achieve this. I've tried most everything I can think of, but with no success.
I'm still fairly new with working with the map editor, but have been learning fast. Thanks
I'm pretty sure you will just need a "Wait for Condition" action. Basically, you should do this:
1) warp a unit
2) wait until this unit is fully warped
3) issue order to the warped unit
If I understood well, for now you just have steps 1 and 3 in your trigger. So what you seek is to wait before the unit is entirely warped. In that case, just add the following action in between:
Wait for (Conditions) checking every 1 second
Unit (last created unit) is under construction = FALSE
(alternatively, you can check for "Unit progress (percent)" > 99%... This condition will check the production queue of the warp gate, while the other checks if the unit is done)
I don't know why your unit is dying while warping though, they usually can't move when they warp so I don't see why it would be cancelled (unless of course the pylon gets destroyed before the warping process finished). Be sure to check you don't have a trigger killing units somewhere, destroying your units when it shouldn't.
Ok, I was able to get it working. I had to create a trigger that once the unit's health reach's 100% is would move and transfer control. It's almost like there is no 'build progress' for warped units. They appear to be created and revive to 100% health.
thanks for the help, at least I knew I was thinking on the right track.