-
Notifications
You must be signed in to change notification settings - Fork 2
Core Profile: Condition
Lucas Massey edited this page Nov 22, 2020
·
1 revision
Condition Profiles in RivalAI allow you to define some extra conditions that must be met before a Trigger Profile can execute its Actions. It is important that you use a unique SubtypeId for each Condition Profile you create, otherwise they may not work correctly.
Here's an example of how a Condition Profile Definition is setup:
<?xml version="1.0"?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<EntityComponents>
<EntityComponent xsi:type="MyObjectBuilder_InventoryComponentDefinition">
<Id>
<TypeId>Inventory</TypeId>
<SubtypeId>RAI-ExampleConditionProfile</SubtypeId>
</Id>
<Description>
[RivalAI Condition]
[UseConditions:true]
[MatchAnyCondition:true]
</Description>
</EntityComponent>
</EntityComponents>
</Definitions>
| Tag: | UseConditions |
|---|---|
| Tag Format: | [UseConditions:Value] |
| Description: | This tag specifies if the Condition Profile should be active / used. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | MatchAnyCondition |
|---|---|
| Tag Format: | [MatchAnyCondition:Value] |
| Description: | This tag allows you to require if all conditions in the profile must be met (false), or if any condition can be met (true). |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | CheckAllLoadedModIDs |
|---|---|
| Tag Format: | [CheckAllLoadedModIDs:Value] |
| Description: | This tag allows you to check for mods currently loaded in your game world. For this condition to be satisfied, all mod IDs included in AllModIDsToCheck must be present in the world. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | AllModIDsToCheck |
|---|---|
| Tag Format: | [AllModIDsToCheck:Value] |
| Description: | Specifies a mod ID you want to have checked if CheckAllLoadedModIDs is true. |
| Allowed Values: | Any Mod ID |
| Multiple Tag Allowed: | Yes |
| Tag: | CheckAnyLoadedModIDs |
|---|---|
| Tag Format: | [CheckAnyLoadedModIDs:Value] |
| Description: | This tag allows you to check for mods currently loaded in your game world. For this condition to be satisfied, any mod IDs included in AnyModIDsToCheck must be present in the world. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | AnyModIDsToCheck |
|---|---|
| Tag Format: | [AnyModIDsToCheck:Value] |
| Description: | Specifies a mod ID you want to have checked if CheckAnyLoadedModIDs is true. |
| Allowed Values: | Any Mod ID |
| Multiple Tag Allowed: | Yes |
| Tag: | CheckTrueBooleans |
|---|---|
| Tag Format: | [CheckTrueBooleans:Value] |
| Description: | This tag allows you to check for Boolean Variables stored in the Drone Behavior that are true. All provided variables must be true for this condition to be satisfied. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | TrueBooleans |
|---|---|
| Tag Format: | [TrueBooleans:Value] |
| Description: | Specifies the name of a Boolean Variable you want to have checked if CheckTrueBooleans is true. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | CheckCustomCounters |
|---|---|
| Tag Format: | [CheckCustomCounters:Value] |
| Description: | This tag allows you to check for Integer Counter Variables stored in the Drone Behavior. All provided variables must be equal or higher for this condition to be satisfied. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | CustomCounters |
|---|---|
| Tag Format: | [CustomCounters:Value] |
| Description: | Specifies the name of an Integer Counter Variable you want to have checked if CheckCustomCounters is true. You must also provide a value to CustomCountersTargets as well for this tag to work. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | CustomCountersTargets |
|---|---|
| Tag Format: | [CustomCountersTargets:Value] |
| Description: | Specifies the target value of an Integer Counter Variable you want to have checked if CheckCustomCounters is true. You must also provide a value to CustomCounters as well for this tag to work. |
| Allowed Values: | Any interger equal or greater than 0
|
| Multiple Tag Allowed: | Yes |
| Tag: | CounterCompareTypes |
|---|---|
| Tag Format: | [CounterCompareTypes:Value] |
| Description: | Specifies the logic used to determine if the behavior counter check passes or not for each provided counter. If no value is provided for a counter name, then GreaterOrEqual is used by default. |
| Allowed Values: |
GreaterOrEqualGreaterEqualNotEqualLessLessOrEqual
|
| Multiple Tag Allowed: | Yes |
| Tag: | CheckTrueSandboxBooleans |
|---|---|
| Tag Format: | [CheckTrueSandboxBooleans:Value] |
| Description: | This tag allows you to check for Boolean Variables stored in the Save File that are true. All provided variables must be true for this condition to be satisfied. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | TrueSandboxBooleans |
|---|---|
| Tag Format: | [TrueSandboxBooleans:Value] |
| Description: | Specifies the name of a Sandbox Boolean Variable you want to have checked if CheckTrueSandboxBooleans is true. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | CheckCustomSandboxCounters |
|---|---|
| Tag Format: | [CheckCustomSandboxCounters:Value] |
| Description: | This tag allows you to check for Integer Counter Variables stored in the Save File. All provided variables must be equal or higher for this condition to be satisfied. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | CustomSandboxCounters |
|---|---|
| Tag Format: | [CustomSandboxCounters:Value] |
| Description: | Specifies the name of an Integer Counter Variable you want to have checked if CheckCustomSandboxCounters is true. You must also provide a value to CustomSandboxCountersTargets as well for this tag to work. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | CustomSandboxCountersTargets |
|---|---|
| Tag Format: | [CustomSandboxCountersTargets:Value] |
| Description: | Specifies the target value of an Integer Counter Variable you want to have checked if CheckCustomSandboxCounters is true. You must also provide a value to CustomSandboxCounters as well for this tag to work. |
| Allowed Values: | Any interger equal or greater than 0
|
| Multiple Tag Allowed: | Yes |
| Tag: | SandboxCounterCompareTypes |
|---|---|
| Tag Format: | [SandboxCounterCompareTypes:Value] |
| Description: | Specifies the logic used to determine if the sandbox counter check passes or not for each provided counter. If no value is provided for a counter name, then GreaterOrEqual is used by default. |
| Allowed Values: |
GreaterOrEqualGreaterEqualNotEqualLessLessOrEqual
|
| Multiple Tag Allowed: | Yes |
| Tag: | CheckGridSpeed |
|---|---|
| Tag Format: | [CheckGridSpeed:Value] |
| Description: | This tag allows you to check the current NPC grid speed. For this condition to be satisfied, the grid speed must be between MinGridSpeed and MaxGridSpeed. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | MinGridSpeed |
|---|---|
| Tag Format: | [MinGridSpeed:Value] |
| Description: | The minimum grid speed that must be met if CheckGridSpeed is true. |
| Allowed Values: | Any number equal or greater than 0Must be lower than MaxGridSpeed
|
| Multiple Tag Allowed: | No |
| Tag: | MaxGridSpeed |
|---|---|
| Tag Format: | [MaxGridSpeed:Value] |
| Description: | The maximum grid speed that must be met if CheckGridSpeed is true. |
| Allowed Values: | Any number equal or greater than 0Must be higher than MinGridSpeed
|
| Multiple Tag Allowed: | No |
| Tag: | CheckMESBlacklistedSpawnGroups |
|---|---|
| Tag Format: | [CheckMESBlacklistedSpawnGroups:Value] |
| Description: | This tag allows you to check the Modular Encounters Spawner NPC SpawnGroup Blacklist for entries. For this condition to be satisfied.. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | SpawnGroupBlacklistContainsAll |
|---|---|
| Tag Format: | [SpawnGroupBlacklistContainsAll:Value] |
| Description: | Specifies the name of a SpawnGroup SubtypeID you want checked for if CheckMESBlacklistedSpawnGroups is true. If this tag contains values, then All values must be present in the BlackList for the condition to be satisfied. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | SpawnGroupBlacklistContainsAny |
|---|---|
| Tag Format: | [SpawnGroupBlacklistContainsAny:Value] |
| Description: | Specifies the name of a SpawnGroup SubtypeID you want checked for if CheckMESBlacklistedSpawnGroups is true. If this tag contains values, then Any of values must be present in the BlackList for the condition to be satisfied. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | UseRequiredFunctionalBlocks |
|---|---|
| Tag Format: | [UseRequiredFunctionalBlocks:Value] |
| Description: | Specifies if the condition should check for certain blocks that exist in a functional status on the grid. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | RequiredAllFunctionalBlockNames |
|---|---|
| Tag Format: | [RequiredAllFunctionalBlockNames:Value] |
| Description: | Specifies the name of a Block you want checked for if UseRequiredFunctionalBlocks is true. If this tag contains values, then the grid must have All blocks (in a working/functional state) with names specified for the condition to be satisfied. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | RequiredAnyFunctionalBlockNames |
|---|---|
| Tag Format: | [RequiredAnyFunctionalBlockNames:Value] |
| Description: | Specifies the name of a Block you want checked for if UseRequiredFunctionalBlocks is true. If this tag contains values, then the grid must have Any blocks (in a working/functional state) with names specified for the condition to be satisfied. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | RequiredNoneFunctionalBlockNames |
|---|---|
| Tag Format: | [RequiredNoneFunctionalBlockNames:Value] |
| Description: | Specifies the name of a Block you want checked for if UseRequiredFunctionalBlocks is true. If this tag contains values, then the grid must have No blocks (in a working/functional state) with names specified for the condition to be satisfied. |
| Allowed Values: | Any name string excluding characters :, [, ]
|
| Multiple Tag Allowed: | Yes |
| Tag: | CheckTargetAltitudeDifference |
|---|---|
| Tag Format: | [CheckTargetAltitudeDifference:Value] |
| Description: | Specifies if the condition should check the altitude difference between itself and its current target. Only works if NPC has a valid target and the NPC is in planetary gravity. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | MinTargetAltitudeDifference |
|---|---|
| Tag Format: | [MinTargetAltitudeDifference:Value] |
| Description: | The minimum target altitude difference that must be met if CheckTargetAltitudeDifference is true. |
| Allowed Values: | Any number equal or greater than 0Must be lower than MaxTargetAltitudeDifference
|
| Multiple Tag Allowed: | No |
| Tag: | MaxTargetAltitudeDifference |
|---|---|
| Tag Format: | [MaxTargetAltitudeDifference:Value] |
| Description: | The maximum target altitude difference that must be met if CheckTargetAltitudeDifference is true. |
| Allowed Values: | Any number equal or greater than 0Must be higher than MinTargetAltitudeDifference
|
| Multiple Tag Allowed: | No |
| Tag: | CheckTargetDistance |
|---|---|
| Tag Format: | [CheckTargetDistance:Value] |
| Description: | Specifies if the condition should check the distance difference between itself and its current target. Only works if NPC has a valid target. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | MinTargetDistance |
|---|---|
| Tag Format: | [MinTargetDistance:Value] |
| Description: | The minimum target distance difference that must be met if CheckTargetDistance is true. |
| Allowed Values: | Any number equal or greater than 0Must be lower than MaxTargetDistance
|
| Multiple Tag Allowed: | No |
| Tag: | MaxTargetDistance |
|---|---|
| Tag Format: | [MaxTargetDistance:Value] |
| Description: | The maximum target distance difference that must be met if CheckTargetDistance is true. |
| Allowed Values: | Any number equal or greater than 0Must be higher than MinTargetDistance
|
| Multiple Tag Allowed: | No |
| Tag: | CheckTargetAngleFromForward |
|---|---|
| Tag Format: | [CheckTargetAngleFromForward:Value] |
| Description: | Specifies if the condition should check the angle difference between itself (forward direction) and its current target. Only works if NPC has a valid target. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | MinTargetAngle |
|---|---|
| Tag Format: | [MinTargetAngle:Value] |
| Description: | The minimum target angle difference that must be met if CheckTargetAngleFromForward is true. |
| Allowed Values: | Any number equal or greater than 0Must be lower than MaxTargetAngle
|
| Multiple Tag Allowed: | No |
| Tag: | MaxTargetAngle |
|---|---|
| Tag Format: | [MaxTargetAngle:Value] |
| Description: | The maximum target angle difference that must be met if CheckTargetAngleFromForward is true. |
| Allowed Values: | Any number equal or greater than 0Must be higher than MinTargetAngle
|
| Multiple Tag Allowed: | No |
| Tag: | CheckIfTargetIsChasing |
|---|---|
| Tag Format: | [CheckIfTargetIsChasing:Value] |
| Description: | Specifies if the condition should check the velocity direction angle from the current target to the NPC. Only works if NPC has a valid target. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | MinTargetChaseAngle |
|---|---|
| Tag Format: | [MinTargetChaseAngle:Value] |
| Description: | The minimum target velocity angle difference that must be met if CheckIfTargetIsChasing is true. |
| Allowed Values: | Any number equal or greater than 0Must be lower than MaxTargetChaseAngle
|
| Multiple Tag Allowed: | No |
| Tag: | MaxTargetChaseAngle |
|---|---|
| Tag Format: | [MaxTargetChaseAngle:Value] |
| Description: | The maximum target velocity angle difference that must be met if CheckIfTargetIsChasing is true. |
| Allowed Values: | Any number equal or greater than 0Must be higher than MinTargetChaseAngle
|
| Multiple Tag Allowed: | No |
| Tag: | CheckIfGridNameMatches |
|---|---|
| Tag Format: | [CheckIfGridNameMatches:Value] |
| Description: | Specifies if the condition should check the name of the NPC CubeGrid matches a provided value. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | AllowPartialGridNameMatches |
|---|---|
| Tag Format: | [AllowPartialGridNameMatches:Value] |
| Description: | Specifies if the NPC CubeGrid name can be a partial match instead of exact. |
| Allowed Values: |
truefalse
|
| Multiple Tag Allowed: | No |
| Tag: | GridNamesToCheck |
|---|---|
| Tag Format: | [GridNamesToCheck:Value] |
| Description: | Specifies the name(s) to check against the NPC CubeGrid name. |
| Allowed Values: | Any Grid Name |
| Multiple Tag Allowed: | Yes |
- Home
- Getting Started
- Tutorial (Planned)
- Setting up a Behavior
- Autopilot Configuration
- Trigger System
- Spawning
- Core System Tags
- Behavior Specific Tags
- Example Files
- Troubleshooting & Debug
- Mod Repositories
- Modular Encounters Spawner Wiki