Advertisement
Dark_Agent

Oxide limb reanim old 1

Jun 26th, 2025
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 12.14 KB | Gaming | 0 0
  1. local roothidecf = CFrame.new(0, -255, 0)
  2.  
  3. if not game.IsLoaded then
  4.     game.Loaded:Wait()
  5. end
  6. local desiredmode = false
  7.  
  8. local zeropointone = 0.1
  9. local twait = task.wait
  10. local tspawn = task.spawn
  11. local currentfakechar = nil
  12. local vector3zero = Vector3.zero
  13. local getgenv = getgenv or function()
  14.         return _G
  15.     end
  16.  
  17. local NaN = 0 / 0
  18.  
  19. local dummypart = Instance.new("Part")
  20.  
  21. local GetDescendants = dummypart.GetDescendants
  22. local IsA = dummypart.IsA
  23. local Destroy = dummypart.Destroy
  24.  
  25. local math_random = math.random
  26. local Vector3_new = Vector3.new
  27.  
  28. local usedefaultanims = false
  29.  
  30. local transparency_level = 1
  31.  
  32. local disablescripts = true
  33.  
  34. local fakecollisions = true
  35.  
  36. local nametoexcludefromtransparency = {}
  37.  
  38. local parentrealchartofakechar = false
  39.  
  40. local respawncharacter = (function()
  41.     if _G["Respawn character"] == nil then
  42.         return true
  43.     else
  44.         return _G["Respawn character"]
  45.     end
  46. end)()
  47.  
  48. local instantrespawn = true
  49.  
  50. local LocalPlayer = game:GetService("Players").LocalPlayer
  51.  
  52. local exploit = "shitsploit"
  53.  
  54. if not LocalPlayer.Character then
  55.     LocalPlayer.CharacterAdded:Wait()
  56.     twait(zeropointone)
  57.     if LocalPlayer.Character:FindFirstChildOfClass("Humanoid").RigType ~= Enum.HumanoidRigType.R6 then
  58.         error("Script is only compatible with R6 type rigs")
  59.         return
  60.     end
  61. end
  62.  
  63. local function removeAnims(character)
  64.     if character == currentfakechar then
  65.         return
  66.     end
  67.     local humanoid = character:WaitForChild("Humanoid", 5)
  68.     local animator = humanoid:FindFirstChildWhichIsA("Animator")
  69.     if animator then
  70.         Destroy(animator)
  71.     end
  72.     local animateScript = character:FindFirstChild("Animate")
  73.     if animateScript then
  74.         Destroy(animateScript)
  75.     end
  76.     local a = nil
  77.     a =
  78.         humanoid.DescendantAdded:Connect(
  79.         function(child)
  80.             if child:IsA("Animator") then
  81.                 Destroy(child)
  82.                 a:Disconnect()
  83.                 a = nil
  84.             end
  85.         end
  86.     )
  87. end
  88.  
  89. LocalPlayer.CharacterAdded:Once(removeAnims)
  90.  
  91. _G.OxideRealChar = LocalPlayer.Character
  92. LocalPlayer.Character.Archivable = true
  93. local originalChar = LocalPlayer.Character
  94. local char = originalChar:Clone()
  95. char.Name = "non"
  96. local signaldiedbackend = LocalPlayer.ConnectDiedSignalBackend
  97. local signalkill = LocalPlayer.Kill
  98.  
  99. if respawncharacter then
  100.     if instantrespawn then
  101.         if replicatesignal then
  102.             replicatesignal(signaldiedbackend)
  103.             twait(game.Players.RespawnTime - 0.05)
  104.             replicatesignal(signalkill)
  105.             LocalPlayer.CharacterAdded:Wait()
  106.             char.Parent = workspace
  107.             currentfakechar = char
  108.         end
  109.     else
  110.         originalChar:BreakJoints()
  111.         LocalPlayer.CharacterAdded:Wait()
  112.         char.Parent = workspace
  113.         currentfakechar = char
  114.     end
  115. end
  116.  
  117. twait(zeropointone)
  118.  
  119. local newChar = LocalPlayer.Character
  120. newChar.Archivable = true
  121.  
  122. if disablescripts then
  123.     tspawn(
  124.         function()
  125.             for _, obj in ipairs(char:GetChildren()) do
  126.                 if obj:IsA("LocalScript") then
  127.                     obj.Enabled = false
  128.                 end
  129.             end
  130.         end
  131.     )
  132. end
  133.  
  134. for _, part in ipairs(char:GetDescendants()) do
  135.     if part:IsA("BasePart") or part:IsA("Decal") then
  136.         part.Transparency = transparency_level
  137.     end
  138. end
  139.  
  140. twait(0.4)
  141. LocalPlayer.Character.Parent = char
  142. LocalPlayer.Character = char
  143. if parentrealchartofakechar then
  144.     newChar.Parent = char
  145. end
  146. _G.OxideRealChar = char
  147.  
  148. char.Humanoid.RequiresNeck = false
  149. char.Humanoid:SetStateEnabled(15, false)
  150.  
  151. local newcharTorso = newChar:WaitForChild("Torso")
  152. local fakecharTorso = char:WaitForChild("Torso")
  153. local newcharRoot = newChar:WaitForChild("HumanoidRootPart")
  154. local fakecharRoot = char:WaitForChild("HumanoidRootPart")
  155.  
  156. local limbmapping = {
  157.     Neck = char:WaitForChild("Head"),
  158.     RootJoint = char:WaitForChild("Torso"),
  159.     ["Left Shoulder"] = char:WaitForChild("Left Arm"),
  160.     ["Right Shoulder"] = char:WaitForChild("Right Arm"),
  161.     ["Left Hip"] = char:WaitForChild("Left Leg"),
  162.     ["Right Hip"] = char:WaitForChild("Right Leg")
  163. }
  164.  
  165. local jointmapping = {
  166.     Neck = newcharTorso:WaitForChild("Neck"),
  167.     RootJoint = newChar.HumanoidRootPart:WaitForChild("RootJoint"),
  168.     ["Left Shoulder"] = newcharTorso:WaitForChild("Left Shoulder"),
  169.     ["Right Shoulder"] = newcharTorso:WaitForChild("Right Shoulder"),
  170.     ["Left Hip"] = newcharTorso:WaitForChild("Left Hip"),
  171.     ["Right Hip"] = newcharTorso:WaitForChild("Right Hip")
  172. }
  173.  
  174. local function RCA6dToCFrame(Motor6D, TargetPart, ReferencePart)
  175.     local rel = ReferencePart.CFrame:Inverse() * TargetPart.CFrame
  176.     local delta = Motor6D.C0:Inverse() * rel * Motor6D.C1
  177.     local axis, angle = delta:ToAxisAngle()
  178.     local newangle = axis * angle
  179.     local offset = Vector3.zero
  180.     if TargetPart:FindFirstChildOfClass("SpecialMesh") then
  181.         offset = TargetPart:FindFirstChildOfClass("SpecialMesh").Offset
  182.     end
  183.     sethiddenproperty(Motor6D, "ReplicateCurrentOffset6D", delta.Position + offset)
  184.     sethiddenproperty(Motor6D, "ReplicateCurrentAngle6D", newangle)
  185. end
  186.  
  187. local ToObjectSpace = CFrame.new().ToObjectSpace
  188. local ToEulerAnglesXYZ = CFrame.new().ToEulerAnglesXYZ
  189. local task_spawn = task.spawn
  190. local function stepReanimate()
  191.     --// YES the code is badly formatted YES the code barely works
  192.     --// YES it is unstable. im working on a fix.
  193.     for joint, limb in pairs(limbmapping) do
  194.         local realJoint = jointmapping[joint]
  195.         realJoint.MaxVelocity = 9e9
  196.     end
  197.     task_spawn(
  198.         function()
  199.             for joint, limb in pairs(limbmapping) do
  200.                 newcharRoot.CFrame = roothidecf + Vector3_new(0, 0, math_random(1, 2) / 326.19)
  201.                 newcharRoot.Velocity = vector3zero
  202.                 newcharRoot.RotVelocity = vector3zero
  203.                 local relativecframe = ToObjectSpace(limb.CFrame, fakecharTorso.CFrame)
  204.                 local pitch, yaw, _ = ToEulerAnglesXYZ(relativecframe)
  205.                 local angle = 0
  206.  
  207.                 if joint == "Neck" then
  208.                     angle = -yaw
  209.                 elseif joint == "Left Shoulder" or joint == "Left Hip" then
  210.                     angle = pitch
  211.                 elseif joint == "Right Shoulder" or joint == "Right Hip" then
  212.                     angle = -pitch
  213.                 end
  214.                 local realJoint = jointmapping[joint]
  215.  
  216.                 realJoint:SetDesiredAngle(angle)
  217.                 realJoint.MaxVelocity = 9e9
  218.                 if joint == "RootJoint" then
  219.                     RCA6dToCFrame(realJoint, fakecharTorso, newcharTorso)
  220.                 else
  221.                     if desiredmode == false then
  222.                         RCA6dToCFrame(realJoint, limb, fakecharTorso)
  223.                     end
  224.                 end
  225.             end
  226.         end
  227.     )
  228. end
  229.  
  230. local function setdestroyheight(height)
  231.     local sucess, result =
  232.         pcall(
  233.         function()
  234.             workspace.FallenPartsDestroyHeight = height
  235.         end
  236.     )
  237.     if not sucess then
  238.     end
  239. end
  240.  
  241. local currentheight = workspace.FallenPartsDestroyHeight
  242.  
  243. local function flinginternal(character, time)
  244.     local time = time or 5
  245.  
  246.     flinging = true
  247.     local start = tick()
  248.     local connection
  249.     connection =
  250.         game:GetService("RunService").Heartbeat:Connect(
  251.         function()
  252.             if tick() - start >= time then
  253.                 setdestroyheight(currentheight)
  254.                 flinging = false
  255.                 connection:Disconnect()
  256.             --break
  257.             end
  258.             if character then
  259.                 if character:FindFirstChild("HumanoidRootPart") then
  260.                     local velocity = character.HumanoidRootPart.Velocity
  261.                     local direction = velocity.Magnitude > 1 and velocity.Unit or Vector3_new(0, 0, 0)
  262.                     local predictedPosition =
  263.                         (character.PrimaryPart.CFrame or character.HumanoidRootPart.CFrame).Position +
  264.                         direction * math_random(5, 12)
  265.  
  266.                     newcharRoot.CFrame = CFrame.new(predictedPosition)
  267.                     newcharRoot.Velocity = Vector3_new(9e7, 9e7 * 10, 9e7)
  268.                     newcharRoot.RotVelocity = Vector3_new(9e8, 9e8, 9e8)
  269.                 else
  270.                     --break
  271.                     flinging = false
  272.                     connection:Disconnect()
  273.                 end
  274.             else
  275.                 --break
  276.                 flinging = false
  277.                 connection:Disconnect()
  278.             end
  279.         end
  280.     )
  281. end
  282.  
  283. getgenv().fling = function(character, time, yield)
  284.     setdestroyheight(NaN)
  285.     local yield = yield or false
  286.     if yield then
  287.         flinginternal(character, time)
  288.     else
  289.         tspawn(flinginternal, character, time)
  290.     end
  291. end
  292.  
  293. local function disableCollisions()
  294.     pcall(
  295.         function()
  296.             for _, char in ipairs({newChar}) do
  297.                 for _, obj in ipairs(GetDescendants(char)) do
  298.                     if IsA(obj, "BasePart") then
  299.                         obj.CanCollide = false
  300.                         obj.Massless = true
  301.                     end
  302.                 end
  303.             end
  304.         end
  305.     )
  306. end
  307.  
  308. local function disableCollisionsWithFakeChar()
  309.     pcall(
  310.         function()
  311.             for _, char in ipairs({newChar, char}) do
  312.                 for _, obj in ipairs(GetDescendants(char)) do
  313.                     if IsA(obj, "BasePart") then
  314.                         obj.CanCollide = false
  315.                         obj.Massless = true
  316.                     end
  317.                 end
  318.             end
  319.         end
  320.     )
  321. end
  322.  
  323. local RunService = game:GetService("RunService")
  324.  
  325. RunService.Heartbeat:Connect(stepReanimate)
  326.  
  327. local humanoidnewchar = newChar:WaitForChild("Humanoid")
  328.  
  329. humanoidnewchar.PlatformStand = true
  330. humanoidnewchar.AutoRotate = false
  331.  
  332. if fakecollisions then
  333.     RunService.PreSimulation:Connect(disableCollisions)
  334. else
  335.     RunService.PreSimulation:Connect(disableCollisionsWithFakeChar)
  336. end
  337.  
  338. workspace.CurrentCamera.CameraSubject = char:WaitForChild("Humanoid")
  339.  
  340. finished = true
  341.  
  342. local uis = game:GetService("UserInputService")
  343. uis.InputBegan:Connect(
  344.     function(k, chatting)
  345.         if chatting then
  346.             return
  347.         end
  348.         if k.KeyCode == Enum.KeyCode.Comma then
  349.             desiredmode = not desiredmode
  350.         elseif k.KeyCode == Enum.KeyCode.Minus then
  351.             roothidecf = fakecharRoot.CFrame
  352.         end
  353.     end
  354. )
  355. newcharRoot.Transparency = 0.5
  356. local speaker = game:GetService("Players").LocalPlayer
  357. local Players = game:GetService("Players")
  358. local RunService = game:GetService("RunService")
  359. antifling =
  360.     RunService.Stepped:Connect(
  361.     function()
  362.         for _, player in pairs(Players:GetPlayers()) do
  363.             if player ~= speaker and player.Character then
  364.                 for _, v in pairs(player.Character:GetDescendants()) do
  365.                     if v:IsA("BasePart") then
  366.                         v.CanCollide = false
  367.                     end
  368.                 end
  369.             end
  370.         end
  371.     end
  372. )
  373. local seatdebounce = 3
  374. local cansit = true
  375. char:FindFirstChild("Left Leg").Touched:Connect(
  376.     function(p)
  377.         if p:IsA("Seat") and cansit == true then
  378.             local sw = Instance.new("Weld", p)
  379.             sw.Name = "SeatWeld"
  380.             sw.Part0 = p
  381.             sw.Part1 = char:FindFirstChild("HumanoidRootPart")
  382.             sw.C0 = CFrame.new(0, 0.2, 0, 1, 0, -0, 0, 0, 1, 0, -1, 0)
  383.             sw.C1 = CFrame.new(0, -1.5, 0, 1, 0, -0, 0, 0, 1, 0, -1, 0)
  384.             char:FindFirstChildOfClass("Humanoid").Sit = true
  385.             char:FindFirstChildOfClass("Humanoid").Jumping:Wait()
  386.             sw:Destroy()
  387.             char:FindFirstChildOfClass("Humanoid").Sit = false
  388.             cansit = false
  389.             task.spawn(
  390.                 function()
  391.                     task.wait(seatdebounce)
  392.                     cansit = true
  393.                 end
  394.             )
  395.         end
  396.     end
  397. )
  398. pcall(
  399.     function()
  400.         char.ForceField:Destroy()
  401.     end
  402. )
  403. pcall(
  404.     function()
  405.         char.OverheadGUI:Destroy()
  406.     end
  407. )
  408.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement