• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Hero auto-attacking problem

Status
Not open for further replies.
Level 2
Joined
May 30, 2013
Messages
8
Does anyone know how to disable hero auto-attacking?
For example: My hero was hiding in a bush, an enemy unit went across (but it didn't see my hero) and then my hero attacked it.
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
Making the unit a worker makes the idle button at the bottom left I think.
How about this--

  • stop auto attack
    • Events
      • Unit - A unit enters Bush <gen>
    • Conditions
    • Actions
      • Unit - Set (Triggering unit) acquisition range to 1.00
  • Enable autoattack
    • Events
      • Unit - A unit leaves Bush <gen>
    • Conditions
    • Actions
      • Unit - Set (Triggering unit) acquisition range to (Default acquisition range of (Triggering unit))
 
Level 21
Joined
Mar 27, 2012
Messages
3,232
There's one other way
Make a modified silence ability that disables attacks, but not spells.
Make it so that whenever a unit enters a bush you cast that silence on it.
Make the silence last long.
Make it so the silence buff is removed when unit leaves buff.

Note that in this case it's good to also make a custom buff.
 
Level 13
Joined
Mar 24, 2013
Messages
1,105
@ Undead
I'm sorry, I don't understand. Are you saying if the unit is within that 1 range of acquisition?
Edit:
Ohhhhh. If its a ranged unit. You can still attack at whatever their range is I believe, you just have to order the attack.


@Xonok I think he wants the unit to still be able to attack from the bush, just not auto attack from it, they would like the user to decide when to "reveal" oneself.
 
Status
Not open for further replies.
Top