Hello! I already asked this long time ago, but I still haven't found a solution and I've been inactive on this project for a long time. I'd be very thankful if someone could help me with this issue.
I've made an ai for a custom race using ai editor (see the screenshots). The problem is that ai doesn't build anything, it only sends workers to gather gold and wood.
I've imported the ai to the map, and I've started it through triggers. Here's my initialization trigger, where I replace the standard units and activate the ai:
I've made an ai for a custom race using ai editor (see the screenshots). The problem is that ai doesn't build anything, it only sends workers to gather gold and wood.
I've imported the ai to the map, and I've started it through triggers. Here's my initialization trigger, where I replace the standard units and activate the ai:
-
Melee Initialization
-
Events
- Map initialization
- Conditions
-
Actions
- Melee Game - Use melee time of day (for all players)
- Melee Game - Limit Heroes to 1 per Hero-type (for all players)
- Melee Game - Give trained Heroes a Scroll of Town Portal (for all players)
- Melee Game - Set starting resources (for all players)
- Melee Game - Remove creeps and critters from used start locations (for all players)
- Melee Game - Create starting units (for all players)
- Melee Game - Run melee AI scripts (for computer players)
-
Player Group - Pick every player in (All players) and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Race of (Picked player)) Equal to Human
-
Then - Actions
-
Unit Group - Pick every unit in (Units owned by (Picked player)) and do (Actions)
-
Loop - Actions
- Unit - Remove (Picked unit) from the game
-
Loop - Actions
- Unit - Create 1 Town Hall (custom) for (Picked player) at ((Picked player) start location) facing Default building facing degrees
- Unit - Create 5 Worker for (Picked player) at ((Picked player) start location) facing Default building facing degrees
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- ((Picked player) is in (All players controlled by a User player)) Equal to False
-
Then - Actions
- AI - Start campaign AI script for (Picked player): war3mapImported\AlienAiHuman.ai
- Else - Actions
-
If - Conditions
-
Unit Group - Pick every unit in (Units owned by (Picked player)) and do (Actions)
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions
-
Events