• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

[AI] How to make Computer players cast spells?

Status
Not open for further replies.

nailuj

N

nailuj

Is there an easy way, besides triggers, to make a unit owned by the computer cast a spell?
 
You can't just do nothing...Here is the solution for everyone: (I Finally figured it out)

Go into the scenario menu
_click on the player properties option
_click the Player's tab
-> Set the appropriate player to a computer player

_then click on the forces tab
-> Ensure that 'Custom Forces' and 'Fixed player settings' is ticked.

Go into the trigger editor
_click on melee initialisation
->delete the 'Run AI scripts' function.

The result is an AI that obeys your orders, never retreats and casts spells.

BEAWARE that spells will be cast given that certain conditions are met. For example, I gave a caster the 'Hurl Bolder' ability. The caster will only cast the spell when he is directly attacked by an enemy unit. It would be great if somebody could list what spells are triggered under what conditions. e.g:

_All damage spells are triggered when the unit is under attack.
_AOE spells are triggered when there are a few enemy units.

Something like the above but without my vagueness.
 
Status
Not open for further replies.
Back
Top