2much4Us

Untitled

Jun 11th, 2018
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.60 KB | None | 0 0
  1. [[if !bombstrike then
  2.  
  3. hook.Add("Think", "lulz_bombstrike", function()
  4.  
  5. local explode = ents.Create( "env_explosion" )
  6.  
  7. local ps = Vector(math.random(-8000, 8000), math.random(-8000, 8000), math.random(-5000, 5000))
  8.  
  9. local trc = {}
  10.  
  11. trc.start = ps
  12.  
  13. trc.endpos = ps + Vector( 0, 0, -99999)
  14.  
  15. local tr = util.TraceLine(trc)
  16.  
  17. if !tr.Hit then return end
  18.  
  19. explode:SetPos( tr.HitPos )
  20.  
  21. explode:Spawn()
  22.  
  23. explode:SetKeyValue( "iMagnitude", "400" )
  24.  
  25. explode:Fire( "Explode", 0, 0 )
  26.  
  27. end)
  28.  
  29. bombstrike = true
  30.  
  31. else
  32.  
  33. hook.Remove("Think", "lulz_bombstrike")
  34.  
  35. bombstrike = false
  36.  
  37. end]]
Advertisement
Add Comment
Please, Sign In to add comment