Game.PolicyAdjustmentTriggerTargetFlags
Assembly: Assembly-CSharp
Namespace: Game.Tutorials
Type: enum
Base: System.Enum
Summary:
PolicyAdjustmentTriggerTargetFlags is a bitwise (Flags) enumeration used by the tutorial system to indicate which target(s) a policy-adjustment trigger applies to. It is marked [Serializable] and [Flags], so multiple values can be combined (e.g., City | District). Typical uses include filtering or dispatching tutorial actions depending on whether the trigger affects the entire city, a specific district, or a particular object.
Fields
-
City = 1
Identifies the entire city as the target of the policy adjustment trigger (bit 0). -
District = 2
Identifies a district as the target of the policy adjustment trigger (bit 1). -
Object = 4
Identifies a specific object (building, prop, etc.) as the target of the policy adjustment trigger (bit 2).
Properties
None
This enum exposes no properties. It's a plain flags enum with named constant values.
Constructors
None (implicit)
Enums do not declare explicit constructors in C#. The underlying type is int and the named values above are the available constants. Instances are typically created by assigning one of the enum values or a bitwise combination of them.
Methods
None
No methods are defined on this enum type. Use standard enum/bitwise operations or Enum.HasFlag to work with values.
Usage Example
// Combine targets: apply to both city and district
PolicyAdjustmentTriggerTargetFlags targets = PolicyAdjustmentTriggerTargetFlags.City | PolicyAdjustmentTriggerTargetFlags.District;
// Check using bitwise operation
if ((targets & PolicyAdjustmentTriggerTargetFlags.City) != 0)
{
// Handle city-targeted trigger
}
// Or using HasFlag (slower but clearer)
if (targets.HasFlag(PolicyAdjustmentTriggerTargetFlags.Object))
{
// Handle object-targeted trigger
}