Is there a material that blocks bullets but not players?

Discussion in 'Mapping Questions & Discussion' started by Kataiser, Nov 1, 2015.

  1. Kataiser

    Kataiser L1: Registered

    Messages:
    47
    Positive Ratings:
    3
    I figured that Block Bullets would stop bullets (including rockets and pills) from passing through. Turns out, that's not the case. Is there a material that I can apply to a brush that would do that?
     
  2. tyler

    aa tyler snail prince, master of a ruined tower

    Messages:
    5,031
    Positive Ratings:
    3,975
  3. Exactol

    aa Exactol Certified Hammer Hacker

    Messages:
    393
    Positive Ratings:
    451
    There is actually a way to do this!

    Create a brush with nodraw/trigger texture, make it a func_physbox_multiplayer, make sure these flags are checked:

    • Start Asleep

    • Debris

    • Motion Disabled

    • Only Break on Trigger

    • Don't Take Physics Damage

    • Don't Allow Bullet Penetration

    • Prevent Motion Enable on Player Bump
    Uncheck the rest.

    Also, set these keyvalues:

    • Material: (Anything)

    • Strength: 0

    • Disable Shadows: Yes

    • Disable Receiving Shadows: Yes

    • Render Mode: Don't Render
     
  4. tyler

    aa tyler snail prince, master of a ruined tower

    Messages:
    5,031
    Positive Ratings:
    3,975
    OK, actually, there's a gross and hacky solution here. This is bad for a bunch of reasons, but the main one would be that this would probably end up severely lagging your map in multiplayer servers due to the amount of info being tracked (depending on where it is and how it's used, I guess).

    I really recommend not doing this though, unless it's for a trade/joke map.
     
  5. Kataiser

    Kataiser L1: Registered

    Messages:
    47
    Positive Ratings:
    3
    Okay. I'll figure something else out.
     
  6. Exactol

    aa Exactol Certified Hammer Hacker

    Messages:
    393
    Positive Ratings:
    451
    The way I did it, which is the same as tyler I think, does not lag
     
  7. tyler

    aa tyler snail prince, master of a ruined tower

    Messages:
    5,031
    Positive Ratings:
    3,975
    Like I said it depends on what you're doing--I guess I assumed it would be big and therefore unwieldy, but Exactol is right that depending on the implementation you go after it could work fine. Or if you tell us what you want to do, we might know a better way to accomplish it.
     
  8. Zed

    aa Zed Certified Most Crunk™

    Messages:
    1,235
    Positive Ratings:
    994
     
  9. Seba

    aa Seba DR. BIG FUCKER, PHD

    Messages:
    2,363
    Positive Ratings:
    2,365
    There's a solution to this in the third post of the thread, coltn
     
    • Thanks Thanks x 1
  10. MoonFox

    MoonFox L10: Glamorous Member

    Messages:
    735
    Positive Ratings:
    72
    well then I guess I should go before I make a bigger fool of myself
     
    • Thanks Thanks x 1
  11. Kataiser

    Kataiser L1: Registered

    Messages:
    47
    Positive Ratings:
    3
    I'm trying to make a security fence at the edge of the map not be possible to stand on, but still possible to be shot.
     
  12. MoonFox

    MoonFox L10: Glamorous Member

    Messages:
    735
    Positive Ratings:
    72
    well I would look at how valve does their fences as such, but basically all fences have a solid mesh that stops just about everything, and to fix the not able to stand on top: use a player clip (just type clip into materials window, it should be the first one there) from the bottom of the fence (or top) and drag upwards to the skybox, so you don't get little nooks that players can stand on and exploit.
     
  13. Kataiser

    Kataiser L1: Registered

    Messages:
    47
    Positive Ratings:
    3
    Pretty much. My problem was that the clip didn't exactly line up with the edge of the prop's collision mesh, for aesthetics I guess. I fixed it by putting little player clip "ramps".
     
  14. MoonFox

    MoonFox L10: Glamorous Member

    Messages:
    735
    Positive Ratings:
    72
    So you still want people to stand on the fence? Alright, good luck with what you do.
     
  15. Kataiser

    Kataiser L1: Registered

    Messages:
    47
    Positive Ratings:
    3
    No, I put ramps so people slide off the top of the fence and can't stand on it.
     
  16. Yrr

    aa Yrr An Actual Deer

    Messages:
    984
    Positive Ratings:
    1,871
    People will surf those, you really need to clip it all the way to the ceiling.
     
  17. Kataiser

    Kataiser L1: Registered

    Messages:
    47
    Positive Ratings:
    3
    Ah, okay. Thanks.
     
  18. MoonFox

    MoonFox L10: Glamorous Member

    Messages:
    735
    Positive Ratings:
    72
    And to add in, it's actually best to go and ground floor up all the walls and structures with player clip, it's the best way to ensure no one can exploit, the only reason why you would not go from floor to sky: would be for ledges, small buildings/sheds, or out door structures anyone could theoretically get on
     
  19. zahndah

    aa zahndah professional letter

    Messages:
    715
    Positive Ratings:
    618
    You could disable collision on the fence prop and clip all the way down to the floor.
     
    • Thanks Thanks x 1
  20. JMaxchill

    JMaxchill L5: Dapper Member

    Messages:
    220
    Positive Ratings:
    64
    This is probably the cleanest way to do it. Fewer brushes and no ramps. I can't remember if that allows projectiles through, though