• 🏆 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] Some trigger problem

Status
Not open for further replies.
Level 8
Joined
Sep 24, 2007
Messages
300
1. Units are ordered to walk into a region
2. On left and right side of that region are towers and ranged enemy units. Those units are on the cliffs, so normal meele units cannot attack them.
3. Instead of walking forward, to attack tower, they start running around the cliffs, and ranges simply kill them.

Trigger:
Unit enters region
Owner of picked unit equal to player 6
Pick every unit in region and do action: Order picked unit to attack tower.

It looks like units stop walking in the triggering direction, because they are attacked, and as soon as they are attacked, they try to attack back. I tried with another trigger:

Every 1 second of game time
Owner of picked unit equal to player 6
Pick every unit in region and do action: Order picked unit to attack tower.

This should pick all units every second, and send them to attack tower, but units still doesn't obey the orders. They still want to attack back.


So, anyone have a suggestion, how to order units to attack tower, even if they are attacked? It should be like in stronghold: Spawned units run to enemy base, and even if there are mass towers, they don't give a shit and proceed.

How to do that?
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
Ok, first it wouldn't work because the condition - Owner of picked unit equal to player 6 isn't working... you did that condition BEFORE you actualy picked a unit so you order "picked unit=no one" to attack the towers.

Your trigger should look like this:
  • Unknown
    • Events
      • Unit - A unit enters A_Region
    • Conditions
      • (Owner of (Triggering unit)) Equal to Player 6 (Orange)
    • Actions
      • Unit - Order (Triggering unit) to Attack A_Tower

Now off topic, please when writting triggers put it into the trigger code so its easier to see (its on the menu when u type your comment or you can just type "[TRIG*GER]" and "[/TRIG*GER]" (without the "*")and put your code in beetwin.
To copy the code as text from the World Editor just right click on the Event/Condition/Action/Whole trigger and click on Copy As Text.
 
Level 8
Joined
Sep 24, 2007
Messages
300
Your trigger doesn't work. Units still want to attack the attackers.

About condition, I used conditions with pick options like this in some other triggers and it worked just fine.

Any other suggestions?
 
Level 3
Joined
Apr 7, 2007
Messages
48
Your description of this problem is confusing, There are towers on the left and right .. so you want them to attack those towers or no? Then you mention a tower in front and I'm not sure if you mean the left and right towers or not .. but w/e

To make them NOT attack:
Order them to Move, not Move and Attack to whatever point. Also if they have to stand still try ordering them to Hold Position.

To make them only attack the tower:
Trying making their attacks only able to hit buildings (if you aren't using them for anything else in the map)
 
Level 8
Joined
Sep 24, 2007
Messages
300
1. Yes, there are 2 towers on the cliffs, and one forward the cliffs, which should be attacked.
2. I will try move, but I didn't use Move and attack now, only attack.

Actualy, I think that I should disable auto attack when units come in region, so they wouldn't attack all the enemies around them. Is it possible to do that (if your suggestions won't work)?
 
Status
Not open for further replies.
Top