setCameraGoggleEffect
Client-side
Server-side
Shared
Pair: getCameraGoggleEffect
This page is incomplete! Help wanted!
Please finish this page using the corresponding Old Wiki article.
Go to Contribution guidelines for more information.
This function allows you to set the camera's current goggle effect. This means you can activate nightvision or infrared effects by script
Syntax
setCameraGoggleEffect ( )Code Examples
client
function nightvision() local effect = (getCameraGoggleEffect() == "normal") and "nightvision" or "normal" setCameraGoggleEffect(effect)endaddCommandHandler("nightvision", nightvision)