| 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 GetAutoDisable: Boolean; |
| 28 |
procedure SetAutoDisable(const Value: Boolean); |
| 29 |
function GetConstantForceMix: Single; |
| 30 |
procedure SetConstantForceMix(const Value: Single); |
| 31 |
function GetContactSurfaceThickness: Single; |
| 32 |
procedure SetContactSurfaceThickness(const Value: Single); |
| 33 |
function GetDisableAngularSpeed: Single; |
| 34 |
procedure SetDisableAngularSpeed(const Value: Single); |
| 35 |
function GetDisableLinearSpeed: Single; |
| 36 |
procedure SetDisableLinearSpeed(const Value: Single); |
| 37 |
function GetDisableTime: Single; |
| 38 |
procedure SetDisableTime(const Value: Single); |
| 39 |
function GetEnabled: Boolean; |
| 40 |
procedure SetEnabled(const Value: Boolean); |
| 41 |
function GetErrorCorrection: Single; |
| 42 |
procedure SetErrorCorrection(const Value: Single); |
| 43 |
function GetGravity: TVector3; |
| 44 |
procedure SetGravity(const Value: TVector3); |
| 45 |
function GetIterations: Integer; |
| 46 |
procedure SetIterations(const Value: Integer); |
| 47 |
function GetMaxCorrectionSpeed: Single; |
| 48 |
procedure SetMaxCorrectionSpeed(const Value: Single); |
| 49 |
function GetPreferAccuracy: Boolean; |
| 50 |
procedure SetPreferAccuracy(const Value: Boolean); |
| 51 |
function GetCollider: TCollisionCollectionNode; |
| 52 |
procedure SetCollider(const Value: TCollisionCollectionNode); |
| 53 |
public |
| 54 |
{ Create node fields and events. } |
| 55 |
procedure CreateNode; override; |
| 56 |
class function ClassX3DType: String; override; |
| 57 |
|
| 58 |
strict private FEventSet_contacts: TMFNodeEvent; |
| 59 |
{ } |
| 60 |
public property EventSet_contacts: TMFNodeEvent read FEventSet_contacts; |
| 61 |
|
| 62 |
strict private FFdAutoDisable: TSFBool; |
| 63 |
{ Internal wrapper for property @code(AutoDisable). This wrapper API may change, we advise to access simpler @code(AutoDisable) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 64 |
public property FdAutoDisable: TSFBool read FFdAutoDisable; |
| 65 |
{ } |
| 66 |
property AutoDisable: Boolean read GetAutoDisable write SetAutoDisable; |
| 67 |
|
| 68 |
strict private FFdBodies: TMFNode; |
| 69 |
{ Internal wrapper for property @code(Bodies). This wrapper API may change, we advise to access simpler @code(Bodies) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 70 |
public property FdBodies: TMFNode read FFdBodies; |
| 71 |
{ } |
| 72 |
procedure SetBodies(const Value: array of TRigidBodyNode); |
| 73 |
|
| 74 |
strict private FFdConstantForceMix: TSFFloat; |
| 75 |
{ Internal wrapper for property @code(ConstantForceMix). This wrapper API may change, we advise to access simpler @code(ConstantForceMix) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 76 |
public property FdConstantForceMix: TSFFloat read FFdConstantForceMix; |
| 77 |
{ } |
| 78 |
property ConstantForceMix: Single read GetConstantForceMix write SetConstantForceMix; |
| 79 |
|
| 80 |
strict private FFdContactSurfaceThickness: TSFFloat; |
| 81 |
{ Internal wrapper for property @code(ContactSurfaceThickness). This wrapper API may change, we advise to access simpler @code(ContactSurfaceThickness) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 82 |
public property FdContactSurfaceThickness: TSFFloat read FFdContactSurfaceThickness; |
| 83 |
{ } |
| 84 |
property ContactSurfaceThickness: Single read GetContactSurfaceThickness write SetContactSurfaceThickness; |
| 85 |
|
| 86 |
strict private FFdDisableAngularSpeed: TSFFloat; |
| 87 |
{ Internal wrapper for property @code(DisableAngularSpeed). This wrapper API may change, we advise to access simpler @code(DisableAngularSpeed) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 88 |
public property FdDisableAngularSpeed: TSFFloat read FFdDisableAngularSpeed; |
| 89 |
{ } |
| 90 |
property DisableAngularSpeed: Single read GetDisableAngularSpeed write SetDisableAngularSpeed; |
| 91 |
|
| 92 |
strict private FFdDisableLinearSpeed: TSFFloat; |
| 93 |
{ Internal wrapper for property @code(DisableLinearSpeed). This wrapper API may change, we advise to access simpler @code(DisableLinearSpeed) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 94 |
public property FdDisableLinearSpeed: TSFFloat read FFdDisableLinearSpeed; |
| 95 |
{ } |
| 96 |
property DisableLinearSpeed: Single read GetDisableLinearSpeed write SetDisableLinearSpeed; |
| 97 |
|
| 98 |
strict private FFdDisableTime: TSFFloat; |
| 99 |
{ Internal wrapper for property @code(DisableTime). This wrapper API may change, we advise to access simpler @code(DisableTime) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 100 |
public property FdDisableTime: TSFFloat read FFdDisableTime; |
| 101 |
{ } |
| 102 |
property DisableTime: Single read GetDisableTime write SetDisableTime; |
| 103 |
|
| 104 |
strict private FFdEnabled: TSFBool; |
| 105 |
{ 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). } |
| 106 |
public property FdEnabled: TSFBool read FFdEnabled; |
| 107 |
{ } |
| 108 |
property Enabled: Boolean read GetEnabled write SetEnabled; |
| 109 |
|
| 110 |
strict private FFdErrorCorrection: TSFFloat; |
| 111 |
{ Internal wrapper for property @code(ErrorCorrection). This wrapper API may change, we advise to access simpler @code(ErrorCorrection) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 112 |
public property FdErrorCorrection: TSFFloat read FFdErrorCorrection; |
| 113 |
{ } |
| 114 |
property ErrorCorrection: Single read GetErrorCorrection write SetErrorCorrection; |
| 115 |
|
| 116 |
strict private FFdGravity: TSFVec3f; |
| 117 |
{ Internal wrapper for property @code(Gravity). This wrapper API may change, we advise to access simpler @code(Gravity) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 118 |
public property FdGravity: TSFVec3f read FFdGravity; |
| 119 |
{ } |
| 120 |
property Gravity: TVector3 read GetGravity write SetGravity; |
| 121 |
|
| 122 |
strict private FFdIterations: TSFInt32; |
| 123 |
{ Internal wrapper for property @code(Iterations). This wrapper API may change, we advise to access simpler @code(Iterations) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 124 |
public property FdIterations: TSFInt32 read FFdIterations; |
| 125 |
{ } |
| 126 |
property Iterations: Integer read GetIterations write SetIterations; |
| 127 |
|
| 128 |
strict private FFdJoints: TMFNode; |
| 129 |
{ Internal wrapper for property @code(Joints). This wrapper API may change, we advise to access simpler @code(Joints) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 130 |
public property FdJoints: TMFNode read FFdJoints; |
| 131 |
{ } |
| 132 |
procedure SetJoints(const Value: array of TAbstractRigidJointNode); |
| 133 |
|
| 134 |
strict private FFdMaxCorrectionSpeed: TSFFloat; |
| 135 |
{ Internal wrapper for property @code(MaxCorrectionSpeed). This wrapper API may change, we advise to access simpler @code(MaxCorrectionSpeed) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 136 |
public property FdMaxCorrectionSpeed: TSFFloat read FFdMaxCorrectionSpeed; |
| 137 |
{ } |
| 138 |
property MaxCorrectionSpeed: Single read GetMaxCorrectionSpeed write SetMaxCorrectionSpeed; |
| 139 |
|
| 140 |
strict private FFdPreferAccuracy: TSFBool; |
| 141 |
{ Internal wrapper for property @code(PreferAccuracy). This wrapper API may change, we advise to access simpler @code(PreferAccuracy) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 142 |
public property FdPreferAccuracy: TSFBool read FFdPreferAccuracy; |
| 143 |
{ } |
| 144 |
property PreferAccuracy: Boolean read GetPreferAccuracy write SetPreferAccuracy; |
| 145 |
|
| 146 |
strict private FFdCollider: TSFNode; |
| 147 |
{ Internal wrapper for property @code(Collider). This wrapper API may change, we advise to access simpler @code(Collider) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). } |
| 148 |
public property FdCollider: TSFNode read FFdCollider; |
| 149 |
{ } |
| 150 |
property Collider: TCollisionCollectionNode read GetCollider write SetCollider; |
| 151 |
|
| 152 |
{$endif read_interface} |
| 153 |
|
| 154 |
{$ifdef read_implementation} |
| 155 |
|
| 156 |
{ TRigidBodyCollectionNode ----------------------------------------------- } |
| 157 |
|
| 158 |
function TRigidBodyCollectionNode.GetAutoDisable: Boolean; |
| 159 |
begin |
| 160 |
Result := FdAutoDisable.Value; |
| 161 |
end; |
| 162 |
|
| 163 |
procedure TRigidBodyCollectionNode.SetAutoDisable(const Value: Boolean); |
| 164 |
begin |
| 165 |
FdAutoDisable.Send(Value); |
| 166 |
end; |
| 167 |
|
| 168 |
procedure TRigidBodyCollectionNode.SetBodies(const Value: array of TRigidBodyNode); |
| 169 |
var |
| 170 |
L: Integer; |
| 171 |
A: array of TX3DNode; |
| 172 |
begin |
| 173 |
L := High(Value) + 1; |
| 174 |
SetLength(A, L); |
| 175 |
if L > 0 then |
| 176 |
Move(Value[0], A[0], L * SizeOf(TRigidBodyNode)); |
| 177 |
FdBodies.Send(A); |
| 178 |
end; |
| 179 |
|
| 180 |
function TRigidBodyCollectionNode.GetConstantForceMix: Single; |
| 181 |
begin |
| 182 |
Result := FdConstantForceMix.Value; |
| 183 |
end; |
| 184 |
|
| 185 |
procedure TRigidBodyCollectionNode.SetConstantForceMix(const Value: Single); |
| 186 |
begin |
| 187 |
FdConstantForceMix.Send(Value); |
| 188 |
end; |
| 189 |
|
| 190 |
function TRigidBodyCollectionNode.GetContactSurfaceThickness: Single; |
| 191 |
begin |
| 192 |
Result := FdContactSurfaceThickness.Value; |
| 193 |
end; |
| 194 |
|
| 195 |
procedure TRigidBodyCollectionNode.SetContactSurfaceThickness(const Value: Single); |
| 196 |
begin |
| 197 |
FdContactSurfaceThickness.Send(Value); |
| 198 |
end; |
| 199 |
|
| 200 |
function TRigidBodyCollectionNode.GetDisableAngularSpeed: Single; |
| 201 |
begin |
| 202 |
Result := FdDisableAngularSpeed.Value; |
| 203 |
end; |
| 204 |
|
| 205 |
procedure TRigidBodyCollectionNode.SetDisableAngularSpeed(const Value: Single); |
| 206 |
begin |
| 207 |
FdDisableAngularSpeed.Send(Value); |
| 208 |
end; |
| 209 |
|
| 210 |
function TRigidBodyCollectionNode.GetDisableLinearSpeed: Single; |
| 211 |
begin |
| 212 |
Result := FdDisableLinearSpeed.Value; |
| 213 |
end; |
| 214 |
|
| 215 |
procedure TRigidBodyCollectionNode.SetDisableLinearSpeed(const Value: Single); |
| 216 |
begin |
| 217 |
FdDisableLinearSpeed.Send(Value); |
| 218 |
end; |
| 219 |
|
| 220 |
function TRigidBodyCollectionNode.GetDisableTime: Single; |
| 221 |
begin |
| 222 |
Result := FdDisableTime.Value; |
| 223 |
end; |
| 224 |
|
| 225 |
procedure TRigidBodyCollectionNode.SetDisableTime(const Value: Single); |
| 226 |
begin |
| 227 |
FdDisableTime.Send(Value); |
| 228 |
end; |
| 229 |
|
| 230 |
function TRigidBodyCollectionNode.GetEnabled: Boolean; |
| 231 |
begin |
| 232 |
Result := FdEnabled.Value; |
| 233 |
end; |
| 234 |
|
| 235 |
procedure TRigidBodyCollectionNode.SetEnabled(const Value: Boolean); |
| 236 |
begin |
| 237 |
FdEnabled.Send(Value); |
| 238 |
end; |
| 239 |
|
| 240 |
function TRigidBodyCollectionNode.GetErrorCorrection: Single; |
| 241 |
begin |
| 242 |
Result := FdErrorCorrection.Value; |
| 243 |
end; |
| 244 |
|
| 245 |
procedure TRigidBodyCollectionNode.SetErrorCorrection(const Value: Single); |
| 246 |
begin |
| 247 |
FdErrorCorrection.Send(Value); |
| 248 |
end; |
| 249 |
|
| 250 |
function TRigidBodyCollectionNode.GetGravity: TVector3; |
| 251 |
begin |
| 252 |
Result := FdGravity.Value; |
| 253 |
end; |
| 254 |
|
| 255 |
procedure TRigidBodyCollectionNode.SetGravity(const Value: TVector3); |
| 256 |
begin |
| 257 |
FdGravity.Send(Value); |
| 258 |
end; |
| 259 |
|
| 260 |
function TRigidBodyCollectionNode.GetIterations: Integer; |
| 261 |
begin |
| 262 |
Result := FdIterations.Value; |
| 263 |
end; |
| 264 |
|
| 265 |
procedure TRigidBodyCollectionNode.SetIterations(const Value: Integer); |
| 266 |
begin |
| 267 |
FdIterations.Send(Value); |
| 268 |
end; |
| 269 |
|
| 270 |
procedure TRigidBodyCollectionNode.SetJoints(const Value: array of TAbstractRigidJointNode); |
| 271 |
var |
| 272 |
L: Integer; |
| 273 |
A: array of TX3DNode; |
| 274 |
begin |
| 275 |
L := High(Value) + 1; |
| 276 |
SetLength(A, L); |
| 277 |
if L > 0 then |
| 278 |
Move(Value[0], A[0], L * SizeOf(TAbstractRigidJointNode)); |
| 279 |
FdJoints.Send(A); |
| 280 |
end; |
| 281 |
|
| 282 |
function TRigidBodyCollectionNode.GetMaxCorrectionSpeed: Single; |
| 283 |
begin |
| 284 |
Result := FdMaxCorrectionSpeed.Value; |
| 285 |
end; |
| 286 |
|
| 287 |
procedure TRigidBodyCollectionNode.SetMaxCorrectionSpeed(const Value: Single); |
| 288 |
begin |
| 289 |
FdMaxCorrectionSpeed.Send(Value); |
| 290 |
end; |
| 291 |
|
| 292 |
function TRigidBodyCollectionNode.GetPreferAccuracy: Boolean; |
| 293 |
begin |
| 294 |
Result := FdPreferAccuracy.Value; |
| 295 |
end; |
| 296 |
|
| 297 |
procedure TRigidBodyCollectionNode.SetPreferAccuracy(const Value: Boolean); |
| 298 |
begin |
| 299 |
FdPreferAccuracy.Send(Value); |
| 300 |
end; |
| 301 |
|
| 302 |
function TRigidBodyCollectionNode.GetCollider: TCollisionCollectionNode; |
| 303 |
begin |
| 304 |
if FdCollider.Value is TCollisionCollectionNode then |
| 305 |
Result := TCollisionCollectionNode(FdCollider.Value) |
| 306 |
else |
| 307 |
Result := nil; |
| 308 |
end; |
| 309 |
|
| 310 |
procedure TRigidBodyCollectionNode.SetCollider(const Value: TCollisionCollectionNode); |
| 311 |
begin |
| 312 |
FdCollider.Send(Value); |
| 313 |
end; |
| 314 |
|
| 315 |
class function TRigidBodyCollectionNode.ClassX3DType: String; |
| 316 |
begin |
| 317 |
Result := 'RigidBodyCollection'; |
| 318 |
end; |
| 319 |
|
| 320 |
procedure TRigidBodyCollectionNode.CreateNode; |
| 321 |
begin |
| 322 |
inherited; |
| 323 |
|
| 324 |
FEventSet_contacts := TMFNodeEvent.Create(Self, 'set_contacts', true); |
| 325 |
AddEvent(FEventSet_contacts); |
| 326 |
|
| 327 |
FFdAutoDisable := TSFBool.Create(Self, True, 'autoDisable', false); |
| 328 |
FdAutoDisable.ChangeAlways := chVisibleNonGeometry; |
| 329 |
AddField(FFdAutoDisable); |
| 330 |
|
| 331 |
FFdBodies := TMFNode.Create(Self, True, 'bodies', [TRigidBodyNode]); |
| 332 |
FdBodies.ChangeAlways := chVisibleNonGeometry; |
| 333 |
AddField(FFdBodies); |
| 334 |
|
| 335 |
FFdConstantForceMix := TSFFloat.Create(Self, True, 'constantForceMix', 0.0001); |
| 336 |
FdConstantForceMix.ChangeAlways := chVisibleNonGeometry; |
| 337 |
FdConstantForceMix.MustBeNonnegative := true; |
| 338 |
AddField(FFdConstantForceMix); |
| 339 |
|
| 340 |
FFdContactSurfaceThickness := TSFFloat.Create(Self, True, 'contactSurfaceThickness', 0); |
| 341 |
FdContactSurfaceThickness.ChangeAlways := chVisibleNonGeometry; |
| 342 |
FdContactSurfaceThickness.MustBeNonnegative := true; |
| 343 |
AddField(FFdContactSurfaceThickness); |
| 344 |
|
| 345 |
FFdDisableAngularSpeed := TSFFloat.Create(Self, True, 'disableAngularSpeed', 0); |
| 346 |
FdDisableAngularSpeed.ChangeAlways := chVisibleNonGeometry; |
| 347 |
FdDisableAngularSpeed.MustBeNonnegative := true; |
| 348 |
AddField(FFdDisableAngularSpeed); |
| 349 |
|
| 350 |
FFdDisableLinearSpeed := TSFFloat.Create(Self, True, 'disableLinearSpeed', 0); |
| 351 |
FdDisableLinearSpeed.ChangeAlways := chVisibleNonGeometry; |
| 352 |
FdDisableLinearSpeed.MustBeNonnegative := true; |
| 353 |
AddField(FFdDisableLinearSpeed); |
| 354 |
|
| 355 |
FFdDisableTime := TSFFloat.Create(Self, True, 'disableTime', 0); |
| 356 |
FdDisableTime.ChangeAlways := chVisibleNonGeometry; |
| 357 |
FdDisableTime.MustBeNonnegative := true; |
| 358 |
AddField(FFdDisableTime); |
| 359 |
|
| 360 |
FFdEnabled := TSFBool.Create(Self, True, 'enabled', true); |
| 361 |
FdEnabled.ChangeAlways := chVisibleNonGeometry; |
| 362 |
AddField(FFdEnabled); |
| 363 |
|
| 364 |
FFdErrorCorrection := TSFFloat.Create(Self, True, 'errorCorrection', 0.8); |
| 365 |
FdErrorCorrection.ChangeAlways := chVisibleNonGeometry; |
| 366 |
FdErrorCorrection.MustBeNonnegative := true; |
| 367 |
AddField(FFdErrorCorrection); |
| 368 |
|
| 369 |
FFdGravity := TSFVec3f.Create(Self, True, 'gravity', Vector3(0, -9.8, 0)); |
| 370 |
FdGravity.ChangeAlways := chVisibleNonGeometry; |
| 371 |
AddField(FFdGravity); |
| 372 |
|
| 373 |
FFdIterations := TSFInt32.Create(Self, True, 'iterations', 10); |
| 374 |
FdIterations.ChangeAlways := chVisibleNonGeometry; |
| 375 |
FdIterations.MustBeNonnegative := true; |
| 376 |
AddField(FFdIterations); |
| 377 |
|
| 378 |
FFdJoints := TMFNode.Create(Self, True, 'joints', [TAbstractRigidJointNode]); |
| 379 |
FdJoints.ChangeAlways := chVisibleNonGeometry; |
| 380 |
AddField(FFdJoints); |
| 381 |
|
| 382 |
FFdMaxCorrectionSpeed := TSFFloat.Create(Self, True, 'maxCorrectionSpeed', -1); |
| 383 |
FdMaxCorrectionSpeed.ChangeAlways := chVisibleNonGeometry; |
| 384 |
AddField(FFdMaxCorrectionSpeed); |
| 385 |
|
| 386 |
FFdPreferAccuracy := TSFBool.Create(Self, True, 'preferAccuracy', false); |
| 387 |
FdPreferAccuracy.ChangeAlways := chVisibleNonGeometry; |
| 388 |
AddField(FFdPreferAccuracy); |
| 389 |
|
| 390 |
FFdCollider := TSFNode.Create(Self, False, 'collider', [TCollisionCollectionNode]); |
| 391 |
FdCollider.ChangeAlways := chVisibleNonGeometry; |
| 392 |
AddField(FFdCollider); |
| 393 |
end; |
| 394 |
|
| 395 |
{$endif read_implementation} |