DayZ 1.24
Loading...
Searching...
No Matches
PointLightBase Class Reference
Inheritance diagram for PointLightBase:
[legend]
Collaboration diagram for PointLightBase:
[legend]

Protected Member Functions

void Roadblock_Light ()
 
void EntranceLight ()
 

Protected Attributes

float m_DefaultBrightness = 5.5
 
float m_DefaultRadius = 20
 

Private Member Functions

void AnniversaryBoxLight ()
 
void BonfireLight ()
 
override void OnFrameLightSource (IEntity other, float timeSlice)
 
void BrightnessTestLight ()
 
override void OnFrameLightSource (IEntity other, float timeSlice)
 
void ChemlightLight ()
 
void SetIntensity (float coef, float time)
 
void SetColorToWhite ()
 
void SetColorToRed ()
 
void SetColorToGreen ()
 
void SetColorToBlue ()
 
void SetColorToYellow ()
 
void FireplaceLight ()
 
void SetInteriorMode ()
 
void SetExteriorMode ()
 
void FlareLight ()
 
void GoatLight ()
 
void MuzzleFlashLight ()
 
void MuzzleFlashLight_2 ()
 
void PartyLight ()
 
override void OnFrameLightSource (IEntity other, float timeSlice)
 
void PersonalLight ()
 
override void OnFrameLightSource (IEntity other, float timeSlice)
 
void PortableGasLampLight ()
 
void RoadflareLight ()
 
void StoveLight ()
 
void TorchLight ()
 
override void OnFrameLightSource (IEntity other, float timeSlice)
 
void XmasSleighLight ()
 
void XmasTreeLight ()
 
void ZombieMummyLight ()
 

Private Attributes

float m_Timer = 0
 

Static Private Attributes

static float m_FireRadius = 40
 
static float m_FireBrightness = 15.0
 
static string m_MemoryPoint = "bonfire_fire"
 
static float m_DefaultBrightness = 1.5
 
static float m_DefaultRadius = 7.5
 
static float m_FireplaceRadius = 25
 
static float m_FireplaceBrightness = 4.75
 
static float m_FlareRadius = 100
 
static float m_FlareBrightness = 10.0
 
static float m_Lifetime = 0.04
 
static float m_TorchRadius = 15
 
static float m_TorchBrightness = 5.0
 
static float m_RoadflareRadius = 30
 
static float m_RoadflareBrightness = 8.5
 

Detailed Description

Definition at line 25 of file StaticObj_Roadblock_Wood_Small.c.

Member Function Documentation

◆ AnniversaryBoxLight()

void PointLightBase::AnniversaryBoxLight ( )
inlineprivate

Definition at line 3 of file AnniversaryBoxLight.c.

4 {
5 SetVisibleDuringDaylight(true);
6 SetRadiusTo(1);
7 SetBrightnessTo(3);
8 SetCastShadow(false);
9 SetAmbientColor(0.9, 0.85, 0.4);
10 SetDiffuseColor(0.9, 0.85, 0.4);
11 }

◆ BonfireLight()

void PointLightBase::BonfireLight ( )
inlineprivate

Definition at line 7 of file BonfireLight.c.

8 {
9 SetVisibleDuringDaylight(true);
10 SetRadiusTo(m_FireRadius);
11 SetBrightnessTo(m_FireBrightness);
12 SetCastShadow(false);
13 SetFadeOutTime(1);
14 SetDiffuseColor(1.0, 0.45, 0.25);
15 SetAmbientColor(1.0, 0.45, 0.25);
16 SetFlareVisible(false);
17 SetFlickerAmplitude(0.55);
18 SetFlickerSpeed(0.75);
19 SetDancingShadowsMovementSpeed(0.1);
20 SetDancingShadowsAmplitude(0.03);
21 }
static float m_FireBrightness
Definition BonfireLight.c:4
static float m_FireRadius
Definition BonfireLight.c:3

◆ BrightnessTestLight()

void PointLightBase::BrightnessTestLight ( )
inlineprivate

Definition at line 7 of file BrightnessTestLight.c.

8 {
9 SetVisibleDuringDaylight(true);
10 SetRadiusTo(30);
11 SetCastShadow(true);
12 SetDiffuseColor(1, 1, 1);
13 SetAmbientColor(1, 1, 1);
14
15 SetBrightnessTo(10);
16 }

◆ ChemlightLight()

void PointLightBase::ChemlightLight ( )
inlineprivate

Definition at line 6 of file ChemlightLight.c.

7 {
8 SetVisibleDuringDaylight(false);
9 SetRadiusTo(m_DefaultRadius);
10 SetBrightnessTo(m_DefaultBrightness);
11 FadeIn(1);
12 SetFadeOutTime(2);
13 SetFlareVisible(false);
14 }

References m_DefaultBrightness, and m_DefaultRadius.

◆ EntranceLight()

void PointLightBase::EntranceLight ( )
inlineprotected

Definition at line 6 of file EntranceLight.c.

7 {
8 SetVisibleDuringDaylight(true);
9 SetRadiusTo(m_DefaultRadius);
10 SetBrightnessTo(m_DefaultBrightness);
11 FadeIn(1);
12 SetFadeOutTime(2);
13 SetFlareVisible(false);
14 SetCastShadow(false);
15 SetAmbientColor(0.9, 0.9, 0.7);
16 SetDiffuseColor(0.9, 0.9, 0.7);
17 }

References m_DefaultBrightness, and m_DefaultRadius.

◆ FireplaceLight()

void PointLightBase::FireplaceLight ( )
inlineprivate

Definition at line 6 of file FireplaceLight.c.

7 {
8 SetVisibleDuringDaylight(false);
9 SetRadiusTo(m_FireplaceRadius);
10 SetBrightnessTo(m_FireplaceBrightness);
11 SetCastShadow(true);
12 SetFadeOutTime(5);
13 SetDiffuseColor(1.3, 0.35, 0.15);
14 SetAmbientColor(1.3, 0.35, 0.15);
15 SetFlareVisible(false);
16 SetFlickerAmplitude(0.3);
17 SetFlickerSpeed(0.9);
19 EnableHeatHaze(true);
20 SetHeatHazeRadius(0.23);
21 SetHeatHazePower(0.010);
22 }
static float m_FireplaceRadius
static float m_FireplaceBrightness

References SetExteriorMode().

◆ FlareLight()

void PointLightBase::FlareLight ( )
inlineprivate

Definition at line 7 of file FlareLight.c.

8 {
9 SetVisibleDuringDaylight(true);
10 SetRadiusTo(m_FlareRadius);
11 SetBrightnessTo(m_FlareBrightness);
12 FadeIn(1);
13 SetFadeOutTime(0.2);
14 SetDiffuseColor(0.7, 0.7, 0.3);
15 SetAmbientColor(0.7, 0.7, 0.3);
16 SetFlareVisible(false);
17 SetFlickerAmplitude(0.9);
18 SetFlickerSpeed(0.3);
19 SetDancingShadowsMovementSpeed(0.5);
20 SetDancingShadowsAmplitude(0.15);
21 //SetLifetime( 50 );
22 EnableLinear(true);
23 EnableHeatHaze(true);
24 SetHeatHazeRadius(0.1);
25 SetHeatHazePower(0.02);
26#ifdef PLATFORM_WINDOWS
27 SetCastShadow(true);
28#else
29 SetCastShadow(false);
30#endif
31
32 }
static float m_FlareBrightness
Definition FlareLight.c:4
static float m_FlareRadius
Definition FlareLight.c:3

References m_FlareBrightness, and m_FlareRadius.

◆ GoatLight()

void PointLightBase::GoatLight ( )
inlineprivate

Definition at line 3 of file GoatLight.c.

4 {
5 SetVisibleDuringDaylight(true);
6 SetRadiusTo(1.6);
7 SetBrightnessTo(3.1);
8 SetCastShadow(false);
9 SetFadeOutTime(15);
10 SetDiffuseColor(0.85, 0.1, 0.1);
11 SetAmbientColor(0.85, 0.1, 0.1);
12 SetFlareVisible(false);
13 SetFlickerAmplitude(0.35);
14 SetFlickerSpeed(0.25);
15 SetDancingShadowsMovementSpeed(0.05);
16 SetDancingShadowsAmplitude(0.03);
17 }

◆ MuzzleFlashLight()

void PointLightBase::MuzzleFlashLight ( )
inlineprivate

Definition at line 5 of file MuzzleFlashLight.c.

6 {
7 SetLifetime(m_Lifetime);
8 FadeIn(m_Lifetime * 0.5);
9 SetFadeOutTime(m_Lifetime * 0.5);
10 SetVisibleDuringDaylight(true);
11 SetRadiusTo(15);
12 SetBrightnessTo(1);
13 SetCastShadow(false);
14 SetAmbientColor(0.76, 0.68, 0.31);
15 SetDiffuseColor(0.76, 0.68, 0.31);
16 SetFlareVisible(false);
17 }
static float m_Lifetime

References m_Lifetime.

◆ MuzzleFlashLight_2()

void PointLightBase::MuzzleFlashLight_2 ( )
inlineprivate

Definition at line 43 of file MuzzleFlashLight.c.

44 {
45 SetLifetime(m_Lifetime);
46 FadeIn(m_Lifetime * 0.1);
47 SetFadeOutTime(m_Lifetime * 0.1);
48 SetVisibleDuringDaylight(true);
49 SetRadiusTo(12);
50 SetBrightnessTo(0.2);
51 SetCastShadow(false);
52 SetAmbientColor(0.36, 0.32, 0.13);
53 SetDiffuseColor(0.36, 0.32, 0.13);
54 SetFlareVisible(false);
55 }

References m_Lifetime.

◆ OnFrameLightSource() [1/5]

override void PointLightBase::OnFrameLightSource ( IEntity other,
float timeSlice )
inlineprivate

Definition at line 23 of file BonfireLight.c.

24 {
25
26 }

◆ OnFrameLightSource() [2/5]

override void PointLightBase::OnFrameLightSource ( IEntity other,
float timeSlice )
inlineprivate

Definition at line 18 of file BrightnessTestLight.c.

19 {
21
23
24 if (pulse > 0)
25 {
26 Print(pulse);
27 SetBrightnessTo(pulse);
28 }
29 }
Definition EnMath.c:7
proto void Print(void var)
Prints content of variable to console/log.
static proto float Cos(float angle)
Returns cosinus of angle in radians.
static proto float AbsFloat(float f)
Returns absolute value.

References Math::AbsFloat(), Math::Cos(), m_Timer, and Print().

◆ OnFrameLightSource() [3/5]

override void PointLightBase::OnFrameLightSource ( IEntity other,
float timeSlice )
inlineprivate

Definition at line 15 of file PartyLight.c.

16 {
20 SetDiffuseColor(valS, valC, valT);
21 SetAmbientColor(valS, valC, valT);
22
23
25 }
static const float PI2
Definition EnMath.c:13
static proto float Tan(float angle)
Returns tangent of angle in radians.
static proto float Sin(float angle)
Returns sinus of angle in radians.

References Math::AbsFloat(), Math::Cos(), m_Timer, Math::PI2, Math::Sin(), and Math::Tan().

◆ OnFrameLightSource() [4/5]

override void PointLightBase::OnFrameLightSource ( IEntity other,
float timeSlice )
inlineprivate

Definition at line 15 of file PersonalLight.c.

16 {
17 if (GetGame() && IsEnabled())
18 {
19 vector pos = GetGame().GetCurrentCameraPosition();
20 pos += Vector(0, -0.4, 0);
21
22 SetPosition(pos);
23 }
24 }
proto native CGame GetGame()
proto native void SetPosition(vector position)
Set the world position of the Effect.
Definition Effect.c:420
proto native vector Vector(float x, float y, float z)
Vector constructor from components.

References GetGame(), SetPosition(), and Vector().

◆ OnFrameLightSource() [5/5]

override void PointLightBase::OnFrameLightSource ( IEntity other,
float timeSlice )
inlineprivate

Definition at line 25 of file TorchLight.c.

26 {
27
28 }

◆ PartyLight()

void PointLightBase::PartyLight ( )
inlineprivate

Definition at line 5 of file PartyLight.c.

6 {
7 SetVisibleDuringDaylight(true);
8 SetRadiusTo(30);
9 SetBrightnessTo(1.0);
10 SetCastShadow(true);
11 //SetLifetime(600);
12 SetFadeOutTime(1);
13 }

◆ PersonalLight()

void PointLightBase::PersonalLight ( )
inlineprivate

Definition at line 3 of file PersonalLight.c.

4 {
5 SetVisibleDuringDaylight(false);
6 SetRadiusTo(3);
7 SetBrightnessTo(0.38);
8 SetDiffuseColor(0.2, 0.23, 0.25);
9 SetCastShadow(false);
10 EnableSpecular(false);
11 EnableLinear(true);
12 SetFlareVisible(false);
13 }

◆ PortableGasLampLight()

void PointLightBase::PortableGasLampLight ( )
inlineprivate

Definition at line 6 of file PortableGasLampLight.c.

7 {
8 SetVisibleDuringDaylight(false);
9 SetRadiusTo(m_TorchRadius);
10 SetBrightnessTo(m_TorchBrightness);
11 SetCastShadow(true);
12 FadeIn(0.5);
13 SetFadeOutTime(0.1);
14 SetDiffuseColor(1.0, 0.7, 0.5);
15 SetAmbientColor(1.0, 0.7, 0.5);
16 SetFlickerAmplitude(0.3);
17 SetFlickerSpeed(0.75);
18 SetDancingShadowsMovementSpeed(0.005);
19 SetDancingShadowsAmplitude(0.003);
20 }
static float m_TorchRadius
static float m_TorchBrightness

◆ Roadblock_Light()

void PointLightBase::Roadblock_Light ( )
inlineprotected

Definition at line 30 of file StaticObj_Roadblock_Wood_Small.c.

31 {
32 SetVisibleDuringDaylight(true);
33 SetRadiusTo(m_DefaultRadius);
34 SetBrightnessTo(m_DefaultBrightness);
35 FadeIn(1);
36 SetFadeOutTime(2);
37 SetFlareVisible(false);
38 SetCastShadow(false);
39 SetAmbientColor(0.9, 0.9, 0.7);
40 SetDiffuseColor(0.9, 0.9, 0.7);
41
42 SetBlinkingSpeed(1);
43 }

References m_DefaultBrightness, and m_DefaultRadius.

◆ RoadflareLight()

void PointLightBase::RoadflareLight ( )
inlineprivate

Definition at line 7 of file RoadflareLight.c.

8 {
9 SetVisibleDuringDaylight(true);
10 SetRadiusTo(m_RoadflareRadius);
11 SetBrightnessTo(m_RoadflareBrightness);
12 SetCastShadow(true);
13 FadeIn(1);
14 SetFadeOutTime(1);
15 SetDiffuseColor(1.0, 0.3, 0.3);
16 SetAmbientColor(1.0, 0.3, 0.3);
17 SetFlareVisible(true);
18 SetFlickerAmplitude(0.2);
19 SetFlickerSpeed(1.5);
20 SetDancingShadowsMovementSpeed(0.1);
21 SetDancingShadowsAmplitude(0.015);
22 EnableHeatHaze(true);
23 SetHeatHazeRadius(0.1);
24 SetHeatHazePower(0.02);
25 }
static float m_RoadflareRadius
static float m_RoadflareBrightness

◆ SetColorToBlue()

void PointLightBase::SetColorToBlue ( )
inlineprivate

Definition at line 40 of file ChemlightLight.c.

41 {
42 SetAmbientColor(0.3, 0.3, 1.0);
43 SetDiffuseColor(0.3, 0.3, 1.0);
44 }

◆ SetColorToGreen()

void PointLightBase::SetColorToGreen ( )
inlineprivate

Definition at line 34 of file ChemlightLight.c.

35 {
36 SetAmbientColor(0.3, 1.0, 0.2);
37 SetDiffuseColor(0.3, 1.0, 0.2);
38 }

◆ SetColorToRed()

void PointLightBase::SetColorToRed ( )
inlineprivate

Definition at line 28 of file ChemlightLight.c.

29 {
30 SetAmbientColor(1.0, 0.3, 0.2);
31 SetDiffuseColor(1.0, 0.3, 0.2);
32 }

Referenced by Headtorch_Black::OnLightCreated().

◆ SetColorToWhite()

void PointLightBase::SetColorToWhite ( )
inlineprivate

Definition at line 22 of file ChemlightLight.c.

23 {
24 SetAmbientColor(0.9, 0.9, 1.0);
25 SetDiffuseColor(0.9, 0.9, 1.0);
26 }

Referenced by Clothing::OnLightCreated().

◆ SetColorToYellow()

void PointLightBase::SetColorToYellow ( )
inlineprivate

Definition at line 46 of file ChemlightLight.c.

47 {
48 SetAmbientColor(1.0, 1.0, 0.3);
49 SetDiffuseColor(1.0, 1.0, 0.3);
50 }

◆ SetExteriorMode()

void PointLightBase::SetExteriorMode ( )
inlineprivate

Definition at line 32 of file FireplaceLight.c.

33 {
34 SetDancingShadowsMovementSpeed(0.25);
35 SetDancingShadowsAmplitude(0.10);
36 }

Referenced by FireplaceLight().

◆ SetIntensity()

void PointLightBase::SetIntensity ( float coef,
float time )
inlineprivate

Definition at line 16 of file ChemlightLight.c.

17 {
18 FadeBrightnessTo(m_DefaultBrightness * coef, time);
19 FadeRadiusTo(m_DefaultRadius * coef, time);
20 }

References m_DefaultBrightness, and m_DefaultRadius.

Referenced by Clothing::OnWork(), ItemBase::OnWork(), and Switchable_Base::OnWork().

◆ SetInteriorMode()

void PointLightBase::SetInteriorMode ( )
inlineprivate

Definition at line 25 of file FireplaceLight.c.

26 {
27 SetDancingShadowsMovementSpeed(0.05);
28 SetDancingShadowsAmplitude(0.05);
29 }

◆ StoveLight()

void PointLightBase::StoveLight ( )
inlineprivate

Definition at line 3 of file StoveLight.c.

4 {
5 SetVisibleDuringDaylight(false);
6 SetRadiusTo(1);
7 SetBrightnessTo(3.0);
8 SetCastShadow(true);
9 SetFadeOutTime(0.2);
10 SetDiffuseColor(0.2, 0.45, 0.7);
11 SetAmbientColor(0.2, 0.45, 0.7);
12 SetFlareVisible(false);
13 SetFlickerAmplitude(0.35);
14 SetFlickerSpeed(0.55);
15 SetDancingShadowsMovementSpeed(0.05);
16 SetDancingShadowsAmplitude(0.03);
17 EnableHeatHaze(true);
18 SetHeatHazeRadius(0.08);
19 SetHeatHazePower(0.015);
20 }

◆ TorchLight()

void PointLightBase::TorchLight ( )
inlineprivate

Definition at line 6 of file TorchLight.c.

7 {
8 SetVisibleDuringDaylight(false);
9 SetRadiusTo(m_TorchRadius);
10 SetBrightnessTo(m_TorchBrightness);
11 SetCastShadow(true);
12 SetFadeOutTime(1);
13 SetDiffuseColor(1.3, 0.35, 0.15);
14 SetAmbientColor(1.3, 0.35, 0.15);
15 SetFlareVisible(false);
16 SetFlickerAmplitude(0.55);
17 SetFlickerSpeed(0.75);
18 SetDancingShadowsMovementSpeed(0.1);
19 SetDancingShadowsAmplitude(0.03);
20 EnableHeatHaze(true);
21 SetHeatHazeRadius(0.08);
22 SetHeatHazePower(0.015);
23 }

◆ XmasSleighLight()

void PointLightBase::XmasSleighLight ( )
inlineprivate

Definition at line 3 of file XmasSleighLight.c.

4 {
5 SetVisibleDuringDaylight(false);
6 SetRadiusTo(24);
7 SetBrightnessTo(3);
8 SetCastShadow(false);
9 SetDiffuseColor(0.7, 0.7, 1.0);
10 SetFlareVisible(false);
11 SetFlickerAmplitude(0.5);
12 SetFlickerSpeed(1);
13 }

◆ XmasTreeLight()

void PointLightBase::XmasTreeLight ( )
inlineprivate

Definition at line 3 of file XmasTreeLight.c.

4 {
5 SetVisibleDuringDaylight(false);
6 SetRadiusTo(12);
7 SetBrightnessTo(0.50);
8 SetCastShadow(false);
9 SetDiffuseColor(1.2, 1.0, 0.7);
10 SetDancingShadowsMovementSpeed(0.005);
11 SetDancingShadowsAmplitude(0.003);
12 }

◆ ZombieMummyLight()

void PointLightBase::ZombieMummyLight ( )
inlineprivate

Definition at line 3 of file ZombieMummyLight.c.

4 {
5 SetVisibleDuringDaylight(false);
6 SetRadiusTo(2.1);
7 SetBrightnessTo(3.1);
8 SetCastShadow(false);
9 SetFadeOutTime(15);
10 SetDiffuseColor(0.6, 0.5, 0.1);
11 SetAmbientColor(0.6, 0.5, 0.1);
12 SetFlareVisible(false);
13 SetFlickerAmplitude(0.35);
14 SetFlickerSpeed(0.25);
15 SetDancingShadowsMovementSpeed(0.05);
16 SetDancingShadowsAmplitude(0.03);
17 }

Member Data Documentation

◆ m_DefaultBrightness [1/2]

float PointLightBase::m_DefaultBrightness = 5.5
protected

Definition at line 27 of file StaticObj_Roadblock_Wood_Small.c.

◆ m_DefaultBrightness [2/2]

float PointLightBase::m_DefaultBrightness = 1.5
staticprivate

Definition at line 3 of file ChemlightLight.c.

◆ m_DefaultRadius [1/2]

float PointLightBase::m_DefaultRadius = 20
protected

Definition at line 28 of file StaticObj_Roadblock_Wood_Small.c.

◆ m_DefaultRadius [2/2]

float PointLightBase::m_DefaultRadius = 7.5
staticprivate

Definition at line 4 of file ChemlightLight.c.

◆ m_FireBrightness

float PointLightBase::m_FireBrightness = 15.0
staticprivate

Definition at line 4 of file BonfireLight.c.

Referenced by BuildingSuper::EEInit().

◆ m_FireplaceBrightness

float PointLightBase::m_FireplaceBrightness = 4.75
staticprivate

Definition at line 4 of file FireplaceLight.c.

◆ m_FireplaceRadius

float PointLightBase::m_FireplaceRadius = 25
staticprivate

Definition at line 3 of file FireplaceLight.c.

◆ m_FireRadius

float PointLightBase::m_FireRadius = 40
staticprivate

Definition at line 3 of file BonfireLight.c.

Referenced by BuildingSuper::EEInit().

◆ m_FlareBrightness

float PointLightBase::m_FlareBrightness = 10.0
staticprivate

Definition at line 4 of file FlareLight.c.

◆ m_FlareRadius

float PointLightBase::m_FlareRadius = 100
staticprivate

Definition at line 3 of file FlareLight.c.

◆ m_Lifetime

static float PointLightBase::m_Lifetime = 0.04
staticprivate

Definition at line 3 of file MuzzleFlashLight.c.

◆ m_MemoryPoint

static string PointLightBase::m_MemoryPoint = "bonfire_fire"
staticprivate

Definition at line 5 of file BonfireLight.c.

Referenced by BuildingSuper::EEInit().

◆ m_RoadflareBrightness

float PointLightBase::m_RoadflareBrightness = 8.5
staticprivate

Definition at line 4 of file RoadflareLight.c.

◆ m_RoadflareRadius

float PointLightBase::m_RoadflareRadius = 30
staticprivate

Definition at line 3 of file RoadflareLight.c.

◆ m_Timer

float PointLightBase::m_Timer = 0
private

Definition at line 5 of file BrightnessTestLight.c.

◆ m_TorchBrightness

static float PointLightBase::m_TorchBrightness = 5.0
staticprivate

Definition at line 4 of file PortableGasLampLight.c.

◆ m_TorchRadius

static float PointLightBase::m_TorchRadius = 15
staticprivate

Definition at line 3 of file PortableGasLampLight.c.


The documentation for this class was generated from the following files: