как сделать зелье скорости с таймером эффекта на экране в роблокс !

Аватар автора
Atremn
скрипт: -- Скрипт зелья скорости с таймером эффекта на экране local tool = script.Parent local speedBoost = 100 -- новая скорость бега local boostDuration = 30 -- длительность эффекта в секундах tool.Activated:Connect(function() local player = game.Players:GetPlayerFromCharacter(tool.Parent) if not player then return end local character = player.Character if not character then return end local humanoid = character:FindFirstChildOfClass("Humanoid") if not humanoid then return end -- Создаем GUI для таймера local playerGui = player:WaitForChild("PlayerGui") local timerGui = Instance.new("ScreenGui") timerGui.Name = "SpeedBoostTimer" timerGui.Parent = playerGui local timerLabel = Instance.new("TextLabel") timerLabel.Size = UDim2.new(0, 200, 0, 50) timerLabel.Position = UDim2.new(0.5, -100, 0.8, 0) timerLabel.BackgroundColor3 = Color3.fromRGB(0, 0, 0) timerLabel.BackgroundTransparency = 0.5 timerLabel.TextColor3 = Color3.new(1, 1, 1) timerLabel.Font = Enum.Font.SourceSansBold timerLabel.TextSize = 24 timerLabel.Parent = timerGui timerLabel.Text = "Скорость: " .. boostDuration .. " сек." -- Сохраняем текущую скорость local originalWalkSpeed = humanoid.WalkSpeed -- Увеличиваем скорость humanoid.WalkSpeed = speedBoost -- Отключаем использование зелья tool.Enabled = false tool.Handle.Transparency = 1 tool.Handle.CanCollide = false -- Таймер обратного отсчета for i = boostDuration, 1, -1 do timerLabel.Text = "Скорость: " .. i .. " сек."...

0/0


0/0

0/0

0/0