• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece!🔗 Click here to enter!

Capture Unit on Death help triggers

Status
Not open for further replies.

Chaosy

Tutorial Reviewer
Level 40
Joined
Jun 9, 2011
Messages
13,183
  • some trigger
  • Events
  • Unit - A unit dies
  • Conditions
  • Actions
  • Unit create a unit for owner of killing unit at posision of dying unit
written at free hand

EDIT right one is bellow not free hand
  • Untitled Trigger 001
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Dying unit)) Equal to (Unit-type of your_unit)
    • Actions
      • Unit - Create 1 (Unit-type of (Dying unit)) for (Owner of (Killing unit)) at (Position of (Dying unit)) facing Default building facing degrees
i know it leaks but i show how to do this not how to make leakless :p
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
You can use Resurrection ability. Make it revive one unit. When a unit dies, create a dummy at he unit's position and order the unit to use resurrection. Then change the owner of the dying unit. Make sure the death of the dummy won't run the action, otherwise the game will freeze since it causes an infinite loop.
 
Status
Not open for further replies.
Top