Class IsPerformerCondition
- Namespace
- ElectricDrill.AstraRpgFramework.Conditions
- Assembly
- com.electricdrill.astra-rpg-framework.Runtime.dll
Condition that evaluates to true when Performer is the same
entity as Holder (i.e., the effect was self-applied).
Returns false when Performer is null.
[Serializable]
[TypeSelectableMenu("Leaf/Entity")]
public class IsPerformerCondition : Condition
- Inheritance
-
objectIsPerformerCondition
Remarks
This is a strict reference-identity check and does not walk Owner.
Under composition (e.g. a weapon entity applying an effect on behalf of its owning ship) a
self-applied effect where Performer is the weapon and Holder is the ship evaluates to
false here even though the ship is, in a broader sense, affecting itself. Use
IsOwnedByCondition (e.g. Owned = Holder, Owner = PerformerOwner) for
ownership-aware "is this self-inflicted" checks.
Methods
Evaluate(EvaluationContext)
Evaluates this condition against the provided context.
public override bool Evaluate(EvaluationContext ctx)
Parameters
ctxEvaluationContextContextual data available to the condition (holder, performer, payload).
Returns
- bool
trueif the condition is satisfied; otherwisefalse.