FoundryVTT MCP Server Documentation - v1.5.3
    Preparing search index...

    Interface WorldCombat

    Raw combat document from worldData.

    interface WorldCombat {
        _id: string;
        scene?: string;
        active: boolean;
        round: number;
        turn: number | null;
        started?: boolean;
        combatants: {
            _id: string;
            actorId?: string;
            tokenId?: string;
            sceneId?: string;
            name: string;
            img?: string;
            initiative: number | null;
            hidden: boolean;
            defeated: boolean;
            flags?: Record<string, unknown>;
        }[];
        settings?: { skipDefeated?: boolean; resource?: string };
        flags?: Record<string, unknown>;
    }
    Index

    Properties

    _id: string
    scene?: string
    active: boolean
    round: number
    turn: number | null
    started?: boolean

    Not persisted by FoundryVTT — do not gate behaviour on it.

    Combat#started is a client-side derived getter (turns.length > 0 && round > 0); BaseCombat.defineSchema() never declares it, so a document arriving in the world socket payload (validated only as z.array(z.unknown()) and cast, see client.ts) carries no such key. Optional here so the compiler cannot imply the transport provides it — derive started-ness from round and combatants instead.

    combatants: {
        _id: string;
        actorId?: string;
        tokenId?: string;
        sceneId?: string;
        name: string;
        img?: string;
        initiative: number | null;
        hidden: boolean;
        defeated: boolean;
        flags?: Record<string, unknown>;
    }[]
    settings?: { skipDefeated?: boolean; resource?: string }

    Combat tracker settings. The core skipDefeated toggle lives in the core.combatTrackerConfig world setting and may not be present in every worldData snapshot, so it is optional here.

    flags?: Record<string, unknown>