3#include <Core/Interfaces/WindWorldModule.h>
4#include <Core/World/Component.h>
5#include <Core/World/Declarations.h>
6#include <Core/World/World.h>
7#include <GameEngine/GameEngineDLL.h>
49 float m_fStrengthFactor = 1.0f;
65 float GetWindInMetersPerSecond()
const;
97 float GetRadius()
const {
return m_fRadius; }
98 void SetRadius(
float fVal);
103 float m_fRadius = 1.0f;
114 using StorageType = plUInt8;
152 float GetRadius()
const {
return m_fRadius; }
153 void SetRadius(
float fVal);
155 float GetRadiusFalloff()
const {
return m_fRadiusFalloff; }
156 void SetRadiusFalloff(
float fVal);
158 float GetLength()
const {
return m_fLength; }
159 void SetLength(
float fVal);
161 float GetPositiveFalloff()
const {
return m_fPositiveFalloff; }
162 void SetPositiveFalloff(
float fVal);
164 float GetNegativeFalloff()
const {
return m_fNegativeFalloff; }
165 void SetNegativeFalloff(
float fVal);
172 void ComputeScaleBiasValues();
174 float m_fRadius = 1.0f;
175 float m_fRadiusFalloff = 0.0f;
176 float m_fLength = 5.0f;
177 float m_fPositiveFalloff = 0.0f;
178 float m_fNegativeFalloff = 0.0f;
214 float GetLength()
const {
return m_fLength; }
215 void SetLength(
float fVal);
217 plAngle GetAngle()
const {
return m_Angle; }
223 float m_fLength = 1.0f;
Float wrapper struct for a safe usage and conversions of angles.
Definition Angle.h:10
static constexpr plAngle MakeFromDegree(float fDegree)
Creates an instance of plAngle that was initialized from degree. (Performs a conversion)
Definition Angle_inl.h:33
Base class of all component types.
Definition Component.h:25
virtual void SerializeComponent(plWorldWriter &inout_stream) const
Override this to save the current state of the component to the given stream.
Definition Component.cpp:54
virtual void OnDeactivated()
This method is called when the component gets deactivated.
Definition Component.cpp:142
virtual void OnSimulationStarted()
This method is called once for active components, at the start of the next world update,...
Definition Component.cpp:144
virtual void DeserializeComponent(plWorldReader &inout_stream)
Override this to load the current state of the component from the given stream.
Definition Component.cpp:58
virtual void OnActivated()
This method is called when the component gets activated.
Definition Component.cpp:140
Definition ComponentManager.h:88
A 4-component SIMD vector class.
Definition SimdVec4f.h:8
Base class for components that define wind volumes.
Definition WindVolumeComponent.h:17
plEnum< plWindStrength > m_Strength
How strong the wind shall blow at the strongest point of the volume.
Definition WindVolumeComponent.h:46
plEnum< plOnComponentFinishedAction > m_OnFinishedAction
What happens after the wind burst is over.
Definition WindVolumeComponent.h:59
plTime m_BurstDuration
If non-zero, the wind will only last for a limited amount of time.
Definition WindVolumeComponent.h:43
static plSpatialData::Category SpatialDataCategory
The spatial category to use to find all wind volume components through the spatial system.
Definition WindVolumeComponent.h:40
A conical shape in which wind shall be applied to objects.
Definition WindVolumeComponent.h:195
A cylindrical volume in which wind shall be applied.
Definition WindVolumeComponent.h:133
A spherical shape in which wind shall be applied to objects.
Definition WindVolumeComponent.h:78
Reads a world description from a stream. Allows to instantiate that world multiple times in different...
Definition WorldReader.h:47
Stores an entire plWorld in a stream.
Definition WorldWriter.h:13
A custom enum implementation that allows to define the underlying storage type to control its memory ...
Definition Enum.h:37
For internal use by components to trigger some known behavior. Usually components will post this mess...
Definition TriggerMessage.h:26
Definition DeleteObjectMessage.h:7
Definition UpdateLocalBoundsMessage.h:9
Definition SpatialData.h:27
The time class encapsulates a double value storing the time in seconds.
Definition Time.h:12
How the wind direction shall be calculated in a cylindrical wind volume.
Definition WindVolumeComponent.h:113
Enum
Definition WindVolumeComponent.h:117
@ Directional
The wind direction is outwards from the cylinder.
Definition WindVolumeComponent.h:118
@ Vortex
The wind direction is tangential, moving in a circular fashion around the cylinder like in a tornado.
Definition WindVolumeComponent.h:119