Cogs.Core
Extensions
Drilling
Source
TensionRingComponent.h
1
2
#include "EntityPtr.h"
3
#include "Components/Core/DynamicComponent.h"
4
5
namespace
Cogs
6
{
7
namespace
Core
8
{
9
class
Context;
10
11
class
TensionRingComponent
:
public
DynamicComponent
12
{
13
public
:
14
TensionRingComponent
()
15
{
16
this->
setChanged
();
17
}
18
19
float
extensionRadius
= 1.3f;
20
float
splitDistance
= 0.0f;
21
float
splitAngle
= 0.0f;
22
23
float
innerRadius
= 0.8f;
24
float
outerRadius
= 1.0f;
25
26
float
startDepth
= 0.0f;
27
float
endDepth
= 100.0f;
28
29
float
startAngle = 0.0f;
30
31
static
void
registerType();
32
33
void
initialize(
Context
* context);
34
void
update();
35
void
updateChildren();
36
37
EntityPtr
shape1;
38
EntityPtr
shape2;
39
40
EntityPtr
trajectory1;
41
EntityPtr
trajectory2;
42
};
43
}
44
}
45
46
template
<>
inline
Cogs::StringView
getName<Cogs::Core::TensionRingComponent>() {
return
"TensionRingComponent"
; }
Cogs::ComponentModel::Component::setChanged
void setChanged()
Sets the component to the ComponentFlags::Changed state with carry.
Definition:
Component.h:202
Cogs::Core::Context
A Context instance contains all the services, systems and runtime components needed to use Cogs.
Definition:
Context.h:83
Cogs::Core::DynamicComponent
Base class for components implementing dynamic behavior.
Definition:
DynamicComponent.h:31
Cogs::Core::TensionRingComponent
Definition:
TensionRingComponent.h:12
Cogs::Core::TensionRingComponent::endDepth
float endDepth
End depth along trajectory.
Definition:
TensionRingComponent.h:27
Cogs::Core::TensionRingComponent::startDepth
float startDepth
Start depth along trajectory.
Definition:
TensionRingComponent.h:26
Cogs::Core::TensionRingComponent::outerRadius
float outerRadius
Outer radius of the tension ring.
Definition:
TensionRingComponent.h:24
Cogs::Core::TensionRingComponent::extensionRadius
float extensionRadius
Outermost extended radius of the ring.
Definition:
TensionRingComponent.h:19
Cogs::Core::TensionRingComponent::innerRadius
float innerRadius
Inner radius of the tension ring.
Definition:
TensionRingComponent.h:23
Cogs::Core::TensionRingComponent::splitAngle
float splitAngle
Specify at which angle in radians the ring should be split in two.
Definition:
TensionRingComponent.h:21
Cogs::Core::TensionRingComponent::splitDistance
float splitDistance
The distance between the two halves of the ring if it is split in two.
Definition:
TensionRingComponent.h:20
Cogs::StringView
Provides a weakly referenced view over the contents of a string.
Definition:
StringView.h:24
Cogs::Core::EntityPtr
std::shared_ptr< ComponentModel::Entity > EntityPtr
Smart pointer for Entity access.
Definition:
EntityPtr.h:12
Cogs
Contains all Cogs related functionality.
Definition:
FieldSetter.h:23
Generated by
1.9.6