I'm trying to make a platform that you can jump through and stand on and I'm trying to use collision groups. I'm not very familiar with them and this is my first time trying them, but could anyone tell me how I would go about adding a player's character to a collision group? When I tried it, it said only BaseParts could be in collision groups? My code is below
local ps = game:GetService("PhysicsService")
ps:CreateCollisionGroup("Player")
ps:CreateCollisionGroup("Platform")
ps:CollisionGroupSetCollidable("Player", "Platform", false)
plat = game.Workspace.Platform1
plat.Touched:Connect(function(hit)
h = hit.parent:FindFirstChild("Humanoid")
if h then
ps:SetPartCollisionGroup("Player" ,h)
wait(plat.TouchEnded)
ps:RemoveCollisionGroup(h, "Player")
end
end)
