I can create an Action with parameters using an Actiondefintion.

enter image description here

But how can I create an Eventdefinition ? I'd like to make an Event that is 'called' when a Unit, that is saved in a variable, dies. Like an Event called 'My unit dies'.

enter image description here

The desired behavior is the following:

  • Called when a unit defined in a variable dies
  • the deceased unit should be returned by 'Triggering Unit()'
  • the owning player of the deceased unit should be returned by 'Triggering Player()'

I hope you get my point, Thanks


1 Answer 1


It's not possible to create useful Event Definitions for this purpose. Creating a custom event definition basically requires custom scripting and you should probably avoid it.

What I think you want to do is create a Trigger that uses the Unit Dies event. Right click in the trigger list and select New -> New Trigger (Ctrl+T). Then right click Events in the trigger pane and select New Event (Ctrl+E). This should bring up a dialog that lets you pick the Unit Dies event.

After adding the Unit Dies event you can hook it up to only trigger when your hero dies by double clicking the Unit: Any Unit item and choosing your hero unit.

Then you can add any actions you want to this trigger that will be run when your hero dies.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .