IsDynamicPedShadowsEnabled: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
(Created page with "__NOTOC__ {{Client function}} This function checks whether dynamic shadows for peds are currently enabled on the client. The returned value may reflect: * The player's video settings. * Any override applied using setDynamicPedShadowsEnabled. Use resetDynamicPedShadows to restore the setting back to the player’s original video configuration. ==Syntax== <syntaxhighlight lang="lua"> bool isDynamicPedShadowsEnabled ( ) </syntaxhighlight> ===Required Arguments==...")
 
No edit summary
 
Line 37: Line 37:


==See Also==
==See Also==
* [[setDynamicPedShadowsEnabled]]
{{World functions|client}}
* [[resetDynamicPedShadows]]
* [[Client functions]]

Latest revision as of 10:04, 17 April 2026

This function checks whether dynamic shadows for peds are currently enabled on the client.

The returned value may reflect:

Use resetDynamicPedShadows to restore the setting back to the player’s original video configuration.

Syntax

bool isDynamicPedShadowsEnabled ( )

Required Arguments

  • None

Returns

Returns true if dynamic ped shadows are enabled, false otherwise.

Examples

if isDynamicPedShadowsEnabled() then
    outputChatBox("Dynamic ped shadows are enabled.")
else
    outputChatBox("Dynamic ped shadows are disabled.")
end

Example: Toggle shadows

-- Toggle dynamic ped shadows
local current = isDynamicPedShadowsEnabled()
setDynamicPedShadowsEnabled(not current)

See Also