M MY Multiplayer: Wiki
Side
Kind

fadeCamera

Client

Fades the screen out to a colour or back in.

bool fadeCamera(bool fadeIn [, float time = 1, int red = 0, int green = 0, int blue = 0])

Parameters

NameTypeDescription
fadeInbooltrue to fade the screen in, false to fade it out.
timefloatHow long the fade takes, in seconds.default 1
redintThe colour's red, from 0 to 255. Only used when fading out.default 0
greenintThe colour's green, from 0 to 255. Only used when fading out.default 0
blueintThe colour's blue, from 0 to 255. Only used when fading out.default 0

Returns

true.

Example

fadeCamera(false, 1.5)
setTimer(function()
    setCameraTarget(localPlayer)
    fadeCamera(true, 1.5)
end, 2000, 1)

See also