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=' ExplosionPrototype.x3d '/> |
6 | <meta name='description' content='Prototype of an explosion (Ball of fire)'/> |
7 | <meta name='creator' content='Alan Hudson, Yumetech, Inc'/> |
8 | <meta name='created' content='27 July 2006'/> |
9 | <meta name='modified' content='28 November 2019'/> |
10 |
<meta name='Image' content='ExplosionPrototypeExample.png'![]() |
11 | <meta name='MovingImage' content='ExplosionExampleVideo.mov'/> |
12 | <meta name='reference' content=' ExplosionExample.x3d '/> |
13 | <meta name='identifier' content=' https://www.web3d.org/x3d/content/examples/Savage/Tools/Explosions/ExplosionPrototype.x3d '/> |
14 | <meta name='generator' content='X3D-Edit 3.2, https://www.web3d.org/x3d/tools/X3D-Edit'/> |
15 | <meta name='license' content='../../license.html'/> |
16 | </head> |
17 | <Scene> |
18 | <WorldInfo title='ExplosionPrototype.x3d'/> |
19 | <ProtoDeclare name='Explosion' appinfo='Simple explosion animation of a sphere covered with a flame texture, plus a sound effect'> |
20 | <ProtoInterface> |
21 |
<field name='detonateTime' type='SFTime' accessType='inputOnly'
appinfo='time event to trigger explosion'/> |
22 |
<field name='size' type='SFVec3f' value='1.0 1.0 1.0' accessType='inputOutput'
appinfo='size of explosion sphere'/> |
23 | </ProtoInterface> |
24 | <ProtoBody> |
25 | <Group> |
26 |
<!-- ROUTE information for TRANS node:
[from SCALE_INTERP.value_changed to set_scale
]
-->
<Transform DEF='TRANS' scale='0.0010 0.0010 0.0010'> |
27 | <Transform> |
28 | <IS> |
29 | <connect nodeField='scale' protoField='size'/> |
30 | </IS> |
31 | <Shape> |
32 | <Appearance> |
33 |
<!-- ROUTE information for MAT node:
[from TRANSPARENCY_INTERP.value_changed to set_transparency
]
-->
<Material DEF='MAT' diffuseColor='1.0 0.0 0.0'/> |
34 |
<ImageTexture
url=' "../../../Savage/Tools/Explosions/flametexture.jpg![]() ![]() |
35 |
<!-- ROUTE information for TT node:
[from ROTATION_INTERP.value_changed to set_rotation
]
-->
<TextureTransform DEF='TT'/> |
36 | </Appearance> |
37 | <IndexedFaceSet creaseAngle='0.5' coordIndex='0 1 2 -1 2 1 3 -1 2 3 4 -1 4 3 5 -1 4 5 6 -1 6 5 7 -1 6 7 8 -1 8 7 9 -1 8 9 10 -1 1 11 3 -1 3 11 12 -1 3 12 5 -1 5 12 13 -1 5 13 7 -1 7 13 14 -1 7 14 9 -1 11 15 12 -1 12 15 16 -1 12 16 13 -1 13 16 17 -1 13 17 14 -1 15 18 16 -1 16 18 19 -1 16 19 17 -1 19 18 20 -1 10 9 21 -1 21 9 22 -1 21 22 23 -1 23 22 24 -1 23 24 25 -1 25 24 26 -1 25 26 27 -1 27 26 28 -1 27 28 29 -1 9 14 22 -1 22 14 30 -1 22 30 24 -1 24 30 31 -1 24 31 26 -1 26 31 32 -1 26 32 28 -1 14 17 30 -1 30 17 33 -1 30 33 31 -1 31 33 34 -1 31 34 32 -1 17 19 33 -1 33 19 35 -1 33 35 34 -1 35 19 20 -1 10 36 8 -1 8 36 37 -1 8 37 6 -1 6 37 38 -1 6 38 4 -1 4 38 39 -1 4 39 2 -1 2 39 40 -1 2 40 0 -1 36 41 37 -1 37 41 42 -1 37 42 38 -1 38 42 43 -1 38 43 39 -1 39 43 44 -1 39 44 40 -1 41 45 42 -1 42 45 46 -1 42 46 43 -1 43 46 47 -1 43 47 44 -1 45 48 46 -1 46 48 49 -1 46 49 47 -1 49 48 50 -1 29 51 27 -1 27 51 52 -1 27 52 25 -1 25 52 53 -1 25 53 23 -1 23 53 54 -1 23 54 21 -1 21 54 36 -1 21 36 10 -1 51 55 52 -1 52 55 56 -1 52 56 53 -1 53 56 57 -1 53 57 54 -1 54 57 41 -1 54 41 36 -1 55 58 56 -1 56 58 59 -1 56 59 57 -1 57 59 45 -1 57 45 41 -1 58 60 59 -1 59 60 48 -1 59 48 45 -1 48 60 50 -1 61 62 63 -1 63 62 64 -1 63 64 65 -1 65 64 66 -1 65 66 67 -1 67 66 68 -1 67 68 69 -1 69 68 1 -1 69 1 0 -1 62 70 64 -1 64 70 71 -1 64 71 66 -1 66 71 72 -1 66 72 68 -1 68 72 11 -1 68 11 1 -1 70 73 71 -1 71 73 74 -1 71 74 72 -1 72 74 15 -1 72 15 11 -1 73 75 74 -1 74 75 18 -1 74 18 15 -1 18 75 20 -1 29 28 76 -1 76 28 77 -1 76 77 78 -1 78 77 79 -1 78 79 80 -1 80 79 81 -1 80 81 82 -1 82 81 62 -1 82 62 61 -1 28 32 77 -1 77 32 83 -1 77 83 79 -1 79 83 84 -1 79 84 81 -1 81 84 70 -1 81 70 62 -1 32 34 83 -1 83 34 85 -1 83 85 84 -1 84 85 73 -1 84 73 70 -1 34 35 85 -1 85 35 75 -1 85 75 73 -1 75 35 20 -1 0 40 69 -1 69 40 86 -1 69 86 67 -1 67 86 87 -1 67 87 65 -1 65 87 88 -1 65 88 63 -1 63 88 89 -1 63 89 61 -1 40 44 86 -1 86 44 90 -1 86 90 87 -1 87 90 91 -1 87 91 88 -1 88 91 92 -1 88 92 89 -1 44 47 90 -1 90 47 93 -1 90 93 91 -1 91 93 94 -1 91 94 92 -1 47 49 93 -1 93 49 95 -1 93 95 94 -1 95 49 50 -1 61 89 82 -1 82 89 96 -1 82 96 80 -1 80 96 97 -1 80 97 78 -1 78 97 98 -1 78 98 76 -1 76 98 51 -1 76 51 29 -1 89 92 96 -1 96 92 99 -1 96 99 97 -1 97 99 100 -1 97 100 98 -1 98 100 55 -1 98 55 51 -1 92 94 99 -1 99 94 101 -1 99 101 100 -1 100 101 58 -1 100 58 55 -1 94 95 101 -1 101 95 60 -1 101 60 58 -1 60 95 50 -1' texCoordIndex='0 1 2 -1 2 1 3 -1 2 3 4 -1 4 3 5 -1 4 5 6 -1 6 5 7 -1 6 7 8 -1 8 7 9 -1 8 9 10 -1 1 11 3 -1 3 11 12 -1 3 12 5 -1 5 12 13 -1 5 13 7 -1 7 13 14 -1 7 14 9 -1 11 15 12 -1 12 15 16 -1 12 16 13 -1 13 16 17 -1 13 17 14 -1 15 18 16 -1 16 18 19 -1 16 19 17 -1 19 18 20 -1 10 9 21 -1 21 9 22 -1 21 22 23 -1 23 22 24 -1 23 24 25 -1 25 24 26 -1 25 26 27 -1 27 26 28 -1 27 28 29 -1 9 14 22 -1 22 14 30 -1 22 30 24 -1 24 30 31 -1 24 31 26 -1 26 31 32 -1 26 32 28 -1 14 17 30 -1 30 17 33 -1 30 33 31 -1 31 33 34 -1 31 34 32 -1 17 19 33 -1 33 19 35 -1 33 35 34 -1 35 19 20 -1 10 36 8 -1 8 36 37 -1 8 37 6 -1 6 37 38 -1 6 38 4 -1 4 38 39 -1 4 39 2 -1 2 39 40 -1 2 40 0 -1 36 41 37 -1 37 41 42 -1 37 42 38 -1 38 42 43 -1 38 43 39 -1 39 43 44 -1 39 44 40 -1 41 45 42 -1 42 45 46 -1 42 46 43 -1 43 46 47 -1 43 47 44 -1 45 48 46 -1 46 48 49 -1 46 49 47 -1 49 48 50 -1 29 51 27 -1 27 51 52 -1 27 52 25 -1 25 52 53 -1 25 53 23 -1 23 53 54 -1 23 54 21 -1 21 54 36 -1 21 36 10 -1 51 55 52 -1 52 55 56 -1 52 56 53 -1 53 56 57 -1 53 57 54 -1 54 57 41 -1 54 41 36 -1 55 58 56 -1 56 58 59 -1 56 59 57 -1 57 59 45 -1 57 45 41 -1 58 60 59 -1 59 60 48 -1 59 48 45 -1 48 60 50 -1 61 62 63 -1 63 62 64 -1 63 64 65 -1 65 64 66 -1 65 66 67 -1 67 66 68 -1 67 68 69 -1 69 68 1 -1 69 1 0 -1 62 70 64 -1 64 70 71 -1 64 71 66 -1 66 71 72 -1 66 72 68 -1 68 72 11 -1 68 11 1 -1 70 73 71 -1 71 73 74 -1 71 74 72 -1 72 74 15 -1 72 15 11 -1 73 75 74 -1 74 75 18 -1 74 18 15 -1 18 75 20 -1 29 28 76 -1 76 28 77 -1 76 77 78 -1 78 77 79 -1 78 79 80 -1 80 79 81 -1 80 81 82 -1 82 81 62 -1 82 62 61 -1 28 32 77 -1 77 32 83 -1 77 83 79 -1 79 83 84 -1 79 84 81 -1 81 84 70 -1 81 70 62 -1 32 34 83 -1 83 34 85 -1 83 85 84 -1 84 85 73 -1 84 73 70 -1 34 35 85 -1 85 35 75 -1 85 75 73 -1 75 35 20 -1 0 40 69 -1 69 40 86 -1 69 86 67 -1 67 86 87 -1 67 87 65 -1 65 87 88 -1 65 88 63 -1 63 88 89 -1 63 89 61 -1 40 44 86 -1 86 44 90 -1 86 90 87 -1 87 90 91 -1 87 91 88 -1 88 91 92 -1 88 92 89 -1 44 47 90 -1 90 47 93 -1 90 93 91 -1 91 93 94 -1 91 94 92 -1 47 49 93 -1 93 49 95 -1 93 95 94 -1 95 49 50 -1 61 89 82 -1 82 89 96 -1 82 96 80 -1 80 96 97 -1 80 97 78 -1 78 97 98 -1 78 98 76 -1 76 98 51 -1 76 51 29 -1 89 92 96 -1 96 92 99 -1 96 99 97 -1 97 99 100 -1 97 100 98 -1 98 100 55 -1 98 55 51 -1 92 94 99 -1 99 94 101 -1 99 101 100 -1 100 101 58 -1 100 58 55 -1 94 95 101 -1 101 95 60 -1 101 60 58 -1 60 95 50 -1'> |
38 | <Coordinate point='1.0 0.0 0.0 0.970142 0.242536 0.0 0.970142 0.0 0.242536 0.904534 0.301511 0.301511 0.83205 0.0 0.5547 0.666667 0.333333 0.666667 0.5547 0.0 0.83205 0.301511 0.301511 0.904534 0.242536 0.0 0.970142 0.0 0.242536 0.970142 0.0 0.0 1.0 0.83205 0.5547 0.0 0.666667 0.666667 0.333333 0.333333 0.666667 0.666667 0.0 0.5547 0.83205 0.5547 0.83205 0.0 0.301511 0.904534 0.301511 0.0 0.83205 0.5547 0.242536 0.970142 0.0 0.0 0.970142 0.242536 0.0 1.0 0.0 -0.242536 0.0 0.970142 -0.301511 0.301511 0.904534 -0.5547 0.0 0.83205 -0.666667 0.333333 0.666667 -0.83205 0.0 0.5547 -0.904534 0.301511 0.301511 -0.970142 0.0 0.242536 -0.970142 0.242536 0.0 -1.0 0.0 0.0 -0.333333 0.666667 0.666667 -0.666667 0.666667 0.333333 -0.83205 0.5547 0.0 -0.301511 0.904534 0.301511 -0.5547 0.83205 0.0 -0.242536 0.970142 0.0 0.0 -0.242536 0.970142 0.301511 -0.301511 0.904534 0.666667 -0.333333 0.666667 0.904534 -0.301511 0.301511 0.970142 -0.242536 0.0 0.0 -0.5547 0.83205 0.333333 -0.666667 0.666667 0.666667 -0.666667 0.333333 0.83205 -0.5547 0.0 0.0 -0.83205 0.5547 0.301511 -0.904534 0.301511 0.5547 -0.83205 0.0 0.0 -0.970142 0.242536 0.242536 -0.970142 0.0 0.0 -1.0 0.0 -0.970142 -0.242536 0.0 -0.904534 -0.301511 0.301511 -0.666667 -0.333333 0.666667 -0.301511 -0.301511 0.904534 -0.83205 -0.5547 0.0 -0.666667 -0.666667 0.333333 -0.333333 -0.666667 0.666667 -0.5547 -0.83205 0.0 -0.301511 -0.904534 0.301511 -0.242536 -0.970142 0.0 0.0 0.0 -1.0 0.0 0.242536 -0.970142 0.242536 0.0 -0.970142 0.301511 0.301511 -0.904534 0.5547 0.0 -0.83205 0.666667 0.333333 -0.666667 0.83205 0.0 -0.5547 0.904534 0.301511 -0.301511 0.970142 0.0 -0.242536 0.0 0.5547 -0.83205 0.333333 0.666667 -0.666667 0.666667 0.666667 -0.333333 0.0 0.83205 -0.5547 0.301511 0.904534 -0.301511 0.0 0.970142 -0.242536 -0.970142 0.0 -0.242536 -0.904534 0.301511 -0.301511 -0.83205 0.0 -0.5547 -0.666667 0.333333 -0.666667 -0.5547 0.0 -0.83205 -0.301511 0.301511 -0.904534 -0.242536 0.0 -0.970142 -0.666667 0.666667 -0.333333 -0.333333 0.666667 -0.666667 -0.301511 0.904534 -0.301511 0.904534 -0.301511 -0.301511 0.666667 -0.333333 -0.666667 0.301511 -0.301511 -0.904534 0.0 -0.242536 -0.970142 0.666667 -0.666667 -0.333333 0.333333 -0.666667 -0.666667 0.0 -0.5547 -0.83205 0.301511 -0.904534 -0.301511 0.0 -0.83205 -0.5547 0.0 -0.970142 -0.242536 -0.301511 -0.301511 -0.904534 -0.666667 -0.333333 -0.666667 -0.904534 -0.301511 -0.301511 -0.333333 -0.666667 -0.666667 -0.666667 -0.666667 -0.333333 -0.301511 -0.904534 -0.301511'/> |
39 | <TextureCoordinate point='0.75 1.0 0.25 0.922021 0.5 0.922021 0.375 0.859781 0.5 0.812833 0.426208 0.73228 0.5 0.687167 0.448792 0.597491 0.5 0.577979 0.46101 0.5 0.5 0.5 0.25 0.812833 0.323792 0.73228 0.375 0.608173 0.406417 0.5 0.25 0.687167 0.301208 0.597491 0.343584 0.5 0.25 0.577979 0.28899 0.5 0.25 0.5 0.5 0.422021 0.448792 0.402509 0.5 0.312833 0.426208 0.26772 0.5 0.187167 0.375 0.140219 0.5 0.0779793 0.25 0.0779793 0.25 0.0 0.375 0.391827 0.323792 0.26772 0.25 0.187167 0.301208 0.402509 0.25 0.312833 0.25 0.422021 0.53899 0.5 0.551208 0.597491 0.573792 0.73228 0.625 0.859781 0.75 0.922021 0.593584 0.5 0.625 0.608173 0.676208 0.73228 0.75 0.812833 0.656416 0.5 0.698792 0.597491 0.75 0.687167 0.71101 0.5 0.75 0.577979 0.75 0.5 0.75 0.0779793 0.625 0.140219 0.573792 0.26772 0.551208 0.402509 0.75 0.187167 0.676208 0.26772 0.625 0.391827 0.75 0.312833 0.698792 0.402509 0.75 0.422021 1.0 0.5 0.0389897 0.5 1.0 0.577979 0.0512081 0.597491 1.0 0.687167 0.0737917 0.73228 1.0 0.812833 0.125 0.859781 1.0 0.922021 0.0935835 0.5 0.125 0.608173 0.176208 0.73228 0.156416 0.5 0.198792 0.597491 0.21101 0.5 0.0 0.0779793 0.125 0.140219 0.0 0.187167 0.0737917 0.26772 0.0 0.312833 0.0512082 0.402509 0.0 0.422021 0.176208 0.26772 0.125 0.391827 0.198792 0.402509 0.875 0.859781 0.926208 0.73228 0.948792 0.597491 0.96101 0.5 0.823792 0.73228 0.875 0.608173 0.906416 0.5 0.801208 0.597491 0.843584 0.5 0.78899 0.5 0.948792 0.402509 0.926208 0.26772 0.875 0.140219 0.875 0.391827 0.823792 0.26772 0.801208 0.402509'/> |
40 | </IndexedFaceSet> |
41 | </Shape> |
42 | </Transform> |
43 |
<!-- ROUTE information for TIMER node:
[from fraction_changed to SCALE_INTERP.set_fraction
]
[from fraction_changed to TRANSPARENCY_INTERP.set_fraction
]
[from fraction_changed to ROTATION_INTERP.set_fraction
]
-->
<TimeSensor DEF='TIMER' cycleInterval='3.0'> |
44 | <IS> |
45 | <connect nodeField='startTime' protoField='detonateTime'/> |
46 | </IS> |
47 | </TimeSensor> |
48 |
<!-- ROUTE information for SCALE_INTERP node:
[from TIMER.fraction_changed to set_fraction
]
[from value_changed to TRANS.set_scale
]
-->
<PositionInterpolator DEF='SCALE_INTERP' key='0.0 1.0' keyValue='0.0010 0.0010 0.0010 1.0 1.0 1.0'/> |
49 |
<!-- ROUTE information for TRANSPARENCY_INTERP node:
[from TIMER.fraction_changed to set_fraction
]
[from value_changed to MAT.set_transparency
]
-->
<ScalarInterpolator DEF='TRANSPARENCY_INTERP' key='0.0 1.0' keyValue='0.0 1.0'/> |
50 |
<!-- ROUTE information for ROTATION_INTERP node:
[from TIMER.fraction_changed to set_fraction
]
[from value_changed to TT.set_rotation
]
-->
<ScalarInterpolator DEF='ROTATION_INTERP' key='0.0 1.0' keyValue='0.0 1.57075'/> |
51 | < ROUTE fromNode='TIMER' fromField='fraction_changed' toNode='SCALE_INTERP' toField='set_fraction'/> |
52 | < ROUTE fromNode='TIMER' fromField='fraction_changed' toNode='TRANSPARENCY_INTERP' toField='set_fraction'/> |
53 | < ROUTE fromNode='TIMER' fromField='fraction_changed' toNode='ROTATION_INTERP' toField='set_fraction'/> |
54 | < ROUTE fromNode='SCALE_INTERP' fromField='value_changed' toNode='TRANS' toField='set_scale'/> |
55 | < ROUTE fromNode='TRANSPARENCY_INTERP' fromField='value_changed' toNode='MAT' toField='set_transparency'/> |
56 | < ROUTE fromNode='ROTATION_INTERP' fromField='value_changed' toNode='TT' toField='set_rotation'/> |
57 | </Transform> |
58 | <Sound maxBack='100' maxFront='100' minBack='10' minFront='10'> |
59 | <AudioClip description='Normal Explosion' url=' "NormalExplosion.wav" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Explosions/NormalExplosion.wav" '> |
60 | <IS> |
61 | <connect nodeField='startTime' protoField='detonateTime'/> |
62 | </IS> |
63 | </AudioClip> |
64 | </Sound> |
65 | </Group> |
66 | </ProtoBody> |
67 | </ProtoDeclare> |
68 | <!-- ==================== --> |
69 | <Background groundAngle='1.57' groundColor='0.6 0.9 0.6 0.6 0.9 0.6' skyColor='0.6 0.6 0.9'/> |
70 | <Anchor description='Explosion Example' parameter='"target=_blank"' url=' "ExplosionExample.wrl" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Explosions/ExplosionExample.wrl" "MultipleTimerExplodingBuildingExample.x3d" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Explosions/ExplosionExample.x3d" '> |
71 | <Shape> |
72 | <Text string='"ExplosionPrototype" "is a prototype definition file" "" "Click this text to see" "ExplosionExample"'> |
73 | <FontStyle justify='"MIDDLE" "MIDDLE"'/> |
74 | </Text> |
75 | <Appearance> |
76 | <Material diffuseColor='0.2 0.2 0.8'/> |
77 | </Appearance> |
78 | </Shape> |
79 | </Anchor> |
80 | </Scene> |
81 | </X3D> |
Event Graph ROUTE Table entries with 6 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.
TIMER
TimeSensor fraction_changed SFFloat |
SCALE_INTERP
PositionInterpolator set_fraction SFFloat |
then
|
SCALE_INTERP
PositionInterpolator value_changed SFVec3f |
TRANS
Transform set_scale SFVec3f |
||
TIMER
TimeSensor fraction_changed SFFloat |
TRANSPARENCY_INTERP
ScalarInterpolator set_fraction SFFloat |
then
|
TRANSPARENCY_INTERP
ScalarInterpolator value_changed SFFloat |
MAT
Material set_transparency SFFloat |
||
TIMER
TimeSensor fraction_changed SFFloat |
ROTATION_INTERP
ScalarInterpolator set_fraction SFFloat |
then
|
ROTATION_INTERP
ScalarInterpolator value_changed SFFloat |
TT
TextureTransform set_rotation SFFloat |
line 70
Anchor |
description='Explosion Example' User-interaction hint for this node. |
<!--
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)
<ProtoDeclare name='ProtoName'>
<field
name='fieldName'/> </ProtoDeclare>
-->
<!--
For additional help information about X3D scenes, please see X3D Tooltips, X3D Resources, and X3D Scene Authoring Hints.
-->