Skip to main content

NPCTraitGetOptionValue

Callable

  • NPCTraitGetOptionValue(Dialog: string, Trait: readonly NPCTrait[]): number

  • Returns the weight value of the specified option (The higher the value, the higher the chances the option will be picked, an opposite trait will always result as an option that's not picked)


    Parameters

    • Dialog: string

      Specified dialog line with the affecting traits.

    • Trait: readonly NPCTrait[]

      List of traits of the NPC.

    Returns number

    • Weight of the dialog option