Pathfinder 1e for Foundry VTT
    Preparing search index...

    Class CR

    Challenge Rating helper functions.

    Index

    Constructors

    • Returns CR

    Methods

    • Convert number to string representation.

      Parameters

      • value: number = 0

        Number to transform

      Returns string

      • String representation
    • Convert a CR step index to its corresponding CR value.

      Parameters

      Returns number

      • The corresponding CR value
    • Parse CR string to produce a numeric representation

      Parses 1/8, 1/6, 1/4, 1/3, and 1/2 as exact decimals. Everything else is treated as regular number string and passed through parseFloat().

      Parameters

      • value: string

        String to transform

      Returns number

      • Transformed number
    • Get the CR step for a given CR value.

      Parameters

      • cr: number

        The creature's challenge rating

      Returns number

    • Return the amount of experience granted by killing a creature of a certain CR.

      Parameters

      • cr: number

        The creature's challenge rating

      Returns number | void

      • The amount of experience granted per kill. Or undefined if the CR was invalid.