Invisible and CanCollide Players

hello, i want to make a player customization system but have one area where all the players are but they are all can collide and invisible except for the local player who can see themselves. What would be the best way of doing this because i could make a different area for the players and there is just a model which you customize your character and when you press play you have that character or i could make all the players invisible and can collide which i am having trouble doing.

my code for making them Cancollide:


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.CharcterAdded:connect(function(char)
		char:WaitForChild("HumanoidRootPart")
		char:WaitForChild("Head")
		char:WaitForChild("Humanoid")
		wait(0.1)
		NoCollide(char)
	end)
		if player.Character then
			NoCollide(player.Character)
		end
end)
3 Likes

I’m a bit confused as to what you’re trying to do but from my understanding you want the localplayer to be able to collide with other players but not see them?

2 Likes

i have made it so the local player can’t see the other players, but i don’t know how to make it so the local player is can collide. i want them all to spawn in the same position but not make other players go flying if there isn’t enough space.

2 Likes

In my opinion the best way to do this is to spawn the players somewhere else and create a R15 / R6 rig for the customization system. You’ll change everything on the client, so other players cannot see each other’s customization.

2 Likes

Perhaps try anchoring the HumanoidRootPart of the Local Player. Also try setting can collide false to all the children of the character.

2 Likes

i tried that but it doesn’t work

1 Like

I was thinking about that, but i want to save the character so when the player presses play the player gets teleported to another game and then he has the new character.

1 Like

Well, you can teleport the player using TeleportService:Teleport() and send the character’s data at the same time, as the third argument in the function and handle the data on the new server.
(placeId, player, teleportData, customLoadingScreen)

2 Likes