• 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.

[General] The Computer AI constantly target buildings instead of units

Status
Not open for further replies.
Level 12
Joined
Nov 3, 2013
Messages
989
I have this problem where the computer AI target buildings (usually with area of effect spells, e.g. Blizzard & rain of fire) and it does it even if structures & mechanical aren't on the "targets allowed"...

However the most annoying problem is the tornado. I have a spell that summon a tornado which has been slightly modified (the only notable changes afaik is that I increased the move speed on the unit and changed the damage aura against buildings damage to damage units is ntead of buildings).

As you can see in this short clip, when there are no buildings nearby the tornado work just fine, they run around a bit randomly and throw nearby units up into the air etc, but if there's any building (even ones without any attack, like the scout tower) the tornadoes focus them, they go right for them ignoring everything else and stay on top of the buildings instead of moving around...


p.s. sorry for the bad quality video, idk why OBS wasn't working properly.
 
Level 13
Joined
Oct 12, 2016
Messages
769
There is a reason for this: the base AI tends to focus tornados on buildings.
This is because in Warcraft's AI script, the Tornado spell is meant to demolish buildings.

One work-around is to detect when a tornado enters the map.
If it's owned by a computer player, force it to move to nearby enemy units on a periodic timer.
Else, I think you can do something in JASS and make a custom AI script, but I know nothing about JASS.
I just tend to exploit the base WC3 AI to do what I want it to do. Way easier.

Alternatively, there's always triggered spells!
Make a dummy "tornado" summon that "wanders" and use a dummy ability like Cyclone to have the same effect.
Make the dummy unit periodically cast Cyclone on a nearby unit.
 
Status
Not open for further replies.
Top