Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --// ========== MÓDULO: CLICK TELEPORT (MANTIDO) ========== //
- local ClickTeleportModule = (function()
- local _enabled = false
- local _uiVisible = false
- local _screenGui = nil
- local _mainFrame = nil
- local _minimizedBtn = nil
- local _connections = {}
- local Mouse = LocalPlayer:GetMouse()
- local ClickState = {
- StartTime = 0,
- StartPosition = nil,
- IsValid = false,
- }
- local CTConfig = {
- MaxClickTime = 0.3,
- MaxDragDistance = 10,
- RaycastDistance = 10000,
- TeleportOffset = 3,
- }
- local CTTheme = {
- Background = Color3.fromRGB(25, 25, 35),
- Secondary = Color3.fromRGB(35, 35, 45),
- Accent = Color3.fromRGB(90, 170, 255),
- Success = Color3.fromRGB(90, 255, 140),
- Danger = Color3.fromRGB(255, 90, 90),
- Text = Color3.fromRGB(255, 255, 255),
- TextDim = Color3.fromRGB(180, 180, 200),
- }
- local function _getMouseHit()
- local unitRay = Camera:ScreenPointToRay(Mouse.X, Mouse.Y)
- local raycastParams = RaycastParams.new()
- raycastParams.FilterType = Enum.RaycastFilterType.Blacklist
- raycastParams.FilterDescendantsInstances = {LocalPlayer.Character}
- raycastParams.IgnoreWater = false
- local raycastResult = workspace:Raycast(
- unitRay.Origin,
- unitRay.Direction * CTConfig.RaycastDistance,
- raycastParams
- )
- return raycastResult
- end
- local function _teleportToPosition(position)
- local root = getHumanoidRootPart()
- if not root then return false end
- local currentPosition = root.Position
- local teleportPos = position + Vector3.new(0, CTConfig.TeleportOffset, 0)
- local directionVector = (position - currentPosition)
- local horizontalDirection = Vector3.new(directionVector.X, 0, directionVector.Z)
- local lookDirection = horizontalDirection.Unit
- local targetCFrame = CFrame.new(teleportPos, teleportPos + lookDirection)
- root.CFrame = targetCFrame
- updateStat("TeleportsUsed", 1)
- return true
- end
- local function _isValidClick(startPos, endPos, duration)
- if duration > CTConfig.MaxClickTime then return false end
- local dragDistance = (endPos - startPos).Magnitude
- if dragDistance > CTConfig.MaxDragDistance then return false end
- return true
- end
- local function _updateStatusLabel(text, color)
- if _mainFrame then
- local statusLabel = _mainFrame:FindFirstChild("Container"):FindFirstChild("StatusLabel")
- if statusLabel then
- statusLabel.Text = text
- statusLabel.TextColor3 = color
- end
- end
- end
- local function _enableClickDetection()
- for _, conn in ipairs(_connections) do
- if conn and conn.Connected then
- conn:Disconnect()
- end
- end
- _connections = {}
- table.insert(_connections, UserInputService.InputBegan:Connect(function(input, gameProcessed)
- if gameProcessed then return end
- if not _enabled then return end
- if input.UserInputType == Enum.UserInputType.MouseButton1 or
- input.UserInputType == Enum.UserInputType.Touch then
- ClickState.StartTime = tick()
- ClickState.StartPosition = Vector2.new(Mouse.X, Mouse.Y)
- ClickState.IsValid = true
- end
- end))
- table.insert(_connections, UserInputService.InputEnded:Connect(function(input, gameProcessed)
- if gameProcessed then return end
- if not _enabled then return end
- if not ClickState.IsValid then return end
- if input.UserInputType == Enum.UserInputType.MouseButton1 or
- input.UserInputType == Enum.UserInputType.Touch then
- local clickDuration = tick() - ClickState.StartTime
- local endPosition = Vector2.new(Mouse.X, Mouse.Y)
- if _isValidClick(ClickState.StartPosition, endPosition, clickDuration) then
- local raycastResult = _getMouseHit()
- if raycastResult then
- if _teleportToPosition(raycastResult.Position) then
- _updateStatusLabel("✅ Teleportado!", CTTheme.Success)
- task.wait(1)
- _updateStatusLabel("Clique em qualquer lugar para teleportar", CTTheme.TextDim)
- end
- else
- _updateStatusLabel("❌ Não é possível teleportar para o céu", CTTheme.Danger)
- task.wait(1.5)
- _updateStatusLabel("Clique em qualquer lugar para teleportar", CTTheme.TextDim)
- end
- end
- ClickState.IsValid = false
- end
- end))
- end
- local function _disableClickDetection()
- for _, conn in ipairs(_connections) do
- if conn and conn.Connected then
- conn:Disconnect()
- end
- end
- _connections = {}
- end
- local function _minimizeUI()
- if _mainFrame then
- _mainFrame.Visible = false
- end
- if _minimizedBtn then
- _minimizedBtn.Visible = true
- _minimizedBtn.Size = UDim2.new(0, 0, 0, 0)
- TweenService:Create(_minimizedBtn, TweenInfo.new(0.3, Enum.EasingStyle.Back, Enum.EasingDirection.Out), {
- Size = UDim2.new(0, 50, 0, 50)
- }):Play()
- end
- end
- local function _maximizeUI()
- if _minimizedBtn then
- TweenService:Create(_minimizedBtn, TweenInfo.new(0.2, Enum.EasingStyle.Back, Enum.EasingDirection.In), {
- Size = UDim2.new(0, 0, 0, 0)
- }):Play()
- task.wait(0.2)
- _minimizedBtn.Visible = false
- end
- if _mainFrame then
- _mainFrame.Visible = true
- _mainFrame.Size = UDim2.new(0, 0, 0, 0)
- TweenService:Create(_mainFrame, TweenInfo.new(0.3, Enum.EasingStyle.Back, Enum.EasingDirection.Out), {
- Size = UDim2.new(0, 260, 0, 180)
- }):Play()
- end
- end
- local function _createUI()
- if _screenGui then
- pcall(function() _screenGui:Destroy() end)
- _screenGui = nil
- end
- _screenGui = Instance.new("ScreenGui")
- _screenGui.Name = "ClickTeleportUI_PreHistoria"
- _screenGui.ResetOnSpawn = false
- _screenGui.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
- _screenGui.Parent = CoreGui
- _mainFrame = Instance.new("Frame")
- _mainFrame.Name = "MainFrame"
- _mainFrame.Size = UDim2.new(0, 260, 0, 180)
- _mainFrame.Position = UDim2.new(0.5, -130, 0.5, -90)
- _mainFrame.BackgroundColor3 = CTTheme.Background
- _mainFrame.BackgroundTransparency = 0.05
- _mainFrame.BorderSizePixel = 0
- _mainFrame.Active = true
- _mainFrame.Draggable = true
- _mainFrame.Parent = _screenGui
- local mainCorner = Instance.new("UICorner")
- mainCorner.CornerRadius = UDim.new(0, 12)
- mainCorner.Parent = _mainFrame
- local mainStroke = Instance.new("UIStroke")
- mainStroke.Color = CTTheme.Accent
- mainStroke.Thickness = 2
- mainStroke.Transparency = 0.3
- mainStroke.Parent = _mainFrame
- local bgGradient = Instance.new("UIGradient")
- bgGradient.Color = ColorSequence.new{
- ColorSequenceKeypoint.new(0, Color3.fromRGB(30, 30, 40)),
- ColorSequenceKeypoint.new(1, Color3.fromRGB(20, 20, 30))
- }
- bgGradient.Rotation = 45
- bgGradient.Parent = _mainFrame
- local header = Instance.new("Frame")
- header.Size = UDim2.new(1, 0, 0, 50)
- header.BackgroundColor3 = CTTheme.Secondary
- header.BackgroundTransparency = 0.2
- header.BorderSizePixel = 0
- header.Parent = _mainFrame
- local headerCorner = Instance.new("UICorner")
- headerCorner.CornerRadius = UDim.new(0, 12)
- headerCorner.Parent = header
- local headerFix = Instance.new("Frame")
- headerFix.Size = UDim2.new(1, 0, 0, 12)
- headerFix.Position = UDim2.new(0, 0, 1, -12)
- headerFix.BackgroundColor3 = CTTheme.Secondary
- headerFix.BackgroundTransparency = 0.2
- headerFix.BorderSizePixel = 0
- headerFix.Parent = header
- local title = Instance.new("TextLabel")
- title.Size = UDim2.new(1, -85, 1, 0)
- title.Position = UDim2.new(0, 15, 0, 0)
- title.BackgroundTransparency = 1
- title.Text = "🎯 Click Teleport"
- title.TextColor3 = CTTheme.Text
- title.TextSize = 17
- title.Font = Enum.Font.GothamBold
- title.TextXAlignment = Enum.TextXAlignment.Left
- title.Parent = header
- local minimizeBtn = Instance.new("TextButton")
- minimizeBtn.Size = UDim2.new(0, 35, 0, 35)
- minimizeBtn.Position = UDim2.new(1, -78, 0.5, -17.5)
- minimizeBtn.BackgroundColor3 = Color3.fromRGB(255, 200, 100)
- minimizeBtn.BackgroundTransparency = 0.2
- minimizeBtn.Text = "➖"
- minimizeBtn.TextColor3 = CTTheme.Text
- minimizeBtn.TextSize = 18
- minimizeBtn.Font = Enum.Font.GothamBold
- minimizeBtn.AutoButtonColor = false
- minimizeBtn.Parent = header
- local minimizeCorner = Instance.new("UICorner")
- minimizeCorner.CornerRadius = UDim.new(0, 8)
- minimizeCorner.Parent = minimizeBtn
- local closeBtn = Instance.new("TextButton")
- closeBtn.Size = UDim2.new(0, 35, 0, 35)
- closeBtn.Position = UDim2.new(1, -38, 0.5, -17.5)
- closeBtn.BackgroundColor3 = CTTheme.Danger
- closeBtn.BackgroundTransparency = 0.2
- closeBtn.Text = "✕"
- closeBtn.TextColor3 = CTTheme.Text
- closeBtn.TextSize = 20
- closeBtn.Font = Enum.Font.GothamBold
- closeBtn.AutoButtonColor = false
- closeBtn.Parent = header
- local closeCorner = Instance.new("UICorner")
- closeCorner.CornerRadius = UDim.new(0, 8)
- closeCorner.Parent = closeBtn
- local container = Instance.new("Frame")
- container.Name = "Container"
- container.Size = UDim2.new(1, -20, 1, -60)
- container.Position = UDim2.new(0, 10, 0, 55)
- container.BackgroundTransparency = 1
- container.Parent = _mainFrame
- local toggleBtn = Instance.new("TextButton")
- toggleBtn.Name = "ToggleBtn"
- toggleBtn.Size = UDim2.new(1, 0, 0, 55)
- toggleBtn.Position = UDim2.new(0, 0, 0, 0)
- toggleBtn.BackgroundColor3 = CTTheme.Danger
- toggleBtn.BackgroundTransparency = 0.1
- toggleBtn.Text = "🔴 DESATIVADO"
- toggleBtn.TextColor3 = CTTheme.Text
- toggleBtn.TextSize = 16
- toggleBtn.Font = Enum.Font.GothamBold
- toggleBtn.AutoButtonColor = false
- toggleBtn.Parent = container
- local toggleCorner = Instance.new("UICorner")
- toggleCorner.CornerRadius = UDim.new(0, 10)
- toggleCorner.Parent = toggleBtn
- local toggleStroke = Instance.new("UIStroke")
- toggleStroke.Name = "Stroke"
- toggleStroke.Color = CTTheme.Danger
- toggleStroke.Thickness = 2
- toggleStroke.Transparency = 0.3
- toggleStroke.Parent = toggleBtn
- local statusLabel = Instance.new("TextLabel")
- statusLabel.Name = "StatusLabel"
- statusLabel.Size = UDim2.new(1, 0, 0, 25)
- statusLabel.Position = UDim2.new(0, 0, 0, 65)
- statusLabel.BackgroundTransparency = 1
- statusLabel.Text = "Clique em qualquer lugar para teleportar"
- statusLabel.TextColor3 = CTTheme.TextDim
- statusLabel.TextSize = 12
- statusLabel.Font = Enum.Font.Gotham
- statusLabel.TextWrapped = true
- statusLabel.Parent = container
- local infoLabel = Instance.new("TextLabel")
- infoLabel.Size = UDim2.new(1, 0, 0, 20)
- infoLabel.Position = UDim2.new(0, 0, 0, 92)
- infoLabel.BackgroundTransparency = 1
- infoLabel.Text = "⚡ Teleporte limpo e instantâneo"
- infoLabel.TextColor3 = CTTheme.Success
- infoLabel.TextSize = 11
- infoLabel.Font = Enum.Font.Gotham
- infoLabel.Parent = container
- _minimizedBtn = Instance.new("TextButton")
- _minimizedBtn.Name = "MinimizedBtn"
- _minimizedBtn.Size = UDim2.new(0, 50, 0, 50)
- _minimizedBtn.Position = UDim2.new(1, -60, 0, 10)
- _minimizedBtn.BackgroundColor3 = CTTheme.Accent
- _minimizedBtn.BackgroundTransparency = 0.1
- _minimizedBtn.Text = "🎯"
- _minimizedBtn.TextColor3 = CTTheme.Text
- _minimizedBtn.TextSize = 24
- _minimizedBtn.Font = Enum.Font.GothamBold
- _minimizedBtn.AutoButtonColor = false
- _minimizedBtn.Visible = false
- _minimizedBtn.Active = true
- _minimizedBtn.Draggable = true
- _minimizedBtn.Parent = _screenGui
- local minimizedCorner = Instance.new("UICorner")
- minimizedCorner.CornerRadius = UDim.new(0, 12)
- minimizedCorner.Parent = _minimizedBtn
- local minimizedStroke = Instance.new("UIStroke")
- minimizedStroke.Color = CTTheme.Accent
- minimizedStroke.Thickness = 2
- minimizedStroke.Parent = _minimizedBtn
- local minimizedGradient = Instance.new("UIGradient")
- minimizedGradient.Color = ColorSequence.new{
- ColorSequenceKeypoint.new(0, Color3.fromRGB(100, 180, 255)),
- ColorSequenceKeypoint.new(1, Color3.fromRGB(70, 140, 255))
- }
- minimizedGradient.Rotation = 90
- minimizedGradient.Parent = _minimizedBtn
- toggleBtn.MouseButton1Click:Connect(function()
- _enabled = not _enabled
- if _enabled then
- toggleBtn.Text = "🟢 ATIVADO"
- toggleBtn.BackgroundColor3 = CTTheme.Success
- toggleStroke.Color = CTTheme.Success
- statusLabel.Text = "Clique em qualquer lugar para teleportar"
- _enableClickDetection()
- else
- toggleBtn.Text = "🔴 DESATIVADO"
- toggleBtn.BackgroundColor3 = CTTheme.Danger
- toggleStroke.Color = CTTheme.Danger
- statusLabel.Text = "Teleporte desativado"
- _disableClickDetection()
- end
- end)
- minimizeBtn.MouseButton1Click:Connect(function()
- _minimizeUI()
- end)
- _minimizedBtn.MouseButton1Click:Connect(function()
- _maximizeUI()
- end)
- closeBtn.MouseButton1Click:Connect(function()
- _enabled = false
- _disableClickDetection()
- if _screenGui then
- pcall(function() _screenGui:Destroy() end)
- _screenGui = nil
- _mainFrame = nil
- _minimizedBtn = nil
- end
- _uiVisible = false
- Config.ClickTeleportEnabled = false
- Rayfield:Notify({
- Title = "🎯 Click Teleport",
- Content = "Desativado completamente",
- Duration = 1,
- Image = 4483362458
- })
- end)
- local function addHoverEffect(button, normalTrans)
- button.MouseEnter:Connect(function()
- TweenService:Create(button, TweenInfo.new(0.2), {
- BackgroundTransparency = 0
- }):Play()
- end)
- button.MouseLeave:Connect(function()
- TweenService:Create(button, TweenInfo.new(0.2), {
- BackgroundTransparency = normalTrans or 0.1
- }):Play()
- end)
- end
- addHoverEffect(toggleBtn, 0.1)
- addHoverEffect(minimizeBtn, 0.2)
- addHoverEffect(closeBtn, 0.2)
- addHoverEffect(_minimizedBtn, 0.1)
- _uiVisible = true
- end
- return {
- Init = function()
- print("✅ Módulo Click Teleport inicializado")
- end,
- Toggle = function(state)
- Config.ClickTeleportEnabled = state
- if state then
- if not _uiVisible then
- _createUI()
- Rayfield:Notify({
- Title = "🎯 Click Teleport",
- Content = "Interface aberta!",
- Duration = 1,
- Image = 4483362458
- })
- end
- else
- if _screenGui then
- _enabled = false
- _disableClickDetection()
- pcall(function() _screenGui:Destroy() end)
- _screenGui = nil
- _mainFrame = nil
- _minimizedBtn = nil
- end
- _uiVisible = false
- Rayfield:Notify({
- Title = "🎯 Click Teleport",
- Content = "Desativado",
- Duration = 1,
- Image = 4483362458
- })
- end
- end,
- Cleanup = function()
- _enabled = false
- _disableClickDetection()
- if _screenGui then
- pcall(function() _screenGui:Destroy() end)
- _screenGui = nil
- _mainFrame = nil
- _minimizedBtn = nil
- end
- _uiVisible = false
- print("🧹 Click Teleport limpo")
- end,
- IsEnabled = function()
- return Config.ClickTeleportEnabled
- end
- }
- end)()
- ClickTeleportModule.Init()
- --// ========== SISTEMA DE NÍVEL DO DINO (MANTIDO) ========== //
- local function getDinoLevelSilent()
- local now = tick()
- if (now - DinoLevelCache.lastUpdate) < DinoLevelCache.updateInterval then
- return DinoLevelCache.value
- end
- local leaderstats = LocalPlayer:FindFirstChild("leaderstats")
- if leaderstats then
- for _, stat in ipairs(leaderstats:GetChildren()) do
- local name = stat.Name:lower()
- if name:find("level") or name:find("lvl") or name:find("nivel") then
- if stat:IsA("IntValue") or stat:IsA("NumberValue") then
- local val = tonumber(stat.Value) or 0
- if val > 0 then
- DinoLevelCache.value = val
- DinoLevelCache.lastUpdate = now
- return val
- end
- end
- end
- end
- end
- local playerGui = LocalPlayer:FindFirstChild("PlayerGui")
- if playerGui then
- for _, gui in ipairs(playerGui:GetDescendants()) do
- if gui:IsA("TextLabel") or gui:IsA("TextBox") then
- local text = gui.Text:lower()
- if text:find("level") or text:find("lvl") or text:find("nivel") then
- local number = text:match("%d+")
- if number then
- local val = tonumber(number)
- if val and val > 0 and val <= 100 then
- DinoLevelCache.value = val
- DinoLevelCache.lastUpdate = now
- return val
- end
- end
- end
- end
- if gui:IsA("IntValue") or gui:IsA("NumberValue") then
- local name = gui.Name:lower()
- if name:find("level") or name:find("lvl") or name:find("nivel") then
- local val = tonumber(gui.Value) or 0
- if val > 0 then
- DinoLevelCache.value = val
- DinoLevelCache.lastUpdate = now
- return val
- end
- end
- end
- end
- end
- local char = LocalPlayer.Character
- if char then
- for _, obj in ipairs(char:GetDescendants()) do
- if obj:IsA("IntValue") or obj:IsA("NumberValue") then
- local name = obj.Name:lower()
- if name:find("level") or name:find("lvl") or name:find("nivel") then
- local val = tonumber(obj.Value) or 0
- if val > 0 then
- DinoLevelCache.value = val
- DinoLevelCache.lastUpdate = now
- return val
- end
- end
- end
- end
- end
- local possibleFolders = {
- workspace:FindFirstChild("Dinosaurs"),
- workspace:FindFirstChild("Pets"),
- workspace:FindFirstChild("NPCs"),
- workspace:FindFirstChild("Creatures"),
- workspace:FindFirstChild("Animals")
- }
- for _, folder in ipairs(possibleFolders) do
- if folder then
- for _, dino in ipairs(folder:GetChildren()) do
- local owner = dino:FindFirstChild("Owner") or dino:FindFirstChild("Player")
- if owner and owner:IsA("ObjectValue") and owner.Value == LocalPlayer then
- for _, obj in ipairs(dino:GetDescendants()) do
- if obj:IsA("IntValue") or obj:IsA("NumberValue") or obj:IsA("StringValue") then
- local name = obj.Name:lower()
- if name:find("level") or name:find("lvl") or name:find("nivel") then
- local val = tonumber(obj.Value) or 0
- if val > 0 then
- DinoLevelCache.value = val
- DinoLevelCache.lastUpdate = now
- return val
- end
- end
- end
- end
- end
- end
- end
- end
- DinoLevelCache.lastUpdate = now
- return DinoLevelCache.value
- end
- --// ========== SISTEMA DE CRISTAIS (MANTIDO) ========== //
- local prioridadeMap = { legendary = 1, epic = 2, rare = 3, bloom = 0, crystal = 4 }
- local function getCrystalRank(name)
- name = name:lower()
- for key, rank in pairs(prioridadeMap) do
- if name:find(key) then return rank end
- end
- return 5
- end
- local function getSortedCrystals()
- local found = {}
- for _, obj in ipairs(workspace:GetDescendants()) do
- if obj:IsA("BasePart") and obj.Parent and obj.Parent:IsA("Model") then
- local rank = getCrystalRank(obj.Parent.Name)
- if rank < 5 then
- table.insert(found, {part = obj, rank = rank})
- end
- end
- end
- table.sort(found, function(a, b) return a.rank < b.rank end)
- local parts = {}
- for _, entry in ipairs(found) do
- table.insert(parts, entry.part)
- if entry.rank == 0 then -- Bloom crystal
- updateStat("CrystalsCollected", 1)
- end
- end
- return parts
- end
- --// ========== [CONTINUA NA PARTE 3 COM ESP, UI E LOOPS] ========== //
Advertisement
Add Comment
Please, Sign In to add comment