Universal Script 📌
1.4k Views
248 Executions

desync roblox script

Universal Script 📌
dyxmy
dyxmyFirst script
7 months ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

red part in the screenshot is the server position ( vector3.new(0, 5, 0)) need support hook's

View Raw
-- code from here https://x64.gg/t/roblox-universal-desync-using-hooks/101
local runService = game:GetService("RunService")
local localPlayer = game:GetService("Players").LocalPlayer

local desyncT = {
   enabled = true,
   loc = CFrame.new()
}

runService.Heartbeat:Connect(function()
    if desyncT.enabled and localPlayer.Character then
        local character = localPlayer.Character
        local root = character:FindFirstChild("HumanoidRootPart")
        if root then
            desyncT.loc = root.CFrame -- setting the real cframe to where we are
            local newCframe = desyncT.loc -- storing the actual cframe
            newCframe = newCframe * CFrame.new(0, -5, 0) -- moving our player down 5 studs (via the desync)
            root.CFrame = newCframe -- setting our root cframe to the new cframe we made (no u will not be able to see this on ur client)
            runService.RenderStepped:Wait() -- waiitiititt
            root.CFrame = desyncT.loc -- reset our players cframe back to where we were beforehand
        end
    end
end)

local desynchook = nil
desynchook = hookmetamethod(game, "__index", newcclosure(function(self, key)
    if desyncT.enabled and not checkcaller() and key == "CFrame" and localPlayer.Character and self == localPlayer.Character.HumanoidRootPart then
        return desyncT.loc
    end
    return desynchook(self, key)
end))


Comments

1
Log in to join the conversation. Login
09uu's profile picture
09uu7 months ago

nice desync

1

More universal scripts

See all
Script hub
186.9k
1.9M
Bumped 47 minutes ago
Key System

Script hub

#13 this week

Verified script badgeAirflow HUB

Script hub
602.2k
52.8k
Bumped 54 minutes ago
Script hub
45.6k
11.1k
Bumped 3 hours ago
Key System
Paid

Script hub

#25 this month

Verified script badgeZekeHub - 58 Games, 1,300+ Features

Universal Script 📌
46
4
Approved 3 hours ago
Script hub
1.7k
9.7k
Bumped 4 hours ago