The cinema in the first level of Duke 3D... "Just some pondering."
#1 Posted 08 November 2016 - 05:22 PM
I'm sure this has been discussed in some form in the past, but as a newbie to Build engine code I've always wondered how the level creator pulled off the projector room in the cinema in the first level of the game.
As far as I could tell from the research I've done, the engine couldn't do room over room techniques yet, so it's kind of mystifying to me how they got around it without it conflicting with the small hallway that runs underneath.
The only thing I can think of is that they used some sort of fancy way of teleporting the player around...
Screenshot:
As someone who has been a part of the Doom community for a long time, this has been something that puzzled me whenever I tried to recreate this scene with a Doom source-port.
I'm sorry if this has been posted here before!
#2 Posted 08 November 2016 - 05:26 PM
#3 Posted 08 November 2016 - 06:39 PM
#4 Posted 08 November 2016 - 07:08 PM
top view - the crossed sectors
view of inside small corridor
view of the movie projector room with lowered floor to make it clearer
#5 Posted 08 November 2016 - 08:26 PM
#6 Posted 09 November 2016 - 02:18 AM
Wolfyboy, on 08 November 2016 - 05:22 PM, said:
The only thing I can think of is that they used some sort of fancy way of teleporting the player around...
"Teleporting" is a common misconception I hear all the time about Build. I think it comes from the fact that some places, like the rooftop at the start of E1L1 or some types of elevator, do teleport the player to another area; however these are a complete different thing altogether and people tend to make a generality out of it.
Basically, I think due to the way it renders the world, Build can have as many sectors as you want on the same X/Y placement (Z level doesn't matter), as long as the player isn't able to see two overlapping sectors at the same time (to be precise: you can build two overallapping areas even if the player sees two overlapping sector, but there will be a visual glitch preventing him from seeing one of the two).
This is why the corridor in the theater has entrances on the sides, and not directly beneath the window; and why like Jimmy and Hank explained, they cut down that corridor into several sectors so that the parts of the corridor that you can see while also being able to see the window, are not sectors which overlap directly with the ones the window let you see.
Check maps like E2L11 Spin Cycle or usermap DM_Ducts, and you'll get a better understanding of how it works, and of the possibilities it allow.
You can also check E3L4 L.A. Rumble as a good example of another use of this: the building opened by the blue keycard, you can enter near the blue lock, but you can also go on the rooftop directly 'above' the inside room. That is done by exploiting white walls, and couldn't be done with red ones. Redneck Rampage games have ton of even smarter uses like that.
It's also worth noting that Room over Room doesn't always completely replace this. Quite often in Blood or SW, Room Over Room, which are 'just' view portals, like a mirror but giving you view to another area, is mixed with this feature just described above to further mimick the feel of true 3D. For instance in many cases, the two floors really are there 'on top of each others' (sharing the same X/Y coordinates like in E1L1) and RoR portals are a trick used to let the player see both areas at the same time and teleport him if he goes through the portal.
In other words, in those cases, the only difference with E1L1 theater, is that RoR allows to connect areas both in the way E1L1 does like you naturally could, and also through view portals. I'm pretty sure it's the case in Blood's E1M1 for instance, when you destroy the front wall of the funeral home.
Not every case of RoR in those games are like this (in many cases, the RoR area is only connected through a teleporting view portal, like all the RoR pieces of Redneck Rampage: Rides Again), but those which make use of both means at the same time make for good examples on how to understand both things.
I haven't dived into EDuke32's TRoR though, but I think it works differently.
This post has been edited by MetHy: 09 November 2016 - 02:35 AM
#7 Posted 09 November 2016 - 02:30 AM
#8 Posted 09 November 2016 - 02:58 AM
This post has been edited by ck3D: 09 November 2016 - 02:59 AM
#9 Posted 09 November 2016 - 03:03 AM
This post has been edited by MetHy: 09 November 2016 - 03:03 AM
#10 Posted 09 November 2016 - 03:07 AM
If you know how sectors work in doom then you know that they can't overlap at all, creating overlaps will just make wall lines (splits) appear in the current existing one instead.
This is different in duke, you can actually have even more than two sectors overlapping each other if you wish so. Editing them is not really supported that easily as the editor is still fully 2D
Why this is possible in Duke but not Doom?
How Duke calculates geometry visibility and such is entirely different compared to Doom.
Where Doom relies on more predictable BSP (same as quake but way simpler due to no 3D), Duke does everything on the fly.
Since visibility and such are done on the fly and being portal based, unlike Doom/Quake/etc.. where everything that occupies player geometry should be drawn (by logic), Duke instead only cares about the sectors the player can currently see.
You're essentially creating sectors that link to each other and form their own world continuity. This allows crazier stuff than just rooms over rooms since you can actually have rooms literally overlap each other in same x/y/z but as different "dimensions". So how does this work in that cinema setting ?
Evan's picture shows those helpful yellow lines, consider those your "cone of vision" for the upper/lower area.
Key here is that you can never see two rooms overlap at the SAME time but you can have them overlap very closely and let your brain fill in the rest as you move around.
However, it's not as simple as cutting based on vision, instead the game extends that vision to all the sectors that are visible inside those "yellow line portals".
Prime example here is the circle stairs leading to the upper area, no teleportation ever gets done but you can still circle around. Height here is irrelevant, the steps are just tiny enough and the pillar in the middle is just big enough that you never see the sectors which are on top of you, only just enough to make it seem that you actually do.
These overlaps both rely on tight sector splitting and making sure that the same yellow line "portals" never reach other other at the same time.
Again, it's all just about creating a world continuity based on the sectors that you see. Height is irrelevant* here. Stairs could be completely flat and so could be the projector room in the cinema.
Once you learn how this works in practice, creating complicated SOS can be very simple and fun, only limitation being the 2D based editor that can require creative workarounds as it can get messy really fast. Any overlaps you see in the automap are just this trick in action. It really does add a lot to the maps when done properly.
(*Height abuse can allow some more complex SOS, providing that you can make 100% sure that the player never sees the top/bottom at the same time.)
Old video from a map I'm working on with a pretty SOS-heavy section:
This post has been edited by oasiz: 09 November 2016 - 03:08 AM
#11 Posted 09 November 2016 - 03:25 AM
#12 Posted 09 November 2016 - 03:33 AM
but as a casual player back then I wouldn't look at all the details that made the game interesting in depth. be it Doom, Quake or Duke, if the game was good then it was good... didn't care much about the 'true 3D' aspect as far as nerding out on it besides what I just referenced (and how I'd find it so frustrating that you couldn't jump in Doom). I was more focused on amusing myself with the primary pleasures of breaking lights, blowing up sewer caps to enter the system (and escape through secret toilets), and talking to myself in the mirror like Narcissus
Micky C, on 09 November 2016 - 03:25 AM, said:
not sure if that counts as 'vanilla' Duke even though technically, it certainly is, but mappers such as Billy Boy did pull off some pioneering room-over-room tricks relatively early in DN3D mapping history as well. remember that weird complex trick Zaxtor still uses to this day (I think ?) that allowed you to enter sectors with a window you could look out of AND walk on the roof of as well ? I remember James making a step-by-step tutorial for it on AMC centuries ago, and even then it was tough to pull off and many things could go wrong.
This post has been edited by ck3D: 09 November 2016 - 04:07 AM
#13 Posted 09 November 2016 - 04:09 PM
That's a nice explanation oasiz. Thanks for that! Thanks for your other thoughtful replies as well, guys. As someone who's been playing Duke 3D since I was a kid, I enjoyed reading / learning that.
It's definitely still a bit puzzling to me since I have very little experience using the Build engine. The most experience I have with modding is by using ZDoom and derivatives, but they're not quite capable of rendering levels like in Duke 3D. They do support 3D sectors, so I guess someone like myself could use that to recreate Hollywood Holocaust in Doom.
#14 Posted 11 November 2016 - 01:09 AM
MetHy, on 09 November 2016 - 03:03 AM, said:
In what way is it an advancement over the Jedi engine as used in Dark Forces (which has its fair share of spiral staircases)?
#15 Posted 11 November 2016 - 01:24 AM
X-Vector, on 11 November 2016 - 01:09 AM, said:
You don't get my point, I'm not talking engine possibilities, I'm talking level design mentality.
Dark Forces has some nice stuff here and there, but most of the level design follow a Doom, or even Wolf3D, mentality with only some set pieces of "3D design" here and there.
On the other hand, it's pretty much the entire game in DN3D which levels were designed with a "make it as 3D we can" mentality.
I'm not claiming DN3D is responsible for 3D FPS design, that would be very silly (besides it was still lacking the level of 3D combat Quake brought up). I'm saying it was a thing of its time, but DN3D tends to be forgotten for it.
This post has been edited by MetHy: 11 November 2016 - 01:25 AM
#16 Posted 11 November 2016 - 04:15 PM
HulkNukem, on 08 November 2016 - 06:39 PM, said:
Not at all.
#17 Posted 11 November 2016 - 07:31 PM
Jimmy Gnosis, on 11 November 2016 - 04:15 PM, said:
Which is what I found astounding. Its cool to see how it was actually done