I don't know why but I can't seem to find any information on what should be one of the most simplest things to do in the editor. I have placed units on the map and they belong to an AI. I want the AI to not use these units like they normally would, (ie bunch them up together/defend/attack) I want the units to just stand in that area and wait for the player to come and engage them - just like you would have in the campaign or in co-op. Yet I can't seem to get the AI to decide against grabbing everything on the map and immediately attacking the player with it rendering my map unplayable.
I have gone to Object properties and unchecked "Available for attack waves" and I thought this would do the trick, but to no avail.
If anyone can help or link a tutorial I'd much appreciate it.
If you're using a create unit action, to reference those units as a unit group, use the function "Last created units".
It would look something like this:
Test spawn units
Game -Map initialization
Unit -Create 10 Marine for player 1 at Start Location 001 using default facing (No Options)
AI -Enable script control for (Last created units)
Ah, that's the problem - I don't want to delete the AI initializing triggers... I could I guess, by having a seperate AI and initialize the AI's individually, but I ideally want the AI to play a normal game of Starcraft but Also the game will spawn some units into an area of which I want the AI to ignore these units so they can defend that area.
I'll try MaskedImposter's method of disabling script control for the last created units tonight and let you know how successful I am.
Okay, so it worked...kind of. If I spawn 5 Zealots then use AISetUnitScriptControlled on UnitLastCreated the AI will use 4 of the Zealots and ignore 1. So, I could spawn each zealot one at a time and use this method, but it does seem inefficient. Any ideas?