I'm coding for a swep that fire flame bullet in zombie survival but the fire deals only 1 damage per tick, how can I increase it?
wept.BulletCallback = function(attacker, tr, dmginfo)
local ent = tr.Entity
if SERVER and math.random(2) == 1 and ent:IsValidLivingZombie() then
ent:Ignite(20,150)
for __, fire in pairs(ents.FindByClass("entityflame")) do
if fire:IsValid() and fire:GetParent() == ent then
fire:SetOwner(attacker)
fire:SetPhysicsAttacker(attacker)
fire.AttackerForward = attacker
end
end
end
end
Use GM/EntityTakeDamage, use CTakeDamageInfo/GetDamageType to see if it's DMG_BURN. If so, increase the damage from there with CTakeDamageInfo/AddDamage
Sorry, you need to Log In to post a reply to this thread.