Skip to main content

PreferenceGetPreviousIndex

Callable

  • PreferenceGetPreviousIndex(List: readonly unknown[], Index: number): number

  • Returns the index of the previous preference list item (and wraps back to the end of the list if currently at 0)


    Parameters

    • List: readonly unknown[]

      The preference list

    • Index: number

      The current preference index for the given list

    Returns number

    • The index of the previous item in the array, or the last item in the array if currently at 0