Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I make this gun weapon script anti-teamkill? [closed]

Asked by 7 years ago
pcall(function() if (hit.Parent:findFirstChild("Hit")) then hit.Parent.Health.Value = hit.Parent.Health.Value - damage end local numbd = 0 for i = 1,#suits do if hit.Parent.Name == suits[i] then numbd = numbd + 1 end end if (hit.Parent.className == "Hat") or (hit.Parent.className == "Tool")or (numbd>=1)  then if (hit.Name == "Riot Shield") then return end    if (game.Players:GetPlayerFromCharacter(hit.Parent.Parent)) then 
end end 
    if (hit.Parent ~= player.Character) then 
tagHumanoid(hit.Parent.Humanoid, player) if (hit.Name == "Head") then damagehum(damage*3, hit.Parent) elseif(hit.Name == "Head") then damagehum(damage*1.2, hit.Parent) else damagehum(damage, hit.Parent) end end end )
    game:service("Debris"):AddItem(p,0.075)
end
end

I need to make it so that the bullet only damages enemies and not people of the same team color.

0
Sorry if it's a bit messy billybobjo27 0 — 7y

Closed as Not Constructive by Goulstem

This question has been closed because it is not constructive to others or the asker. Most commonly, questions that are requests with no attempt from the asker to solve their problem will fall into this category.

Why was this question closed?