Search Unity

Bug Bug #1368465: Extruding PB faces results in accumulated error

Discussion in 'World Building' started by dgoyette, Sep 25, 2021.

  1. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    4,195
    Reported as bug #1368465. Easy to reproduce. Start with a PB cube, remove all but one face, and make sure it's at Y=0. Then pick an edge, hold shift, and repeatedly extrude like this:

    PBExtrude.gif

    Now drop some prefab from the Project view onto the object. Notice that the Y-position of the object will be 0 if you drop the object on the first face, but it will be higher for each subsequent face, increasing with each extrusion. In this example, dropping a prefab on the last face results in it having a Y-position of 0.001867543.

    It seems that a small amount of error is being introduced, and it compounds with each subsequent face.

    This becomes fairly annoying when making a level with a lot of turns, each of which is a new extrusion. The end result is a floor that isn't level, where every face is at a different height. Dropping prefabs onto the level puts them at arbitrary Y positions instead of at Y=0. I end up having to manually raise and lower all faces using snapping to reset their positions to Y=0, and manually set prefab's positions to Y=0.