Debian Codegraph @

src/scene/x3d/auto_generated_node_helpers/x3dnodes_x3drigidjointnode.inc

raw
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 GetBody1: TRigidBodyNode;
28 procedure SetBody1(const Value: TRigidBodyNode);
29 function GetBody2: TRigidBodyNode;
30 procedure SetBody2(const Value: TRigidBodyNode);
31 public
32 { Create node fields and events. }
33 procedure CreateNode; override;
34 class function ClassX3DType: String; override;
35
36 strict private FFdBody1: TSFNode;
37 { Internal wrapper for property @code(Body1). This wrapper API may change, we advise to access simpler @code(Body1) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
38 public property FdBody1: TSFNode read FFdBody1;
39 { }
40 property Body1: TRigidBodyNode read GetBody1 write SetBody1;
41
42 strict private FFdBody2: TSFNode;
43 { Internal wrapper for property @code(Body2). This wrapper API may change, we advise to access simpler @code(Body2) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
44 public property FdBody2: TSFNode read FFdBody2;
45 { }
46 property Body2: TRigidBodyNode read GetBody2 write SetBody2;
47
48 strict private FFdForceOutput: TMFString;
49 { Internal wrapper for property @code(ForceOutput). This wrapper API may change, we advise to access simpler @code(ForceOutput) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
50 public property FdForceOutput: TMFString read FFdForceOutput;
51 { }
52 procedure SetForceOutput(const Value: array of string); overload;
53 { }
54 procedure SetForceOutput(const Value: TCastleStringList); overload;
55
56 {$endif read_interface}
57
58 {$ifdef read_implementation}
59
60 { TAbstractRigidJointNode ----------------------------------------------- }
61
62 function TAbstractRigidJointNode.GetBody1: TRigidBodyNode;
63 begin
64 if FdBody1.Value is TRigidBodyNode then
65 Result := TRigidBodyNode(FdBody1.Value)
66 else
67 Result := nil;
68 end;
69
70 procedure TAbstractRigidJointNode.SetBody1(const Value: TRigidBodyNode);
71 begin
72 FdBody1.Send(Value);
73 end;
74
75 function TAbstractRigidJointNode.GetBody2: TRigidBodyNode;
76 begin
77 if FdBody2.Value is TRigidBodyNode then
78 Result := TRigidBodyNode(FdBody2.Value)
79 else
80 Result := nil;
81 end;
82
83 procedure TAbstractRigidJointNode.SetBody2(const Value: TRigidBodyNode);
84 begin
85 FdBody2.Send(Value);
86 end;
87
88 procedure TAbstractRigidJointNode.SetForceOutput(const Value: array of string);
89 begin
90 FdForceOutput.Send(Value);
91 end;
92
93 procedure TAbstractRigidJointNode.SetForceOutput(const Value: TCastleStringList);
94 begin
95 FdForceOutput.Send(Value);
96 end;
97
98 class function TAbstractRigidJointNode.ClassX3DType: String;
99 begin
100 Result := 'X3DRigidJointNode';
101 end;
102
103 procedure TAbstractRigidJointNode.CreateNode;
104 begin
105 inherited;
106
107 FFdBody1 := TSFNode.Create(Self, True, 'body1', [TRigidBodyNode]);
108 FdBody1.ChangeAlways := chVisibleNonGeometry;
109 AddField(FFdBody1);
110
111 FFdBody2 := TSFNode.Create(Self, True, 'body2', [TRigidBodyNode]);
112 FdBody2.ChangeAlways := chVisibleNonGeometry;
113 AddField(FFdBody2);
114
115 FFdForceOutput := TMFString.Create(Self, True, 'forceOutput', ['NONE']);
116 FdForceOutput.ChangeAlways := chVisibleNonGeometry;
117 AddField(FFdForceOutput);
118
119 DefaultContainerField := 'joints';
120 end;
121
122 {$endif read_implementation}