This is a bug that I discovered when making a game that had enclosed rooms you could teleport to (this was almost a year ago). Occasionally, when testing, another player would join after I had teleported into a room. When I teleported out, I was invisible to them except for random pieces of me glitching/appearing all over the baseplate. Whenever I came into contact with them, they would often glitch/fling/shoot across the map. I eventually narrowed the issue down after lots of testing & various attempts at repros to the repro I’m posting here. I left the issue untouched until now because teleporting via CFrames appeared to resolve the issue. However, this glitchy behavior is continuing to occur in my game despite the changes I made, so I thought I’d post the repro+bug report in an attempt to resolve said issues (the bug still occurs in the repro after new tests so Roblox has not resolved this issue since I last encountered it).
It appears that merely teleporting the player via the HumanoidRootPart’s Position
property is enough to cause this bug (i.e. it doesn’t have to be a teleport into an enclosed room).
Here is the place file (but the place itself should be uncopylocked):
Engine_Bug_Demonstration.rbxl (21.4 KB)
This is the link to the repro:
The steps are as follows for the place I posted:
- Player A joins the game and teleports into the room.
- Player B joins the game.
- Player A comes out of the room and is either extremely glitchy to player B or invisible entirely. Either way, if - player A ever comes into contact with Player B, player A is able to fling and easily push around player B as shown in the videos I shared.
The repro is a simple place with a room + door + spawn and one script:
I shall post the script here because it is short:
local tp_part_a = workspace.TPPartA
local tp_part_b = workspace.TPPartB
tp_part_a.Touched:Connect(function(hit)
local character = hit.Parent
local humanoid_root_part = character:FindFirstChild("HumanoidRootPart")
if humanoid_root_part then
humanoid_root_part.Position = tp_part_b.Position + tp_part_b.CFrame.LookVector*5
end
end)
tp_part_b.Touched:Connect(function(hit)
local character = hit.Parent
local humanoid_root_part = character:FindFirstChild("HumanoidRootPart")
if humanoid_root_part then
humanoid_root_part.Position = tp_part_a.Position + tp_part_a.CFrame.LookVector*5
end
end)
Here are videos from both angles of the bug occuring:
and