Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  
Chris Hansen

Vanilla - are merged sectors friends or foes?

Recommended Posts

I'm hard at work trying to get my map for TNT Revilution to stay HOM free. I'm using the Visplane Explorer plugin in gzdoombuilder to aid me and I'm mainly focusing on the reports of red drawsegs in the map. During my struggles I've noticed that there might be a difference in those red dots if I merge or unmerge sectors. I think that merged sectors help to reduce them, but I'm not sure. Are merged sectors a good thing or not? Any input or advice are of course also welcome :)

Share this post


Link to post

Merged sectors shouldn't have a notable effect on rendering limits. If two floors have the same properties and the renderer can merge them into a single visplane (which sometimes happens and sometimes can't), the planes will be merged regardless of whether the sectors themselves were merged together.

Chocorenderlimits has a special mode you can access via one of the Fkeys (I forget which one offhand) that will show you each visplane, so you can get a better idea of where splits are happening.

Drawsegs aren't directly related to sectors or visplanes. They're made from sidedefs: 2-sided lines create at least two segs, or more depending on how complex the shapes are and how the nodebuilder splits them up. I think they get split based on how the nodebuilder creates convex subsectors.

Merging sectors might be causing some minor but basically random changes by giving the nodebuilder slightly different data to play with, but I wouldn't expect anything of significance from them. Also be careful when merging sectors together, because of how sound travels: if you merge two sectors on opposite ends of a sound-blocking line, you've prevented the sound-blocking line from working.

Reducing 2-sided lines and using simpler shapes are the keys to reducing drawsegs. Sometimes it's easy, other times it means rethinking stuff more fundamentally to make it less costly without looking like you've taken an axe to it.

If you're not already doing so, try one of these (copied and pasted from a BTSX forum post):

Nodebuilder configs: http://esselfortium.net/wasd/CustomNodes.cfg
Drop this in Doom Builder 2 (or GZDB)'s /Compilers/Nodebuilders/ subfolder.

  • "ZenNode (Vanilla Optimized)" is the BTSX nodebuilder of choice, as it does a very nice job of optimizing segs and visplanes. A bit finicky with self-referencing sector tricks (if they aren't working, try switching the sector numbers around), but otherwise the best all-around choice for vanilla mapping.

  • "BSP-W32 - Fast Optimized Visplanes" is a good choice if you find ZenNode too finicky for weirdo sector tricks, but seems to have somewhat worse visplane optimization, so be aware of that tradeoff.


If you're still having trouble, posting a screenshot or a map demo would make it possible to give more specific advice!

Share this post


Link to post

Thank you very much for that comprehensive and helpful reply, Essel! Some of it is a bit technical for someone like me, but I think I understand the key points :)

I didn't know about the 2 sided linedefs point you made, so I will definitely keep that in mind! I'll of course also try and build the nodes with the suggested nodebuilder - thanks!

I've had problems with the sound travelling through merged sectors before, so I'm already trying to avoid that problem, but thanks for telling me. Sometimes I've actually used merged sectors to deliberately make sound travel to other parts of the map.

Thanks again!

Share this post


Link to post

Nah, no need for that. I read it a couple of times and the technical bits are actually not that bad. Overall, I think you did an excellent job explaining everything! I have a feeling that you could do much worse if you didn't have to restrain yourself! ;)

Share this post


Link to post

Wasn't there a problem discovered with the sector bounding box having influence on floor/ceiling movement? That'd be more likely to happen with merged sectors.

Share this post


Link to post
boris said:

Wasn't there a problem discovered with the sector bounding box having influence on floor/ceiling movement? That'd be more likely to happen with merged sectors.



Yes, indeed. The original algorithm will actually check the entire bounding box of the sector. In Boom and derivatives this has been changed to only affect any actors which touch the sector. For any kind of sector which contains movement merging is not recommended

Another thing to look for is that sound which propagates to one section of the sector will automatically be heard by monsters in all parts of the sector and propagate from those other sections.

Overall I think, merging sectors doesn't really make much sense, unless you want to exploit the sound propagation. The sector limit is normally the last one hit of all the limits in the engine and I do not really think this will improve performance anywhere else.

Share this post


Link to post
Graf Zahl said:

Overall I think, merging sectors doesn't really make much sense, unless you want to exploit the sound propagation.


In most cases, I merge sectors to make it easier and faster to change their properties while designing the map. This can be changing heights or flats when working with highly symmetrical areas i.e. if you have something like 4 pools of water divided by a cross like bridge. But I guess that's just because I'm a slow designer, who constantly goes back to existing areas to change their properties. Most designers probably don't have this problem and it's one of the reasons I'll never be able to do a speedmap :)

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
×