Return Family Node

From Intrigues Wiki
Revision as of 08:58, 5 August 2024 by Tayfunwiki (talk | contribs) (Created page with "thumb|Return Clan<b>Description</b><div class="description" style="padding-left:35px;">By creating a method in the specified format, you can reference any '''Clan''' of your choice. For example, if you want to reference the Clan of a Conspirator's spouse, the '''Return Clan Node''' will accomplish this for you.</div><syntaxhighlight lang="c#" line="1" start="1"> [GetClan("Get Spouse Clan")] private Clan GetSpouseClan(Scheme scheme) { if (!sch...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Return Clan

Description

By creating a method in the specified format, you can reference any Clan of your choice. For example, if you want to reference the Clan of a Conspirator's spouse, the Return Clan Node will accomplish this for you.
[GetClan("Get Spouse Clan")]
private Clan GetSpouseClan(Scheme scheme) {
    if (!scheme.Conspirator.HasSpouse) return null;
    return scheme.Conspirator.Spouses().First().Clan;
}

» The method must return a value of the Clan type. » The method should be marked using the [GetClan] attribute. (Using this attribute, you can give a specific name to the method.)

Outputs

» [Clan]: Transfers the referenced clan to the next node. » [Null]: If the method returns a null value, the flow continues from here.