Class HasProfessionCondition
ECA condition placeholder: the character practises a profession. ALWAYS FALSE today.
[Serializable]
public class HasProfessionCondition : BaseCondition, ICondition
- Inheritance
-
HasProfessionCondition
- Implements
- Inherited Members
Remarks
FishMMO has no profession system yet (2026-10-10: portals take a profession condition as a placeholder; there is no Archaeology or any other profession). The condition exists so portals and other content can be authored against a profession key now and start working the day professions land, without re-authoring.
Because portal requirements are any-of, a portal whose only requirement is this condition cannot be opened by it — give such a portal a key or another condition too.
When professions exist: resolve the character's profession record here, compare ProfessionKey (case-insensitive) and MinimumRank, and delete the warning.
Fields
MinimumRank
[Tooltip("The rank the character must have reached in it. Placeholder.")]
[Min(0)]
public int MinimumRank
Field Value
ProfessionKey
[Tooltip("The profession's key, e.g. \"archaeology\". Placeholder: no profession system exists yet, so this condition is always false.")]
public string ProfessionKey
Field Value
Methods
Evaluate(ICharacter, EventData)
Evaluates the condition's raw pass/fail logic. Must be implemented by derived classes. Derived classes should NOT apply Invert themselves — the framework calls Check(ICharacter, EventData), which wraps this method and applies Invert uniformly.
public override bool Evaluate(ICharacter initiator, EventData eventData = null)
Parameters
initiatorICharacterThe character initiating the check.
eventDataEventDataOptional event data for the condition.
Returns
- bool
True if the underlying check passes; otherwise, false.
GetTooltipContribution()
Returns a short, designer-facing tooltip line describing this condition's effect,
or null when the condition has nothing to contribute. Override on concrete
conditions that should appear in ability/quest/dialogue tooltips (e.g. attribute
requirements, faction membership). Returning null or whitespace omits the
line entirely.
public override string GetTooltipContribution()
Returns
Remarks
The base implementation returns null. Aggregators
(BaseAbilityTemplate) skip null/whitespace contributions, so most
conditions need not override.