GetPostFXMode

From Multi Theft Auto: Wiki
Revision as of 11:05, 3 December 2025 by O22 (talk | contribs) (Created page with "__NOTOC__ {{Client function}} {{New feature/item|3.0161|1.6|23644| Gets the current mode of PostFX. }} ==Syntax== <syntaxhighlight lang="lua"> int getPostFXMode ( ) </syntaxhighlight> ===Returns=== An integer for the current PostFX mode: * 0: Disabled * 1: Enabled in fullscreen mode * 2: Enabled in windowed/borderless mode ==Example== This example gets the current PostFX mode and displays it in the chat. <syntaxhighlight lang="lua"> local modes = { [0] = "Disabl...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

ADDED/UPDATED IN VERSION 1.6 r23644:

Gets the current mode of PostFX.

Syntax

int getPostFXMode ( )

Returns

An integer for the current PostFX mode:

  • 0: Disabled
  • 1: Enabled in fullscreen mode
  • 2: Enabled in windowed/borderless mode

Example

This example gets the current PostFX mode and displays it in the chat.

local modes = {
    [0] = "Disabled",
    [1] = "Enabled in fullscreen mode",
    [2] = "Enabled in windowed/borderless mode"
}

addCommandHandler("getMyMode", 
    function()
        local currentMode = getPostFXMode()
        outputChatBox("Your PostFX mode is: "..modes[currentMode])
    end, false, false
)

See Also