Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Hub, open source. Editing and other is not prohibited.
- --discord=qelvix
- -- Instances: 24 | Scripts: 8 | Modules: 0 | Tags: 0
- local G2L = {};
- -- StarterGui.HubOil
- G2L["1"] = Instance.new("ScreenGui", game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui"));
- G2L["1"]["Name"] = [[HubOil]];
- G2L["1"]["ZIndexBehavior"] = Enum.ZIndexBehavior.Sibling;
- G2L["1"]["ResetOnSpawn"] = false;
- -- StarterGui.HubOil.Drag
- G2L["2"] = Instance.new("Frame", G2L["1"]);
- G2L["2"]["BorderSizePixel"] = 0;
- G2L["2"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["2"]["Size"] = UDim2.new(0, 399, 0, 37);
- G2L["2"]["Position"] = UDim2.new(0.35137, 0, 0.29305, 0);
- G2L["2"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["2"]["Name"] = [[Drag]];
- -- StarterGui.HubOil.Drag.Frame
- G2L["3"] = Instance.new("Frame", G2L["2"]);
- G2L["3"]["BorderSizePixel"] = 0;
- G2L["3"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["3"]["Size"] = UDim2.new(0, 400, 0, 250);
- G2L["3"]["Position"] = UDim2.new(-0.00113, 0, -0.00425, 0);
- G2L["3"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["3"]["BackgroundTransparency"] = 0.85;
- -- StarterGui.HubOil.Drag.Frame.Close
- G2L["4"] = Instance.new("TextButton", G2L["3"]);
- G2L["4"]["TextWrapped"] = true;
- G2L["4"]["BorderSizePixel"] = 0;
- G2L["4"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["4"]["TextSize"] = 14;
- G2L["4"]["TextScaled"] = true;
- G2L["4"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["4"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["4"]["Size"] = UDim2.new(0, 35, 0, 36);
- G2L["4"]["BackgroundTransparency"] = 1;
- G2L["4"]["Name"] = [[Close]];
- G2L["4"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["4"]["Text"] = [[X]];
- G2L["4"]["Position"] = UDim2.new(0.91113, 0, 0.00063, 0);
- -- StarterGui.HubOil.Drag.Frame.Close.LocalScript
- G2L["5"] = Instance.new("LocalScript", G2L["4"]);
- -- StarterGui.HubOil.Drag.Frame.RandomTime
- G2L["6"] = Instance.new("TextButton", G2L["3"]);
- G2L["6"]["TextWrapped"] = true;
- G2L["6"]["BorderSizePixel"] = 0;
- G2L["6"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["6"]["TextSize"] = 14;
- G2L["6"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["6"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["6"]["Size"] = UDim2.new(0, 80, 0, 40);
- G2L["6"]["Name"] = [[RandomTime]];
- G2L["6"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["6"]["Text"] = [[RandomTime]];
- G2L["6"]["Position"] = UDim2.new(0.045, 0, 0.41935, 0);
- -- StarterGui.HubOil.Drag.Frame.RandomTime.LocalScript
- G2L["7"] = Instance.new("LocalScript", G2L["6"]);
- -- StarterGui.HubOil.Drag.Frame.AntiBang
- G2L["8"] = Instance.new("TextButton", G2L["3"]);
- G2L["8"]["TextWrapped"] = true;
- G2L["8"]["BorderSizePixel"] = 0;
- G2L["8"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["8"]["TextSize"] = 14;
- G2L["8"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["8"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["8"]["Size"] = UDim2.new(0, 80, 0, 40);
- G2L["8"]["Name"] = [[AntiBang]];
- G2L["8"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["8"]["Text"] = [[AntiBang]];
- G2L["8"]["Position"] = UDim2.new(0.045, 0, 0.63935, 0);
- -- StarterGui.HubOil.Drag.Frame.AntiBang.LocalScript
- G2L["9"] = Instance.new("LocalScript", G2L["8"]);
- -- StarterGui.HubOil.Drag.Frame.MysteriousBusinessCard
- G2L["a"] = Instance.new("TextButton", G2L["3"]);
- G2L["a"]["TextWrapped"] = true;
- G2L["a"]["BorderSizePixel"] = 0;
- G2L["a"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["a"]["TextSize"] = 14;
- G2L["a"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["a"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["a"]["Size"] = UDim2.new(0, 80, 0, 40);
- G2L["a"]["Name"] = [[MysteriousBusinessCard]];
- G2L["a"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["a"]["Text"] = [[MysteriousBusinessCard]];
- G2L["a"]["Position"] = UDim2.new(0.2925, 0, 0.19135, 0);
- -- StarterGui.HubOil.Drag.Frame.MysteriousBusinessCard.LocalScript
- G2L["b"] = Instance.new("LocalScript", G2L["a"]);
- -- StarterGui.HubOil.Drag.Frame.AntiKnockback
- G2L["c"] = Instance.new("TextButton", G2L["3"]);
- G2L["c"]["TextWrapped"] = true;
- G2L["c"]["BorderSizePixel"] = 0;
- G2L["c"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["c"]["TextSize"] = 14;
- G2L["c"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["c"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["c"]["Size"] = UDim2.new(0, 80, 0, 40);
- G2L["c"]["Name"] = [[AntiKnockback]];
- G2L["c"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["c"]["Text"] = [[AntiKnockback]];
- G2L["c"]["Position"] = UDim2.new(0.045, 0, 0.19135, 0);
- -- StarterGui.HubOil.Drag.Frame.AntiKnockback.LocalScript
- G2L["d"] = Instance.new("LocalScript", G2L["c"]);
- -- StarterGui.HubOil.Drag.Frame.SnowRoom
- G2L["e"] = Instance.new("TextButton", G2L["3"]);
- G2L["e"]["TextWrapped"] = true;
- G2L["e"]["BorderSizePixel"] = 0;
- G2L["e"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["e"]["TextSize"] = 14;
- G2L["e"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["e"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["e"]["Size"] = UDim2.new(0, 80, 0, 40);
- G2L["e"]["Name"] = [[SnowRoom]];
- G2L["e"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["e"]["Text"] = [[SnowRoom]];
- G2L["e"]["Position"] = UDim2.new(0.2925, 0, 0.41935, 0);
- -- StarterGui.HubOil.Drag.Frame.SnowRoom.LocalScript
- G2L["f"] = Instance.new("LocalScript", G2L["e"]);
- -- StarterGui.HubOil.Drag.Frame.UnlockAll
- G2L["10"] = Instance.new("TextButton", G2L["3"]);
- G2L["10"]["TextWrapped"] = true;
- G2L["10"]["BorderSizePixel"] = 0;
- G2L["10"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["10"]["TextSize"] = 14;
- G2L["10"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["10"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["10"]["Size"] = UDim2.new(0, 80, 0, 40);
- G2L["10"]["Name"] = [[UnlockAll]];
- G2L["10"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["10"]["Text"] = [[UnlockAllDoors]];
- G2L["10"]["Position"] = UDim2.new(0.2925, 0, 0.63935, 0);
- -- StarterGui.HubOil.Drag.Frame.UnlockAll.LocalScript
- G2L["11"] = Instance.new("LocalScript", G2L["10"]);
- -- StarterGui.HubOil.Drag.TextBox
- G2L["12"] = Instance.new("TextBox", G2L["2"]);
- G2L["12"]["Active"] = false;
- G2L["12"]["Interactable"] = false;
- G2L["12"]["BorderSizePixel"] = 0;
- G2L["12"]["TextWrapped"] = true;
- G2L["12"]["TextSize"] = 14;
- G2L["12"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["12"]["TextScaled"] = true;
- G2L["12"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["12"]["RichText"] = true;
- G2L["12"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["12"]["Selectable"] = false;
- G2L["12"]["ClearTextOnFocus"] = false;
- G2L["12"]["Size"] = UDim2.new(0, 75, 0, 37);
- G2L["12"]["Position"] = UDim2.new(0.72, 0, 0, 0);
- G2L["12"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["12"]["Text"] = [[flex your weather]];
- G2L["12"]["BackgroundTransparency"] = 1;
- -- StarterGui.HubOil.Drag.Smooth GUI Dragging
- G2L["13"] = Instance.new("LocalScript", G2L["2"]);
- G2L["13"]["Name"] = [[Smooth GUI Dragging]];
- -- StarterGui.HubOil.Drag.BackgroundMain
- G2L["14"] = Instance.new("ImageLabel", G2L["2"]);
- G2L["14"]["ZIndex"] = 0;
- G2L["14"]["BorderSizePixel"] = 0;
- G2L["14"]["BackgroundColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["14"]["ScaleType"] = Enum.ScaleType.Crop;
- G2L["14"]["ImageTransparency"] = 0.5;
- G2L["14"]["Image"] = [[http://www.roblox.com/asset/?id=9305457875]];
- G2L["14"]["Size"] = UDim2.new(0, 399, 0, 212);
- G2L["14"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["14"]["BackgroundTransparency"] = 1;
- G2L["14"]["Name"] = [[BackgroundMain]];
- G2L["14"]["Position"] = UDim2.new(0, 0, 1, 0);
- -- StarterGui.HubOil.Drag.Frame
- G2L["15"] = Instance.new("ImageLabel", G2L["2"]);
- G2L["15"]["ZIndex"] = 0;
- G2L["15"]["BorderSizePixel"] = 0;
- G2L["15"]["BackgroundColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["15"]["ScaleType"] = Enum.ScaleType.Slice;
- G2L["15"]["Image"] = [[http://www.roblox.com/asset/?id=10173985980]];
- G2L["15"]["Size"] = UDim2.new(0, 399, 0, 37);
- G2L["15"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["15"]["BackgroundTransparency"] = 1;
- G2L["15"]["Name"] = [[Frame]];
- -- StarterGui.HubOil.Drag.TextBox
- G2L["16"] = Instance.new("TextBox", G2L["2"]);
- G2L["16"]["Active"] = false;
- G2L["16"]["Interactable"] = false;
- G2L["16"]["BorderSizePixel"] = 0;
- G2L["16"]["TextWrapped"] = true;
- G2L["16"]["TextSize"] = 14;
- G2L["16"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["16"]["TextScaled"] = true;
- G2L["16"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["16"]["RichText"] = true;
- G2L["16"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["16"]["Selectable"] = false;
- G2L["16"]["ClearTextOnFocus"] = false;
- G2L["16"]["Size"] = UDim2.new(0, 34, 0, 37);
- G2L["16"]["Position"] = UDim2.new(0.65802, 0, 0, 0);
- G2L["16"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["16"]["Text"] = [[V0.1]];
- G2L["16"]["BackgroundTransparency"] = 1;
- -- StarterGui.HubOil.Drag.TextBox
- G2L["17"] = Instance.new("TextBox", G2L["2"]);
- G2L["17"]["Active"] = false;
- G2L["17"]["Interactable"] = false;
- G2L["17"]["BorderSizePixel"] = 0;
- G2L["17"]["TextWrapped"] = true;
- G2L["17"]["TextSize"] = 14;
- G2L["17"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["17"]["TextScaled"] = true;
- G2L["17"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["17"]["RichText"] = true;
- G2L["17"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["17"]["Selectable"] = false;
- G2L["17"]["ClearTextOnFocus"] = false;
- G2L["17"]["Size"] = UDim2.new(0, -59, 0, 37);
- G2L["17"]["Position"] = UDim2.new(0.33584, 0, 0, 0);
- G2L["17"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["17"]["Text"] = [[Discord:Qelvix]];
- G2L["17"]["BackgroundTransparency"] = 1;
- -- StarterGui.HubOil.Drag.TextBox
- G2L["18"] = Instance.new("TextBox", G2L["2"]);
- G2L["18"]["Active"] = false;
- G2L["18"]["Interactable"] = false;
- G2L["18"]["BorderSizePixel"] = 0;
- G2L["18"]["TextWrapped"] = true;
- G2L["18"]["TextSize"] = 14;
- G2L["18"]["TextColor3"] = Color3.fromRGB(255, 255, 255);
- G2L["18"]["TextScaled"] = true;
- G2L["18"]["BackgroundColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["18"]["RichText"] = true;
- G2L["18"]["FontFace"] = Font.new([[rbxasset://fonts/families/SourceSansPro.json]], Enum.FontWeight.Regular, Enum.FontStyle.Normal);
- G2L["18"]["Selectable"] = false;
- G2L["18"]["ClearTextOnFocus"] = false;
- G2L["18"]["Size"] = UDim2.new(0, -73, 0, 37);
- G2L["18"]["Position"] = UDim2.new(0.18296, 0, 0, 0);
- G2L["18"]["BorderColor3"] = Color3.fromRGB(0, 0, 0);
- G2L["18"]["Text"] = [[Hub by oliver]];
- G2L["18"]["BackgroundTransparency"] = 1;
- -- StarterGui.HubOil.Drag.Frame.Close.LocalScript
- local function C_5()
- local script = G2L["5"];
- script.Parent.MouseButton1Click:Connect(function()
- script.Parent.Parent.Parent.Parent.Parent.HubOil:destroy()
- end)
- end;
- task.spawn(C_5);
- -- StarterGui.HubOil.Drag.Frame.RandomTime.LocalScript
- local function C_7()
- local script = G2L["7"];
- local button = script.Parent
- local enabled = false
- local timeLoop = nil
- local isSafeCall = false
- local blockExternalCalls = false -- новый флаг для блокировки
- local function updateButtonState()
- if enabled then
- button.BackgroundColor3 = Color3.fromRGB(0, 200, 0)
- button.Text = "Time Random: ON"
- else
- button.BackgroundColor3 = Color3.fromRGB(200, 0, 0)
- button.Text = "Time Random: OFF"
- end
- end
- -- Устанавливаем метаметод один раз
- local mt = getrawmetatable(game)
- setreadonly(mt, false)
- if not mt.__timeProtectInstalled then
- local oldNamecall = mt.__namecall
- mt.__namecall = newcclosure(function(self, ...)
- local method = getnamecallmethod()
- -- если защита включена и это не наш безопасный вызов — блокируем
- if blockExternalCalls
- and self.Name == "updateLocalTime"
- and method == "FireServer"
- and not isSafeCall then
- warn("🚫 Заблокирован внешний вызов updateLocalTime")
- return nil
- end
- return oldNamecall(self, ...)
- end)
- mt.__timeProtectInstalled = true
- end
- setreadonly(mt, true)
- button.MouseButton1Click:Connect(function()
- enabled = not enabled
- blockExternalCalls = enabled -- включаем/выключаем защиту
- updateButtonState()
- if enabled then
- -- запускаем цикл, когда включено
- timeLoop = task.spawn(function()
- while enabled do
- task.wait(0.1)
- isSafeCall = true
- local minutes = string.format("%02d", math.random(0, 24))
- local seconds = string.format("%02d", math.random(0, 59))
- local timeString = minutes .. ":" .. seconds
- game:GetService("ReplicatedStorage")
- :WaitForChild("updateLocalTime")
- :FireServer(timeString)
- isSafeCall = false
- end
- end)
- else
- -- при выключении protected вызовы снимаются,
- -- и другие скрипты могут без проблем юзать updateLocalTime
- end
- end)
- -- Инициализация
- updateButtonState()
- end;
- task.spawn(C_7);
- -- StarterGui.HubOil.Drag.Frame.AntiBang.LocalScript
- local function C_9()
- local script = G2L["9"];
- debounce = false
- local originalDestroyHeight = game.Workspace.FallenPartsDestroyHeight
- local newDestroyHeight = originalDestroyHeight - 200
- game.Workspace.FallenPartsDestroyHeight = newDestroyHeight
- -- Рассчитываем позицию платформы посередине
- local platformY = (originalDestroyHeight + newDestroyHeight) / 2
- local player = game.Players.LocalPlayer
- -- Инициализация персонажа
- local function initCharacter()
- character = player.Character or player.CharacterAdded:Wait()
- hrp = character:WaitForChild("HumanoidRootPart")
- originalCFrame = hrp.CFrame
- end
- initCharacter()
- player.CharacterAdded:Connect(initCharacter)
- -- Настройки телепортации
- local isTeleported = false
- local platform = nil
- -- Функция создания платформы (динамическая позиция)
- local function createPlatform()
- if platform and platform.Parent then return end
- -- Берем текущую позицию игрока для X/Z
- local playerPos = hrp.Position
- platform = Instance.new("Part")
- platform.Name = "DynamicPlatform"
- platform.Size = Vector3.new(20, 2, 20)
- platform.Anchored = true
- platform.CanCollide = true
- platform.Material = Enum.Material.Neon
- platform.Color = Color3.fromRGB(0, 255, 255)
- -- Устанавливаем позицию:
- -- X/Z - текущая позиция игрока
- -- Y - расчетная середина
- platform.Position = Vector3.new(
- playerPos.X,
- platformY,
- playerPos.Z
- )
- platform.Parent = workspace
- end
- -- Функции телепортации
- local function teleportToTarget()
- if isTeleported then return end
- isTeleported = true
- originalCFrame = hrp.CFrame
- -- Телепорт на платформу прямо под игроком
- hrp.CFrame = CFrame.new(
- originalCFrame.X,
- platformY + 5, -- 5 единиц выше платформы
- originalCFrame.Z
- )
- createPlatform()
- end
- local function teleportBack()
- if not isTeleported then return end
- isTeleported = false
- hrp.CFrame = originalCFrame
- if platform then
- platform:Destroy()
- platform = nil
- end
- end
- -- Обработка клика мыши
- script.Parent.MouseButton1Click:Connect(function()
- if debounce == false then
- debounce = true
- teleportToTarget()
- wait(0.01)
- teleportBack()
- wait(0.4)
- debounce = false
- end
- end)
- end;
- task.spawn(C_9);
- -- StarterGui.HubOil.Drag.Frame.MysteriousBusinessCard.LocalScript
- local function C_b()
- local script = G2L["b"];
- local button = script.Parent
- local cooldown = false
- -- Объект ClickDetector
- local MysteriousBusinessCard = workspace.ShopFunctional.MysteriousBusinessCard.ClickDetector
- -- Устанавливаем начальное состояние кнопки (зелёный)
- button.BackgroundColor3 = Color3.fromRGB(0, 200, 0)
- button.Text = "MysteriousBusinessCard"
- button.MouseButton1Click:Connect(function()
- if cooldown then
- return -- на паузе, выходим
- end
- cooldown = true
- -- Сразу же переключаем цвет на красный
- button.BackgroundColor3 = Color3.fromRGB(200, 0, 0)
- button.Text = "Cooldown..."
- -- Вызываем ClickDetector
- fireclickdetector(MysteriousBusinessCard)
- -- Ждём 1 секунду, затем возвращаем зелёный
- task.delay(1, function()
- button.BackgroundColor3 = Color3.fromRGB(0, 200, 0)
- button.Text = "Use Card"
- cooldown = false
- end)
- end)
- end;
- task.spawn(C_b);
- -- StarterGui.HubOil.Drag.Frame.AntiKnockback.LocalScript
- local function C_d()
- local script = G2L["d"];
- local button = script.Parent
- local AntiSitBypass = false
- local isSafeSit = false
- local cooldown = false
- -- Обновление состояния кнопки
- local function updateButton()
- if AntiSitBypass then
- button.BackgroundColor3 = Color3.fromRGB(0, 200, 0)
- button.Text = "AntiKnockBack: ON"
- else
- button.BackgroundColor3 = Color3.fromRGB(200, 0, 0)
- button.Text = "AntiKnockBack: OFF"
- end
- end
- -- === Защита принудительного Sit через __newindex ===
- do
- local mt = getrawmetatable(game)
- setreadonly(mt, false)
- local oldNewIndex = mt.__newindex
- mt.__newindex = newcclosure(function(self, key, value)
- -- блокируем только внешние Sit=true, когда нет SeatPart
- if AntiSitBypass
- and self:IsA("Humanoid")
- and key == "Sit"
- and value == true
- and not isSafeSit
- and self.SeatPart == nil then
- warn("🚫 blocked try sit")
- return
- end
- return oldNewIndex(self, key, value)
- end)
- setreadonly(mt, true)
- end
- -- === Отмена авто-сидения без SeatPart ===
- local Players = game:GetService("Players")
- local plr = Players.LocalPlayer
- local function onCharacterAdded(char)
- local hum = char:WaitForChild("Humanoid")
- hum:GetPropertyChangedSignal("Sit"):Connect(function()
- -- если включена защита, и сидим без реального SeatPart — сразу отменяем
- if AntiSitBypass and hum.Sit and hum.SeatPart == nil then
- isSafeSit = true
- hum.Sit = false
- isSafeSit = false
- end
- end)
- end
- if plr.Character then
- onCharacterAdded(plr.Character)
- end
- plr.CharacterAdded:Connect(onCharacterAdded)
- -- === GUI-кнопка с кд 1 сек ===
- updateButton()
- button.MouseButton1Click:Connect(function()
- if cooldown then return end
- cooldown = true
- AntiSitBypass = not AntiSitBypass
- updateButton()
- task.delay(1, function()
- cooldown = false
- end)
- end)
- end;
- task.spawn(C_d);
- -- StarterGui.HubOil.Drag.Frame.SnowRoom.LocalScript
- local function C_f()
- local script = G2L["f"];
- local Players = game:GetService("Players")
- local plr = Players.LocalPlayer
- local button = script.Parent
- local cooldown = false
- local teleported = false
- local lastCFrame
- -- Целевой CFrame для «SecretRoom»
- local secretCFrame = CFrame.new(
- -81.9071579, 4.54490328, 12.2773209,
- 0.205820113, 0, -0.978589833,
- 0, 1, 0,
- 0.978589833, 0, 0.205820113
- )
- -- Обновление состояния кнопки
- local function setButton(state)
- if state == "ready" then
- button.BackgroundColor3 = Color3.fromRGB(0, 200, 0)
- button.Text = "Teleport SnowRoom"
- else -- "return"
- button.BackgroundColor3 = Color3.fromRGB(200, 0, 0)
- button.Text = "Return"
- end
- end
- -- Инициализация вида кнопки
- setButton("ready")
- button.MouseButton1Click:Connect(function()
- if cooldown then return end
- cooldown = true
- local char = plr.Character
- local hrp = char and char:FindFirstChild("HumanoidRootPart")
- if hrp then
- if not teleported then
- -- сохраняем текущую позицию
- lastCFrame = hrp.CFrame
- -- телепортируем в секретную комнату
- hrp.CFrame = secretCFrame
- teleported = true
- setButton("return")
- else
- -- возвращаемся на сохранённую позицию
- hrp.CFrame = lastCFrame
- teleported = false
- setButton("ready")
- end
- end
- -- сброс кд через 1 секунду
- task.delay(1, function()
- cooldown = false
- end)
- end)
- end;
- task.spawn(C_f);
- -- StarterGui.HubOil.Drag.Frame.UnlockAll.LocalScript
- local function C_11()
- local script = G2L["11"];
- local button = script.Parent
- local toggled = false
- -- Таблица с объектами, которые нужно скрывать/открывать
- local blocksToToggle = {
- workspace.american.american,
- workspace.rainy,
- workspace.sunny,
- workspace.weatherPlus
- }
- -- Обновление состояния объектов
- local function setObjectsState(state)
- for _, part in ipairs(blocksToToggle) do
- if part and part:IsA("BasePart") then
- part.CanCollide = not state
- part.CanTouch = not state
- part.Transparency = state and 1 or 0
- end
- end
- end
- -- Обновление состояния кнопки
- local function updateButton()
- if toggled then
- button.BackgroundColor3 = Color3.fromRGB(0, 200, 0) -- зелёный
- button.Text = "Unlock all : on"
- else
- button.BackgroundColor3 = Color3.fromRGB(200, 0, 0) -- красный
- button.Text = "Unlock all : off"
- end
- setObjectsState(toggled)
- end
- -- Инициализация
- updateButton()
- -- Обработка нажатия
- button.MouseButton1Click:Connect(function()
- toggled = not toggled
- updateButton()
- end)
- end;
- task.spawn(C_11);
- -- StarterGui.HubOil.Drag.Smooth GUI Dragging
- local function C_13()
- local script = G2L["13"];
- local UserInputService = game:GetService("UserInputService")
- local runService = (game:GetService("RunService"));
- local gui = script.Parent
- local dragging
- local dragInput
- local dragStart
- local startPos
- function Lerp(a, b, m)
- return a + (b - a) * m
- end;
- local lastMousePos
- local lastGoalPos
- local DRAG_SPEED = (8); -- // The speed of the UI darg.
- function Update(dt)
- if not (startPos) then return end;
- if not (dragging) and (lastGoalPos) then
- gui.Position = UDim2.new(startPos.X.Scale, Lerp(gui.Position.X.Offset, lastGoalPos.X.Offset, dt * DRAG_SPEED), startPos.Y.Scale, Lerp(gui.Position.Y.Offset, lastGoalPos.Y.Offset, dt * DRAG_SPEED))
- return
- end;
- local delta = (lastMousePos - UserInputService:GetMouseLocation())
- local xGoal = (startPos.X.Offset - delta.X);
- local yGoal = (startPos.Y.Offset - delta.Y);
- lastGoalPos = UDim2.new(startPos.X.Scale, xGoal, startPos.Y.Scale, yGoal)
- gui.Position = UDim2.new(startPos.X.Scale, Lerp(gui.Position.X.Offset, xGoal, dt * DRAG_SPEED), startPos.Y.Scale, Lerp(gui.Position.Y.Offset, yGoal, dt * DRAG_SPEED))
- end;
- gui.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- dragging = true
- dragStart = input.Position
- startPos = gui.Position
- lastMousePos = UserInputService:GetMouseLocation()
- input.Changed:Connect(function()
- if input.UserInputState == Enum.UserInputState.End then
- dragging = false
- end
- end)
- end
- end)
- gui.InputChanged:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then
- dragInput = input
- end
- end)
- runService.Heartbeat:Connect(Update)
- end;
- task.spawn(C_13);
- return G2L["1"], require;
Advertisement
Add Comment
Please, Sign In to add comment