I've studied it for a long time, but I know how to use AIBehaviorList.
I read the official documentation of AI behaviors。
include:
Prepar3D's artificial entities support the following behaviors:
Attacker
Combat Air Patrol
Close Air Support
Pursue
SearchTrack
Wingman Formation Flight
But when I used them in simdirector, they didn't work.
For example:
I created Attacker,Combat Air Patrol and SearchTrack,then I created three AIBehaviorActivationActions.
When I drove the plane into the range of AI aircraft, he did not attack me.
Is there an official to explain? Or is there any example for me to understand it?
How to use AI Behaviors
-
- Lockheed Martin
- Posts: 1207
- Joined: Tue Sep 25, 2012 2:34 pm
Re: How to use AI Behaviors
Hi nhl1996,
You will also need to define the EntityAffiliation's and EntityIdentification's for your entities. For example, you can create an EntityIdentification for "Friendly" and "Foe", each would need to have a different GroupID.
Then you can use the EntityIdentifications within the AI object's EntityAffiliation element. The idea here is you can create different relationships between AI objects. If you want the AI to attack the user, for example, you would need the AI's EntityAffiliation's Foe list to contain the user's EntityIdentification.
Regards,
Clifton
You will also need to define the EntityAffiliation's and EntityIdentification's for your entities. For example, you can create an EntityIdentification for "Friendly" and "Foe", each would need to have a different GroupID.
Then you can use the EntityIdentifications within the AI object's EntityAffiliation element. The idea here is you can create different relationships between AI objects. If you want the AI to attack the user, for example, you would need the AI's EntityAffiliation's Foe list to contain the user's EntityIdentification.
Regards,
Clifton
Clifton Crane
Prepar3D® Software Engineer Sr.
Prepar3D® Software Engineer Sr.
-
- Lockheed Martin
- Posts: 1207
- Joined: Tue Sep 25, 2012 2:34 pm
Re: How to use AI Behaviors
I should've also mentioned that EntityAffiliation and EntityIdentification are new to Prepar3D v5. In prior versions, the same would be accomplished using the "Association ID" on the AI and user objects. Differing Association ID's would cause one another to be considered enemies. An Association ID of zero was considered neutral.
The new EntityAffiliation and EntityIdentifcation elements allow more complex relationships between entities to be defined.
Regards,
Clifton
The new EntityAffiliation and EntityIdentifcation elements allow more complex relationships between entities to be defined.
Regards,
Clifton
Clifton Crane
Prepar3D® Software Engineer Sr.
Prepar3D® Software Engineer Sr.
Re: How to use AI Behaviors
Thank you very much!
This is very helpful to me!
This is very helpful to me!