• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

How to buff a unit?

Status
Not open for further replies.
Level 7
Joined
Jun 23, 2009
Messages
297
Hmm ok so either I suck at searching in the forum, or it hasn't been questioned yet... Anyways... I want to buff certain units when the map starts. I've been able to add an ability to the unit, but there's no "add buff", only "remove buff". So, how can I buff a unit? I want the buff to last about 30 secs.
 
Level 9
Joined
Dec 15, 2009
Messages
523
what buff u mean?
is it like when the map starts they all hav regeneration aura?
or everybody get howl of terrored?
explain.
____________
im taking a break from my aos map CoE and clear my mind and get some ideas
 

sPy

sPy

Level 21
Joined
Apr 10, 2009
Messages
268
  • Movement Spd Add
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set Allunits = (Units in (Entire map))
      • Unit Group - Pick every unit in Allunits and do (Actions)
        • Loop - Actions
          • Unit - Set (Picked unit) movement speed to ((Default movement speed of (Picked unit)) + 125.00)
      • Wait 5.00 seconds
      • Unit Group - Pick every unit in Allunits and do (Actions)
        • Loop - Actions
          • Unit - Set (Picked unit) movement speed to (Default movement speed of (Picked unit))
      • Custom script: call DestroyGroup(udg_Allunits)
 
Level 7
Joined
Jun 23, 2009
Messages
297
I don't know, but, something by triggers? I mean sPy's method is quite good, except that the effect slowly faded, I want it to disappear from one second to another.
And, I'm not sure about your method Kino, are you saying about giving the item to each unit? Because not all of them have an inventory...

Edit: Thanks a lot sPy! That was about what I was looking for!

Edit 2: Ok, so, for some reason, it's not working...


dibujovvh.png
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
How about this:

Use dummy unit and custom slow ability. Make the slow have several levels, each level having lower effect than the previous.

Set Check dependencies to false, edit allowed targets, set mana cost to 0, set cast time to 0, edit cast range and buff

  • Untitled Trigger 066
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • Set i1 = 1
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in group and do (Actions)
        • Loop - Actions
          • Set p1 = (Position of (Picked unit))
          • Unit - Create 1 Footman for Neutral Passive at p1 facing Default building facing degrees
          • Unit - Add Slow to (Last created unit)
          • Unit - Order (Last created unit) to Human Sorceress - Slow (Picked unit)
          • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
          • Custom script: call RemoveLocation(udg_p1)
      • Wait 2.00 seconds
      • Set i1 = (i1 + 1)
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in group and do (Actions)
        • Loop - Actions
          • Set p1 = (Position of (Picked unit))
          • Unit - Create 1 Footman for Neutral Passive at p1 facing Default building facing degrees
          • Unit - Add Slow to (Last created unit)
          • Unit - Set level of Slow for (Last created unit) to i1
          • Unit - Order (Last created unit) to Human Sorceress - Slow (Picked unit)
          • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
          • Custom script: call RemoveLocation(udg_p1)
      • Wait 2.00 seconds
      • Set i1 = (i1 + 1)
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in group and do (Actions)
        • Loop - Actions
          • Set p1 = (Position of (Picked unit))
          • Unit - Create 1 Footman for Neutral Passive at p1 facing Default building facing degrees
          • Unit - Add Slow to (Last created unit)
          • Unit - Set level of Slow for (Last created unit) to i1
          • Unit - Order (Last created unit) to Human Sorceress - Slow (Picked unit)
          • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
          • Custom script: call RemoveLocation(udg_p1)
 
Level 7
Joined
Jun 23, 2009
Messages
297
Sorry Maker, I didn't understand a word you said :( But, how can it be so complicated to merely buff a few units? I mean, it's no rare thing, why isn't there trigger for it?
defskull I'll check the map when I come home, thanks for the help
 
Status
Not open for further replies.
Top