rednode API - v0.80.1
    Preparing search index...

    Interface GameState

    What the game is showing, and whether REDnode is linked to it.

    interface GameState {
        connected: boolean;
        mainMenu: boolean;
        menu: boolean;
        overlay: "passive" | "interactive" | "hidden";
        pauseMenu: boolean;
        photoMode: boolean;
        scene: boolean;
        world: boolean;
    }
    Index
    connected: boolean

    True while the overlay host is linked to the game. All other fields are false when it is not.

    mainMenu: boolean

    The main menu, before a save is loaded.

    menu: boolean

    A game menu is open: inventory, map, pause menu and so on.

    overlay: "passive" | "interactive" | "hidden"

    The overlay's input mode, switched with F10.

    pauseMenu: boolean

    The game's pause menu (Esc in the world) is open, its Save, Load and Settings pages too. menu is also true then. From REDnode 0.67.2.

    photoMode: boolean

    Photo mode is on.

    scene: boolean

    A scene that takes control of V, such as a cutscene. The threshold is unverified.

    world: boolean

    V is in the world: a save has loaded and no other load has started. False while the game starts, at the main menu and from the moment a load starts, from the pause menu too. Call the game's world systems (time, weather, districts, quests) only while it is true: api refuses them while it is false, since some crash the game before the world exists. Game.onState tells when it changes. From REDnode 0.47.0.