LensFlare Type

The LensFlare object type is created by ObjectTemplate.Create.

Lens flares add a nice effect to increase the realism of the game. The LensFlare type allows you to create these flares and place them in the scene. They are created in the [level]/Init SkyAndSun.con file.

Used in a total of 29 .con files: Skyandsun.con

Parent directory of these .con files: Bf1942/Levels

Example: (from Bf1942/Levels/Bocage/Init/SkyAndSun.con)
   rem ************************
   rem *** Lenzflare ***
   rem ************************
   rem
   rem *** "TSun" of primitive LensFlare ***
   rem
   ObjectTemplate.Create LensFlare TSun
   ObjectTemplate.SetLensFlareCount 5
   ObjectTemplate.SetBackFlareCount 0
   ObjectTemplate.SetCoronaCount 2
   ObjectTemplate.initLensFlares
   ObjectTemplate.SetVisibilityAngleDeg 360
   REM *** Falre no:1 ***
   REM
   ObjectTemplate.SetFlareSrcBlend BMSourceAlpha 0
   ObjectTemplate.SetFlareDestBlend BMOne 0
   ObjectTemplate.SetFlareTexture ring5.tga 0
   ObjectTemplate.SetFlareSize 3 0
   ObjectTemplate.SetFlareScale -1.5 0
   ObjectTemplate.SetFlareRot 0 0
   ObjectTemplate.SetFlareColor 255/255/255/50 0
   ObjectTemplate.SetFlareDistFadeScale 1 0
   REM
   REM *** Falre no:2 > LittleDot***
   REM
   ObjectTemplate.SetFlareSrcBlend BMSourceAlpha 1
   ObjectTemplate.SetFlareDestBlend BMOne 1
   ObjectTemplate.SetFlareTexture ring3.tga 1
   ObjectTemplate.SetFlareSize 0.5 1
   ObjectTemplate.SetFlareScale 1 1
   ObjectTemplate.SetFlareRot 0 1
   ObjectTemplate.SetFlareColor 255/255/255/200 1
   REM
   REM *** Falre no:3 ***
   REM
   ObjectTemplate.SetFlareSrcBlend BMSourceAlpha 2
   ObjectTemplate.SetFlareDestBlend BMOne 2
   ObjectTemplate.SetFlareTexture ring4.tga 2
   ObjectTemplate.SetFlareSize 0.3 2
   ObjectTemplate.SetFlareScale 1.5 2
   ObjectTemplate.SetFlareRot 0 2
   ObjectTemplate.SetFlareColor 255/255/255/155 2
   REM *** Falre no:4 :Twins***
   ObjectTemplate.SetFlareSrcBlend BMSourceAlpha 3
   ObjectTemplate.SetFlareDestBlend BMOne 3
   ObjectTemplate.SetFlareTexture ring5.tga 3
   ObjectTemplate.SetFlareSize 2 3
   ObjectTemplate.SetFlareScale -2 3
   ObjectTemplate.SetFlareRot 0 3
   ObjectTemplate.SetFlareColor 255/255/255/50 3
   ObjectTemplate.SetFlareDistFadeScale 0.5 3
   REM
   REM *** Falre no:5 :Twins***
   REM
   ObjectTemplate.SetFlareSrcBlend BMSourceAlpha 4
   ObjectTemplate.SetFlareDestBlend BMOne 4
   ObjectTemplate.SetFlareTexture ring5.tga 4
   ObjectTemplate.SetFlareSize 0 4
   ObjectTemplate.SetFlareScale -2 4
   ObjectTemplate.SetFlareRot 1 4
   ObjectTemplate.SetFlareColor 255/255/255/100 4
   ObjectTemplate.SetFlareDistFadeScale 1 4
   REM
   REM *** Corona no:0 ***
   REM
   ObjectTemplate.SetCoronaSrcBlend BMSourceAlpha 0
   ObjectTemplate.SetCoronaDestBlend BMOne 0
   ObjectTemplate.SetCoronaTexture sunflare7.tga 0
   ObjectTemplate.SetCoronaSize 2 0
   ObjectTemplate.SetCoronaScale 1 0
   ObjectTemplate.SetCoronaRot 0 0
   ObjectTemplate.SetCoronaColor 255/255/200/225 0
   REM
   REM *** Corona no:1 - Red aura***
   REM
   ObjectTemplate.SetCoronaSrcBlend BMSourceAlpha 1
   ObjectTemplate.SetCoronaDestBlend BMOne 1
   ObjectTemplate.SetCoronaTexture sunflare9.tga 1
   ObjectTemplate.SetCoronaSize 5 1
   ObjectTemplate.SetCoronaScale 5 1
   ObjectTemplate.SetCoronaRot 0 1
   ObjectTemplate.SetCoronaColor 255/150/0/100 1

Properties used with this type of object:
   ObjectTemplate.Create
   ObjectTemplate.SetBackFlareCount
   ObjectTemplate.SetCoronaColor
   ObjectTemplate.SetCoronaCount
   ObjectTemplate.SetCoronaDestBlend
   ObjectTemplate.SetCoronaRot
   ObjectTemplate.SetCoronaScale
   ObjectTemplate.SetCoronaSize
   ObjectTemplate.SetCoronaSrcBlend
   ObjectTemplate.SetCoronaTexture
   ObjectTemplate.SetFlareColor
   ObjectTemplate.SetFlareDestBlend
   ObjectTemplate.SetFlareDistFadeScale
   ObjectTemplate.SetFlareRot
   ObjectTemplate.SetFlareScale
   ObjectTemplate.SetFlareSize
   ObjectTemplate.SetFlareSrcBlend
   ObjectTemplate.SetFlareTexture
   ObjectTemplate.SetLensFlareCount
   ObjectTemplate.SetVisibilityAngleDeg


Go to the ObjectTemplate type list page, ObjectTemplate page, All Types list, Class list, CON file list, or Main scripting page.