clik-engine API
    Preparing search index...

    Interface CancelWindowDef

    Defines frame ranges where an animation state can be cancelled.

    Usage:

    const cancel = new CancelWindow();
    cancel.define('attack1', { start: 8, end: 15, into: ['attack2', 'dodge'] });
    cancel.define('attack1', { start: 4, end: 15, into: ['special'] }); // special can cancel earlier

    cancel.canCancel('attack1', 'attack2', 10); // true (frame 10 is in [8, 15])
    cancel.canCancel('attack1', 'attack2', 3); // false (frame 3 is before window)
    interface CancelWindowDef {
        end: number;
        into: string[];
        start: number;
    }
    Index

    Properties

    Properties

    end: number

    Last frame where cancelling is allowed

    into: string[]

    States that can be cancelled into during this window

    start: number

    First frame where cancelling is allowed