getLightInfo: Difference between revisions

From Bohemia Interactive Community
No edit summary
No edit summary
Line 25: Line 25:
* 9 - AttachedToPars: [[Array]] - getter for [[lightAttachObject]], [[lightDetachObject]]
* 9 - AttachedToPars: [[Array]] - getter for [[lightAttachObject]], [[lightDetachObject]]
* 10 - ConePars: [[Array]] - getter for [[setLightConePars]]
* 10 - ConePars: [[Array]] - getter for [[setLightConePars]]
* 11 - VolumeShapePars: [[Array]] - getter for [[setLightConePars]]
* 11 - VolumeShapePars: [[Array]] - getter for [[setLightVolumeShape]]


|s2= light [[getLightInfo]] index
|s2= light [[getLightInfo]] index

Revision as of 21:55, 13 November 2025

Hover & click on the images for description

Description

Description:
Returns various properties for the given #lightpoint or #lightreflector. ConePars and VolumeShapePars are exclusive properties of #lightreflector only.
Groups:
Object Manipulation

Syntax

Syntax:
getLightInfo light
Parameters:
light: Object - #lightpoint or #lightreflector
Return Value:
Array in format [Intensity, DiffuseColor, AmbientColor, DayLight, IR, UseFlare, FlareSize, FlareMaxDistance, AttenuationPars, AttachedToPars, ConePars, VolumeShapePars], where:

Alternative Syntax

Syntax:
light getLightInfo index
Parameters:
light: Object - #lightpoint or #lightreflector
index: Number - property index (see main syntax, for example 0 for light intensity)
Return Value:
Anything - depends on the requested property, or Nothing

Examples

Example 1:
private _lightInfo = getLightInfo light1;
Example 2:
private _lightIntensity = light1 getLightInfo 0;

Additional Information

See also:
setLightIntensity setLightColor setLightAmbient setLightDayLight setLightIR setLightUseFlare setLightFlareSize setLightFlareMaxDistance setLightAttenuation lightAttachObject lightDetachObject setLightConePars getUnitFreefallInfo setLightConePars getEntityInfo getModelInfo

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note