Switch Node
Sculpted Surface? ] Sculpted Tubular ] Sculpted Complex ] Lamp ] Lighting ] Spotlight ] Midi Media ] IFS Edit ] IFS_SOI ] Texture Coords ] Animations ] Animation Chat ] Two Animations ] Door ] Gestures ] Complex Avatar ] Heads ] Proximity Sensor ] Proximity VP unbind ] [ Switch Node ] Guided Tour ] Beam Slowly ] Stairs? ] Walk ] Duck Shoot ] Navigation Box ] URNs in URLs ] Play a mp3? ]


How would I make something appear/disappear in my VRML creation? The switch node is related to the Level Of Detail (LOD) node, in fact in Flux Studio one icon is used for both concepts. The same concept works for the LOD node as well, except that is based on distance and the switch is based on a sensor or an animation starting or stopping.

Before you get too involved, try this simple case first. In the example, I have made a box and a cylinder. You can not see the box though, because it is "turned off".

switch_node.jpg (53866 bytes)

If I click the LOD/Switch icon and then click on the scene, I see a LOD appear in the Scene Tree window. In this case I also put two touch sensors into the scene (one for the cylinder, one for the box). If you look below, you will see that I have dragged one sensor and one object under each LOD item.

switch_tree.jpg (26557 bytes)

If you look at the Touch Sensor properties window below, you will see how to configure the trigger. When the sensor is clicked, the trigger will "set level #1".

For the second touch sensor, I have just the opposite settings. If the sensor is clicked, Set Level #0.

ts_switch_prop.jpg (32837 bytes)

OK, so if you click the cylinder, the box appears. Then if you click the box, the cylinder appears. I know, it seems simple now, but trying to figure it out on your own would have taken a bit longer. It can be a very useful concept. The switch node can also be triggered by other events such as animations.

Would you like to see this concept in action? Additionally, I have provided a Flux Studio version 2.3 file that you can download and analyze on your own. I actually needed this concept to turn off/on the shooting in my War of the Worlds avatar.

Back ] Home ] Up ] Next ]