Skip to main content

NodeHelper

Index

Constructors

constructor

Methods

staticall

  • Returns all nodes from the given node.


    Parameters

    NameTypeDefaultDescription
    optionalnodeINode

    Node to start from.

    optionalnodesINode[]

    Array to add items to.

    Returns INode[]

    nodes or new array with all nodes.

staticallTier

  • Returns all nodes from the given node with their spirit tier. Tiers are determined by wing buff unlocks, starting at 0 and incrementing at each wing buff (inclusive).


    Parameters

    NameTypeDefaultDescription
    optionalnodeINode
    optionaltiernumber
    optionalnodesITierNode[]

    Returns ITierNode[]

staticfind

  • Finds the first node that satisfies the predicate.


    Parameters

    NameTypeDefaultDescription
    nodeINode

    Node to start searching from.

    predicate(node: INode) => boolean

    Function to search for.

    Returns undefined | INode

    First node that matches or undefined.

staticgetItems

  • getItems(node?: INode, includeHidden?: boolean): IItem[]
  • Gets all items from the node tree.


    Parameters

    NameTypeDefaultDescription
    optionalnodeINode

    Node to start from.

    optionalincludeHiddenboolean

    Include hidden items (see INode.hiddenItems).

    Returns IItem[]

    Array of items.

statictrace

  • Gets all nodes leading up to this node.


    Parameters

    NameTypeDefaultDescription
    optionalnodeINode

    Target node.

    Returns INode[]

    Array in order from root node to given node.

statictraceMany

  • Gets all nodes leading up to these nodes.

    @remarks

    Nodes are distinct but order is not guaranteed.


    Parameters

    NameTypeDefaultDescription
    nodesINode[]

    Returns INode[]

statictraceManySet

  • Gets all nodes leading up to these nodes.


    Parameters

    NameTypeDefaultDescription
    nodesINode[]

    Returns Set<INode>