Content: Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Background: Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Pattern: Blank Waves Notes Sharp Wood Rockface Leather Honey Vertical Triangles
Welcome to Xbox Chaos: Modding Evolved

Register now to gain access to all of our features. Once registered and logged in, you will be able to contribute to this site by submitting your own content or replying to existing content. You'll be able to customize your profile, receive reputation points as a reward for submitting content, while also communicating with other members via your own private inbox, plus much more! This message will be removed once you have signed in.

matty45

Modding
Scripting - Is it possible to add ai to a squad that has been spawned from an effect?

3 posts in this topic

Ive been trying to figure this out for a while but to no avail.

Currently the way that could be possible is to get all the ai thats currently in a trigger volume and use the ai_migrate function, however i dont know how i would iterate the function for each ai in the trigger volume.

If anyone knows how to do this or that it is not possible, that would be great. Thanks!

Share this post


Link to post
Share on other sites

Loop through your list for the amount that exists in the list, `list_count` will give your max count while `list_get` will return each object in that list.

`volume_return_objects_by_type` is handy for filtering things out, so you wont be trying to pass unwanted engine objects that a volume check would get.

 

Would be a good idea to make sure the AI you end up casting is actually alive too.

 

Edit: You may want to take a look at how AI expressions are used, take a look at some campaign examples. They can be setup to reference a bunch of things including whole squads, objectives and tasks. Situational. 
 

Edited by Akarias
matty45 likes this

Share this post


Link to post
Share on other sites

This may sound stupid but what would the syntax be for iterating stuff? Searched on google for halo ce examples but could not find any.

Also where can i get info about the types you can use for 'volume_return_objects_by_type'

Edited by matty45

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now