SetSunSize

From Multi Theft Auto: Wiki
Revision as of 18:48, 14 March 2011 by Arran Fortuna (talk | contribs) (Created page with "__NOTOC__ {{Server client function}} This function is used to set the size of the sun. ==Syntax== <syntaxhighlight lang="lua"> bool setSunSize ( int Size ) </syntaxhighlight> ===Required Arguments=== *...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This function is used to set the size of the sun.

Syntax

bool setSunSize ( int Size )

Required Arguments

  • Size: The size you want to the sun to be in the sky.

Returns

Returns true if the size of the sun was set, false otherwise.

Example

This example lets any player set the size of the sun like /setsunsize 2

function commandSetSunSize(player, command, size)
    local size = tonumber(size)
    if (not size) then return end -- They didn't use a number
    setSunSize(size)
end
addCommandHandler("setsunsize", commandSetSunSize)

See Also