How to make things collide but other things not?

Hola aliens!

I am currently attempting a great feat: to make a Part collide with Folder1 but NOT Folder2 :exploding_head::exploding_head::exploding_head::exploding_head:

I know that there is collision groups however I am A bit confused on how it works :slightly_frowning_face: :slightly_frowning_face:

Respond now, and claim your FREE SOLUTION! so how do I do this? :thinking::male_detective:

1 Like

You have your answer, CollisonGroups!!!
Open your Collison Group Editor (On the Advanced Tab of Models Tab in Studio), create a Collison Group, and dont use the Table View, because that looks like a mess


List view would make it much easier to edit.

Wait… I had to pay?

your response is pure brilliance. It is like watching magnus carlson in chess

But how do I do this in a script mr doggy?
5276355_2

object.CollisionGroup = SomeCollisonGroup; -- must be a string

Yes my doggy friend however I believe they changed it :hot_face:

local PhysicsService = game:GetService("PhysicsService")

local collisionGroupBall = "CollisionGroupBall"
local collisionGroupDoor = "CollisionGroupDoor"

-- Register collision groups
PhysicsService:RegisterCollisionGroup(collisionGroupBall)
PhysicsService:RegisterCollisionGroup(collisionGroupDoor)

-- Assign parts to collision groups
script.Parent.BallPart.CollisionGroup = collisionGroupBall
script.Parent.DoorPart.CollisionGroup = collisionGroupDoor

-- Set groups as non-collidable with each other and check the result
PhysicsService:CollisionGroupSetCollidable(collisionGroupBall, collisionGroupDoor, false)
print(PhysicsService:CollisionGroupsAreCollidable(collisionGroupBall, collisionGroupDoor)) --> false

This is what the documentation says however its confusing. I am also very dumb :smiley: :smiley: :smiley:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.