Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How Do I Make Players Able To Walk Through Me?

Asked by 9 years ago

how to make it so players can walk through me?, not cancollide = false, then i fall through the baseplate.

(I'm not very fluent in English, apologies)

2 answers

Log in to vote
0
Answered by
Kurieita 125
9 years ago

Only way I can think of is to make a complete physics engine based off of ray casting to determine where the floor is and use body movers to move your character. That would be too much to post here tho.

Ad
Log in to vote
0
Answered by 9 years ago

Put this in a LocalScript in StarterPlayerScripts. Make sure that FilteringEnabled is on.

-- Written by Tim7775, 2015
game:GetService("RunService").Stepped:connect(function()
    for _, player in pairs(game.Players:GetPlayers()) do
        if player ~= game.Players.LocalPlayer then
            local character = player.Character
            if character then
                local head = character:FindFirstChild("Head")
                local torso = character:FindFirstChild("Torso")
                if head then head.CanCollide = false end
                if torso then torso.CanCollide = false end
            end
        end
    end
end)

Answer this question