I am testing out a script that print something everytime you die. But the issue is that I get a warning. However the script works.
The warning that I get is:
05:56:07.347 RunService:UnbindFromRenderStep removed different functions with same reference name utility-focus-state-inspect-PixelCrypth 2 times. - Studio
Localscript: (located in StarterCharacterScripts)
local Player = game.Players.LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")
-- Check if the Died event is already connected
local isConnected = false
local function OnPlayerDied()
-- Ensure the event is only fired once
print("ur ded")
end
-- Connect the Died event only if it's not already connected
if not isConnected then
Humanoid.Died:Connect(OnPlayerDied)
end
Would anyone be enable to help? I even tried to check the connection if it’s not connected yet but still no use. It always shows first in the output the orange warning when I reset my character.
It’s not your script, it’s just a small bug in the Core scripts that happen when you turn on a Beta Feature - features that aren’t fully released and could have bugs.
The warning is from a Roblox engineer making a mistake in their code, it’s not your fault. You can just ignore it, or turn off the Beta Feature.
Ye it’s kinda confusing. I was researching where it came first from the game.
Then basically making this test script to see if similair thing happens and well after that researching what else may be the issue and asking devforum.
I am very glad that Roblox has such a helpful community dedicated on scripting help and fixing issues. Thank you all again for the great assistance.