Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add initiative ties resolution setting #295

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Commits on Aug 8, 2024

  1. Add option to define initiative order in a tie

    Player first - player characters go first, order is otherwise undefined.
    This appears to be the existing behaviour, because player characters appear
    in the unsorted array first.
    NPC first - NPCs go first, order is otherwise undefined.
    Random - All characters on the same initiative go in a random order
    
    Also uses OVERFOW_TYPE constants in settings.ts
    Trantion897 committed Aug 8, 2024
    Configuration menu
    Copy the full SHA
    f348a24 View commit details
    Browse the repository at this point in the history

Commits on Aug 9, 2024

  1. Fix drag & drop reordering with new initiative ties code

    When any creature is dragged in the initiative order, the current order of every
    creature is stored. The order of all creatures is resolved in this order:
    1. Initiative
    2. Manual order
    3. Initiative ties option
    If a creature is dragged out of its current initiative, the initiative value is
    updated, as previously. Manual ordering lets you reorder initiative to override
    other settings, for example in Pathfinder where by default NPCs always come
    before players on the same initiative, you can drag a player to come before an
    NPC if they have the feat that allows this.
    
    Manual ordering is wiped when initiative is rerolled. It isn't wiped if the
    initiative ties setting is changed, because this might not be what the player
    wants.
    Trantion897 committed Aug 9, 2024
    Configuration menu
    Copy the full SHA
    340a340 View commit details
    Browse the repository at this point in the history