$title="3D Bridge"; $focus="doom"; include("/var/www/doomworld.com/public_html/php/before.php"); include("/var/www/doomworld.com/public_html/php/dirstruct.php"); ?>
|This screenshot was taken in Map13 of Requiem.This bridge can be walked over and under, but the floor consists of 'crossbeams' and not an actual floor texture.|
1 : ceiling/floor 320/0;
a : no textures, both sides reference to sector 1, trigger 91 for sector 3;
You can walk both on and below this true 3D bridge. Tested with warm, dmapedit and BSP succesfully. Note that I have indicated the vertices connecting linedefs in bright yellow, to emphasis the lack of connecting vertices on the crossing 'e' and 'd' linedefs.
So, how does it work? Basically, the fact that you can walk on and under the bridge is due to the raising and lowering of sector 3. Sector 3 has two parts: one actually within the map, acting as bridge, another as a dummy sector in the void, connected to two other dummy sectors. You can now see that crossing linedef 'a' will cause sector 3 to "raise to minimum adjacent ceiling".. only the minimum adjacent ceiling (of sector 5) is actually below the current floor height of sector 3, causing the floor of sector 3 to *instantly drop* to height=0, enabling you to walk under the bridge. Crossing linedef 'b' "raises the floor to minimum adjacent"... in this case, the floor height of sector 6, which is 256.
|To give the floor of the bridge a 'solid' look, middle textures are added to linedefs 'c' and 'e', like "steptop" (Y=16, Y offsett= -16, lower pegged). These now look like 'crossbeams' on which the player appears to be walking. If you want the player to be able to drop from the bridge, both sides of linedefs 'c' should reference back to sector 1. However, if you want to have a railing on the bridge, follow the example given. Sector 4's lowered ceiling takes care of the blocking effect, while still letting the player pass under the bridge. You are still able to see and shoot through linedefs 'c'.|
|This is not the only possible way to make a 3D bridge, and depends on your own preferences. However, most bridges follow the same logic illustrated here. Dmapedit, Warm and BSP are capable of doing a 3D bridge. A note on Dmapedit and BSP tho... I've noticed that sometimes one of the 'b' linedefs blocks the player, altho when pushing it can overcome this block...I don't know what causes this...maybe it's due to something I did, but it only occurs if the blocking linedefs "c" touch a 2-sided wall... in order words, if it touches the sides of sector 2 instead of void. Take a look at the drawing on your left... Notice that the linedefs 'c' are now referencing back to sector 1 entirely. The "blocking" is now done by a single linedefs 'a' that references back to sector 4. For the rest, nothing is changed, but this construction avoids weird bugs mentioned above.|
And another tip... to get rid of the sound of the platform going up and down, make the dummy sector 3 first before making the in-level part of this sector 3. In order words: so that the linedefs/sector number of the dummy sector is lower then the in-level part. Now, place the dummy sector 3 and its two adjacent sectors a good distance away and the bridge will be virtually soundless.