i cant seem to figure out how to make a script that allows players to not collide with each other. all the yt vids a watched were no help. can somebody help.
COMMUNITY QUESTION
How can i make a script that allows players to not collide? (non collide script)
1 answer
Sorry Last Time I messed up.insert a script in workspace
Script:
script.Parent = game:GetService("ServerScriptService")
local PhysService = game:GetService("PhysicsService")
local PlayerGroup = PhysService:CreateCollisionGroup("p")
PhysService:CollisionGroupSetCollidable("p","p",false)
function NoCollide(model)
for k,v in pairs (model:GetChildren()) do
if v:IsA"BasePart" then
PhysService:SetPartCollisionGroup(v,"p")
end
end
end
game:GetService("Players").PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function(char)
char:WaitForChild("HumanoidRootPart")
char:WaitForChild("Head")
char:WaitForChild("Humanoid")
wait(0.1)
NoCollide(char)
if player.Character then
NoCollide(player.Character)
end
end)
end)
--Give me a Good Review and follow my roblox account
--if doesnt work tell me
This discussion is preserved as it was. New answers, comments, and votes are closed.

3 comments
Sorry Everyone i did it wrong
dude u did not put it in script format
yes