[ZDBSP] Node issues with dead.air

These bugs do plan to be resolved, when they can be.

Moderator: GZDoom Developers

Post Reply
User avatar
Xaser
 
 
Posts: 10772
Joined: Sun Jul 20, 2003 12:15 pm
Contact:

[ZDBSP] Node issues with dead.air

Post by Xaser »

The v1 build of dead.air has a few geometry holes, presumably from node shenanigans. The map is UDMF and a large portion of the map's vertices are off-grid, which is likely what's throwing ZDBSP off.

Some gzdoom screenshots (clickable thumbnails) w/coordinates of the 4 reported trouble-spots:
ImageImage
ImageImage

The first 3 only manifest in GZDoom but #4 results in an ugly HOM in ZDoom as well, for those hunting for the issue.

This may be a "can't do much because floating point precision/rounding/whatnot" thing, but it's worth a report. I'll see if I can spot-fix these map-side in the meantime, but #4 in particular has resisted attempts to oust it so far.


[EDIT] Added a direct link to the old v1 build of the wad, since the v2 release patches up the symptoms mod-side.
Last edited by Xaser on Wed Dec 28, 2016 12:33 am, edited 2 times in total.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49067
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [ZDBSP] Node issues with dead.air

Post by Graf Zahl »

Good luck finding Randi and get ZDBSP fixed.
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: [ZDBSP] Node issues with dead.air

Post by _mental_ »

Indeed missing geometry is caused by fractional part of vertex coordinates. Running ZDBSP from command line with -w options will output all of problems encountered:

Code: Select all

zdbsp -w map01.wad
Spoiler: Pretty long list of warnings
How about these simple steps suggested by MaxED?

Some time ago I made a fairly simple hack for ZDBSP: I added a tolerance (or rather coordinate rounding) for vertices in UDMF which in theory should "solve" such issues automatically.
It worked more or less OK but I never tested it extensively.
User avatar
Xaser
 
 
Posts: 10772
Joined: Sun Jul 20, 2003 12:15 pm
Contact:

Re: [ZDBSP] Node issues with dead.air

Post by Xaser »

Grid size 1 is too coarse to do the entire map, but probably the trouble spots can be snapped to 1 without causing any jaggies. I'd love to snap everything to, say, 0.25, but GZDB doesn't do fractional grid sizes and SLADE doesn't have a "snap vertices to grid" feature... though maybe I ought to feature suggest that already. :P

I'm curious to know if your hacked ZDBSP will fix the issues. It's a real-world test case at least.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49067
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [ZDBSP] Node issues with dead.air

Post by Graf Zahl »

So it is indeed the selection algorithm screwing up on too short lines. Just like I expected. I just posted in another thread a few days ago that Randi outright refused to address the bug where it could have been fixed for (in my opinion laughable) performance considerations (yeah, broken nodes are definitely better than a 5% speed loss...)
User avatar
Xaser
 
 
Posts: 10772
Joined: Sun Jul 20, 2003 12:15 pm
Contact:

Re: [ZDBSP] Node issues with dead.air

Post by Xaser »

For what it's worth, I made a sweep for short linedefs and deleted quite a few (seems the last time I did this for the map was prior to adding the end arena; welp). This fixed the holes in screenshots #2 and #4, but #1 and #3 still persist, so there's still some voodoo at play.
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: [ZDBSP] Node issues with dead.air

Post by _mental_ »

Xaser wrote:Grid size 1 is too coarse to do the entire map, but probably the trouble spots can be snapped to 1 without causing any jaggies. I'd love to snap everything to, say, 0.25, but GZDB doesn't do fractional grid sizes and SLADE doesn't have a "snap vertices to grid" feature... though maybe I ought to feature suggest that already. :P

I'm curious to know if your hacked ZDBSP will fix the issues. It's a real-world test case at least.
I uploaded my ZDBSP build here. Compiled from the latest sources with my rough rounding hack.

It's the same old ZDBSP just with a new option:

Code: Select all

  -y, --tolerance=NN       Round vertex coordinates (0..16, default 0)
                           0 - none, 16 - drop whole fractional part
To achieve rounding to 0.25 I used the following command line:

Code: Select all

zdbsp -w -y 14 -o tolerance_test.wad map01.wad
The good news: all four issues from screenshots were fixed. Now the bad news: there are 13 removed lines and still 3 unclosed subsectors:

Code: Select all

   Removed 13 lines with 0 length.
   Removed 26 unused sidedefs.
Unclosed subsector 7342, from (-4412,3774) to (-4412,3774)
Unclosed subsector 11075, from (857,14429) to (856,14428)
Unclosed subsector 11214, from (284,15469) to (283,15469)
Honestly I have no idea what problems my hack can introduce. You can give it a try if you want but use it on your own risk.
User avatar
Xaser
 
 
Posts: 10772
Joined: Sun Jul 20, 2003 12:15 pm
Contact:

Re: [ZDBSP] Node issues with dead.air

Post by Xaser »

Super-thanks! That seems incredibly useful for evading this sort of thing in the future. If it fixes all the visible issues, then hurrah! :D

I'll bet those missing lines are legit mapping errors. There were several vestigial short linedefs I removed in my working copy; between that and some vertex jiggling I was able to oust the issues for the next release, but I'll probably use this ZDBSP build going forward to avoid having to do the vertex snap. Also because it may solve issues with another (secret, unreleased) map -- that's a side-note, but worth mentioning for funsies.
User avatar
MaxED
Posts: 2246
Joined: Tue Feb 28, 2012 12:55 pm

Re: [ZDBSP] Node issues with dead.air

Post by MaxED »

I should probably chime in and say that the smallest grid size in GZDB is now 0.125 in UDMF.
Post Reply

Return to “On Hold Bugs”