| 1 |
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.0//EN" "https://www.web3d.org/specifications/x3d-3.0.dtd">
|
| 3 | <X3D profile='Immersive' version='3.0' xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-3.0.xsd'> |
| 4 | <head> |
| 5 | <meta name='title' content=' NonLethalNetLauncherPrototype.x3d '/> |
| 6 | <meta name='description' content='Simple model that depicts small boat launched net entanglement system.'/> |
| 7 | <meta name='creator' content='James Harney'/> |
| 8 | <meta name='created' content='14 March 2002'/> |
| 9 | <meta name='modified' content='28 November 2019'/> |
| 10 | <meta name='identifier' content=' https://www.web3d.org/x3d/content/examples/Savage/Weapons/Guns/NonLethalNetLauncherPrototype.x3d '/> |
| 11 | <meta name='generator' content='X3D-Edit 3.2, https://www.web3d.org/x3d/tools/X3D-Edit'/> |
| 12 | <meta name='license' content='../../license.html'/> |
| 13 | </head> |
| 14 | <Scene> |
| 15 | <WorldInfo title='NonLethalNetLauncherPrototype.x3d'/> |
| 16 | <NavigationInfo speed='10'/> |
| 17 | <ProtoDeclare name='NetLauncher' appinfo='Nonlethal Net Launcher to repel boarders'> |
| 18 | <ProtoInterface> |
| 19 | <field name='startLaunchToStbd' type='SFTime' accessType='inputOnly'/> |
| 20 | <field name='startLaunchToPort' type='SFTime' accessType='inputOnly'/> |
| 21 | <field name='netTranslation' type='SFVec3f' accessType='outputOnly'/> |
| 22 | <field name='netScale' type='SFVec3f' accessType='outputOnly'/> |
| 23 | <field name='netOrientation' type='SFRotation' accessType='outputOnly'/> |
| 24 | <field name='nettingScale' type='SFVec3f' accessType='outputOnly'/> |
| 25 | </ProtoInterface> |
| 26 | <ProtoBody> |
| 27 | <Group> |
| 28 | <Background groundAngle='1.309 1.570796' groundColor='0.1 0.1 0 0.4 0.25 0.2 0.6 0.6 0.6' skyAngle='1.309 1.571' skyColor='0 0.2 0.7 0 0.5 1 1 1 1'/> |
| 29 | <!-- Note that the term stbd refers to the position of the launcher tube and is 180 the direction of launch --> |
| 30 | <Transform> |
| 31 | <Viewpoint DEF='STBD' description='Net Launcher stbd View' jump='false' orientation='1 0 0 -.2' position='0 5 12'/> |
| 32 | <Viewpoint DEF='FRONT' description='Net Launcher Front View' orientation='0 1 0 1.57' position='12 3 0'/> |
| 33 | <Viewpoint DEF='PORT' description='Net Launcher Port View' jump='false' orientation='0 1 0 3.14' position='0 3 -12'/> |
| 34 | <Viewpoint DEF='REAR' description='Net Launcher Rear View' orientation='0 1 0 -1.57' position='-12 3 0'/> |
| 35 | </Transform> |
| 36 |
<!-- ROUTE information for NetPositClock node:
[from fraction_changed to NetPositInterp.set_fraction
]
[from fraction_changed to NetOrientInterp.set_fraction
]
[from fraction_changed to NetPositScale.set_fraction
]
[from fraction_changed to NettingScale.set_fraction
]
-->
<TimeSensor DEF='NetPositClock' cycleInterval='3'> |
| 37 | <IS> |
| 38 | <connect nodeField='startTime' protoField='startLaunchToStbd'/> |
| 39 | </IS> |
| 40 | </TimeSensor> |
| 41 |
<!-- ROUTE information for NetPositClockStbd node:
[from fraction_changed to NetPositScaleStbd.set_fraction
]
[from fraction_changed to NetPositInterpStbd.set_fraction
]
[from fraction_changed to NetOrientInterpStbd.set_fraction
]
[from fraction_changed to NettingScaleStbd.set_fraction
]
-->
<TimeSensor DEF='NetPositClockStbd' cycleInterval='3'> |
| 42 | <IS> |
| 43 | <connect nodeField='startTime' protoField='startLaunchToPort'/> |
| 44 | </IS> |
| 45 | </TimeSensor> |
| 46 |
<!-- ROUTE information for NetPositInterp node:
[from NetPositClock.fraction_changed to set_fraction
]
[from value_changed to NetTransform.set_translation
]
-->
<PositionInterpolator DEF='NetPositInterp' key='0 .5 1' keyValue='0 0 0 0 25 10 0 7.5 21'> |
| 47 | <IS> |
| 48 | <connect nodeField='value_changed' protoField='netTranslation'/> |
| 49 | </IS> |
| 50 | </PositionInterpolator> |
| 51 |
<!-- ROUTE information for NetPositInterpStbd node:
[from NetPositClockStbd.fraction_changed to set_fraction
]
[from value_changed to NetTransformStbd.set_translation
]
-->
<PositionInterpolator DEF='NetPositInterpStbd' key='0 .5 1' keyValue='0 0 0 0 25 -10 0 7.5 -21'/> |
| 52 |
<!-- ROUTE information for NetPositScale node:
[from NetPositClock.fraction_changed to set_fraction
]
[from value_changed to NetTransform.scale
]
-->
<PositionInterpolator DEF='NetPositScale' key='.1 1.0' keyValue='1 1 1 1 8 1'/> |
| 53 |
<!-- ROUTE information for NetPositScaleStbd node:
[from NetPositClockStbd.fraction_changed to set_fraction
]
[from value_changed to NetTransformStbd.scale
]
-->
<PositionInterpolator DEF='NetPositScaleStbd' key='.1 1.0' keyValue='1 1 1 1 8 1'/> |
| 54 |
<!-- ROUTE information for NettingScale node:
[from NetPositClock.fraction_changed to set_fraction
]
[from value_changed to NettingTransform.set_scale
]
-->
<PositionInterpolator DEF='NettingScale' key='.3 1' keyValue='.01 .01 .01 1 2 1'/> |
| 55 |
<!-- ROUTE information for NettingScaleStbd node:
[from NetPositClockStbd.fraction_changed to set_fraction
]
[from value_changed to NettingTransformStbd.set_scale
]
-->
<PositionInterpolator DEF='NettingScaleStbd' key='.3 1' keyValue='.01 .01 .01 1 2 1'/> |
| 56 |
<!-- ROUTE information for NetOrientInterp node:
[from NetPositClock.fraction_changed to set_fraction
]
[from value_changed to NetTransform.set_rotation
]
-->
<OrientationInterpolator DEF='NetOrientInterp' key='0 .5 .9 1' keyValue='1 0 0 0 1 0 0 .78 1 0 0 1 1 0 0 .78'/> |
| 57 |
<!-- ROUTE information for NetOrientInterpStbd node:
[from NetPositClockStbd.fraction_changed to set_fraction
]
[from value_changed to NetTransformStbd.set_rotation
]
-->
<OrientationInterpolator DEF='NetOrientInterpStbd' key='0 .5 .9 1' keyValue='1 0 0 0 1 0 0 -.78 1 0 0 -1 1 0 0 -.78'/> |
| 58 | <Transform DEF='TubeTransform'> |
| 59 | <Transform DEF='PortTubeTransform' rotation='1 0 0 .78'> |
| 60 | <Shape> |
| 61 | <Appearance> |
| 62 | <Material diffuseColor='.9 .9 .9' shininess='1'/> |
| 63 | </Appearance> |
| 64 | <Cylinder height='1.5' radius='.15'/> |
| 65 | </Shape> |
| 66 | <Transform rotation='1 0 0 1.57' translation='0 -.75 0'> |
| 67 | <Shape> |
| 68 | <Box size='.5 .5 .01'/> |
| 69 | <Appearance> |
| 70 | <Material diffuseColor='.9 .9 .9' shininess='1'/> |
| 71 | </Appearance> |
| 72 | </Shape> |
| 73 | </Transform> |
| 74 |
<!-- ROUTE information for NetTransform node:
[from NetPositInterp.value_changed to set_translation
]
[from NetOrientInterp.value_changed to set_rotation
]
[from NetPositScale.value_changed to scale
]
-->
<Transform DEF='NetTransform'> |
| 75 | <IS> |
| 76 | <connect nodeField='scale' protoField='netScale'/> |
| 77 | <connect nodeField='rotation' protoField='netOrientation'/> |
| 78 | </IS> |
| 79 |
<!-- ROUTE information for NettingTransform node:
[from NettingScale.value_changed to set_scale
]
-->
<Transform DEF='NettingTransform' rotation='0 1 0 1.57' scale='.01 .01 .01' translation='0 0 1'> |
| 80 | <IS> |
| 81 | <connect nodeField='scale' protoField='nettingScale'/> |
| 82 | </IS> |
| 83 | </Transform> |
| 84 | </Transform> |
| 85 | </Transform> |
| 86 | <Transform DEF='StbdTubeTransform' translation='-.3 0 0'> |
| 87 | <Transform rotation='1 0 0 -.78'> |
| 88 | <Shape> |
| 89 | <Appearance> |
| 90 | <Material diffuseColor='.9 .9 .9' shininess='1'/> |
| 91 | </Appearance> |
| 92 | <Cylinder height='1.5' radius='.15'/> |
| 93 | </Shape> |
| 94 | <Transform rotation='1 0 0 -1.57' translation='0 -.75 0'> |
| 95 | <Shape> |
| 96 | <Appearance> |
| 97 | <Material diffuseColor='.9 .9 .9' shininess='1'/> |
| 98 | </Appearance> |
| 99 | <Box size='.5 .5 .01'/> |
| 100 | </Shape> |
| 101 | </Transform> |
| 102 |
<!-- ROUTE information for NetTransformStbd node:
[from NetPositInterpStbd.value_changed to set_translation
]
[from NetOrientInterpStbd.value_changed to set_rotation
]
[from NetPositScaleStbd.value_changed to scale
]
-->
<Transform DEF='NetTransformStbd'> |
| 103 | <Shape> |
| 104 | <Appearance> |
| 105 | <Material diffuseColor='1 0 0' shininess='1'/> |
| 106 | </Appearance> |
| 107 | <Cylinder height='1.4' radius='.12'/> |
| 108 | </Shape> |
| 109 |
<!-- ROUTE information for NettingTransformStbd node:
[from NettingScaleStbd.value_changed to set_scale
]
-->
<Transform DEF='NettingTransformStbd' rotation='0 1 0 1.57' scale='.01 .01 .01' translation='0 0 -1'> |
| 110 | <Shape DEF='NETTING'> |
| 111 | <Appearance> |
| 112 | <Material/> |
| 113 |
<ImageTexture DEF='grill'
url=' "grill.png
" "../../Weapons/Guns/grill.png
" "../../../Weapons/Guns/grill.png
" "https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Chapter18-TextureMapping/grill.png
" '/>
|
| 114 | <TextureTransform center='0.5 0.5' scale='32 8'/> |
| 115 | </Appearance> |
| 116 | <IndexedFaceSet DEF='Screen' solid='false' coordIndex='0 1 2 3' texCoordIndex='0 1 2 3'> |
| 117 | <Coordinate point='-1 -.4 0.1 1 -.4 0.1 1 .4 .1 -1 .4 .1'/> |
| 118 | <TextureCoordinate point='0 0 1 0 1 1 0 1'/> |
| 119 | </IndexedFaceSet> |
| 120 | </Shape> |
| 121 | </Transform> |
| 122 | </Transform> |
| 123 | </Transform> |
| 124 | </Transform> |
| 125 | <Transform translation='-.2 -.75 0'> |
| 126 | <Shape> |
| 127 | <Box size='1.5 .2 1.5'/> |
| 128 | <Appearance> |
| 129 | <Material diffuseColor='.4 .4 .4' shininess='1'/> |
| 130 | </Appearance> |
| 131 | </Shape> |
| 132 | </Transform> |
| 133 | </Transform> |
| 134 | < ROUTE fromNode='NetPositClock' fromField='fraction_changed' toNode='NetPositInterp' toField='set_fraction'/> |
| 135 | < ROUTE fromNode='NetPositClock' fromField='fraction_changed' toNode='NetOrientInterp' toField='set_fraction'/> |
| 136 | < ROUTE fromNode='NetPositClock' fromField='fraction_changed' toNode='NetPositScale' toField='set_fraction'/> |
| 137 | < ROUTE fromNode='NetPositClock' fromField='fraction_changed' toNode='NettingScale' toField='set_fraction'/> |
| 138 | < ROUTE fromNode='NetPositClockStbd' fromField='fraction_changed' toNode='NetPositScaleStbd' toField='set_fraction'/> |
| 139 | < ROUTE fromNode='NetPositClockStbd' fromField='fraction_changed' toNode='NetPositInterpStbd' toField='set_fraction'/> |
| 140 | < ROUTE fromNode='NetPositClockStbd' fromField='fraction_changed' toNode='NetOrientInterpStbd' toField='set_fraction'/> |
| 141 | < ROUTE fromNode='NetPositClockStbd' fromField='fraction_changed' toNode='NettingScaleStbd' toField='set_fraction'/> |
| 142 | < ROUTE fromNode='NetPositInterp' fromField='value_changed' toNode='NetTransform' toField='set_translation'/> |
| 143 | < ROUTE fromNode='NetOrientInterp' fromField='value_changed' toNode='NetTransform' toField='set_rotation'/> |
| 144 | < ROUTE fromNode='NetPositScale' fromField='value_changed' toNode='NetTransform' toField='scale'/> |
| 145 | < ROUTE fromNode='NettingScale' fromField='value_changed' toNode='NettingTransform' toField='set_scale'/> |
| 146 | < ROUTE fromNode='NettingScaleStbd' fromField='value_changed' toNode='NettingTransformStbd' toField='set_scale'/> |
| 147 | < ROUTE fromNode='NetPositInterpStbd' fromField='value_changed' toNode='NetTransformStbd' toField='set_translation'/> |
| 148 | < ROUTE fromNode='NetOrientInterpStbd' fromField='value_changed' toNode='NetTransformStbd' toField='set_rotation'/> |
| 149 | < ROUTE fromNode='NetPositScaleStbd' fromField='value_changed' toNode='NetTransformStbd' toField='scale'/> |
| 150 | </Group> |
| 151 | </ProtoBody> |
| 152 | </ProtoDeclare> |
| 153 |
<!-- ROUTE information for myLauncher node:
[from myTouch.touchTime to startLaunchToStbd
]
[from netTranslation to FinalNetTransform.set_translation
]
[from netScale to FinalNetTransform.set_scale
]
[from nettingScale to FinalNettingTransform.set_scale
]
[from netOrientation to FinalNetTransform.set_rotation
]
-->
<ProtoInstance name='NetLauncher' DEF='myLauncher'/> |
| 154 |
<!-- ROUTE information for myTouch node:
[from touchTime to myLauncher.startLaunchToStbd
]
-->
<TouchSensor DEF='myTouch' description='touch to activate'/> |
| 155 | < ROUTE fromNode='myTouch' fromField='touchTime' toNode='myLauncher' toField='startLaunchToStbd'/> |
| 156 | <Transform translation='0 -1 0'> |
| 157 | <Shape DEF='TestWater'> |
| 158 | <Appearance> |
| 159 | <Material diffuseColor='0 0 1'/> |
| 160 | </Appearance> |
| 161 | <Box size='150 .1 150'/> |
| 162 | </Shape> |
| 163 | </Transform> |
| 164 | <Transform rotation='1 0 0 .78'> |
| 165 |
<!-- ROUTE information for FinalNetTransform node:
[from myLauncher.netTranslation to set_translation
]
[from myLauncher.netScale to set_scale
]
[from myLauncher.netOrientation to set_rotation
]
-->
<Transform DEF='FinalNetTransform' scale='.01 .01 .01'> |
| 166 | <Shape> |
| 167 | <Appearance> |
| 168 | <Material diffuseColor='1 0 0' shininess='1'/> |
| 169 | </Appearance> |
| 170 | <Cylinder height='1.4' radius='.12'/> |
| 171 | </Shape> |
| 172 |
<!-- ROUTE information for FinalNettingTransform node:
[from myLauncher.nettingScale to set_scale
]
-->
<Transform DEF='FinalNettingTransform' rotation='0 1 0 1.57' scale='.01 .01 .01' translation='0 0 1'> |
| 173 | <!-- note can't DEF/USE nodes from within ProtoDeclare to parent scene --> |
| 174 | <Shape DEF='FinalNETTING'> |
| 175 | <Appearance> |
| 176 | <Material/> |
| 177 |
<ImageTexture
url=' "grill.png
" "../../../Weapons/Guns/grill.png
" "../../Weapons/Guns/grill.png
" "https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Chapter18-TextureMapping/grill.png
" '/>
|
| 178 | <TextureTransform center='0.5 0.5' scale='32 8'/> |
| 179 | </Appearance> |
| 180 | <IndexedFaceSet DEF='FinalScreen' solid='false' coordIndex='0 1 2 3' texCoordIndex='0 1 2 3'> |
| 181 | <Coordinate point='-1 -.4 0.1 1 -.4 0.1 1 .4 .1 -1 .4 .1'/> |
| 182 | <TextureCoordinate point='0 0 1 0 1 1 0 1'/> |
| 183 | </IndexedFaceSet> |
| 184 | </Shape> |
| 185 | </Transform> |
| 186 | </Transform> |
| 187 | </Transform> |
| 188 | < ROUTE fromNode='myLauncher' fromField='netTranslation' toNode='FinalNetTransform' toField='set_translation'/> |
| 189 | < ROUTE fromNode='myLauncher' fromField='netScale' toNode='FinalNetTransform' toField='set_scale'/> |
| 190 | < ROUTE fromNode='myLauncher' fromField='nettingScale' toNode='FinalNettingTransform' toField='set_scale'/> |
| 191 | < ROUTE fromNode='myLauncher' fromField='netOrientation' toNode='FinalNetTransform' toField='set_rotation'/> |
| 192 | </Scene> |
| 193 | </X3D> |
Event Graph ROUTE Table entries with 21 ROUTE connections total, showing X3D event-model relationships for this scene.
Each row shows an event cascade that may occur during a single timestamp interval between frame renderings, as part of the X3D execution model.
|
myTouch
TouchSensor touchTime SFTime |
myLauncher
ProtoInstance startLaunchToStbd SFTime |
then
|
myLauncher
ProtoInstance netOrientation SFRotation |
FinalNetTransform
Transform set_rotation SFRotation |
||
|
then
|
myLauncher
ProtoInstance netScale SFVec3f |
FinalNetTransform
Transform set_scale SFVec3f |
||||
|
then
|
myLauncher
ProtoInstance nettingScale SFVec3f |
FinalNettingTransform
Transform set_scale SFVec3f |
||||
|
then
|
myLauncher
ProtoInstance netTranslation SFVec3f |
FinalNetTransform
Transform set_translation SFVec3f |
||||
|
NetPositClock
TimeSensor fraction_changed SFFloat |
NetPositInterp
PositionInterpolator set_fraction SFFloat |
then
|
NetPositInterp
PositionInterpolator value_changed SFVec3f |
NetTransform
Transform set_translation SFVec3f |
||
|
NetPositClock
TimeSensor fraction_changed SFFloat |
NetOrientInterp
OrientationInterpolator set_fraction SFFloat |
then
|
NetOrientInterp
OrientationInterpolator value_changed SFRotation |
NetTransform
Transform set_rotation SFRotation |
||
|
NetPositClock
TimeSensor fraction_changed SFFloat |
NetPositScale
PositionInterpolator set_fraction SFFloat |
then
|
NetPositScale
PositionInterpolator value_changed SFVec3f |
NetTransform
Transform scale SFVec3f |
||
|
NetPositClock
TimeSensor fraction_changed SFFloat |
NettingScale
PositionInterpolator set_fraction SFFloat |
then
|
NettingScale
PositionInterpolator value_changed SFVec3f |
NettingTransform
Transform set_scale SFVec3f |
|
NetPositClockStbd
TimeSensor fraction_changed SFFloat |
NetPositScaleStbd
PositionInterpolator set_fraction SFFloat |
then
|
NetPositScaleStbd
PositionInterpolator value_changed SFVec3f |
NetTransformStbd
Transform scale SFVec3f |
||
|
NetPositClockStbd
TimeSensor fraction_changed SFFloat |
NetPositInterpStbd
PositionInterpolator set_fraction SFFloat |
then
|
NetPositInterpStbd
PositionInterpolator value_changed SFVec3f |
NetTransformStbd
Transform set_translation SFVec3f |
||
|
NetPositClockStbd
TimeSensor fraction_changed SFFloat |
NetOrientInterpStbd
OrientationInterpolator set_fraction SFFloat |
then
|
NetOrientInterpStbd
OrientationInterpolator value_changed SFRotation |
NetTransformStbd
Transform set_rotation SFRotation |
||
|
NetPositClockStbd
TimeSensor fraction_changed SFFloat |
NettingScaleStbd
PositionInterpolator set_fraction SFFloat |
then
|
NettingScaleStbd
PositionInterpolator value_changed SFVec3f |
NettingTransformStbd
Transform set_scale SFVec3f |
|
myLauncher
ProtoInstance netTranslation SFVec3f |
FinalNetTransform
Transform set_translation SFVec3f |
|
|
myLauncher
ProtoInstance netScale SFVec3f |
FinalNetTransform
Transform set_scale SFVec3f |
|
|
myLauncher
ProtoInstance nettingScale SFVec3f |
FinalNettingTransform
Transform set_scale SFVec3f |
|
|
myLauncher
ProtoInstance netOrientation SFRotation |
FinalNetTransform
Transform set_rotation SFRotation |
<!--
Color-coding legend: X3D terminology
<X3dNode
DEF='idName' field='value'/>
matches XML terminology
<XmlElement
DEF='idName' attribute='value'/>
(Light-blue background: event-based behavior node or statement)
(Grey background inside box: inserted documentation)
(Magenta background: X3D Extensibility)
<ProtoInstance name='ProtoName'>
<field
name='fieldName'/> </ProtoInstance>
-->
<!--
For additional help information about X3D scenes, please see X3D Tooltips, X3D Resources, and X3D Scene Authoring Hints.
-->