ya dud one of my kittix hacks has this,
Code:
--[[--------------------------------------------
Lasers
--]]--------------------------------------------
local laser = Material( "sprites/bluelaser1" )
hook.Add("RenderScreenspaceEffects", "lelelel", function()
if shouldbeam then return end
local startpos = LocalPlayer():GetPos()
local EndPos = LocalPlayer():GetEyeTrace().HitPos;
local model = LocalPlayer():GetViewModel()
if not IsValid(model) then
return
end
local attach = model:GetAttachment("1")
if ( Attach == 0 ) then Attach = ViewModel:LookupAttachment("muzzle") end
if not attach then return end
startpos = attach.Pos
cam.Start3D()
render.SetMaterial( laser )
render.DrawBeam( startpos, EndPos, 5, 0, 0, Color( 25, 25, 255, 255 ) )
--------------------------------- FOR THE END PARTICLE
render.SetMaterial(Material("Sprites/light_glow02_add_noz"))
render.DrawQuadEasy(LocalPlayer():GetEyeTrace().HitPos, (EyePos() - LocalPlayer():GetEyeTrace().HitPos):GetNormal(), 30, 30, Color(255,255,255,255))
cam.End3D()
end)