Hello! I've been trying to make my first ai. It's for a custom race (elves). For some reason it doesn't seem to work, workers begin harvesting but they don't build anything, and the player doesn't train new workers. This is how my building tab looks in the ai editor:
I have imported the ai and I create the starting units and start the ai with this trigger:
Code:
Town Hall 1 0/12 Any None
Worker 1 1/12 Any None
Worker 2 2/12 Any None
Worker 3 3/12 Any None
Worker 4 4/12 Any None
Worker 5 5/12 Any None
Training Grounds 1 - Any None
...
I have imported the ai and I create the starting units and start the ai with this trigger:
-
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 - Create 1 Town Hall 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
- AI - Start melee AI script for (Picked player): war3mapImported\custom ai human.ai
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions