Advertisement
mememasterYT

fe pan minor edit

Apr 13th, 2019
262
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  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,Mouse,mouse,UserInputService,ContextActionService = owner
  4. local RealPlayer = Player
  5. do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end
  6.  
  7.  
  8. --By Ruffles14
  9. mouse = game.Players.LocalPlayer:GetMouse()
  10. local rhandclone = game.Players.LocalPlayer.Character.Torso["Right Shoulder"]:Clone()
  11. local rhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  12. rhandweld.Part0 = game.Players.LocalPlayer.Character.Torso
  13. rhandweld.Part1 = game.Players.LocalPlayer.Character["Right Arm"]
  14. rhandweld.C0 = CFrame.new(1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1)
  15. local lhandclone = game.Players.LocalPlayer.Character.Torso["Left Shoulder"]:Clone()
  16. local lhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  17. lhandweld.Part0 = game.Players.LocalPlayer.Character.Torso
  18. lhandweld.Part1 = game.Players.LocalPlayer.Character["Left Arm"]
  19. lhandweld.C0 = CFrame.new(-1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1)
  20. local rootjointclone = game.Players.LocalPlayer.Character.HumanoidRootPart.RootJoint:Clone()
  21. game.Players.LocalPlayer.Character.HumanoidRootPart.RootJoint:Remove()
  22. local humanoidrootpart = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  23. humanoidrootpart.Part0 = game.Players.LocalPlayer.Character.HumanoidRootPart
  24. humanoidrootpart.Part1 = game.Players.LocalPlayer.Character.Torso
  25. local heed = game.Players.LocalPlayer.Character.Torso["Neck"]:Clone()
  26. local headweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
  27. headweld.Part0 = game.Players.LocalPlayer.Character.Torso
  28. headweld.Part1 = game.Players.LocalPlayer.Character.Head
  29. headweld.C0 = headweld.C0 * CFrame.new(0,1.5,0)
  30. game.Players.LocalPlayer.Character.Torso.Neck:Remove()
  31. using = false
  32. --Converted with ttyyuu12345's model to script plugin v4
  33. function sandbox(var,func)
  34. local env = getfenv(func)
  35. local newenv = setmetatable({},{
  36. __index = function(self,k)
  37. if k=="script" then
  38. return var
  39. else
  40. return env[k]
  41. end
  42. end,
  43. })
  44. setfenv(func,newenv)
  45. return func
  46. end
  47. cananimate = true
  48. canhit = false
  49. end
  50. function swing()
  51. if not using then
  52. using = true
  53. cananimate = false
  54. end
  55. canhit = true
  56. end
  57. canhit = false
  58. using = false
  59. cananimate = true
  60. end
  61. end
  62. mouse.Button1Down:connect(swing)
  63. function hittie(part)
  64. if canhit then
  65. local humanoid = part.Parent:findFirstChildOfClass("Humanoid")
  66. if humanoid then
  67. canhit = false
  68. using = false
  69. local uptor = humanoid.Parent:findFirstChild("UpperTorso")
  70. if uptor and uptor.Parent.Name ~= game.Players.LocalPlayer.Name then
  71. humanoid.Parent:BreakJoints()
  72. while humanoid.Health >= 0.001 do
  73. game:GetService("RunService").RenderStepped:wait()
  74. end
  75. if humanoid.Parent:findFirstChild("HumanoidRootPart") then
  76. humanoid.Parent.HumanoidRootPart.CanCollide = false
  77. end
  78. local function makeballlimb(attachone, attachtwo, upperang, lowang, twist)
  79. local constraint = Instance.new("BallSocketConstraint", humanoid.Parent)
  80. constraint.Attachment0 = attachone
  81. constraint.Attachment1 = attachtwo
  82. constraint.LimitsEnabled = true
  83. constraint.TwistLimitsEnabled = true
  84. constraint.TwistLowerAngle = lowang
  85. constraint.TwistUpperAngle = upperang
  86. constraint.UpperAngle = twist
  87. end
  88. local function makehingelimb(attachone, attachtwo, upperang, lowang)
  89. local constraint = Instance.new("HingeConstraint", humanoid.Parent)
  90. constraint.Attachment0 = attachone
  91. constraint.Attachment1 = attachtwo
  92. constraint.LimitsEnabled = true
  93. constraint.LowerAngle = lowang
  94. constraint.UpperAngle = upperang
  95. end
  96. for i,v in pairs(humanoid.Parent:GetChildren()) do --scan player
  97. if v.ClassName == "Accessory" then
  98. local findhandle = v:findFirstChild("Handle") --finding handle in accesorry
  99. if findhandle then
  100. local attach = findhandle:findFirstChildOfClass("Attachment")
  101. for q,w in pairs(humanoid.Parent:GetChildren()) do --scan player
  102. if w.Name == "UpperTorso" or w.Name == "Head" then
  103. attach1 = w:findFirstChild(attach.Name) --finding attachment in head/uppertorso
  104. end
  105. end
  106. if attach and attach1 then
  107. local constraint = Instance.new("HingeConstraint", humanoid.Parent) --making fake weld
  108. constraint.Attachment0 = attach
  109. constraint.Attachment1 = attach1
  110. constraint.LimitsEnabled = true
  111. constraint.LowerAngle = 0
  112. constraint.UpperAngle = 0
  113. end
  114. end
  115. end
  116. end
  117. if humanoid.Parent:findFirstChild("Head") and humanoid.Parent:findFirstChild("UpperTorso") then
  118. local attachment = Instance.new("Attachment", humanoid.Parent.Head)
  119. attachment.Position = Vector3.new(0, -0.5, 0)
  120. attachment.Name = "lol"
  121. attachment.Visible = false
  122. humanoid.Parent.UpperTorso.NeckAttachment.Visible = false
  123. humanoid.Parent.UpperTorso.NeckAttachment.Position = humanoid.Parent.UpperTorso.NeckAttachment.Position + Vector3.new(0,0,0)
  124. local ball = Instance.new("BallSocketConstraint", humanoid.Parent)
  125. ball.Attachment0 = humanoid.Parent.UpperTorso.NeckAttachment
  126. ball.Attachment1 = attachment
  127. ball.LimitsEnabled = true
  128. ball.TwistLimitsEnabled = true
  129. ball.UpperAngle = 40
  130. ball.Restitution = 0.5
  131. ball.TwistUpperAngle = 40
  132. ball.TwistLowerAngle = -40
  133. local collidepartofleftleg = Instance.new("Part", humanoid.Parent.UpperTorso)
  134. collidepartofleftleg.Name = "Bone"
  135. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  136. collidepartofleftleg.Transparency = 1
  137. collidepartofleftleg:BreakJoints()
  138. local weeld = Instance.new("Weld", collidepartofleftleg)
  139. weeld.Part0 = collidepartofleftleg
  140. weeld.Part1 = humanoid.Parent["Head"]
  141. if humanoid.Parent.Head:findFirstChild("Neck") then
  142. humanoid.Parent.Head.Neck:destroy()
  143. end
  144. if humanoid.Parent.Head:findFirstChild("face") then
  145. humanoid.Parent.Head.face.Texture = "http://www.roblox.com/asset/?id=810245460"
  146. end
  147. end
  148. local LeftUpperLeg = humanoid.Parent:findFirstChild("LeftUpperLeg")
  149. local LeftLowerLeg = humanoid.Parent:findFirstChild("LeftLowerLeg")
  150. --
  151. local RightUpperLeg = humanoid.Parent:findFirstChild("RightUpperLeg")
  152. local RightLowerLeg = humanoid.Parent:findFirstChild("RightLowerLeg")
  153. --
  154. local RightUpperArm = humanoid.Parent:findFirstChild("RightUpperArm")
  155. local RightLowerArm = humanoid.Parent:findFirstChild("RightLowerArm")
  156. --
  157. local LeftUpperArm = humanoid.Parent:findFirstChild("LeftUpperArm")
  158. local LeftLowerArm = humanoid.Parent:findFirstChild("LeftLowerArm")
  159. --Foot & Hands--
  160.  
  161. local LeftFoot = humanoid.Parent:findFirstChild("LeftFoot")
  162. local RightFoot = humanoid.Parent:findFirstChild("RightFoot")
  163. --
  164. local LeftHand = humanoid.Parent:findFirstChild("LeftHand")
  165. local RightHand = humanoid.Parent:findFirstChild("RightHand")
  166.  
  167. --END--
  168. --TORSOS--
  169.  
  170. local UpperTorso = humanoid.Parent:findFirstChild("UpperTorso")
  171. local LowerTorso = humanoid.Parent:findFirstChild("LowerTorso")
  172.  
  173. --END--
  174. if LowerTorso then
  175. if LeftUpperLeg then
  176. makeballlimb(LowerTorso["LeftHipRigAttachment"], LeftUpperLeg["LeftHipRigAttachment"], 50,-50, 90)
  177. end
  178. if RightUpperLeg then
  179. makeballlimb(LowerTorso["RightHipRigAttachment"], RightUpperLeg["RightHipRigAttachment"], 50,-50, 90)
  180. end
  181. if LeftLowerLeg then
  182. makehingelimb(LeftUpperLeg["LeftKneeRigAttachment"], LeftLowerLeg["LeftKneeRigAttachment"], 0,-90)
  183. end
  184. if RightLowerLeg then
  185. makehingelimb(RightUpperLeg["RightKneeRigAttachment"], RightLowerLeg["RightKneeRigAttachment"], 0,-90)
  186. end
  187. if LeftFoot then
  188. makehingelimb(LeftLowerLeg["LeftAnkleRigAttachment"], LeftFoot["LeftAnkleRigAttachment"], 30, -30)
  189. end
  190. if RightFoot then
  191. makehingelimb(RightLowerLeg["RightAnkleRigAttachment"], RightFoot["RightAnkleRigAttachment"], 30, -30)
  192. end
  193. if UpperTorso then
  194. makehingelimb(UpperTorso["WaistRigAttachment"], LowerTorso["WaistRigAttachment"], 30, -30)
  195. end
  196. end
  197. if UpperTorso then
  198. local vel = Instance.new("BodyVelocity", UpperTorso)
  199. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  200. vel.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 10
  201. game.Debris:AddItem(vel, 0.1)
  202. local hitsound = Instance.new("Sound", UpperTorso)
  203. hitsound.SoundId = "http://www.roblox.com/asset/?id=148862502"
  204. hitsound:Play()
  205. hitsound.Volume = math.random(5,10)
  206. local woosh = Instance.new("Sound",UpperTorso)
  207. woosh.SoundId = "rbxassetid://147722227"
  208. woosh:Play()
  209. woosh.Volume = math.random(5,10)
  210. local oof = Instance.new("Sound")
  211. local canhit = true
  212. local hitval = 15
  213. local uptor = humanoid.Parent.UpperTorso
  214. if RightUpperArm then
  215. makeballlimb(RightUpperArm["RightShoulderRigAttachment"], UpperTorso["RightShoulderRigAttachment"], 90,-50, 180)
  216. end
  217. if RightLowerArm then
  218. makehingelimb(RightLowerArm["RightElbowRigAttachment"], RightUpperArm["RightElbowRigAttachment"], 0,-90)
  219. end
  220. if RightHand then
  221. makehingelimb(RightHand["RightWristRigAttachment"], RightLowerArm["RightWristRigAttachment"], 30,30)
  222. end
  223. if LeftUpperArm then
  224. makeballlimb(LeftUpperArm["LeftShoulderRigAttachment"], UpperTorso["LeftShoulderRigAttachment"], 90,-50, 180)
  225. end
  226. if LeftLowerArm then
  227. makehingelimb(LeftLowerArm["LeftElbowRigAttachment"], LeftUpperArm["LeftElbowRigAttachment"], 0,-90)
  228. end
  229. if LeftHand then
  230. makehingelimb(LeftHand["LeftWristRigAttachment"], LeftLowerArm["LeftWristRigAttachment"], 30,30)
  231. end
  232. end
  233. else
  234. humanoid.Parent.Archivable = true
  235. humanoid.PlatformStand = true
  236. local clone = humanoid.Parent:Clone()
  237. clone.Parent = workspace
  238. game.Debris:AddItem(clone, 60)
  239. for i,v in pairs(clone:GetChildren()) do
  240. if v.ClassName == "Script" or v.ClassName == "LocalScript" then
  241. v:Remove()
  242. end
  243. for i,p in pairs(v:GetChildren()) do
  244. if p.ClassName == "Weld" or p.ClassName == "Motor6D" or p.ClassName == "BodyVelocity" then
  245. p:Remove()
  246. end
  247. end
  248. end
  249. for i,t in pairs(humanoid.Parent:GetChildren()) do
  250. if t.ClassName == "Accessory" or t.ClassName == "ForceField" then
  251. t:Remove()
  252. end
  253. end
  254. local vel = Instance.new("BodyVelocity", clone.Torso)
  255. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  256. vel.Velocity = game.Players.LocalPlayer.Character.Torso.CFrame.lookVector * 15
  257. game.Debris:AddItem(vel, 0.1)
  258. local hitsound = Instance.new("Sound", clone.Torso)
  259. hitsound.SoundId = "http://www.roblox.com/asset/?id=148862502"
  260. hitsound:Play()
  261. hitsound.Volume = math.random(5,10)
  262. vel = Instance.new("BodyVelocity", clone.Torso)
  263. vel.Velocity = clone.Torso.CFrame.lookVector * -5
  264. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  265. using = false
  266. hit = Instance.new("Sound", clone.Torso)
  267. hit.SoundId = "rbxassetid://260430060"
  268. hit.Volume = 0
  269. hit1 = Instance.new("Sound", clone.Torso)
  270. hit1.SoundId = "rbxassetid://138087186"
  271. hit1.Volume = 0
  272. hit2 = Instance.new("Sound", clone.Torso)
  273. hit2.SoundId = "rbxassetid://131237241"
  274. hit2.Volume = 0
  275. hit3 = Instance.new("Sound", clone.Torso)
  276. hit3.SoundId = "rbxassetid://278062209"
  277. hit3.Volume = 0
  278. hit3.TimePosition = 0.33
  279. ded = Instance.new("Sound", clone.Torso)
  280. ded.SoundId = "rbxassetid://540791978"
  281. ded.Volume = 0
  282. local leftarm = clone:findFirstChild("Left Arm")
  283. local rightrm = clone:findFirstChild("Right Arm")
  284. local leftleg = clone:findFirstChild("Left Leg")
  285. local rightleg = clone:findFirstChild("Right Leg")
  286. local head = clone:findFirstChild("Head")
  287. for i, g in pairs(humanoid.Parent:GetChildren()) do
  288. if g.ClassName == "Part" then
  289. g:destroy()
  290. end
  291. end
  292. for i, h in pairs(humanoid.Parent:GetChildren()) do
  293. if h.ClassName == "Accesory" then
  294. h:destroy()
  295. end
  296. end
  297. for z,x in pairs(clone:GetChildren()) do
  298. if x.ClassName == "Accessory" then
  299. local handle = x:findFirstChild("Handle")
  300. if handle then
  301. local attachment = handle:findFirstChildOfClass("Attachment")
  302. if attachment then
  303. for q,w in pairs(clone:GetChildren()) do
  304. if w.Name == "Torso" or w.Name == "Head" then
  305. local anotherone = w:findFirstChild(attachment.Name)
  306. if attachment and anotherone then
  307. local constraint = Instance.new("HingeConstraint", clone) --making fake weld
  308. constraint.Attachment0 = attachment
  309. constraint.Attachment1 = anotherone
  310. constraint.LimitsEnabled = true
  311. constraint.LowerAngle = 0
  312. constraint.UpperAngle = 0
  313. end
  314. end
  315. end
  316. end
  317. end
  318. end
  319. end
  320. if head and clone.Torso:findFirstChild("NeckAttachment") then
  321. local attachment = Instance.new("Attachment", clone.Head)
  322. attachment.Position = Vector3.new(0, -0.5, 0)
  323. attachment.Name = "lol"
  324. attachment.Visible = false
  325. clone.Torso.NeckAttachment.Visible = false
  326. clone.Torso.NeckAttachment.Position = clone.Torso.NeckAttachment.Position + Vector3.new(0,0,0)
  327. local ball = Instance.new("BallSocketConstraint", clone)
  328. ball.Attachment0 = clone.Torso.NeckAttachment
  329. ball.Attachment1 = attachment
  330. ball.LimitsEnabled = true
  331. ball.TwistLimitsEnabled = true
  332. ball.UpperAngle = 90
  333. ball.Restitution = 0.5
  334. ball.TwistUpperAngle = 90
  335. ball.TwistLowerAngle = -90
  336. local collidepartofleftleg = Instance.new("Part", clone.Torso)
  337. collidepartofleftleg.Name = "Bone"
  338. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  339. collidepartofleftleg.Transparency = 1
  340. collidepartofleftleg:BreakJoints()
  341. local weeld = Instance.new("Weld", collidepartofleftleg)
  342. weeld.Part0 = collidepartofleftleg
  343. weeld.Part1 = clone["Head"]
  344. end
  345. if leftleg ~= nil then
  346. leftleg:BreakJoints()
  347. local glue = Instance.new("Glue", clone.Torso)
  348. glue.Part0 = clone.Torso
  349. glue.Part1 = leftleg
  350. glue.Name = "Left leg"
  351. local collider = Instance.new("Part", leftleg)
  352. collider.Position = Vector3.new(0,999,0)
  353. collider.Size = Vector3.new(1.5, 1, 1)
  354. collider.Shape = "Cylinder"
  355. local weld = Instance.new("Weld", collider)
  356. weld.Part0 = leftleg
  357. weld.Part1 = collider
  358. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  359. collider.TopSurface = "Smooth"
  360. collider.BottomSurface = "Smooth"
  361. collider.formFactor = "Symmetric"
  362. glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  363. glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  364. collider.Transparency = 1
  365. end
  366. ------------
  367. if rightleg ~= nil then
  368. rightleg:BreakJoints()
  369. local glue1 = Instance.new("Glue", clone.Torso)
  370. glue1.Part0 = clone.Torso
  371. glue1.Part1 = rightleg
  372. glue1.Name = "Right leg"
  373. local collider1 = Instance.new("Part", rightleg)
  374. collider1.Position = Vector3.new(0,999,0)
  375. collider1.Size = Vector3.new(1.5, 1, 1)
  376. collider1.Shape = "Cylinder"
  377. local weld1 = Instance.new("Weld", collider1)
  378. weld1.Part0 = rightleg
  379. weld1.Part1 = collider1
  380. weld1.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  381. collider1.TopSurface = "Smooth"
  382. collider1.BottomSurface = "Smooth"
  383. collider1.formFactor = "Symmetric"
  384. glue1.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  385. glue1.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  386. collider1.Transparency = 1
  387. end
  388. ------------
  389. if rightrm ~= nil then
  390. rightrm:BreakJoints()
  391. rightrm.CFrame = clone.Torso.CFrame * CFrame.new(1.7,0,0)
  392. local glue11 = Instance.new("Glue", clone.Torso)
  393. glue11.Part0 = clone.Torso
  394. glue11.Part1 = rightrm
  395. glue11.Name = "Right shoulder"
  396. local collider11 = Instance.new("Part", rightrm)
  397. collider11.Position = Vector3.new(0,9999,0)
  398. collider11.Size = Vector3.new(1.5,1,1)
  399. collider11.Shape = "Cylinder"
  400. local weld11 = Instance.new("Weld", collider11)
  401. weld11.Part0 = rightrm
  402. weld11.Part1 = collider11
  403. weld11.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  404. collider11.TopSurface = "Smooth"
  405. collider11.BottomSurface = "Smooth"
  406. collider11.formFactor = "Symmetric"
  407. glue11.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  408. glue11.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  409. collider11.Transparency = 1
  410. end
  411. ------------
  412. if leftarm ~= nil then
  413. leftarm.CFrame = clone.Torso.CFrame * CFrame.new(-1.7,0,0)
  414. leftarm:BreakJoints()
  415. local glue111 = Instance.new("Glue", clone.Torso)
  416. glue111.Part0 = clone.Torso
  417. glue111.Part1 = leftarm
  418. glue111.Name = "Left shoulder"
  419. local collider111 = Instance.new("Part", leftarm)
  420. collider111.Position = Vector3.new(0,9999,0)
  421. collider111.Size = Vector3.new(1.5,1,1)
  422. collider111.Shape = "Cylinder"
  423. local weld111 = Instance.new("Weld", collider111)
  424. weld111.Part0 = leftarm
  425. weld111.Part1 = collider111
  426. weld111.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  427. collider111.TopSurface = "Smooth"
  428. collider111.BottomSurface = "Smooth"
  429. collider111.formFactor = "Symmetric"
  430. glue111.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  431. glue111.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  432. collider111.Transparency = 1
  433. ----------------
  434. sensoring = Instance.new("Part", clone.Torso)
  435. sensoring.Size = Vector3.new(1.2,1.1,0.8)
  436. sensoring.CanCollide = false
  437. sensoring.Position = clone.Torso.Position
  438. local welder = Instance.new("Weld", sensoring)
  439. welder.Part0 = clone.Torso
  440. welder.Part1 = sensoring
  441. welder.C0 = welder.C0 * CFrame.new(0,0,1.05)
  442. sensoring.Transparency = 1
  443. -----------------
  444. sensoring1 = Instance.new("Part", clone.Torso)
  445. sensoring1.Size = Vector3.new(1.2,1.1,0.8)
  446. sensoring1.CanCollide = false
  447. sensoring1.Position = clone.Torso.Position
  448. local welder1 = Instance.new("Weld", sensoring)
  449. welder1.Part0 = clone.Torso
  450. welder1.Part1 = sensoring1
  451. welder1.C0 = welder1.C0 * CFrame.new(0,0,-1.05)
  452. sensoring1.Transparency = 1
  453. end
  454. clone.Name = humanoid.Parent.Name.." (DED)"
  455. ded.Playing = true
  456. wait(1)
  457. ded.Playing = false
  458. vel:destroy()
  459. wait(0.5)
  460. local function touch()
  461. if not using then
  462. using = true
  463. local Math = math.random(1,4)
  464. if Math == 1 then
  465. hit:Play()
  466. woosh:Play()
  467. end
  468. if Math == 2 then
  469. hit1:Play()
  470. woosh:Play()
  471. end
  472. if Math == 3 then
  473. hit2:Play()
  474. woosh:Play()
  475. end
  476. if Math == 4 then
  477. hit3:Play()
  478. woosh:Play()
  479. end
  480. wait(0.1)
  481. using = false
  482. end
  483. end
  484. sensoring.Touched:connect(touch)
  485. sensoring1.Touched:connect(touch)
  486. while true do
  487. if clone:findFirstChild("Head") then
  488. clone.Head.CanCollide = false
  489. end
  490. game:GetService("RunService").Stepped:wait()
  491. end
  492. end
  493. end
  494. end
  495. end
  496. Part0.Touched:connect(hittie)
  497. function ragdoll()
  498. game.Players.LocalPlayer.Character.Archivable = true
  499. clone = game.Players.LocalPlayer.Character:Clone()
  500. clone.Parent = workspace
  501. for i,v in pairs(clone:GetChildren()) do
  502. if v.ClassName == "Script" or v.ClassName == "LocalScript" then
  503. v:Remove()
  504. end
  505. for i,p in pairs(v:GetChildren()) do
  506. if p.ClassName == "Weld" or p.ClassName == "Motor6D" or p.ClassName == "BodyVelocity" then
  507. p:Remove()
  508. end
  509. end
  510. end
  511. for i,t in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  512. if t.ClassName == "Accessory" or t.ClassName == "ForceField" then
  513. t:Remove()
  514. end
  515. end
  516. vel = Instance.new("BodyVelocity", clone.Torso)
  517. vel.Velocity = clone.Torso.CFrame.lookVector * -5
  518. vel.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  519. clone.Head.face.Texture = "http://www.roblox.com/asset/?id=161061608"
  520. using = false
  521. hit = Instance.new("Sound", clone.Torso)
  522. hit.SoundId = "rbxassetid://260430060"
  523. hit.Volume = 0
  524. hit1 = Instance.new("Sound", clone.Torso)
  525. hit1.SoundId = "rbxassetid://138087186"
  526. hit1.Volume = 0
  527. hit2 = Instance.new("Sound", clone.Torso)
  528. hit2.SoundId = "rbxassetid://131237241"
  529. hit2.Volume = 0
  530. hit3 = Instance.new("Sound", clone.Torso)
  531. hit3.SoundId = "rbxassetid://278062209"
  532. hit3.Volume = 0
  533. hit3.TimePosition = 0.33
  534. ded = Instance.new("Sound", clone.Torso)
  535. ded.SoundId = "rbxassetid://337800380"
  536. ded.Volume = 5
  537. local leftarm = clone:findFirstChild("Left Arm")
  538. local rightrm = clone:findFirstChild("Right Arm")
  539. local leftleg = clone:findFirstChild("Left Leg")
  540. local rightleg = clone:findFirstChild("Right Leg")
  541. local head = clone:findFirstChild("Head")
  542. for i, g in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  543. if g.ClassName == "Part" then
  544. g:destroy()
  545. end
  546. end
  547. for i, h in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  548. if h.ClassName == "Accesory" then
  549. h:destroy()
  550. end
  551. end
  552. game.Workspace.CurrentCamera.CameraSubject = head
  553. if head then
  554. local attachment = Instance.new("Attachment", clone.Head)
  555. attachment.Position = Vector3.new(0, -0.5, 0)
  556. attachment.Name = "lol"
  557. attachment.Visible = false
  558. clone.Torso.NeckAttachment.Visible = false
  559. clone.Torso.NeckAttachment.Position = clone.Torso.NeckAttachment.Position + Vector3.new(0,0,0)
  560. local ball = Instance.new("BallSocketConstraint", clone)
  561. ball.Attachment0 = clone.Torso.NeckAttachment
  562. ball.Attachment1 = attachment
  563. ball.LimitsEnabled = true
  564. ball.TwistLimitsEnabled = true
  565. ball.UpperAngle = 90
  566. ball.Restitution = 0.5
  567. ball.TwistUpperAngle = 90
  568. ball.TwistLowerAngle = -90
  569. local collidepartofleftleg = Instance.new("Part", clone.Torso)
  570. collidepartofleftleg.Name = "Bone"
  571. collidepartofleftleg.Size = Vector3.new(0.7,0.7,0.7)
  572. collidepartofleftleg.Transparency = 1
  573. collidepartofleftleg:BreakJoints()
  574. local weeld = Instance.new("Weld", collidepartofleftleg)
  575. weeld.Part0 = collidepartofleftleg
  576. weeld.Part1 = clone["Head"]
  577. end
  578. if leftleg ~= nil then
  579. local glue = Instance.new("Glue", clone.Torso)
  580. glue.Part0 = clone.Torso
  581. glue.Part1 = leftleg
  582. glue.Name = "Left leg"
  583. local collider = Instance.new("Part", leftleg)
  584. collider.Position = Vector3.new(0,999,0)
  585. collider.Size = Vector3.new(1.5, 1, 1)
  586. collider.Shape = "Cylinder"
  587. local weld = Instance.new("Weld", collider)
  588. weld.Part0 = leftleg
  589. weld.Part1 = collider
  590. weld.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  591. collider.TopSurface = "Smooth"
  592. collider.BottomSurface = "Smooth"
  593. collider.formFactor = "Symmetric"
  594. glue.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  595. glue.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  596. collider.Transparency = 1
  597. end
  598. ------------
  599. if rightleg ~= nil then
  600. local glue1 = Instance.new("Glue", clone.Torso)
  601. glue1.Part0 = clone.Torso
  602. glue1.Part1 = rightleg
  603. glue1.Name = "Right leg"
  604. local collider1 = Instance.new("Part", rightleg)
  605. collider1.Position = Vector3.new(0,999,0)
  606. collider1.Size = Vector3.new(1.5, 1, 1)
  607. collider1.Shape = "Cylinder"
  608. local weld1 = Instance.new("Weld", collider1)
  609. weld1.Part0 = rightleg
  610. weld1.Part1 = collider1
  611. weld1.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  612. collider1.TopSurface = "Smooth"
  613. collider1.BottomSurface = "Smooth"
  614. collider1.formFactor = "Symmetric"
  615. glue1.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  616. glue1.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  617. collider1.Transparency = 1
  618. end
  619. ------------
  620. if rightrm ~= nil then
  621. local glue11 = Instance.new("Glue", clone.Torso)
  622. glue11.Part0 = clone.Torso
  623. glue11.Part1 = rightrm
  624. glue11.Name = "Right shoulder"
  625. local collider11 = Instance.new("Part", rightrm)
  626. collider11.Position = Vector3.new(0,9999,0)
  627. collider11.Size = Vector3.new(1.5,1,1)
  628. collider11.Shape = "Cylinder"
  629. local weld11 = Instance.new("Weld", collider11)
  630. weld11.Part0 = rightrm
  631. weld11.Part1 = collider11
  632. weld11.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  633. collider11.TopSurface = "Smooth"
  634. collider11.BottomSurface = "Smooth"
  635. collider11.formFactor = "Symmetric"
  636. glue11.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  637. glue11.C1 = CFrame.new(0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, 0, 0)
  638. collider11.Transparency = 1
  639. end
  640. ------------
  641. if leftarm ~= nil then
  642. local glue111 = Instance.new("Glue", clone.Torso)
  643. glue111.Part0 = clone.Torso
  644. glue111.Part1 = leftarm
  645. glue111.Name = "Left shoulder"
  646. local collider111 = Instance.new("Part", leftarm)
  647. collider111.Position = Vector3.new(0,9999,0)
  648. collider111.Size = Vector3.new(1.5,1,1)
  649. collider111.Shape = "Cylinder"
  650. local weld111 = Instance.new("Weld", collider111)
  651. weld111.Part0 = leftarm
  652. weld111.Part1 = collider111
  653. weld111.C0 = CFrame.new(0,-0.2,0) * CFrame.fromEulerAnglesXYZ(0, 0, math.pi/2)
  654. collider111.TopSurface = "Smooth"
  655. collider111.BottomSurface = "Smooth"
  656. collider111.formFactor = "Symmetric"
  657. glue111.C0 = CFrame.new(-1.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  658. glue111.C1 = CFrame.new(0, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  659. collider111.Transparency = 1
  660. ----------------
  661. sensoring = Instance.new("Part", clone.Torso)
  662. sensoring.Size = Vector3.new(1.2,1.1,0.8)
  663. sensoring.CanCollide = false
  664. sensoring.Position = clone.Torso.Position
  665. local welder = Instance.new("Weld", sensoring)
  666. welder.Part0 = clone.Torso
  667. welder.Part1 = sensoring
  668. welder.C0 = welder.C0 * CFrame.new(0,0,1.05)
  669. sensoring.Transparency = 1
  670. -----------------
  671. sensoring1 = Instance.new("Part", clone.Torso)
  672. sensoring1.Size = Vector3.new(1.2,1.1,0.8)
  673. sensoring1.CanCollide = false
  674. sensoring1.Position = clone.Torso.Position
  675. local welder1 = Instance.new("Weld", sensoring)
  676. welder1.Part0 = clone.Torso
  677. welder1.Part1 = sensoring1
  678. welder1.C0 = welder1.C0 * CFrame.new(0,0,-1.05)
  679. sensoring1.Transparency = 1
  680. end
  681. clone.Name = game.Players.LocalPlayer.Character.Name.." (OOF'D)"
  682. ded:Play()
  683. vel:destroy()
  684. wait(0.2)
  685. game.Debris:AddItem(clone,60)
  686. local function touch()
  687. if not using then
  688. using = true
  689. local Math = math.random(1,4)
  690. if Math == 1 then
  691. hit:Play()
  692. end
  693. if Math == 2 then
  694. hit1:Play()
  695. end
  696. if Math == 3 then
  697. hit2:Play()
  698. end
  699. if Math == 4 then
  700. hit3:Play()
  701. end
  702. wait(0.1)
  703. using = false
  704. end
  705. end
  706. sensoring.Touched:connect(touch)
  707. sensoring1.Touched:connect(touch)
  708. while true do
  709. clone.Head.CanCollide = false
  710. game:GetService("RunService").Stepped:wait()
  711. end
  712. end
  713.  
  714. game.Players.LocalPlayer.Character.Humanoid.Died:connect(ragdoll)
  715.  
  716. --di ent
  717. while true do
  718. if cananimate then
  719. 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
  720. for i = 0.1,0.3 , 0.008 do
  721. 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
  722. 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)
  723. 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)
  724. game:GetService("RunService").Stepped:wait()
  725. end
  726. end
  727. for i = 0.1,0.3 , 0.008 do
  728. 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
  729. 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)
  730. 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)
  731. game:GetService("RunService").Stepped:wait()
  732. end
  733. end
  734. 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
  735. for i = 0,1 , 0.1 do
  736. 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
  737. weld.C0 = weld.C0:lerp(CFrame.new(0.0769970417, -1.17027426, -1.17937994, 0, 0, 1, -0.999999881, 0, 0, 0, -1, 0),i)
  738. 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)
  739. humanoidrootpart.C0 = humanoidrootpart.C0:lerp(CFrame.new(0, 0, 0, 0.955355227, 0, -0.295459419, 0, 1, 0, 0.295459419, 0, 0.955355227),i)
  740. 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)
  741. 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)
  742. game:GetService("RunService").RenderStepped:wait()
  743. end
  744. end
  745. end
  746. end
  747. wait()
  748. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement