# Subways

Start out making one large oval sector, with a "station" at the top and two island sectors which will become the cars. Set the floor tile of the large oval sector to tile #859 (railhurt) to have Duke get zapped if he stands on the rails. Change to 3d mode and raise the floor of the island sectors so you can see them. Point at their floors and hit 'R' to make them relatively-aligned (sprites will move with the subway.) |

Change both of the island sector hitags to 1. Insert a SE within each of the two island sectors. Change the SE lotag of the lead car to 6, and the trailing car SE lotag to 14. Change the angle of the two SEs to the angle in which the car will begin travel, ie the line will point right if the car is to start moving to the right. To make multiple groups of cars, change the sector hitags of the second group to 2, and so on. You can have more than one car as well, or even just one lead. |

Insert 9 locator sprites (LS) positioned like the picture below. This is the path your cars will travel through your level. You must uniquely identify each of the LS lotags. Starting from the top-middle locator, start counting from 0 and change each of the locators lotags, following the path you wish the cars to travel. The cars will travel in succession across the locators. To make the subway cars stop at a given locator, change its hitag to 1. If you plan out a lengthy track, make sure you place extra locators and assign them in the proper order. That way, if you want to add another stop along your track, you won't have to go changing every locator lotag after it or their relative position. The SE hitag of the individual cars points to the first locator it will come across. In this example, the hitag is set to 0, which is the first locator we want it to cross.

That's all you need for a functioning subway. But it's pretty lame, and not much fun. We're going to add some interior walls, a window, and bench seats to our subway cars. There are a few key points to note when dealing with sectors-in-sectors and subway cars: | The outer, parent sector is the only sector which can contain the SE-6 or SE-14 sprite.
| Each inner sector must have the same hitag/lotag combo as the parent.
| Each inner sector may only share one line with the outer sector.
| Duke can only walk on the parent sector, or he'll get shuffled right off the car and possibly get squished.
| Each interior sector must be made of red lines; no white lines are possible.
| Interior sectors may only be one level deep; ie no sectors within those interior sectors.
With those limitations in mind, let's create a front and back wall to our car. Both walls will be completely inside the outer sector. The front wall will be comprised of three joined pieces: the left and right sections, and a middle section that will become a window. When you create sectors within sectors, they automatically pick up the same tag as their parent. Make sure you've set the parent sector hitag according to the instructions given earlier.
|

Take grid-locking off and move the points of our walls to the very edges of the car, but don't overlap any red lines or vertices. While it may look like they overlap in this image, they really do not. |

Switch to 3d mode and lower the ceilings of the back wall, and the two side pieces of the front wall, all the way to the floor, blocking Duke from walking through. Raise the floor of the middle/front wall a little ways to make a window sill, and lower the ceiling. |

Add two sectors within the car. These will become the bench seat. Take grid-locking off, and move them real close to the back wall, but not overlapping. You should get the feeling that we're trying to work around the limits of the engine... we are. While in 2d mode, make all of the walls of the bench blocking (hit [B] on them.) We need to do this to ensure Duke won't walk on them... they're nice to look at, but Duke will get shuffled right off the car if he attempts to walk on them. |

###
Download this page locally

Duke Nukem 3D is copyright ©1996 , All Rights reserved.

### THIS PAGE IS NOT MADE BY OR SUPPORTED BY 3D REALMS

| Copyright ©1996 Tyler Matthews, All Rights reserved. Go back to my Duke FAQ BUILD page Go back to my Duke FAQ BUILD page Text-Only