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

[AI] Buy a neutral hero

Status
Not open for further replies.
Level 6
Joined
Aug 22, 2008
Messages
123
Hello everyone

I guess nobody can help me with that problem, but if you can, I would be really glad.

My AI should be able to pick a hero out of a neutral tavern. In some tests I found out that
Code:
call IssueNeutralImmediateOrder(ai_player, Tavern, "beastmaster")
worked in testmaps, but not for my running AI. The problem may be that orders in AI scripts cannot be given to units the AI does not own, but I don't want to resign on this point since heros can even buy items in shops and ordering neutral buildings should be definately possible. Anybody got an idea?:wink:
 
Level 9
Joined
Nov 4, 2007
Messages
933
The only workaround I can really think of is to just create the hero for the AI player once it passes through certain conditions (food limit, gold/lumber, hero limiters, near tavern).
 
Status
Not open for further replies.
Top