HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Locust ability not displayed in trigger editor?

02-28-2009, 02:18 PM#1
Michael Peppers
To be short: I want to do an ability that teleports the hero near an enemy and then deals damage to it, I've done everything, but the hero (during the action) can still receive orders from the player, so if a player is quick, can make him deal damage while running away. I tried to fix this by adding temporarily the locust ability to the hero, but it's not possible in the trigger editor. Suggestions?
Maybe changing the ability to a channel ability could be better? (I guess no)
How can I add to him the locust ability in spite of the fact that the trigger editor doesn't want me to use it?
02-28-2009, 02:32 PM#2
darkwulfv
If you're using GUI, you'll need custom script.

call UnitAddAbility(unit, 'Aloc')

There you go. When you want it removed, just call

call UnitRemoveAbility(unit, 'Aloc')
02-28-2009, 02:42 PM#3
Michael Peppers
Quote:
Originally Posted by darkwulfv
If you're using GUI, you'll need custom script.

call UnitAddAbility(unit, 'Aloc')

There you go. When you want it removed, just call

call UnitRemoveAbility(unit, 'Aloc')

Thanks, only one thing, the unit is an array variable: "SACaster[(Player number of (Owner of (Triggering Unit)))]", how should I write this?

EDIT:
Don't worry, found that thanks to the error log, + Rep incoming!
02-28-2009, 04:08 PM#4
Bobo_The_Kodo
It should also be one of the 'presets' in GUI if you are using NewGen
02-28-2009, 04:13 PM#5
Michael Peppers
Quote:
Originally Posted by Bobo_The_Kodo
It should also be one of the 'presets' in GUI if you are using NewGen

Well, I'm not using it...

Another problem right now, when the Locust ability is removed, the hero remains unselectable for the player. Suggestions?
02-28-2009, 04:16 PM#6
darkwulfv
That's an unfortunate side effect of Locust. Refer to the Warcraft III Ability Guide (here @ wc3c) for far more detail about Locust.

Perhaps adding/removing the Ward tag instead?
02-28-2009, 04:23 PM#7
Bobo_The_Kodo
Hide then Show the unit and locust will be gone... mostly
02-28-2009, 04:31 PM#8
Michael Peppers
Quote:
Originally Posted by darkwulfv
That's an unfortunate side effect of Locust. Refer to the Warcraft III Ability Guide (here @ wc3c) for far more detail about Locust.

Perhaps adding/removing the Ward tag instead?

Didn't find the Ward tag, but I tried the "asleep" and "stun" tag, with no result...

Quote:
Originally Posted by Bobo_The_Kodo
Hide then Show the unit and locust will be gone... mostly

Now the hero begins to wander after being unhidden, is that the "mostly" you are referring of? XD
02-28-2009, 04:33 PM#9
Bobo_The_Kodo
But can you select it and such?
02-28-2009, 04:41 PM#10
Michael Peppers
Yes, it works now, I only forgot to remove an "Issue Attack Order".

Thanks to you all, + Thanks to The Kodo!