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

[AI] How to make computer heros cast spells

Status
Not open for further replies.
Level 3
Joined
Apr 9, 2008
Messages
42
How do you make it so a hero which is on a computers team casts his spells?

Whenever I have a hero on a computers team he just stands still waiting for an enemy to come near him and he doesn't cast any spells.
 
Level 5
Joined
Oct 27, 2007
Messages
158
How do you make it so a hero which is on a computers team casts his spells?

Whenever I have a hero on a computers team he just stands still waiting for an enemy to come near him and he doesn't cast any spells.

If the hero is under AI control then you need to apply skills to the hero through a trigger, or give the AI a skill plan through an AI script. The hero doesn't learn skills without a triggered event or an AI script.
 
Level 3
Joined
Apr 9, 2008
Messages
42
No I don't need the hero to learn spells I just want him to cast them.
 
Level 5
Joined
Oct 27, 2007
Messages
158
What spells are not cast? Custom ones? More details please.
Does the computer player's hero has the ability learned? This is a must...
Despite what you're saying. You have to either set the ability level in the map editor in the hero properties, or set abilities using triggers, or use an AI script.

Last but not least. Are you sure that the hero has enough mana to cast the spell?
 
Level 12
Joined
Apr 27, 2008
Messages
1,228
Maybe he is talking baout how to open up the ai editor and add conditions for the spells.
 
Status
Not open for further replies.
Top