local ScreenGui = Instance.new("ScreenGui") local Frame = Instance.new("Frame") local TimeFrame = Instance.new("Frame") local TimeLabel = Instance.new("TextLabel") local UICorner_4 = Instance.new("UICorner") local EarnedFrame = Instance.new("Frame") local EarnedLabel = Instance.new("TextLabel") local UICorner_3 = Instance.new("UICorner") local CurrencyFrame = Instance.new("Frame") local CurrencyLabel = Instance.new("TextLabel") local UICorner_2 = Instance.new("UICorner") local UICorner = Instance.new("UICorner") local function DisableResetOnSpawn(instance) instance.ResetOnSpawn = false for _, child in ipairs(instance:GetDescendants()) do if child:IsA("Instance") then child.ResetOnSpawn = false end end end -- Disable resetonspawn for all instances in the GUI DisableResetOnSpawn(ScreenGui) -- Properties: ScreenGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui") ScreenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling Frame.Parent = ScreenGui Frame.BackgroundColor3 = Color3.fromRGB(21, 21, 21) -- Updated background color Frame.BorderColor3 = Color3.fromRGB(0, 0, 0) Frame.BorderSizePixel = 0 Frame.Size = UDim2.new(1, 0, 1, 0) TimeFrame.Name = "TimeFrame" TimeFrame.Parent = Frame TimeFrame.BackgroundColor3 = Color3.fromRGB(59, 59, 59) TimeFrame.BorderSizePixel = 0 TimeFrame.Position = UDim2.new(0.025, 0, 0.1, 0) TimeFrame.Size = UDim2.new(0.3, 0, 0.8, 0) TimeLabel.Name = "TimeLabel" TimeLabel.Parent = TimeFrame TimeLabel.AnchorPoint = Vector2.new(0.5, 0.5) TimeLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255) TimeLabel.BackgroundTransparency = 1.000 TimeLabel.BorderColor3 = Color3.fromRGB(0, 0, 0) TimeLabel.BorderSizePixel = 0 TimeLabel.Position = UDim2.new(0.5, 0, 0.5, 0) TimeLabel.Size = UDim2.new(0.8, 0, 0.8, 0) TimeLabel.Font = Enum.Font.SourceSans TimeLabel.Text = "Time Elapsed: 00:00:00" TimeLabel.TextColor3 = Color3.fromRGB(255, 0, 0) TimeLabel.TextScaled = true TimeLabel.TextSize = 14.000 TimeLabel.TextWrapped = true UICorner_4.CornerRadius = UDim.new(0, 8) UICorner_4.Parent = TimeFrame EarnedFrame.Name = "EarnedFrame" EarnedFrame.Parent = Frame EarnedFrame.BackgroundColor3 = Color3.fromRGB(59, 59, 59) EarnedFrame.BorderSizePixel = 0 EarnedFrame.Position = UDim2.new(0.35, 0, 0.1, 0) EarnedFrame.Size = UDim2.new(0.3, 0, 0.8, 0) EarnedLabel.Name = "EarnedLabel" EarnedLabel.Parent = EarnedFrame EarnedLabel.AnchorPoint = Vector2.new(0.5, 0.5) EarnedLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255) EarnedLabel.BackgroundTransparency = 1.000 EarnedLabel.BorderColor3 = Color3.fromRGB(0, 0, 0) EarnedLabel.BorderSizePixel = 0 EarnedLabel.Position = UDim2.new(0.5, 0, 0.5, 0) EarnedLabel.Size = UDim2.new(0.8, 0, 0.8, 0) EarnedLabel.Font = Enum.Font.SourceSans EarnedLabel.Text = "Cash Earned: 0" EarnedLabel.TextColor3 = Color3.fromRGB(0, 255, 0) EarnedLabel.TextScaled = true EarnedLabel.TextSize = 14.000 EarnedLabel.TextWrapped = true UICorner_3.CornerRadius = UDim.new(0, 8) UICorner_3.Parent = EarnedFrame CurrencyFrame.Name = "CurrencyFrame" CurrencyFrame.Parent = Frame CurrencyFrame.BackgroundColor3 = Color3.fromRGB(59, 59, 59) CurrencyFrame.BorderSizePixel = 0 CurrencyFrame.Position = UDim2.new(0.675, 0, 0.1, 0) CurrencyFrame.Size = UDim2.new(0.3, 0, 0.8, 0) CurrencyLabel.Name = "CurrencyLabel" CurrencyLabel.Parent = CurrencyFrame CurrencyLabel.AnchorPoint = Vector2.new(0.5, 0.5) CurrencyLabel.BackgroundColor3 = Color3.fromRGB(255, 255, 255) CurrencyLabel.BackgroundTransparency = 1.000 CurrencyLabel.BorderColor3 = Color3.fromRGB(0, 0, 0) CurrencyLabel.BorderSizePixel = 0 CurrencyLabel.Position = UDim2.new(0.5, 0, 0.5, 0) CurrencyLabel.Size = UDim2.new(0.8, 0, 0.8, 0) CurrencyLabel.Font = Enum.Font.SourceSans CurrencyLabel.Text = "Currency: 0" CurrencyLabel.TextColor3 = Color3.fromRGB(0, 0, 0) CurrencyLabel.TextScaled = true CurrencyLabel.TextSize = 14.000 CurrencyLabel.TextWrapped = true UICorner_2.CornerRadius = UDim.new(0, 8) UICorner_2.Parent = CurrencyFrame UICorner.CornerRadius = UDim.new(0, 8) UICorner.Parent = Frame local cashEarned = 0 local previousCash = game.Players.LocalPlayer.DataFolder.Currency.Value local timerValue = 0 local function FormatNumberWithCommas(number) local formatted = tostring(number) local k while true do formatted, k = string.gsub(formatted, "^(-?%d+)(%d%d%d)", '%1,%2') if k == 0 then break end end return formatted end local function FormatTime(seconds) local hours = math.floor(seconds / 3600) local minutes = math.floor((seconds % 3600) / 60) local secs = seconds % 60 return string.format("%02d:%02d:%02d", hours, minutes, secs) end local function UpdateCurrencyLabels() local difference = game.Players.LocalPlayer.DataFolder.Currency.Value - previousCash cashEarned = cashEarned + difference EarnedLabel.Text = "Cash Earned: " .. FormatNumberWithCommas(cashEarned) CurrencyLabel.Text = "Currency: " .. FormatNumberWithCommas(game.Players.LocalPlayer.DataFolder.Currency.Value) previousCash = game.Players.LocalPlayer.DataFolder.Currency.Value end local function UpdateTimerLabel() TimeLabel.Text = "Time Elapsed: " .. FormatTime(timerValue) end local function StartTimer() while true do wait(1) timerValue = timerValue + 1 UpdateTimerLabel() end end game.Players.LocalPlayer.DataFolder.Currency.Changed:Connect(UpdateCurrencyLabels) -- Start the timer when the script runs StartTimer()