HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Computer Autocast Ability

11-19-2005, 09:17 PM#1
Thunder_Eye
Is it possible to make computer or neutral units autocast spells like "Howl of Terror" Without having to use triggers?
11-19-2005, 11:57 PM#2
Balthamos
Hrmmm, not with the object editor on its own.

However, I get the impression you don't want to use the triggers because then you'd have to have something checking for when enemies are within range of these comps? And thus have really muddled triggering, etc.

Perhaps then, a compromise. You could give them an autocast ability, and have a trigger that checks for the casting of said autocast ability. The action that results would be the stopping of that spell and the ordering to cast 'howl of terror' (for example)

Does that help? I'm pretty sure it'd work.
11-20-2005, 01:17 AM#3
TaintedReality
Is it only Howl of Terror or does the computer not cast any spells? And by autocast do you mean actually autocast, where the computer/player doesn't have to order the unit to do it, or are you just saying cast normally?
11-20-2005, 10:58 AM#4
Thunder_Eye
Ive only tested Howl of Terror so far but with computer autocasting I mean normal abilities that the comp cast by themselves.

Balthamos: Yeah Ive thought of that way, just need to find some autocast abilities then ;P

Its just that sometimes Neutral Hostiles casts spells in melee games, like the "Ogre Lord's" Shockwave, does this just work for some abilities and in that case why?

EDIT: I assume this only works on the spells with (Neutral Hostile) after, any way to add this (Neutral Hostile) in any spell?
11-20-2005, 04:00 PM#5
TaintedReality
I think just running the Melee AI for that player will make him cast whatever spells his units have.
11-20-2005, 05:18 PM#6
Thunder_Eye
Ok Im gonna try that out.

EDIT: No that didnt work.

else is there anyone here that can AI script it? Or someone who can show me how to do just these things like when he get attacked, cast Howl of Terror. When he has 30% hp, cast heal. And so on

EDIT 2nd:
Ok I made some testing and the melee.ai works, but only on the melee heroes, can I change the script to work on my heroes instead?
11-21-2005, 12:44 AM#7
TaintedReality
Hmm, I think it should work on your heroes, unless the spells they are casting are dummy spells. It works fine in my map =P. But if you have a low amount of spells, you can just take the time and put em into triggers. Just do something like this.
Code:
Event:
Unit is attacked
Condition:
Attacked unit has ability Howl of Terror
Attacking unit has buff Howl of Terror equal to false
Action:
Order Attacked Unit to cast Neutral Pit Lord - Howl of Terror
Of course, he'll probly end up wasting mana using it in small fights..but iunno what else to do. Try using the melee.ai again, because it really should work. OH! Make sure the melee.ai is the expansion one, since howl of terror is tft only and all ; ). I made the mistake of running the RoC ai once when I needed the TFT ai.

Edit: Actually..now that I go and look at it my custom heroes AREN'T casting their spells =\. I've had enough map making for today, but tommorow I'll get on it and see if I can get it to work ^^.