Breaks After Reset

Hello, I made a admin system. Im running into a problem where. Once resetting your player or spawning back in the character. The script breaks. I don’t know why it doesn’t this or why its happening. Please help.

Code -

-- Services --
local Players = game:GetService('Players')
local ReplicatedStorage = game:GetService('ReplicatedStorage')
-- Variables --
local AdminFolder = ReplicatedStorage:FindFirstChild('Admin')
local Module = require(AdminFolder.Client:FindFirstChild('_Client'))
----

-- Init --
Module:Init()
----

Module -

function Module:Init()
	AdminFolder.CrossClient.OnClientEvent:Connect(ClientEvent)
end

does the screen gui have its reset on spawn property set to true? that might be the problem

1 Like

When I reset then do the command now it just stays on my screen and won’t go away

because it doesn’t reset when you spawn, you can disable the ui when a player first spawn with CharacterAdded, then enable it whenever needed

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.