Gamemode allow FriendlyFire?

I looked it up in the wiki,
I looked to see if there was something similar but nothing.

So I wanted to know if there was a function of some sort that could stop players from giving damage to players that are in the same team as them. I tried to use ShouldCollide but it becomes glitchy.

If it does exist or you know a way to do it, thanks in advance.

local pl2 = dmg:GetAttacker()
if pl2:IsPlayer() and pl:Team() == pl2:Team() then dmg:SetDamage( 0 ) end

Try that. Not sure what you were doing with shouldcollide, but yeah.

Yah Idk, when I was using ShouldCollide, I could set it so that we could not fire another person in our same team, but thanks, I’ll go and work on with the example you provided.