True Room Over Room Mapping Guide - EDukeWiki

# True Room Over Room Mapping Guide

From EDukeWiki
Revision as of 16:52, 8 July 2014 by Micky C (talk | contribs) (→‎Software renderer)
Build/Mapster32 Map Editing

Level Editing · True Room Over Room Mapping Guide · Build/Mapster32 Keyboard Commands
Special Tile Listing · Sector Effector Tag Listing · Sector Tag Listing
Utilities Reference Guide · Mapster32 Scripting · Mapster32 Map Checking

True Room Over Room is a feature new to EDuke32 that allows for the construction of sectors in a vertical arrangement. Other build games (Shadow Warrior, Blood, Redneck Rampage) are able to fake ROR by having sectors in different parts of the map and rendering them on top of each other, and EDuke32 has a similar feature using Sector Effectors. The difference between game ROR and TROR is that the sectors are physically on top of each other, making editing a lot easier and more automatic, while also making it easier to visualize what you're building. For the more technically minded, TROR is part of the engine and map format themselves, instead of an effect bolted on in the game code.

## TROR Editing Modes

There are two modes you should be aware of before starting to build with TROR.

### Side view (orthographic view) mode

This mode allows you see a 3D representation of your map while in 2D mode. This is toggled with [F3]. It can be rotated with the [Q] and [W] buttons, and the angle of viewing can be changed by pressing [A] and [Z]. This mode is absolutely essential not only because it allows you to actually see what you're doing, but because in order to properly use TROR, you need to designate which is the 'active' layer that new sectors will connect to.

This can be done in 2 ways.

The first way is to press [Ctrl-A] which will grey out all other layers except the one the viewpoint (the arrow in 2D/side view mode)is in, which is the active layer. You can move the view point up and down, allowing you to edit above and below layers, by either pressing [page up] and [page down] respectively, or more accurately by pressing down the [middle mouse button] and moving the mouse forward or backwards. This method is usually prefered as it gives you much more control over the vertical position of the viewpoint. If you find the greyed-out walls distracting, you can remove them altogether by pressing [Ctrl-Alt-A]

The second way allows for more precision as you can narrow the active editing range to the height of a single (or set of) sectors. Firstly, select the sector(s) that you want to be able to edit with [Right-Alt], and press [Ctrl-R]. It's as easy as that. Press [Ctrl-R] without having any sectors highlighted to unlock the range again and be able to edit them normally.

### Invisible surfaces viewing mode

This is for 3D mode when you want to toggle seeing invisible objects. All you have to do to toggle this mode is press [I], which primarily allows you to see objects you've made invisible with ['-I]. However, the reason why it's so useful here, is that it also shows you the boundaries between TROR layers (which are invisible in-game). This is a huge benefit when you want to visualize/figure out what's actually going on. It also allows you to edit the TROR surfaces and apply transparent or masked floors, and edit characteristics like the blocking and hitscan bits.

## Properties and Terminology

TROR is created by selecting a sector and extending it (this will be covered later in method). This means that it creates a new sector directly on top of or below the selected sector, which is exactly the same size and shape as the original. The ceiling of the bottom sector is linked with the floor of the top sector. It then makes sense that the extended sector is called an extension.

You can have more than one extension on a sector. You can extend it above and below, then take the bottom and extend that down again and again, and the same with the top. You are effectively stacking sectors on top of each other, so these sectors are part of a stack. The great thing about stacks (even with only one extension) is that if you move the vertex of a wall of one layer, it will automatically move the vertices of all the other layers, so that they're easy to change the shape of without worrying about breaking the connection.

You can highlight a group of sectors and extend them all at the same time so that there can be a single extension covering them all. This is useful because it saves walls, and you can still edit all the child sectors with ease. Now, as soon as you extend these sectors so that they share an extension, they all become a part of the same bunch.

If you take a room with a child sector in the middle, and extend everything upwards except the child layer, there will now be void space in the top layer where the child sector is. If you press [Ctrl-S] there to make it into a child sector in the top layer, you'll then find that you have a floating normal (non-TROR) sector between the two TROR layers that you can do with as you please. This is called an island. I suppose it's still an island even if you don't make it a child sector in the top layer but hey, now you can create floating sectors. These can potentially be glitchy if you're not using the polymer renderer, but we'll get onto that later.

## TROR related keys

The following are a list of keys which are related to editing TROR. They can also be found in the mapster32 keyboard commands page

### 2D mode

[Ctrl-E] sector extension prompt (sectors to extend must be highlighted)
[Ctrl-E] make sandwich [if extending a sector in a direction that has already been extended, see below]
[Ctrl-E] punch loop through extension (loop points must be highlighted, e.g. with [Right Shift]+[Left Ctrl])
[Ctrl-A] toggle auto-grayout of non-extended sectors
[Ctrl-J] TROR-join sectors. The selection must consist of the two sets of sectors you wish to join.
[Ctrl-U] Clear extension: delete the bunch (i.e. ceiling-floor connection) of the aimed-at sector's floor
[PGUP]/[PGDN] Change 'player' height in discrete steps in order to go through the different levels
[Ctrl-tab] Display one currently aimed at sector (of potentially many that lie under the mouse crosshair)
[HOME] and [END] as modifiers to AltGr: select all sectors whose floor's/ceiling's bunchnum equal the bunchnum of the aimed at sector (useful for further operations on whole bunches)

### 3D mode

I invisibility preview: toggle fake ROR texture on non-masked portals
LENTER+CTRL When aiming at an extended floor/ceiling, paste to all floors/ceilings of the bunch of the aimed at one
T, B and H work as with walls, though they set/toggle the bits only on one side

### Advanced Highlighting

Not really specific to TROR, but having greater control over which or how many sectors you can highlight makes doing extensions in TROR much easier. Make sure you're familiar with advanced sector highlighting.

The information on the advanced features is outlined below:

You can highlight a second, third, and multiple sectors by holding down ['] as you drag the selection box over them. This way you can highlight sectors in different parts of the map. Likewise, use the [;] key to deselect sectors. A small plus or minus will appear next to the cursor depending on which button you're holding.

You can select individual sectors with the mouse by moving the cursor inside the sector you want, holding [RIGHT ALT], and holding [RIGHT CTRL] as you release [RIGHT ALT]. The sector is now highlighted. This method of selection also works with ['] and [;] to select/deselect additional sectors by mouse. Simply hold [RIGHT ALT] and the appropriate button depending on what you want to do, then hold [RIGHT CTRL] while releasing the other buttons. This becomes very quick and easy to do after doing it a few times.

## TROR Mapping Examples

### Manhole Sewer Example

In this straightforward example, you're going to make a manhole that goes below a street, and some area around the end of the hole at the bottom.

1. Create the child sector where you want the manhole to be.

2. Highlight the sector with [Right-Alt].

3. Press [Ctrl-E]. Mapster will prompt you whether you want to extend up or down.

4. We want to extend down so press [Z] ([A] if you're extending up).

5. Go into side view mode with [F3], and move the viewpoint down until you're editing the bottom layer.

6. The child sector you created should now have a white boundary, with the street sectors above either greyed out or gone depending on your settings.

7. Now you can treat the manhole sector (the extension) as the very first room you've made on a new map. You can draw sectors on the side of it to attach some rooms there. If you go into 3D mode, you should be able to see that if you go down that manhole, there should now be some area at the bottom which overlaps the street. This was not previously possible without using some kind of cheap trick. Congratulations, you've just made TROR.

### Two Story Building Example

I'm sure that a big reason that people want to use TROR is to build multiple story buildings, and this is how you do it.

1. Design the first floor of your building, both inside and out. This is going to be the first layer, which means the ceiling of every sector, especially the outdoor sectors should not be any higher than the roof of the first floor. Pretend that the second floor doesn't even exist.

2. Make your windows, doors, and anything you want.

Highlight with [Right-Alt] all of the outdoor sectors (the outdoor sectors should all have the same ceiling height, and should not be parallaxed). Knowing your advanced highlighting will come in useful here to select all the sectors.

3. Extend the highlighted area up, and make the top layer the active editing layer.

4. You should notice that the outline of your house has become completely white, and the area inside the house is empty. This is because this area is the second floor of your house.

5. Make a sector inside the house outline, this will be the room on the second floor of your house. Draw small sectors between that room and the house outline to create second floor windows. Alternatively you could just press [Ctrl-S] inside the house sector to make it a regular child sector, and if you go into 3D mode, you'll see your house has a roof you can stand on top of.

6. If you're learning TROR for the first time, it is very helpful at this point to go into 3D mode and press [i] to reveal the boundaries between layers so that you can understand what you've done.

7. You can connect the ground floor to the second floor the same way you'd connect two sector-over-sector sectors; by having a staircase or lift that connects to a different area on the top floor than it does on the bottom (because a lift for example cannot directly cross TROR layers, therefore it must be connected to sectors which do not overlap; i.e have the entrance on one side and the exit on the other.) Or you can connect the ground floor and second floor via TROR and have some sprite stairs or something.

At this stage you should have a perfect two story house where you can look into and enter both stories. Cool stuff eh? ;)

There's nothing stopping you from going on to build a third.. forth.. fifth.. floor in the same manner either.

### TROR water example

This is how you create transparent water using TROR. It works just like regular water, but there are a few things you need to be aware of.

1. Create a main sector, then a child sector in that and extend it downwards.

2. Make both the top and bottom of the TROR surface masked or transparent, and give it the water texture.

3. Give the floor of the top sector a lotag of 1 for water. Give the floor of the bottom sector a lotag of 2 for underwater.

4. Place an SE 7 with the same hitag in the same position in both the top and bottom sector.

5. This is the one that people normally forget. Set the TROR surface in both the top and bottom layer to BLOCKING otherwise it will not work as intended.

See, it's not too bad, just remember the lotags and the blocking. Note if you split up the water sector or add more sectors, make sure those sectors are in both the top and bottom layers, and have new SE 7s, just like normal water. In the future TROR water will be more automatic in that you won't need the SE 7, however this is incomplete as of this writing.

Something that might make life a bit easier is that if you extend the floor of the below-water sector downwards, you can then edit the floor of the new bottom layer and make as complex as you want without having to worry about placing lots of SE 7s.

### Retro-fitting via Joining Example

If you're absolutely clueless with the whole idea of extending, or you want to go back and retrofit some TROR into maps you've done in the past, there's a very easy way of joining them to form TROR. If you have two sectors that have the same shape, area, and external vertices have the same relative positions (essentially they're the same sector, at least as far as their edges are concerned), then all you have to do is highlight both sectors with [Right-Alt], and press [Ctrl-J] to join, the same as joining two sectors normally. It will then prompt you with a few questions such as which sector you want to have on top of the other, which sector(s) you want to move (doesn't matter most of the time), and whether you'd like to move all the connected non-TROR sectors as well (definitely yes).

The good thing about this method is that besides the questions you have to answer, mapster does everything automatically, it even moves the heights for you. Now there'll be a quick example of this method below.

1. Make a child sector in a larger sector and copy-paste it into void space.

2. Give the floor of the original child sector and the ceiling of the new sector the water texture.

3. Highlight both the child sector and new sector with [Right-Alt].

4. Press [Ctrl-J] and answer the simple questions.

5. You should end up with a TROR water sector just as you would via the extension method. You can now alter the transparency of the water to your preference.

### Sandwiching and Sector Punching

It's possible and easy to create a new TROR layer between two TROR layers. All you have to do is highlight one of them, and extend it as you would normally, and it automatically adds a new layer in the middle.

It's also possible to easily create an island sector in the middle of a TROR sector. This is called sector punching, and mainly involves stamping a child sector into the sector below or above. Follow the example below.

1. Extend a sector downwards.

2. Create a child sector in the original sector.

3. Select the vertices of the child sector with [Right-Shift] or [R-Ctrl + R-Shift] and press [Ctrl-E] as though you're extending a sector.

4. It will prompt you whether to punch up or down, in this case, choose down and hit [Enter]. A sector identical in size, shape and position should now be in the bottom layer.

5. Point the mouse cursor at the child sector in the top layer and press [Ctrl-U]. It will prompt you whether you want to break the connection, and unless you press [Ctrl-U] accidentally, you usually do.

6. The child sector should now be a floating sector island. Have fun.

Note that [Ctrl-U] only breaks the connection of a single sector if that sector has been punched. Otherwise it'll break the connection of the entire bunch, which is usually bad.

### List of TROR maps

This (hopefully up to date) list contains maps which make heavy use of the TROR feature in order to make a huge variety of constructions. They each contain a wealth of examples for you to look at to see what's possible and how it works/how to make it. This is not a complete list, as other maps make minor or simple use of the effect and hence are not listed here.

1. The trueror.map in the Samples folder included with eduke32 contains a large amount of random examples of TROR.

2. Retaliation is a small hi-tech map by Loke that was the first proper TROR map and makes some great use of the feature. Download here

3. Parkade is a large city themed map containing large multiple story buildings, along with a large amount of unique, pioneering uses of the feature, made by myself (Micky C) and Paul B. It is the largest, most extensive TROR map and perhaps the best example of what TROR is capable of so far, if I do say so myself. Download here

4. Brooklyn Bridge is another city themed map which also makes extensive and interesting use of TROR, such as an alien ship that flies over water, shooting rockets, and in vents. Download here

## Tricks and Effects with TROR

### SE 13 destructible floor/ceiling

If you have a TROR extension in the floor, you can place an SE 13 on it (facing downwards in 2D mode, and it will become a solid floor in-game (blocked and masked). When the hitag is activated, the TROR surface will become invisible as though a hole has just formed in the floor. You can place the SE 13 on the surface, or above, in which case the floor will initially have the height of the SE 13 just like with the original effect. You can also place it near the ceiling to make the SE 13 control the ceiling instead, or have one near the ceiling and one near the floor to control both.

When placed in a TROR extension with many sectors, it will not just control the sector, but rather the entire extension. So you can add sectors and give them different textures and don't have to worry about adding extra SE 13's. If you want to have TROR surfaces have different heights with different SE 13 sprites, they need to be different extensions; i.e they need to have a sector in both the top and bottom layer, and be extended individually.

The SE 13 also works with TROR slopes, allowing you to create relatively complex destructible objects compared to sprites. But remember that TROR is pretty wall hungry, so keep an eye on complexity. Note that regardless of whether a TROR surface is set to masked or transparent in mapster, it will always become invisible after SE 13 activation.

### TROR water height manipulation

TROR water can also be made to move up and down using the SE 31/32, much like the raising/lowering submergible water in e1l4 Toxic Dump. The effect is the same, however it's easier with TROR, because you only have to set up the effect on one side, either in the top layer or bottom layer, because this effect is set up so that if the ceiling of the bottom sector is moved, it moves the floor of the top sector as well, and vice versa.

## Visual Glitches and Workarounds

### Software renderer

Even though TROR sectors are already physically overlapping, the 8-bit software renderer still needs to render them separately, having to do an extra rendering pass for each additional TROR extension in view. Theoretically if you create a huge amount of extensions in the same area the framerate could potentially drop to unplayable levels, however this is far fetched and I wouldn't worry about it.

The real problem with the software renderer is HOM glitching. In each rendering pass, there can only be one area along the x-interval drawn. For example, if you have an island on the ground, the area between you and the island will be fine, but everything on the other side of the island will show HOM. Try it out yourself to see what I mean. Technically this means that TROR extensions cannot contain islands (although it's been kind of hacked in to do exta-extra passes to overcome this problem, I wouldn't rely on them for perfect drawing.)

However, this can be overcome by breaking up the sector surrounding the child sector, and extending each sector individually. This means there will be multiple drawing portals around the island instead of one big one, and none of the individual extensions would contain the island, hence it should draw fine.

This HOM doesn't just occur due to islands, it can also happen when part of a normal sector is jutting out into a TROR sector, this can be thought of here as a mini-island even though it's connected to something. Don't call it a mini-island, I only called it that to explain why it would cause that glitching. This means that TROR extensions should be convex, i.e if you draw a straight line through a TROR portal so that it leaves the sector, and then comes back, it is not convex (and is most likely due to something jutting out.) However if you draw a line through it and this does not happen, as is the case for a circle, square etc.. then it is convex, and should draw fine.

Also note that currently the software renderer doesn't allow the player to see through more than 8 layers of TROR (it draws the texture on the surface instead). This normally isn't a problem in small sectors of TROR because the player typically won't be able to look up high enough to see the 8 layers due to vertical distortion. The limit could potentially be increased if someone desperately needed it (talk to the devs for that.)

Having void sectors (white-walled sectors with null space inside them) inside a TROR sector, or inside a sector adjacent to/bounding a TROR sector, it will cause visual glitches when viewed from some angles. Consider turning potential void sectors into child sectors, and raise the floor to the ceiling to fix this, as the result would look identical to having a void sector, but without the glitching.

### Polymer renderer

Masked floors and ceilings in polymer are always the last thing drawn on the screen. That means if you have a transparent surface such as a masked wall or sprite, it would cause everything all the TROR masked surfaces behind the transparent surface to stop being drawn and become invisible. There's no real work around for this, just try not to use masked walls or sprites with big transparent surfaces around TROR masked surfaces.

Other than that, polymer is by far the most stable renderer for TROR, and apart from what's written above, is 100% glitch free. Despite being slow sometimes, it is the renderer of choice for TROR. It works by drawing the entire scene, TROR and all in a single rendering pass. This means that it doesn't require any additional computer power to draw TROR, hence TROR will not affect the framerate in polymer.

### Polymost renderer

The polymost renderer is bad, M'kay? It's like a comic relief in bad Hollywood films who can't do anything right. Don't use it. It has also been observed that some TROR constructions work perfectly on some computers, however are incredibly glitchy on others, so if you do decide to use this renderer, and TROR works for you, make sure you have two or three other people check it on their setups before you release your map. There are no plans to add complete polymost TROR compatibility as polymost will be obsolete once polymer is finished and optimised.

## Random Trivia

Extended sectors can be sloped, but the bunch has to be 1:1 in that case. I.e you can't have any child sectors within a sloped TROR sector. If you want different TROR sectors with different slopes, you must use completely different extensions for that, as opposed to breaking up a single extension.

Maps containing one or more TROR bunches are saved in a new map format (v9) since some fields had to be taken over: xrepeat is unavailable on TROR'ed floors and ceilings, and on walls it's lotag if the ceiling, and extra if the floor of the wall's sector is extended. When in-game, these get transferred to internal arrays though.

The system is supposed to be used for 'large-scale' RoR, as a rule of thumb each affected sector should be at least a Duke high [that's too strict though].

Retrieved from "http://wiki.eduke32.com/w/index.php?title=True_Room_Over_Room_Mapping_Guide&oldid=11957"
Category:

- Level editing documentation