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

How to shoot?

Status
Not open for further replies.
Level 2
Joined
Jul 27, 2015
Messages
14
Hello, I want to know how to trigger this:
When an enemy is near a unit it will not attack, it will attack when we click or when we press ESC.

Can someone help me I will really appreciate it and +rep for someone who solve this.
 

Deleted member 242951

D

Deleted member 242951

For that u remove the attack ability of a unit or disable attacks via some purge. (Just set damage to 0 in the object editor)

Now create a trigger. The event is " Player 1 (red) skips a cinematic"

Then the actions are :

1. Unit - Create a dummy unit at position pf caster.


2. Unit - Give "Dummy attack" spell to *The dummy*

2.5 Unit - Add a 2.00 second generic expiration timer to *the dummy*
3. Set the level of dummy attack for dummy to 1.

4. Unit - Order *the dummy* to *the spells ID* *Who u want to attack*

5. Done !


To know more about dummy units and what they are / how they work check the hives tutorial section. :as:
 
Status
Not open for further replies.
Top