AI spawn triggers

Discuss HaloCE modding with the HEK tools here. For help, go to the Help Desk forum above.
Post Reply
GKMods





Posts: 66
Joined: Wed Dec 06, 2006 1:02 pm
Location: High Charity

AI spawn triggers

Post by GKMods »

Does anybody know how to make a trigger that will , for example, make AI spawn around the next corner when you approach a certain place?
User avatar
Cryticfarm





Posts: 3611
Joined: Sat Dec 09, 2006 7:23 pm
Location: canada
Contact:

Post by Cryticfarm »

Can't you make the ai stay there until something goes there making the AI attack?
L0d3x




Articulatist 250

Posts: 454
Joined: Sat Aug 18, 2007 3:32 am

Post by L0d3x »

It's really easy. In Sapien, under Hierarchy view, go to game data and select trigger volumes.

You may have to select new instance (this is off the top of my head), then go to your ingame window thing and right click somewhere. This will place the trigger volume. You can now manipulate it's side by clicking on the sides with the left mouse button and dragging it. Now give your new trigger volume a name, let's call it myTriggerVolume for now.

Now assuming you have an AI encounter called myEncounter, make a script that looks a little something like this:

(script startup myScript
(sleep_until (volume_test_objects myTriggerVolume (players)) 5)
(ai_place myEncounter)
)

That will create your script, the 5 in there just means 'check this trigger volume every 5 halo seconds'. Don't worry about that, it should suffice.
Post Reply