| 1 |
{ -*- buffer-read-only: t -*- |
| 2 |
|
| 3 |
Copyright 2015-2024 Michalis Kamburelis. |
| 4 |
|
| 5 |
This file is part of "Castle Game Engine". |
| 6 |
|
| 7 |
"Castle Game Engine" is free software; see the file COPYING.txt, |
| 8 |
included in this distribution, for details about the copyright. |
| 9 |
|
| 10 |
"Castle Game Engine" is distributed in the hope that it will be useful, |
| 11 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 13 |
|
| 14 |
---------------------------------------------------------------------------- |
| 15 |
} |
| 16 |
|
| 17 |
{ Automatically generated node properties. |
| 18 |
|
| 19 |
Do not edit this file manually! |
| 20 |
To add new properties: |
| 21 |
- add them to the text files in tools/internal/x3d-nodes-to-pascal/nodes-specification/ , |
| 22 |
- and regenerate include files by running x3d-nodes-to-pascal } |
| 23 |
|
| 24 |
{$ifdef read_interface} |
| 25 |
|
| 26 |
strict private |
| 27 |
function GetCycleInterval: TFloatTime; |
| 28 |
procedure SetCycleInterval(const Value: TFloatTime); |
| 29 |
function GetEnabled: Boolean; |
| 30 |
procedure SetEnabled(const Value: Boolean); |
| 31 |
function GetFractionIncreasing: Boolean; |
| 32 |
procedure SetFractionIncreasing(const Value: Boolean); |
| 33 |
function GetDetectAffectedFields: Boolean; |
| 34 |
procedure SetDetectAffectedFields(const Value: Boolean); |
| 35 |
public |
| 36 |
{ Create node fields and events. } |
| 37 |
procedure CreateNode; override; |
| 38 |
class function ClassX3DType: String; override; |
| 39 |
|
| 40 |
strict private FFdCycleInterval: TSFTime; |
| 41 |
{ Internal wrapper for property @code(CycleInterval). This wrapper API may change, we advise to access simpler @code(CycleInterval) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 42 |
public property FdCycleInterval: TSFTime read FFdCycleInterval; |
| 43 |
{ } |
| 44 |
property CycleInterval: TFloatTime read GetCycleInterval write SetCycleInterval; |
| 45 |
|
| 46 |
strict private FEventCycleTime: TSFTimeEvent; |
| 47 |
{ } |
| 48 |
public property EventCycleTime: TSFTimeEvent read FEventCycleTime; |
| 49 |
|
| 50 |
strict private FEventFraction_changed: TSFFloatEvent; |
| 51 |
{ } |
| 52 |
public property EventFraction_changed: TSFFloatEvent read FEventFraction_changed; |
| 53 |
|
| 54 |
strict private FEventTime: TSFTimeEvent; |
| 55 |
{ } |
| 56 |
public property EventTime: TSFTimeEvent read FEventTime; |
| 57 |
|
| 58 |
strict private FFdEnabled: TSFBool; |
| 59 |
{ Internal wrapper for property @code(Enabled). This wrapper API may change, we advise to access simpler @code(Enabled) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 60 |
public property FdEnabled: TSFBool read FFdEnabled; |
| 61 |
{ } |
| 62 |
property Enabled: Boolean read GetEnabled write SetEnabled; |
| 63 |
|
| 64 |
strict private FFdFractionIncreasing: TSFBool; |
| 65 |
{ Internal wrapper for property @code(FractionIncreasing). This wrapper API may change, we advise to access simpler @code(FractionIncreasing) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 66 |
public property FdFractionIncreasing: TSFBool read FFdFractionIncreasing; |
| 67 |
{ } |
| 68 |
property FractionIncreasing: Boolean read GetFractionIncreasing write SetFractionIncreasing; |
| 69 |
|
| 70 |
strict private FFdDetectAffectedFields: TSFBool; |
| 71 |
{ Internal wrapper for property @code(DetectAffectedFields). This wrapper API may change, we advise to access simpler @code(DetectAffectedFields) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 72 |
public property FdDetectAffectedFields: TSFBool read FFdDetectAffectedFields; |
| 73 |
{ } |
| 74 |
property DetectAffectedFields: Boolean read GetDetectAffectedFields write SetDetectAffectedFields; |
| 75 |
|
| 76 |
{$endif read_interface} |
| 77 |
|
| 78 |
{$ifdef read_implementation} |
| 79 |
|
| 80 |
{ TTimeSensorNode ----------------------------------------------- } |
| 81 |
|
| 82 |
function TTimeSensorNode.GetCycleInterval: TFloatTime; |
| 83 |
begin |
| 84 |
Result := FdCycleInterval.Value; |
| 85 |
end; |
| 86 |
|
| 87 |
procedure TTimeSensorNode.SetCycleInterval(const Value: TFloatTime); |
| 88 |
begin |
| 89 |
FdCycleInterval.Send(Value); |
| 90 |
end; |
| 91 |
|
| 92 |
function TTimeSensorNode.GetEnabled: Boolean; |
| 93 |
begin |
| 94 |
Result := FdEnabled.Value; |
| 95 |
end; |
| 96 |
|
| 97 |
procedure TTimeSensorNode.SetEnabled(const Value: Boolean); |
| 98 |
begin |
| 99 |
FdEnabled.Send(Value); |
| 100 |
end; |
| 101 |
|
| 102 |
function TTimeSensorNode.GetFractionIncreasing: Boolean; |
| 103 |
begin |
| 104 |
Result := FdFractionIncreasing.Value; |
| 105 |
end; |
| 106 |
|
| 107 |
procedure TTimeSensorNode.SetFractionIncreasing(const Value: Boolean); |
| 108 |
begin |
| 109 |
FdFractionIncreasing.Send(Value); |
| 110 |
end; |
| 111 |
|
| 112 |
function TTimeSensorNode.GetDetectAffectedFields: Boolean; |
| 113 |
begin |
| 114 |
Result := FdDetectAffectedFields.Value; |
| 115 |
end; |
| 116 |
|
| 117 |
procedure TTimeSensorNode.SetDetectAffectedFields(const Value: Boolean); |
| 118 |
begin |
| 119 |
FdDetectAffectedFields.Send(Value); |
| 120 |
end; |
| 121 |
|
| 122 |
class function TTimeSensorNode.ClassX3DType: String; |
| 123 |
begin |
| 124 |
Result := 'TimeSensor'; |
| 125 |
end; |
| 126 |
|
| 127 |
procedure TTimeSensorNode.CreateNode; |
| 128 |
begin |
| 129 |
inherited; |
| 130 |
|
| 131 |
FFdCycleInterval := TSFTime.Create(Self, True, 'cycleInterval', 1); |
| 132 |
FdCycleInterval.ChangeAlways := chVisibleNonGeometry; |
| 133 |
AddField(FFdCycleInterval); |
| 134 |
|
| 135 |
FEventCycleTime := TSFTimeEvent.Create(Self, 'cycleTime', false); |
| 136 |
AddEvent(FEventCycleTime); |
| 137 |
|
| 138 |
FEventFraction_changed := TSFFloatEvent.Create(Self, 'fraction_changed', false); |
| 139 |
AddEvent(FEventFraction_changed); |
| 140 |
|
| 141 |
FEventTime := TSFTimeEvent.Create(Self, 'time', false); |
| 142 |
AddEvent(FEventTime); |
| 143 |
|
| 144 |
FFdEnabled := TSFBool.Create(Self, True, 'enabled', true); |
| 145 |
FdEnabled.ChangeAlways := chVisibleNonGeometry; |
| 146 |
AddField(FFdEnabled); |
| 147 |
|
| 148 |
FFdFractionIncreasing := TSFBool.Create(Self, True, 'fractionIncreasing', true); |
| 149 |
FdFractionIncreasing.ChangeAlways := chVisibleNonGeometry; |
| 150 |
AddField(FFdFractionIncreasing); |
| 151 |
|
| 152 |
FFdDetectAffectedFields := TSFBool.Create(Self, False, 'detectAffectedFields', true); |
| 153 |
FdDetectAffectedFields.ChangeAlways := chVisibleNonGeometry; |
| 154 |
AddField(FFdDetectAffectedFields); |
| 155 |
end; |
| 156 |
|
| 157 |
{$endif read_implementation} |