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

[Trigger] need help for a "bastard" trigger

Status
Not open for further replies.
Level 20
Joined
Nov 20, 2005
Messages
1,178
When an enemy unit(e.g. player 2) comes into a certain range from any mine-owned peons, the unit has to give attack priority to the peon, hence ignoring other units that will attack it. It's a bastard trigger cuz the enemy concentrates its strikes on your peons, hence damaging seriously your resource production.
 
Level 5
Joined
Jul 11, 2007
Messages
152
You can make it so the peon isn't attacked at all that would solve the problem.

Unit attacks

Unit type of attacked unit equal to peon

Pause attacking unit

If you want them to attack peons last you could add another condition so if no other friendly units are in range then the trigger doesn't meet the conditions and doesn't run
 
Level 20
Joined
Nov 20, 2005
Messages
1,178
maybe i wasn't clear.

The peon(my peon) has to be attacked when an enemy unit comes into a certain range from it. For example: enemy units are coming, i begin to attack them with mine and they retaliate........i take a peon near them because a gold mine is in the path: Here it goes! The enemy units see the peon as a whore and runs toward him to hit him. If i send units fighting this whore, the whore continues to attack the peon until he dies and another one come close like the previous one. Since then, the unit will stop becoming a whore and re-turn its attention to other units that are scratching its back.

Sounds clear now? ^^
I think "Unit comes in range" may be useful, but i dunno how to use it.
That's why i'm here.
 
Level 5
Joined
Jul 11, 2007
Messages
152
To clarify- Higher priority means it is more likely to be attacked, lower priority means it is less likely to be attacked.

Would you be against perhaps a hidden divine shield for the peons? Using spellbook you could trigger it when they get hit once and then the attackers would go back to attacking your units.
 
Level 5
Joined
Jul 11, 2007
Messages
152
Maddawg101 no offence, but next time read the first comment... lol :p

I did... many times sorry I misunderstood. Just trying to help. When he says the peon "has" to be attacked I saw that as the peon was already being attacked and you were trying to prevent it.

I hope we're all clear now.
 
Status
Not open for further replies.
Top