Advertisement
samuelrichter66

pan

Mar 16th, 2019
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 43.50 KB | None | 0 0
  1. --https://github.com/Mokiros/roblox-FE-compatibility
  2. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  3. local Player,game,owner = owner,game
  4. local RealPlayer = Player
  5. do
  6. print("FE Compatibility code V2 by Mokiros")
  7. local RealPlayer = RealPlayer
  8. script.Parent = RealPlayer.Character
  9.  
  10. --Fake event to make stuff like Mouse.KeyDown work
  11. local Disconnect_Function = function(this)
  12. this[1].Functions[this[2]] = nil
  13. end
  14. local Disconnect_Metatable = {__index={disconnect=Disconnect_Function,Disconnect=Disconnect_Function}}
  15. local FakeEvent_Metatable = {__index={
  16. Connect = function(this,f)
  17. local i = tostring(math.random(0,10000))
  18. while this.Functions[i] do
  19. i = tostring(math.random(0,10000))
  20. end
  21. this.Functions[i] = f
  22. return setmetatable({this,i},Disconnect_Metatable)
  23. end
  24. }}
  25. FakeEvent_Metatable.__index.connect = FakeEvent_Metatable.__index.Connect
  26. local function fakeEvent()
  27. return setmetatable({Functions={}},FakeEvent_Metatable)
  28. end
  29.  
  30. --Creating fake input objects with fake variables
  31. local FakeMouse = {Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
  32. FakeMouse.keyUp = FakeMouse.KeyUp
  33. FakeMouse.keyDown = FakeMouse.KeyDown
  34. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  35. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  36. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  37. end}
  38. --Merged 2 functions into one by checking amount of arguments
  39. CAS.UnbindAction = CAS.BindAction
  40.  
  41. --This function will trigger the events that have been :Connect()'ed
  42. local function TriggerEvent(self,ev,...)
  43. for _,f in pairs(self[ev].Functions) do
  44. f(...)
  45. end
  46. end
  47. FakeMouse.TriggerEvent = TriggerEvent
  48. UIS.TriggerEvent = TriggerEvent
  49.  
  50. --Client communication
  51. local Event = Instance.new("RemoteEvent")
  52. Event.Name = "UserInput_Event"
  53. Event.OnServerEvent:Connect(function(plr,io)
  54. if plr~=RealPlayer then return end
  55. FakeMouse.Target = io.Target
  56. FakeMouse.Hit = io.Hit
  57. if not io.isMouse then
  58. local b = io.UserInputState == Enum.UserInputState.Begin
  59. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  60. return FakeMouse:TriggerEvent(b and "Button1Down" or "Button1Up")
  61. end
  62. if io.UserInputType == Enum.UserInputType.MouseButton2 then
  63. return FakeMouse:TriggerEvent(b and "Button2Down" or "Button2Up")
  64. end
  65. for _,t in pairs(CAS.Actions) do
  66. for _,k in pairs(t.Keys) do
  67. if k==io.KeyCode then
  68. t.Function(t.Name,io.UserInputState,io)
  69. end
  70. end
  71. end
  72. FakeMouse:TriggerEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  73. UIS:TriggerEvent(b and "InputBegan" or "InputEnded",io,false)
  74. end
  75. end)
  76. Event.Parent = NLS([==[local Event = script:WaitForChild("UserInput_Event")
  77. local Mouse = owner:GetMouse()
  78. local UIS = game:GetService("UserInputService")
  79. local input = function(io,RobloxHandled)
  80. if RobloxHandled then return end
  81. --Since InputObject is a client-side instance, we create and pass table instead
  82. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  83. end
  84. UIS.InputBegan:Connect(input)
  85. UIS.InputEnded:Connect(input)
  86.  
  87. local h,t
  88. --Give the server mouse data every second frame, but only if the values changed
  89. --If player is not moving their mouse, client won't fire events
  90. local HB = game:GetService("RunService").Heartbeat
  91. while true do
  92. if h~=Mouse.Hit or t~=Mouse.Target then
  93. h,t=Mouse.Hit,Mouse.Target
  94. Event:FireServer({isMouse=true,Target=t,Hit=h})
  95. end
  96. --Wait 2 frames
  97. for i=1,2 do
  98. HB:Wait()
  99. end
  100. end]==],script)
  101.  
  102. ----Sandboxed game object that allows the usage of client-side methods and services
  103. --Real game object
  104. local RealGame = game
  105.  
  106. --Metatable for fake service
  107. local FakeService_Metatable = {
  108. __index = function(self,k)
  109. local s = rawget(self,"_RealService")
  110. if s then
  111. return typeof(s[k])=="function"
  112. and function(_,...)return s[k](s,...)end or s[k]
  113. end
  114. end,
  115. __newindex = function(self,k,v)
  116. local s = rawget(self,"_RealService")
  117. if s then s[k]=v end
  118. end
  119. }
  120. local function FakeService(t,RealService)
  121. t._RealService = typeof(RealService)=="string" and RealGame:GetService(RealService) or RealService
  122. return setmetatable(t,FakeService_Metatable)
  123. end
  124.  
  125. --Fake game object
  126. local FakeGame = {
  127. GetService = function(self,s)
  128. return rawget(self,s) or RealGame:GetService(s)
  129. end,
  130. Players = FakeService({
  131. LocalPlayer = FakeService({GetMouse=function(self)return FakeMouse end},Player)
  132. },"Players"),
  133. UserInputService = FakeService(UIS,"UserInputService"),
  134. ContextActionService = FakeService(CAS,"ContextActionService"),
  135. RunService = FakeService({
  136. _btrs = {},
  137. RenderStepped = RealGame:GetService("RunService").Heartbeat,
  138. BindToRenderStep = function(self,name,_,fun)
  139. self._btrs[name] = self.Heartbeat:Connect(fun)
  140. end,
  141. UnbindFromRenderStep = function(self,name)
  142. self._btrs[name]:Disconnect()
  143. end,
  144. },"RunService")
  145. }
  146. rawset(FakeGame.Players,"localPlayer",FakeGame.Players.LocalPlayer)
  147. FakeGame.service = FakeGame.GetService
  148. FakeService(FakeGame,game)
  149. --Changing owner to fake player object to support owner:GetMouse()
  150. game,owner = FakeGame,FakeGame.Players.LocalPlayer
  151. end
  152.  
  153.  
  154.  
  155. --By Ruffles14
  156. mouse = game.Players.LocalPlayer:GetMouse()
  157. local rhandclone = game.Players.LocalPlayer.Character.Torso["Right Shoulder"]:Clone()
  158. local rhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  159. rhandweld.Part0 = game.Players.LocalPlayer.Character.Torso
  160. rhandweld.Part1 = game.Players.LocalPlayer.Character["Right Arm"]
  161. rhandweld.C0 = CFrame.new(1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1)
  162. local lhandclone = game.Players.LocalPlayer.Character.Torso["Left Shoulder"]:Clone()
  163. local lhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  164. lhandweld.Part0 = game.Players.LocalPlayer.Character.Torso
  165. lhandweld.Part1 = game.Players.LocalPlayer.Character["Left Arm"]
  166. lhandweld.C0 = CFrame.new(-1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1)
  167. local rootjointclone = game.Players.LocalPlayer.Character.HumanoidRootPart.RootJoint:Clone()
  168. game.Players.LocalPlayer.Character.HumanoidRootPart.RootJoint:Remove()
  169. local humanoidrootpart = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  170. humanoidrootpart.Part0 = game.Players.LocalPlayer.Character.HumanoidRootPart
  171. humanoidrootpart.Part1 = game.Players.LocalPlayer.Character.Torso
  172. local heed = game.Players.LocalPlayer.Character.Torso["Neck"]:Clone()
  173. local headweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  174. headweld.Part0 = game.Players.LocalPlayer.Character.Torso
  175. headweld.Part1 = game.Players.LocalPlayer.Character.Head
  176. headweld.C0 = headweld.C0 * CFrame.new(0,1.5,0)
  177. game.Players.LocalPlayer.Character.Torso.Neck:Remove()
  178. using = false
  179. --Converted with ttyyuu12345's model to script plugin v4
  180. function sandbox(var,func)
  181. local env = getfenv(func)
  182. local newenv = setmetatable({},{
  183. __index = function(self,k)
  184. if k=="script" then
  185. return var
  186. else
  187. return env[k]
  188. end
  189. end,
  190. })
  191. setfenv(func,newenv)
  192. return func
  193. end
  194. cors = {}
  195. mas = Instance.new("Model",game:GetService("Lighting"))
  196. Part0 = Instance.new("Part")
  197. SpecialMesh1 = Instance.new("SpecialMesh")
  198. Part0.Parent = mas
  199. Part0.Rotation = Vector3.new(-17.039999, 72.0800018, -73.7399979)
  200. Part0.Size = Vector3.new(0.48999998, 2.96999931, 1.94999981)
  201. Part0.CFrame = CFrame.new(1.99671245, 4.08856773, -0.616976917, 0.0861581191, 0.29545939, 0.95146209, -0.99592489, 0, 0.090184398, 0.0266458243, -0.955355108, 0.294255406)
  202. Part0.BottomSurface = Enum.SurfaceType.Smooth
  203. Part0.TopSurface = Enum.SurfaceType.Smooth
  204. Part0.Position = Vector3.new(1.99671245, 4.08856773, -0.616976917)
  205. Part0.Orientation = Vector3.new(-5.17000008, 72.8099976, -90)
  206. Part0.CanCollide = false
  207. SpecialMesh1.Parent = Part0
  208. SpecialMesh1.MeshId = "rbxassetid://441572308"
  209. SpecialMesh1.Scale = Vector3.new(0.0209999997, 0.0209999997, 0.0209999997)
  210. SpecialMesh1.TextureId = "rbxassetid://441572332"
  211. SpecialMesh1.MeshType = Enum.MeshType.FileMesh
  212. SpecialMesh1.Scale = Vector3.new(0.0209999997, 0.0209999997, 0.0209999997)
  213. for i,v in pairs(mas:GetChildren()) do
  214. v.Parent = game:GetService("Players").LocalPlayer.Character
  215. pcall(function() v:MakeJoints() end)
  216. end
  217. mas:Destroy()
  218. for i,v in pairs(cors) do
  219. spawn(function()
  220. pcall(v)
  221. end)
  222. end
  223. Part0:BreakJoints()
  224. cananimate = true
  225. canhit = false
  226. local weld = Instance.new("Weld", game.Players.LocalPlayer.Character["Right Arm"])
  227. weld.Part0 = game.Players.LocalPlayer.Character["Right Arm"]
  228. weld.Part1 = Part0
  229. weld.C0 = CFrame.new(0.0769970417, -1.17027426, -1.17937994, 0, 0, 1, -0.999999881, 0, 0, 0, -1, 0)
  230. for i = 0,1 , 0.03 do
  231. headweld.C0 = headweld.C0:lerp(CFrame.new(0, 1.5, 0, 0.962374032, 0, 0.271727562, 0, 1, 0, -0.271727562, 0, 0.962374032),i)
  232. humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.955355227, 0, -0.295459419, 0, 1, 0, 0.295459419, 0, 0.955355227),i)
  233. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53559077, 0.0383267403, 0, 0.997264206, 0.0739177391, 0, -0.0739177391, 0.997264266, 0, 2.98023224e-08, 1.86264515e-09, 0.999999881),i)
  234. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54305458, 0.047129631, 2.98023224e-08, 0.99592495, -0.0901843905, 0, 0.090184398, 0.995925009, 0, 0, 0, 0.999999881),i)
  235. game:GetService("RunService").RenderStepped:wait()
  236. end
  237. function swing()
  238. if not using then
  239. using = true
  240. cananimate = false
  241. for i = 0,1 , 0.045 do
  242. weld.C0 = weld.C0:lerp(CFrame.new(0.958130836, -0.815908253, -0.0419664383, 0.379335552, 0.92491132, -0.0253674984, -0.913223445, 0.378668189, 0.150445476, 0.148754537, -0.0339030921, 0.988292694),i)
  243. headweld.C0 = headweld.C0:lerp(CFrame.new(-4.65661287e-10, 1.49999952, 0, 0.601507425, -2.32830644e-10, 0.798867226, 3.0559022e-10, 1, 0, -0.798867226, -4.65661287e-10, 0.601507425),i)
  244. humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.63088727, -0.00573391188, -0.775853336, 0, 0.999972701, -0.00739025697, 0.775874496, 0.00466241874, 0.630870044),i)
  245. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(0.0363237262, 0.350219727, -1.1563791, 0.495106995, -0.857149601, 0.1419992, 0.110766649, -0.0998312235, -0.988819599, 0.861742377, 0.505300522, 0.0455164276),i)
  246. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.50056481, 0.516354084, -0.499166548, 0.995925009, -0.00520473719, 0.09003409, 0.0901844054, 0.0574772507, -0.994265079, -2.98023224e-08, 0.998333335, 0.057712432),i)
  247. game:GetService("RunService").RenderStepped:wait()
  248. end
  249. canhit = true
  250. for i = 0,1 , 0.08 do
  251. weld.C0 = weld.C0:lerp(CFrame.new(0.968596578, -1.15575922, 0.178524971, 0.0531506836, 0.988890588, -0.13881819, -0.988834679, 0.0327400565, -0.145376131, -0.13921617, 0.144995078, 0.979589343),i)
  252. headweld.C0 = headweld.C0:lerp(CFrame.new(-0.0249017328, 1.48724031, 2.04332173e-06, 0.499998868, 0, -0.866026163, 0, 1, 0, 0.866026163, 0, 0.499998868),i)
  253. humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.305942208, 0, -0.952050149, 0, 1, 0, 0.952050149, 0, 0.305942208):inverse(),i)
  254. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.07653618, 0.305679321, -0.818206966, 0.707105398, -0.707108259, 4.32133675e-07, 0.122787982, 0.122786887, -0.984807909, 0.696365714, 0.696363032, 0.173647687),i)
  255. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.74788636, 0.363031864, -0.7663396, 0.70710665, 0.707106948, -2.23517418e-08, -0.0616280138, 0.061627958, -0.99619478, -0.704416275, 0.704416037, 0.0871551335),i)
  256. game:GetService("RunService").RenderStepped:wait()
  257. end
  258. canhit = false
  259. using = false
  260. cananimate = true
  261. end
  262. end
  263. mouse.Button1Down:connect(swing)
  264. function hittie(part)
  265. if canhit then
  266. local humanoid = part.Parent:findFirstChildOfClass("Humanoid")
  267. if humanoid then
  268. canhit = false
  269. using = false
  270. local uptor = humanoid.Parent:findFirstChild("UpperTorso")
  271. if uptor and uptor.Parent.Name ~= game.Players.LocalPlayer.Name then
  272. humanoid.Parent:BreakJoints()
  273. while humanoid.Health >= 0.001 do
  274. game:GetService("RunService").RenderStepped:wait()
  275. end
  276. if humanoid.Parent:findFirstChild("HumanoidRootPart") then
  277. humanoid.Parent.HumanoidRootPart.CanCollide = false
  278. end
  279. local function makeballlimb(attachone, attachtwo, upperang, lowang, twist)
  280. local constraint = Instance.new("BallSocketConstraint", humanoid.Parent)
  281. constraint.Attachment0 = attachone
  282. constraint.Attachment1 = attachtwo
  283. constraint.LimitsEnabled = true
  284. constraint.TwistLimitsEnabled = true
  285. constraint.TwistLowerAngle = lowang
  286. constraint.TwistUpperAngle = upperang
  287. constraint.UpperAngle = twist
  288. end
  289. local function makehingelimb(attachone, attachtwo, upperang, lowang)
  290. local constraint = Instance.new("HingeConstraint", humanoid.Parent)
  291. constraint.Attachment0 = attachone
  292. constraint.Attachment1 = attachtwo
  293. constraint.LimitsEnabled = true
  294. constraint.LowerAngle = lowang
  295. constraint.UpperAngle = upperang
  296. end
  297. for i,v in pairs(humanoid.Parent:GetChildren()) do --scan player
  298. if v.ClassName == "Accessory" then
  299. local findhandle = v:findFirstChild("Handle") --finding handle in accesorry
  300. if findhandle then
  301. local attach = findhandle:findFirstChildOfClass("Attachment")
  302. for q,w in pairs(humanoid.Parent:GetChildren()) do --scan player
  303. if w.Name == "UpperTorso" or w.Name == "Head" then
  304. attach1 = w:findFirstChild(attach.Name) --finding attachment in head/uppertorso
  305. end
  306. end
  307. if attach and attach1 then
  308. local constraint = Instance.new("HingeConstraint", humanoid.Parent) --making fake weld
  309. constraint.Attachment0 = attach
  310. constraint.Attachment1 = attach1
  311. constraint.LimitsEnabled = true
  312. constraint.LowerAngle = 0
  313. constraint.UpperAngle = 0
  314. end
  315. end
  316. end
  317. end
  318. if humanoid.Parent:findFirstChild("Head") and humanoid.Parent:findFirstChild("UpperTorso") then
  319. local attachment = Instance.new("Attachment", humanoid.Parent.Head)
  320. attachment.Position = Vector3.new(0, -0.5, 0)
  321. attachment.Name = "lol"
  322. attachment.Visible = false
  323. humanoid.Parent.UpperTorso.NeckAttachment.Visible = false
  324. humanoid.Parent.UpperTorso.NeckAttachment.Position = humanoid.Parent.UpperTorso.NeckAttachment.Position + Vector3.new(0,0,0)
  325. local ball = Instance.new("BallSocketConstraint", humanoid.Parent)
  326. ball.Attachment0 = humanoid.Parent.UpperTorso.NeckAttachment
  327. ball.Attachment1 = attachment
  328. ball.LimitsEnabled = true
  329. ball.TwistLimitsEnabled = true
  330. ball.UpperAngle = 40
  331. ball.Restitution = 0.5
  332. ball.TwistUpperAngle = 40
  333. ball.TwistLowerAngle = -40
  334. local collidepartofleftleg = Instance.new("Part", humanoid.Parent.UpperTorso)
  335. collidepartofleftleg.Name = "Bone"
  336. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  337. collidepartofleftleg.Transparency = 1
  338. collidepartofleftleg:BreakJoints()
  339. local weeld = Instance.new("Weld", collidepartofleftleg)
  340. weeld.Part0 = collidepartofleftleg
  341. weeld.Part1 = humanoid.Parent["Head"]
  342. if humanoid.Parent.Head:findFirstChild("Neck") then
  343. humanoid.Parent.Head.Neck:destroy()
  344. end
  345. if humanoid.Parent.Head:findFirstChild("face") then
  346. humanoid.Parent.Head.face.Texture = "http://www.roblox.com/asset/?id=810245460"
  347. end
  348. end
  349. local LeftUpperLeg = humanoid.Parent:findFirstChild("LeftUpperLeg")
  350. local LeftLowerLeg = humanoid.Parent:findFirstChild("LeftLowerLeg")
  351. --
  352. local RightUpperLeg = humanoid.Parent:findFirstChild("RightUpperLeg")
  353. local RightLowerLeg = humanoid.Parent:findFirstChild("RightLowerLeg")
  354. --
  355. local RightUpperArm = humanoid.Parent:findFirstChild("RightUpperArm")
  356. local RightLowerArm = humanoid.Parent:findFirstChild("RightLowerArm")
  357. --
  358. local LeftUpperArm = humanoid.Parent:findFirstChild("LeftUpperArm")
  359. local LeftLowerArm = humanoid.Parent:findFirstChild("LeftLowerArm")
  360. --Foot & Hands--
  361.  
  362. local LeftFoot = humanoid.Parent:findFirstChild("LeftFoot")
  363. local RightFoot = humanoid.Parent:findFirstChild("RightFoot")
  364. --
  365. local LeftHand = humanoid.Parent:findFirstChild("LeftHand")
  366. local RightHand = humanoid.Parent:findFirstChild("RightHand")
  367.  
  368. --END--
  369. --TORSOS--
  370.  
  371. local UpperTorso = humanoid.Parent:findFirstChild("UpperTorso")
  372. local LowerTorso = humanoid.Parent:findFirstChild("LowerTorso")
  373.  
  374. --END--
  375. if LowerTorso then
  376. if LeftUpperLeg then
  377. makeballlimb(LowerTorso["LeftHipRigAttachment"], LeftUpperLeg["LeftHipRigAttachment"], 50,-50, 90)
  378. end
  379. if RightUpperLeg then
  380. makeballlimb(LowerTorso["RightHipRigAttachment"], RightUpperLeg["RightHipRigAttachment"], 50,-50, 90)
  381. end
  382. if LeftLowerLeg then
  383. makehingelimb(LeftUpperLeg["LeftKneeRigAttachment"], LeftLowerLeg["LeftKneeRigAttachment"], 0,-90)
  384. end
  385. if RightLowerLeg then
  386. makehingelimb(RightUpperLeg["RightKneeRigAttachment"], RightLowerLeg["RightKneeRigAttachment"], 0,-90)
  387. end
  388. if LeftFoot then
  389. makehingelimb(LeftLowerLeg["LeftAnkleRigAttachment"], LeftFoot["LeftAnkleRigAttachment"], 30, -30)
  390. end
  391. if RightFoot then
  392. makehingelimb(RightLowerLeg["RightAnkleRigAttachment"], RightFoot["RightAnkleRigAttachment"], 30, -30)
  393. end
  394. if UpperTorso then
  395. makehingelimb(UpperTorso["WaistRigAttachment"], LowerTorso["WaistRigAttachment"], 30, -30)
  396. end
  397. end
  398. if UpperTorso then
  399. local vel = Instance.new("BodyVelocity", UpperTorso)
  400. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  401. vel.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 10
  402. game.Debris:AddItem(vel, 0.1)
  403. local hitsound = Instance.new("Sound", UpperTorso)
  404. hitsound.SoundId = "http://www.roblox.com/asset/?id=148862502"
  405. hitsound:Play()
  406. hitsound.Volume = math.random(5,10)
  407. local canhit = true
  408. local hitval = 15
  409. local uptor = humanoid.Parent.UpperTorso
  410. if RightUpperArm then
  411. makeballlimb(RightUpperArm["RightShoulderRigAttachment"], UpperTorso["RightShoulderRigAttachment"], 90,-50, 180)
  412. end
  413. if RightLowerArm then
  414. makehingelimb(RightLowerArm["RightElbowRigAttachment"], RightUpperArm["RightElbowRigAttachment"], 0,-90)
  415. end
  416. if RightHand then
  417. makehingelimb(RightHand["RightWristRigAttachment"], RightLowerArm["RightWristRigAttachment"], 30,30)
  418. end
  419. if LeftUpperArm then
  420. makeballlimb(LeftUpperArm["LeftShoulderRigAttachment"], UpperTorso["LeftShoulderRigAttachment"], 90,-50, 180)
  421. end
  422. if LeftLowerArm then
  423. makehingelimb(LeftLowerArm["LeftElbowRigAttachment"], LeftUpperArm["LeftElbowRigAttachment"], 0,-90)
  424. end
  425. if LeftHand then
  426. makehingelimb(LeftHand["LeftWristRigAttachment"], LeftLowerArm["LeftWristRigAttachment"], 30,30)
  427. end
  428. end
  429. else
  430. humanoid.Parent.Archivable = true
  431. humanoid.PlatformStand = true
  432. local clone = humanoid.Parent:Clone()
  433. clone.Parent = workspace
  434. game.Debris:AddItem(clone, 60)
  435. for i,v in pairs(clone:GetChildren()) do
  436. if v.ClassName == "Script" or v.ClassName == "LocalScript" then
  437. v:Remove()
  438. end
  439. for i,p in pairs(v:GetChildren()) do
  440. if p.ClassName == "Weld" or p.ClassName == "Motor6D" or p.ClassName == "BodyVelocity" then
  441. p:Remove()
  442. end
  443. end
  444. end
  445. for i,t in pairs(humanoid.Parent:GetChildren()) do
  446. if t.ClassName == "Accessory" or t.ClassName == "ForceField" then
  447. t:Remove()
  448. end
  449. end
  450. local vel = Instance.new("BodyVelocity", clone.Torso)
  451. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  452. vel.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 15
  453. game.Debris:AddItem(vel, 0.1)
  454. local hitsound = Instance.new("Sound", clone.Torso)
  455. hitsound.SoundId = "http://www.roblox.com/asset/?id=148862502"
  456. hitsound:Play()
  457. hitsound.Volume = math.random(5,10)
  458. vel = Instance.new("BodyVelocity", clone.Torso)
  459. vel.Velocity = clone.Torso.CFrame.lookVector * -5
  460. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  461. using = false
  462. hit = Instance.new("Sound", clone.Torso)
  463. hit.SoundId = "rbxassetid://260430060"
  464. hit.Volume = 0
  465. hit1 = Instance.new("Sound", clone.Torso)
  466. hit1.SoundId = "rbxassetid://138087186"
  467. hit1.Volume = 0
  468. hit2 = Instance.new("Sound", clone.Torso)
  469. hit2.SoundId = "rbxassetid://131237241"
  470. hit2.Volume = 0
  471. hit3 = Instance.new("Sound", clone.Torso)
  472. hit3.SoundId = "rbxassetid://278062209"
  473. hit3.Volume = 0
  474. hit3.TimePosition = 0.33
  475. ded = Instance.new("Sound", clone.Torso)
  476. ded.SoundId = "rbxassetid://418892870"
  477. ded.Volume = 0
  478. local leftarm = clone:findFirstChild("Left Arm")
  479. local rightrm = clone:findFirstChild("Right Arm")
  480. local leftleg = clone:findFirstChild("Left Leg")
  481. local rightleg = clone:findFirstChild("Right Leg")
  482. local head = clone:findFirstChild("Head")
  483. for i, g in pairs(humanoid.Parent:GetChildren()) do
  484. if g.ClassName == "Part" then
  485. g:destroy()
  486. end
  487. end
  488. for i, h in pairs(humanoid.Parent:GetChildren()) do
  489. if h.ClassName == "Accesory" then
  490. h:destroy()
  491. end
  492. end
  493. for z,x in pairs(clone:GetChildren()) do
  494. if x.ClassName == "Accessory" then
  495. local handle = x:findFirstChild("Handle")
  496. if handle then
  497. local attachment = handle:findFirstChildOfClass("Attachment")
  498. if attachment then
  499. for q,w in pairs(clone:GetChildren()) do
  500. if w.Name == "Torso" or w.Name == "Head" then
  501. local anotherone = w:findFirstChild(attachment.Name)
  502. if attachment and anotherone then
  503. local constraint = Instance.new("HingeConstraint", clone) --making fake weld
  504. constraint.Attachment0 = attachment
  505. constraint.Attachment1 = anotherone
  506. constraint.LimitsEnabled = true
  507. constraint.LowerAngle = 0
  508. constraint.UpperAngle = 0
  509. end
  510. end
  511. end
  512. end
  513. end
  514. end
  515. end
  516. if head and clone.Torso:findFirstChild("NeckAttachment") then
  517. local attachment = Instance.new("Attachment", clone.Head)
  518. attachment.Position = Vector3.new(0, -0.5, 0)
  519. attachment.Name = "lol"
  520. attachment.Visible = false
  521. clone.Torso.NeckAttachment.Visible = false
  522. clone.Torso.NeckAttachment.Position = clone.Torso.NeckAttachment.Position + Vector3.new(0,0,0)
  523. local ball = Instance.new("BallSocketConstraint", clone)
  524. ball.Attachment0 = clone.Torso.NeckAttachment
  525. ball.Attachment1 = attachment
  526. ball.LimitsEnabled = true
  527. ball.TwistLimitsEnabled = true
  528. ball.UpperAngle = 90
  529. ball.Restitution = 0.5
  530. ball.TwistUpperAngle = 90
  531. ball.TwistLowerAngle = -90
  532. local collidepartofleftleg = Instance.new("Part", clone.Torso)
  533. collidepartofleftleg.Name = "Bone"
  534. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  535. collidepartofleftleg.Transparency = 1
  536. collidepartofleftleg:BreakJoints()
  537. local weeld = Instance.new("Weld", collidepartofleftleg)
  538. weeld.Part0 = collidepartofleftleg
  539. weeld.Part1 = clone["Head"]
  540. end
  541. if leftleg ~= nil then
  542. leftleg:BreakJoints()
  543. local glue = Instance.new("Glue", clone.Torso)
  544. glue.Part0 = clone.Torso
  545. glue.Part1 = leftleg
  546. glue.Name = "Left leg"
  547. local collider = Instance.new("Part", leftleg)
  548. collider.Position = Vector3.new(0,999,0)
  549. collider.Size = Vector3.new(1.5, 1, 1)
  550. collider.Shape = "Cylinder"
  551. local weld = Instance.new("Weld", collider)
  552. weld.Part0 = leftleg
  553. weld.Part1 = collider
  554. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  555. collider.TopSurface = "Smooth"
  556. collider.BottomSurface = "Smooth"
  557. collider.formFactor = "Symmetric"
  558. glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  559. glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  560. collider.Transparency = 1
  561. end
  562. ------------
  563. if rightleg ~= nil then
  564. rightleg:BreakJoints()
  565. local glue1 = Instance.new("Glue", clone.Torso)
  566. glue1.Part0 = clone.Torso
  567. glue1.Part1 = rightleg
  568. glue1.Name = "Right leg"
  569. local collider1 = Instance.new("Part", rightleg)
  570. collider1.Position = Vector3.new(0,999,0)
  571. collider1.Size = Vector3.new(1.5, 1, 1)
  572. collider1.Shape = "Cylinder"
  573. local weld1 = Instance.new("Weld", collider1)
  574. weld1.Part0 = rightleg
  575. weld1.Part1 = collider1
  576. weld1.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  577. collider1.TopSurface = "Smooth"
  578. collider1.BottomSurface = "Smooth"
  579. collider1.formFactor = "Symmetric"
  580. glue1.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  581. glue1.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  582. collider1.Transparency = 1
  583. end
  584. ------------
  585. if rightrm ~= nil then
  586. rightrm:BreakJoints()
  587. rightrm.CFrame = clone.Torso.CFrame * CFrame.new(1.7,0,0)
  588. local glue11 = Instance.new("Glue", clone.Torso)
  589. glue11.Part0 = clone.Torso
  590. glue11.Part1 = rightrm
  591. glue11.Name = "Right shoulder"
  592. local collider11 = Instance.new("Part", rightrm)
  593. collider11.Position = Vector3.new(0,9999,0)
  594. collider11.Size = Vector3.new(1.5,1,1)
  595. collider11.Shape = "Cylinder"
  596. local weld11 = Instance.new("Weld", collider11)
  597. weld11.Part0 = rightrm
  598. weld11.Part1 = collider11
  599. weld11.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  600. collider11.TopSurface = "Smooth"
  601. collider11.BottomSurface = "Smooth"
  602. collider11.formFactor = "Symmetric"
  603. glue11.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  604. glue11.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  605. collider11.Transparency = 1
  606. end
  607. ------------
  608. if leftarm ~= nil then
  609. leftarm.CFrame = clone.Torso.CFrame * CFrame.new(-1.7,0,0)
  610. leftarm:BreakJoints()
  611. local glue111 = Instance.new("Glue", clone.Torso)
  612. glue111.Part0 = clone.Torso
  613. glue111.Part1 = leftarm
  614. glue111.Name = "Left shoulder"
  615. local collider111 = Instance.new("Part", leftarm)
  616. collider111.Position = Vector3.new(0,9999,0)
  617. collider111.Size = Vector3.new(1.5,1,1)
  618. collider111.Shape = "Cylinder"
  619. local weld111 = Instance.new("Weld", collider111)
  620. weld111.Part0 = leftarm
  621. weld111.Part1 = collider111
  622. weld111.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  623. collider111.TopSurface = "Smooth"
  624. collider111.BottomSurface = "Smooth"
  625. collider111.formFactor = "Symmetric"
  626. glue111.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  627. glue111.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  628. collider111.Transparency = 1
  629. ----------------
  630. sensoring = Instance.new("Part", clone.Torso)
  631. sensoring.Size = Vector3.new(1.2,1.1,0.8)
  632. sensoring.CanCollide = false
  633. sensoring.Position = clone.Torso.Position
  634. local welder = Instance.new("Weld", sensoring)
  635. welder.Part0 = clone.Torso
  636. welder.Part1 = sensoring
  637. welder.C0 = welder.C0 * CFrame.new(0,0,1.05)
  638. sensoring.Transparency = 1
  639. -----------------
  640. sensoring1 = Instance.new("Part", clone.Torso)
  641. sensoring1.Size = Vector3.new(1.2,1.1,0.8)
  642. sensoring1.CanCollide = false
  643. sensoring1.Position = clone.Torso.Position
  644. local welder1 = Instance.new("Weld", sensoring)
  645. welder1.Part0 = clone.Torso
  646. welder1.Part1 = sensoring1
  647. welder1.C0 = welder1.C0 * CFrame.new(0,0,-1.05)
  648. sensoring1.Transparency = 1
  649. end
  650. clone.Name = humanoid.Parent.Name.." (PANNED)"
  651. ded:Play()
  652. vel:destroy()
  653. wait(0.5)
  654. local function touch()
  655. if not using then
  656. using = true
  657. local Math = math.random(1,4)
  658. if Math == 1 then
  659. hit:Play()
  660. end
  661. if Math == 2 then
  662. hit1:Play()
  663. end
  664. if Math == 3 then
  665. hit2:Play()
  666. end
  667. if Math == 4 then
  668. hit3:Play()
  669. end
  670. wait(0.1)
  671. using = false
  672. end
  673. end
  674. sensoring.Touched:connect(touch)
  675. sensoring1.Touched:connect(touch)
  676. while true do
  677. if clone:findFirstChild("Head") then
  678. clone.Head.CanCollide = false
  679. end
  680. game:GetService("RunService").Stepped:wait()
  681. end
  682. end
  683. end
  684. end
  685. end
  686. Part0.Touched:connect(hittie)
  687. function ragdoll()
  688. game.Players.LocalPlayer.Character.Archivable = true
  689. clone = game.Players.LocalPlayer.Character:Clone()
  690. clone.Parent = workspace
  691. for i,v in pairs(clone:GetChildren()) do
  692. if v.ClassName == "Script" or v.ClassName == "LocalScript" then
  693. v:Remove()
  694. end
  695. for i,p in pairs(v:GetChildren()) do
  696. if p.ClassName == "Weld" or p.ClassName == "Motor6D" or p.ClassName == "BodyVelocity" then
  697. p:Remove()
  698. end
  699. end
  700. end
  701. for i,t in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  702. if t.ClassName == "Accessory" or t.ClassName == "ForceField" then
  703. t:Remove()
  704. end
  705. end
  706. vel = Instance.new("BodyVelocity", clone.Torso)
  707. vel.Velocity = clone.Torso.CFrame.lookVector * -5
  708. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  709. clone.Head.face.Texture = "http://www.roblox.com/asset/?id=161061608"
  710. using = false
  711. hit = Instance.new("Sound", clone.Torso)
  712. hit.SoundId = "rbxassetid://260430060"
  713. hit.Volume = 0
  714. hit1 = Instance.new("Sound", clone.Torso)
  715. hit1.SoundId = "rbxassetid://138087186"
  716. hit1.Volume = 0
  717. hit2 = Instance.new("Sound", clone.Torso)
  718. hit2.SoundId = "rbxassetid://131237241"
  719. hit2.Volume = 0
  720. hit3 = Instance.new("Sound", clone.Torso)
  721. hit3.SoundId = "rbxassetid://278062209"
  722. hit3.Volume = 0
  723. hit3.TimePosition = 0.33
  724. ded = Instance.new("Sound", clone.Torso)
  725. ded.SoundId = "rbxassetid://337800380"
  726. ded.Volume = 5
  727. local leftarm = clone:findFirstChild("Left Arm")
  728. local rightrm = clone:findFirstChild("Right Arm")
  729. local leftleg = clone:findFirstChild("Left Leg")
  730. local rightleg = clone:findFirstChild("Right Leg")
  731. local head = clone:findFirstChild("Head")
  732. for i, g in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  733. if g.ClassName == "Part" then
  734. g:destroy()
  735. end
  736. end
  737. for i, h in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  738. if h.ClassName == "Accesory" then
  739. h:destroy()
  740. end
  741. end
  742. game.Workspace.CurrentCamera.CameraSubject = head
  743. if head then
  744. local attachment = Instance.new("Attachment", clone.Head)
  745. attachment.Position = Vector3.new(0, -0.5, 0)
  746. attachment.Name = "lol"
  747. attachment.Visible = false
  748. clone.Torso.NeckAttachment.Visible = false
  749. clone.Torso.NeckAttachment.Position = clone.Torso.NeckAttachment.Position + Vector3.new(0,0,0)
  750. local ball = Instance.new("BallSocketConstraint", clone)
  751. ball.Attachment0 = clone.Torso.NeckAttachment
  752. ball.Attachment1 = attachment
  753. ball.LimitsEnabled = true
  754. ball.TwistLimitsEnabled = true
  755. ball.UpperAngle = 90
  756. ball.Restitution = 0.5
  757. ball.TwistUpperAngle = 90
  758. ball.TwistLowerAngle = -90
  759. local collidepartofleftleg = Instance.new("Part", clone.Torso)
  760. collidepartofleftleg.Name = "Bone"
  761. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  762. collidepartofleftleg.Transparency = 1
  763. collidepartofleftleg:BreakJoints()
  764. local weeld = Instance.new("Weld", collidepartofleftleg)
  765. weeld.Part0 = collidepartofleftleg
  766. weeld.Part1 = clone["Head"]
  767. end
  768. if leftleg ~= nil then
  769. local glue = Instance.new("Glue", clone.Torso)
  770. glue.Part0 = clone.Torso
  771. glue.Part1 = leftleg
  772. glue.Name = "Left leg"
  773. local collider = Instance.new("Part", leftleg)
  774. collider.Position = Vector3.new(0,999,0)
  775. collider.Size = Vector3.new(1.5, 1, 1)
  776. collider.Shape = "Cylinder"
  777. local weld = Instance.new("Weld", collider)
  778. weld.Part0 = leftleg
  779. weld.Part1 = collider
  780. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  781. collider.TopSurface = "Smooth"
  782. collider.BottomSurface = "Smooth"
  783. collider.formFactor = "Symmetric"
  784. glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  785. glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  786. collider.Transparency = 1
  787. end
  788. ------------
  789. if rightleg ~= nil then
  790. local glue1 = Instance.new("Glue", clone.Torso)
  791. glue1.Part0 = clone.Torso
  792. glue1.Part1 = rightleg
  793. glue1.Name = "Right leg"
  794. local collider1 = Instance.new("Part", rightleg)
  795. collider1.Position = Vector3.new(0,999,0)
  796. collider1.Size = Vector3.new(1.5, 1, 1)
  797. collider1.Shape = "Cylinder"
  798. local weld1 = Instance.new("Weld", collider1)
  799. weld1.Part0 = rightleg
  800. weld1.Part1 = collider1
  801. weld1.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  802. collider1.TopSurface = "Smooth"
  803. collider1.BottomSurface = "Smooth"
  804. collider1.formFactor = "Symmetric"
  805. glue1.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  806. glue1.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  807. collider1.Transparency = 1
  808. end
  809. ------------
  810. if rightrm ~= nil then
  811. local glue11 = Instance.new("Glue", clone.Torso)
  812. glue11.Part0 = clone.Torso
  813. glue11.Part1 = rightrm
  814. glue11.Name = "Right shoulder"
  815. local collider11 = Instance.new("Part", rightrm)
  816. collider11.Position = Vector3.new(0,9999,0)
  817. collider11.Size = Vector3.new(1.5,1,1)
  818. collider11.Shape = "Cylinder"
  819. local weld11 = Instance.new("Weld", collider11)
  820. weld11.Part0 = rightrm
  821. weld11.Part1 = collider11
  822. weld11.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  823. collider11.TopSurface = "Smooth"
  824. collider11.BottomSurface = "Smooth"
  825. collider11.formFactor = "Symmetric"
  826. glue11.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  827. glue11.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  828. collider11.Transparency = 1
  829. end
  830. ------------
  831. if leftarm ~= nil then
  832. local glue111 = Instance.new("Glue", clone.Torso)
  833. glue111.Part0 = clone.Torso
  834. glue111.Part1 = leftarm
  835. glue111.Name = "Left shoulder"
  836. local collider111 = Instance.new("Part", leftarm)
  837. collider111.Position = Vector3.new(0,9999,0)
  838. collider111.Size = Vector3.new(1.5,1,1)
  839. collider111.Shape = "Cylinder"
  840. local weld111 = Instance.new("Weld", collider111)
  841. weld111.Part0 = leftarm
  842. weld111.Part1 = collider111
  843. weld111.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  844. collider111.TopSurface = "Smooth"
  845. collider111.BottomSurface = "Smooth"
  846. collider111.formFactor = "Symmetric"
  847. glue111.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  848. glue111.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  849. collider111.Transparency = 1
  850. ----------------
  851. sensoring = Instance.new("Part", clone.Torso)
  852. sensoring.Size = Vector3.new(1.2,1.1,0.8)
  853. sensoring.CanCollide = false
  854. sensoring.Position = clone.Torso.Position
  855. local welder = Instance.new("Weld", sensoring)
  856. welder.Part0 = clone.Torso
  857. welder.Part1 = sensoring
  858. welder.C0 = welder.C0 * CFrame.new(0,0,1.05)
  859. sensoring.Transparency = 1
  860. -----------------
  861. sensoring1 = Instance.new("Part", clone.Torso)
  862. sensoring1.Size = Vector3.new(1.2,1.1,0.8)
  863. sensoring1.CanCollide = false
  864. sensoring1.Position = clone.Torso.Position
  865. local welder1 = Instance.new("Weld", sensoring)
  866. welder1.Part0 = clone.Torso
  867. welder1.Part1 = sensoring1
  868. welder1.C0 = welder1.C0 * CFrame.new(0,0,-1.05)
  869. sensoring1.Transparency = 1
  870. end
  871. clone.Name = game.Players.LocalPlayer.Character.Name.." (DEAD)"
  872. ded:Play()
  873. vel:destroy()
  874. wait(0.2)
  875. game.Debris:AddItem(clone,60)
  876. local function touch()
  877. if not using then
  878. using = true
  879. local Math = math.random(1,4)
  880. if Math == 1 then
  881. hit:Play()
  882. end
  883. if Math == 2 then
  884. hit1:Play()
  885. end
  886. if Math == 3 then
  887. hit2:Play()
  888. end
  889. if Math == 4 then
  890. hit3:Play()
  891. end
  892. wait(0.1)
  893. using = false
  894. end
  895. end
  896. sensoring.Touched:connect(touch)
  897. sensoring1.Touched:connect(touch)
  898. while true do
  899. clone.Head.CanCollide = false
  900. game:GetService("RunService").Stepped:wait()
  901. end
  902. end
  903.  
  904. game.Players.LocalPlayer.Character.Humanoid.Died:connect(ragdoll)
  905.  
  906. --di ent
  907. while true do
  908. if cananimate then
  909. if game.Players.LocalPlayer.Character.Torso.Velocity.x < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x > 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > 0.5 and cananimate then
  910. for i = 0.1,0.3 , 0.008 do
  911. if cananimate and game.Players.LocalPlayer.Character.Torso.Velocity.x < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x > 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > 0.5 and cananimate then
  912. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53402293, 0.0594797134, 0.144087285, 0.997264206, 0.0707819909, 0.0213012099, -0.0739177391, 0.9549582, 0.287386209, 2.98023224e-08, -0.28817457, 0.957577825),i)
  913. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54035091, 0.0769848824, -0.170524538, 0.99592495, -0.0847774297, 0.0307573378, 0.090184398, 0.936214805, -0.339659303, 0, 0.341049016, 0.940045416),i)
  914. game:GetService("RunService").Stepped:wait()
  915. end
  916. end
  917. for i = 0.1,0.3 , 0.008 do
  918. if cananimate and game.Players.LocalPlayer.Character.Torso.Velocity.x < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x > 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > 0.5 and cananimate then
  919. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53173375, 0.0903658867, -0.222393572, 0.997264206, 0.0662034005, -0.0328776538, -0.0739177391, 0.893185973, -0.443570435, 2.98023224e-08, 0.444787204, 0.895636141),i)
  920. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54079688, 0.0720610619, 0.156226337, 0.99592495, -0.085669145, -0.0281783342, 0.090184398, 0.946062148, 0.311179608, 0, -0.312452823, 0.949932992),i)
  921. game:GetService("RunService").Stepped:wait()
  922. end
  923. end
  924. elseif game.Players.LocalPlayer.Character.Torso.Velocity.x > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x < 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < 0.5 then
  925. for i = 0,1 , 0.1 do
  926. if cananimate and game.Players.LocalPlayer.Character.Torso.Velocity.x > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.x < 0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z > -0.5 or game.Players.LocalPlayer.Character.Torso.Velocity.z < 0.5 and cananimate then
  927. weld.C0 = weld.C0:lerp(CFrame.new(0.0769970417, -1.17027426, -1.17937994, 0, 0, 1, -0.999999881, 0, 0, 0, -1, 0),i)
  928. headweld.C0 = headweld.C0:lerp(CFrame.new(0, 1.5, 0, 0.962374032, 0, 0.271727562, 0, 1, 0, -0.271727562, 0, 0.962374032),i)
  929. humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.955355227, 0, -0.295459419, 0, 1, 0, 0.295459419, 0, 0.955355227),i)
  930. lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-1.53559077, 0.0383267403, 0, 0.997264206, 0.0739177391, 0, -0.0739177391, 0.997264266, 0, 2.98023224e-08, 1.86264515e-09, 0.999999881),i)
  931. rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(1.54305458, 0.047129631, 2.98023224e-08, 0.99592495, -0.0901843905, 0, 0.090184398, 0.995925009, 0, 0, 0, 0.999999881),i)
  932. game:GetService("RunService").RenderStepped:wait()
  933. end
  934. end
  935. end
  936. end
  937. wait()
  938. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement