Level-up and class addition handler.

Hierarchy

  • FormApplication
    • LevelUpForm

Constructors

Properties

actor: ActorPF
config: {
    abilityScore: {
        new: number;
        used: number;
        get available(): number;
    };
    fcb: {
        available: boolean;
        choice: string;
        unavailable: boolean;
    };
    feats: number;
    health: {
        manual: null;
        type: null;
        value: number;
    };
    visibility: null;
} = ...

Type declaration

  • abilityScore: {
        new: number;
        used: number;
        get available(): number;
    }
    • new: number
    • used: number
    • get available(): number
  • fcb: {
        available: boolean;
        choice: string;
        unavailable: boolean;
    }
    • available: boolean
    • choice: string
    • unavailable: boolean
  • feats: number
  • health: {
        manual: null;
        type: null;
        value: number;
    }
    • manual: null
    • type: null
    • value: number
  • visibility: null

Temporary clone of the class to simulate changes.

newLevel: undefined | {
    bab: any;
    feats: number;
    fort: any;
    hd: number;
    hp: any;
    mythicTier: number;
    ref: any;
    skills: {
        bg: number;
        value: number;
    };
    totalHD: any;
    totalMythicTier: any;
    will: any;
}

Type declaration

  • bab: any
  • feats: number
  • fort: any
  • hd: number
  • hp: any
  • mythicTier: number
  • ref: any
  • skills: {
        bg: number;
        value: number;
    }
    • bg: number
    • value: number
  • totalHD: any
  • totalMythicTier: any
  • will: any
object: {}

Type declaration

    simulacra: ActorPF

    Temporary clone of the actor for seeing the results of various modifications with.

    token: TokenDocument

    Relevant token if any.

    useBackgroundSkills: unknown = ...
    ICONS: {
        fcb: {
            alt: string;
            hp: string;
            none: string;
            skill: string;
        };
        health: {
            auto: string;
            manual: string;
            roll: string;
        };
    } = ...

    Type declaration

    • fcb: {
          alt: string;
          hp: string;
          none: string;
          skill: string;
      }
      • alt: string
      • hp: string
      • none: string
      • skill: string
    • health: {
          auto: string;
          manual: string;
          roll: string;
      }
      • auto: string
      • manual: string
      • roll: string

    Accessors

    • get defaultOptions(): InsertKeys<{
          baseApplication: undefined | null | string;
          classes: undefined | any[];
          closeOnSubmit: undefined | boolean;
          dragDrop: undefined | any[];
          editable: undefined | boolean;
          filters: undefined | any[];
          height: undefined | null | number | "auto";
          id: undefined | string;
          left: undefined | null | number;
          minimizable: undefined | boolean;
          popOut: undefined | boolean;
          resizable: undefined | boolean;
          scale: undefined | null | number;
          scrollY: undefined | any[];
          sheetConfig: undefined | boolean;
          submitOnChange: undefined | boolean;
          submitOnClose: undefined | boolean;
          tabs: undefined | any[];
          template: undefined | null | string;
          title: undefined | string;
          top: undefined | null | number;
          width: undefined | null | number;
      }, OmitByValue<{}, never>>
    • Returns InsertKeys<{
          baseApplication: undefined | null | string;
          classes: undefined | any[];
          closeOnSubmit: undefined | boolean;
          dragDrop: undefined | any[];
          editable: undefined | boolean;
          filters: undefined | any[];
          height: undefined | null | number | "auto";
          id: undefined | string;
          left: undefined | null | number;
          minimizable: undefined | boolean;
          popOut: undefined | boolean;
          resizable: undefined | boolean;
          scale: undefined | null | number;
          scrollY: undefined | any[];
          sheetConfig: undefined | boolean;
          submitOnChange: undefined | boolean;
          submitOnClose: undefined | boolean;
          tabs: undefined | any[];
          template: undefined | null | string;
          title: undefined | string;
          top: undefined | null | number;
          width: undefined | null | number;
      }, OmitByValue<{}, never>>

    Methods

    • Internal

      Parameters

      • key: string

        Ability score key

      • op: string = null

        Operator clicked

      Returns 0 | 1 | -1

      • Direction of adjustment
    • Return cost of the adjustment.

      For homebrew support.

      Parameters

      • key: string
      • value: number

      Returns number

    • Internal

      Generate roll instance for the health gain.

      Parameters

      • type: string
      • formula: string

      Returns Roll<any>

    • Internal

      Spoof roll, for maximized, auto and manual health.

      Parameters

      • roll: Roll<any>
      • value: number

      Returns Roll<any>

    • Returns undefined | {
          itemData: {
              img: string;
              name: string;
              system: {
                  description: {
                      value: string;
                  };
                  subType: string;
              };
              type: string;
          };
          update: boolean;
      } | {
          itemData: {
              _id: any;
              system.changes: any;
          };
          update: boolean;
      }

    • Parameters

      • event: any
      • formData: any

      Returns Promise<unknown>

    • Returns Promise<{
          abilityScore: {
              new: number;
              used: number;
              get available(): number;
          };
          actor: ActorPF;
          config: config;
          document: ItemClassPF;
          fcb: {
              available: boolean;
              choice: string;
              unavailable: boolean;
          };
          feats: number;
          health: {
              manual: null;
              type: null;
              value: number;
          };
          icons: any;
          item: PropertiesToSource<ItemDataBaseProperties>;
          labels: {
              fcb: {
                  alt: string;
                  hp: string;
                  none: string;
                  skill: string;
              };
          };
          useBackgroundSkills: unknown;
          visibility: null;
          visibilityOptions: {
              blindroll: string;
              gmroll: string;
              publicroll: string;
              selfroll: string;
          };
      }>

    • Parameters

      • level: any

      Returns {
          bab: any;
          feats: number;
          fort: any;
          hd: number;
          hp: any;
          mythicTier: number;
          ref: any;
          skills: {
              bg: number;
              value: number;
          };
          totalHD: any;
          totalMythicTier: any;
          will: any;
      }

      • bab: any
      • feats: number
      • fort: any
      • hd: number
      • hp: any
      • mythicTier: number
      • ref: any
      • skills: {
            bg: number;
            value: number;
        }
        • bg: number
        • value: number
      • totalHD: any
      • totalMythicTier: any
      • will: any
    • Returns boolean

      Whether this form's associated class is a favoured class.

      Todo

      Add better logic for determining this <26-01-22, Furyspark>

    • Parameters

      • actor: Actor

        Owning actor

      • itemData: object

        Class item data

      • Optional options: {
            token: undefined | TokenDocument;
        } = {}

        Additional options

        • token: undefined | TokenDocument

          Associated token

      Returns Promise<null | Item>

    • Parameters

      • actor: Actor

        Owning actor

      • item: Item

        Class item

      • Optional options: {
            token: undefined | TokenDocument;
        } = {}

        Additional options

        • token: undefined | TokenDocument

          Associated token

      Returns Promise<undefined | null | Item>

      • Updated class item if updated or null if process was cancelled. Undefined if this re-opened existing dialog.

    Generated using TypeDoc