So im helping with a difficulty chart game on roblox but it has this bug sometimes when u die u wont respawn and u are able to like fly around everywhere but u are not able to see ur avatar its like u can fly, u have god mode, nobody can see you. Its weird and if people can just fly around in a obby its kinda cheap anybody know anything about this and a way to fix it might have been this script here tho not to sure
local TweenService = game:GetService("TweenService")
local TweenInformation = TweenInfo.new(1.5,Enum.EasingStyle.Quint,Enum.EasingDirection.Out,0,false,0)
for i,v in pairs(script.Parent:GetChildren()) do
if v:IsA("BasePart") then
v.Touched:Connect(function(hit)
local humanoid = hit.Parent:FindFirstChild("Humanoid")
if humanoid ~= nil then
local player = game.Players:GetPlayerFromCharacter(humanoid.Parent)
if player ~= nil then
if player.leaderstats.Level.Value == tonumber(v.Name) - 1 then
player.leaderstats.Level.Value += 1
local Destiny = {Orientation = Vector3.new(0,360,0),Color = v.CheckpointColor.Value}
local DecorationTween = TweenService:Create(v,TweenInformation,Destiny)
DecorationTween:Play()
end
end
end
end)
end
end

2 comments
Nope did not work i would send a video but dosent allow me to
Try going into studio, pressing ctrl + shift + f, and then searching up .Died(). Then try deleting the script where it appears in.