Skip textured faces on a world brush [Experiment]

Discussion in 'Tutorials & Resources' started by Viperi, Aug 9, 2016.

  1. Viperi

    aa Viperi 100% might be snake

    Messages:
    995
    Positive Ratings:
    544
    Due to some recent dicussion in the TF2maps Steam group chat, I decided to do some testing on what would happen when you texture one of the faces of a world brush to skip and compare it to nodraw.

    The way I did the test was create a simple room with two same sized brushes both off the ground by a certain amount however one of them has their bottom face textured to nodraw and the other one is textured to skip. skip_test_hammer.png
    skip_test_hammer2.png
    At first hand, I thought the brush on the right textured with skip would be considered an invalid solid as skip is ignored by the compiler. So I compiled it. The results were quite unusual. 20160809182702_1.jpg
    The nodraw brush on the left works just as it should be, however the skip brush on the right looks odd. The faces of the skip brush have streched to the ground. 20160809182711_1.jpg
    From another angle. 20160809182748_1.jpg
    But when I walk towards to it, I can get inside of the streched faces. However it's collision is identical to the one of the nodrawed one. What is also unusual is the engine cuts the square under the skip brush as you would expect if you would have moved the brush in Hammer to touch the floor.

    Now the possible reason behind it is that Hammer cannot detect that it is a invalid solid as it looks like a normal convex world brush to Hammer. However the compiler does detect that it is invalid and thus extends the brush until it meets the nearest brush facing the skip texture. But what it doesn't do is also extend the collision of the brush and that makes it sort of interesting.

    Perhaps you could use this method to make a secret room of some sort?
     
    • Thanks Thanks x 2
    • Like Like x 2
  2. Vel0city

    aa Vel0city func_fish

    Messages:
    1,930
    Positive Ratings:
    1,540
    It looks like it's not even stretching. If it was, the texture would've been stretched as well.

    It looks like it's copy-pasting the same brush in the direction of the skip-textured brush face. What happens if you put the brush on, lets say, 2.5x its own hight above the floor, with a 2 HU thick floor and a room underneath it? Will it stop above the floor since it can't place a full brush? Will it continue downwards and clip trough the floor, but stop there because it detected a floor? Will it keep going until it hits the void?
     
    • Thanks Thanks x 1
  3. Viperi

    aa Viperi 100% might be snake

    Messages:
    995
    Positive Ratings:
    544
    That's an interesting idea. I'll try it out sometime tomorrow.
     
    • Thanks Thanks x 1
  4. Viperi

    aa Viperi 100% might be snake

    Messages:
    995
    Positive Ratings:
    544
    Just noticed this on the Valve Developer Wiki regarding skip textured brush entities.

    "Texturing a brush entity with this texture will remove components of it from the map, which not only may result in compile errors like bmodel 36 has no head node" but may also crash the game engine on load."
     
  5. Idolon

    aa Idolon the worst admin

    Messages:
    1,550
    Positive Ratings:
    4,444
    I'm guessing the "stretching" is because VBSP tried to intersect the side planes of the cube with another plane, but never hit anything below them, so they just continued downwards as normal (until they intersected the floor? I have no idea how VBSP's face culling process works). The texture doesn't stretch because Source works with projected textures rather than uving them to vertices.

    As to why the collisions didn't get messed up, I'm guessing that the collision meshes of brushes don't go through the same face-culling process that the visible polys do? Portal speedrunners often get themselves outside of the map and walk on the nodraw faces that are supposedly culled on compile, so I imagine that's the case.
     
    • Like Like x 2
  6. Mikroscopic

    aa Mikroscopic

    Messages:
    604
    Positive Ratings:
    613
    You two have the same profile picture and it's making this thread very confusing to read.

    But yeah, if this can crash the game then maybe it's best not to use this as an intentional feature, unless you can get it working consistently.
     
    • Agree Agree x 1
    • Funny Funny x 1
  7. Viperi

    aa Viperi 100% might be snake

    Messages:
    995
    Positive Ratings:
    544
    Basically you can only use this on world brushes as it doesn't work on brush entities as it was intended to only work with world brushes (hint).