• 0 Damage weapon dealing damage through glass
    2 replies, posted
So i have a weapon that normally deals 0 damage and its mainly for drawing on a wall but if you hit it through a thick window that wouldnt break unless it was hit by damage. How would i go about fixing this? i thought maybe checking if the hitent was that thick glass but i dont know what that would be. Thanks in advance !
I think it would be a better solution to set the damage very high, but then have a check to see if the hit ent is a player, and if so, do no damage.
thing is its not even hitting players [code] if hitEnt:IsPlayer() or hitEnt:GetClass() == "prop_ragdoll" then return end [/code] Was in the code prior to posting and doesn't fix it. I have currently [code]if hitEnt:GetClass() == "func_breakable_surf" || hitEnt:GetClass() == "func_breakable" then return end [/code] But all that does is stop from hitting a window entirely which I would still like the weapon to do.
Sorry, you need to Log In to post a reply to this thread.