Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- return function()
- warn('RE ANIM FUNCTION BY RETRO_JONO')
- local p = game:GetService('Players').LocalPlayer
- if _G.NetOn == nil then
- --_G.NetOn = true
- game:GetService('RunService').RenderStepped:Connect(function()
- settings().Physics.AllowSleep = false
- sethiddenproperty(p,'MaximumSimulationRadius',math.huge)
- sethiddenproperty(p,'SimulationRadius',math.huge)
- end)
- end
- local c = p.Character
- local spos = c.HumanoidRootPart.CFrame
- c.Archivable = true
- local cc = c:Clone()
- local fc = Instance.new('Model',workspace)
- local pa = Instance.new('Part',fc)
- pa.Anchored = true
- pa.Transparency = 1
- pa.Name = 'Head'
- local pa = Instance.new('Part',fc)
- pa.Anchored = true
- pa.Transparency = 1
- pa.Name = 'Torso'
- Instance.new('Humanoid',fc)
- p.Character = fc
- local hc = p.Character.Humanoid:Clone()
- p.Character.Humanoid.Name = 'HumanoidF'
- hc.Parent = p.Character
- p.Character.HumanoidF:Destroy()
- wait(5.65)
- wait()
- p.Character.Humanoid.Health = 0
- p.Character = workspace[p.Name]
- wait(5.65)
- wait()
- p.Character.Humanoid.Health = 0
- local c = p.Character
- cc.Parent = workspace
- cc.HumanoidRootPart.CFrame = spos
- cc.Humanoid.BreakJointsOnDeath = false
- cc.Name = 'ClonedChar'
- local dc = workspace[p.Name]
- local flingpart = dc.HumanoidRootPart
- flingpart.Massless = true
- flingpart.CustomPhysicalProperties = PhysicalProperties.new(0,0,0)
- cc.DescendantAdded:Connect(function(v)
- pcall(function()
- v.Massless = true
- v.Changed:Connect(function()
- v.Massless = true
- end)
- end)
- end)
- workspace.CurrentCamera.CameraSubject = cc.Humanoid
- local campart = Instance.new('Part',workspace)
- campart.Anchored = true
- campart.Transparency = 1
- campart.CanCollide = false
- campart.Locked = true
- campart.Size = Vector3.new(0.5,0.5,0.5)
- game:GetService('RunService').RenderStepped:Connect(function()
- local lv = workspace.CurrentCamera.CFrame.LookVector
- campart.CFrame = CFrame.new(cc.HumanoidRootPart.Position,Vector3.new(lv.X*9999,lv.Y,lv.Z*9999))
- end)
- local humanoid = cc.Humanoid
- local UIS = game:GetService('UserInputService')
- local wd,ad,sd,dd,jd = false,false,false,false,false
- UIS.InputBegan:Connect(function(i,gp)
- if gp then return end
- if i.KeyCode == Enum.KeyCode.W or i.KeyCode == Enum.KeyCode.Up then wd = true end
- if i.KeyCode == Enum.KeyCode.A then ad = true end
- if i.KeyCode == Enum.KeyCode.S or i.KeyCode == Enum.KeyCode.Down then sd = true end
- if i.KeyCode == Enum.KeyCode.D then dd = true end
- if i.KeyCode == Enum.KeyCode.Space then jd = true end
- end)
- UIS.InputEnded:Connect(function(i,gp)
- if gp then return end
- if i.KeyCode == Enum.KeyCode.W or i.KeyCode == Enum.KeyCode.Up then wd = false end
- if i.KeyCode == Enum.KeyCode.A then ad = false end
- if i.KeyCode == Enum.KeyCode.S or i.KeyCode == Enum.KeyCode.Down then sd = false end
- if i.KeyCode == Enum.KeyCode.D then dd = false end
- if i.KeyCode == Enum.KeyCode.Space then jd = false end
- end)
- game:GetService('RunService').RenderStepped:Connect(function()
- local cf = campart.CFrame
- if wd then cf = cf * CFrame.new(0,0,-10) end
- if ad then cf = cf * CFrame.new(-10,0,0) end
- if sd then cf = cf * CFrame.new(0,0,10) end
- if dd then cf = cf * CFrame.new(10,0,0) end
- cf = cf.Position
- humanoid.WalkToPoint = cf
- if jd then
- humanoid.Jump = true
- else
- humanoid.Jump = false
- end
- end)
- local function align(a,b)
- local a0 = Instance.new('Attachment',a)
- local a1 = Instance.new('Attachment',b)
- local ap = Instance.new('AlignPosition',a)
- ap.RigidityEnabled = false
- ap.ReactionForceEnabled = false
- ap.ApplyAtCenterOfMass = true
- ap.MaxForce = 67752
- ap.MaxVelocity = math.huge / 9e110
- ap.Responsiveness = 0
- ap.Attachment0 = a0
- ap.Attachment1 = a1
- local ao = Instance.new('AlignOrientation',a)
- ao.RigidityEnabled = false
- ao.ReactionTorqueEnabled = true
- ao.PrimaryAxisOnly = false
- ao.MaxTorque = 67752
- ao.MaxAngularVelocity = math.huge / 9e110
- ao.Responsiveness = 0
- ao.Attachment0 = a0
- ao.Attachment1 = a1
- return ap,ao
- end
- local names = {'Head','Torso','Left Arm','Right Arm','Left Leg','Right Leg'}
- for _,v in pairs(names) do
- dc[v]:BreakJoints()
- dc[v].Massless = true
- cc[v].Massless = false
- cc[v].CustomPhysicalProperties = PhysicalProperties.new(999,999,999)
- local nc = Instance.new('NoCollisionConstraint',dc[v])
- nc.Part0 = dc[v]
- nc.Part1 = cc[v]
- align(dc[v],cc[v])
- end
- for _,v in pairs(dc:GetChildren()) do
- if v:IsA('Accessory') then
- pcall(function()
- if v.Handle:FindFirstChild('AccessoryWeld') then
- v.Handle:BreakJoints()
- v.Handle.Massless = true
- v.Handle.CanCollide = false
- align(v.Handle,cc[v.Name].Handle)
- end
- end)
- end
- end
- game:GetService('RunService').RenderStepped:Connect(function()
- for _,v in pairs(dc:GetChildren()) do
- pcall(function()
- v.Transparency = 0.6
- v.CanCollide = false
- v.Massless = true
- if v ~= flingpart then
- v.CFrame = cc[v.Name].CFrame
- --v.Velocity = Vector3.new(0,0,0)
- --v.RotVelocity = Vector3.new(0,0,0)
- end
- end)
- pcall(function()
- if v:IsA('Accessory') then
- v.Handle.CFrame = cc[v.Name].Handle.CFrame
- end
- end)
- end
- for _,v in pairs(cc:GetChildren()) do
- pcall(function()
- v.CanCollide = false
- end)
- end
- end)
- flingpart.Massless = true
- flingpart:BreakJoints()
- return cc, flingpart
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement