Sectors are large chunks of static geometry that are not configurable, unlike basic static props, which in turn can be baked and assigned to a specific sector. Sectors cannot be changed or moved but they have collision. Used to improve performance.
The idea is that the level is divided into large chunks – sectors (subway station and surface as an example). Sectors are working this way: when you are inside "Sector 1" (for example), everything in this sector is loaded. Whenever you see portals – adjacent sector and everything inside is uploaded as well. If your camera can't see any other portal of adjacent sectors, this means that every other sector is not loaded. Whenever you are outside of the sector, the only way to "download" it is through the portals. The portals are planes that are added between two sectors (for example, doors and windows).
Rules
General:
Each sector needs to be connected in some way (e.g. door frames are split in the middle, one half is Sector #1, the other is Sector #2).
You must have an "outdoor" sector normally used with open worlds. Also, it is used for connections (bottlenecks) between inner sectors and the outdoor.
Sector:
Needs to have at least one lightmap assigned to it.
Select "Add sector" in the toolbar and create the sectors needed (e.g. Room_1 and Room_2, etc.).
Select "Add Lightmap" and create the lightmaps needed (e.g. Room_1_lightmap, etc.).
If created with 3D software:
Click Add Files and select them;
Select your sector and assign a lightmap for it;
Click Add Portals and select the portal file.
If created within the editor:
Click the objects from the sector and, on the properties tab, choose a sector for it.
Select the lightmap for them in the same tab.
Look for "Portal" in the Entity Listand create a portal. Draw it between the sectors. Remember to snap vertices!
Select lightmaps for bake and click "Build X Checked maps" to bake the selected lightmaps or "Build map" to build everything.
This may take some time (for small scenes, less than a minute, but for large ones, it can take much more time).
After the bake, click Compile Portals and you're done.
Terrains by default are an outdoor sector and need a lightmap.
Calculate Terrain AO works only for terrain and only when clicked (it does not calculate with the "Build Map" button). It does take a long time to bake all, so be careful.
Properties
Object
Property
Description
Sector folder
Devices
Graphics devices.
Used
Allows to choose graphics cards.
Sector name
Sector name.
Sound Occlusion Outdoor Factor
Sound occlusion value.
Sector model
Devices
Graphics devices.
Used
Allows to choose graphics cards.
File name
Model name.
Enabled
Allows to enable or disable the display of the sector.
Sector texture
Devices
Graphics devices.
Used
Allows to choose graphics cards.
Name
Texture name.
Texture
Allows to choose a texture for the sector.
Shader
Allows you to choose a shader and customize its properties.
Lightmap
Lightmap on the sector: true/false (Recommended: TRUE, can be turned off for performance).
Lightmap Density
Lightmap density value on the level.
Cast AO
Enables an effect to cast Ambient Occlusion. (Recommended: TRUE, can be turned off for performance).
No Collision
Option that disables collision of a sector.
No render
Option that disables render of a sector (same as Ghost).