• 🏆 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!

Respond to item use

Status
Not open for further replies.
Level 11
Joined
May 26, 2009
Messages
760
Greetings,

I have an item which a Hero use on a target unit. Then I want the triggers to create a new unit at the position of the targeted unit. How would the triggers look like? I can't seem to figure it out. Below are my current triggers.

Am very thankful for replies.

  • Place
    • Events
      • Unit - A unit Uses an item
    • Conditions
    • Actions
      • Set Loc = (Target point of ability being cast)
      • Unit - Create 1 Footman for (Owner of (Hero manipulating item)) at Loc facing Default building facing degrees
      • Unit - Create 1 Footman for (Owner of (Hero manipulating item)) at (Center of (Playable map area)) facing Default building facing degrees
 
Level 11
Joined
May 26, 2009
Messages
760
Thanks. Sorry for being unfocused. Time for bed anyway :)

Thanks again!

Yours,
Chizume

  • Place
    • Events
      • Unit - A unit Begins casting an ability
    • Conditions
      • (Ability being cast) Equal to Ability
    • Actions
      • Set Loc = (Position of (Target unit of ability being cast))
      • Unit - Create 1 Footman for (Owner of (Casting unit)) at Loc facing Default building facing degrees
 
Level 12
Joined
Jan 30, 2009
Messages
1,067
Don't forget to remove the leak.
  • Custom script: call RemoveLocation(udg_Loc)
Add that to the end.
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
Vizel said:
Add that to the end.
Cleaning leaks DOESN'T need to be at the end, it depends on the situation too ;D

Chizume said:
Thanks. Sorry for being unfocused. Time for bed anyway :)

Thanks again!

Yours,
Chizume

  • Working Trigger
    • Place
    • Events
    • Unit - A unit Begins casting an ability
    • Conditions
    • (Ability being cast) Equal to Ability
    • Actions
    • Set Loc = (Position of (Target unit of ability being cast))
    • Unit - Create 1 Footman for (Owner of (Casting unit)) at Loc facing Default building facing degrees

Well, you used Begins casting an ability
Use Adiktuz's way, Starts the effect of an ability
It is MORE efficient
 
Status
Not open for further replies.
Top