CapsAdmin

Untitled

Jun 21st, 2012
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.38 KB | None | 0 0
  1. local POS = Vector(0,0,0) -- some local position (relative to entity)
  2. local ANG = ANgle() -- some local angle (relative to entity)
  3.  
  4. local bclip = render.EnableClipping(true)
  5.  
  6.  
  7. local pos, ang = LocalToWorld(POS, ANG, ent:GetPos(), ent:GetAngles())
  8. local normal = ang:Forward()
  9. render.PushCustomClipPlane(normal, normal:Dot(pos + normal))
  10.  
  11. -- draw ui
  12.  
  13. render.EnableClipping(bclip)
Advertisement
Add Comment
Please, Sign In to add comment