Advertisement
crustytoe6969

very long worm

Jan 8th, 2023
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 58.85 KB | None | 0 0
  1. --made by 1+1=2/rouxhaver
  2. --reanimate made by myworld
  3. --only works in r6
  4.  
  5.  
  6. --REQURIRED hats/hair (use roblox website to equip more than one hair)
  7. --https://www.roblox.com/catalog/48474313/Red-Roblox-Cap
  8. --https://www.roblox.com/catalog/62724852/Chestnut-Bun
  9. --https://www.roblox.com/catalog/451220849/Lavender-Updo
  10. --https://www.roblox.com/catalog/48474294/ROBLOX-Girl-Hair
  11. --https://www.roblox.com/catalog/376527115/Jade-Necklace-with-Shell-Pendant
  12. --https://www.roblox.com/catalog/63690008/Pal-Hair
  13. --https://www.roblox.com/catalog/62234425/Brown-Hair
  14. --https://www.roblox.com/catalog/4047554959/International-Fedora-Brazil
  15. --https://www.roblox.com/catalog/3409612660/International-Fedora-USA
  16. --https://www.roblox.com/catalog/301818806/Serenas-Hair
  17. --(NO other hats/hairs can be worn)
  18.  
  19. --new features:
  20. --Snake collides with other peoples limbs and hats
  21. --Snake will go up when not moving
  22.  
  23.  
  24.  
  25. if workspace:FindFirstChild("COLISION CHECKER") == nil then
  26. checker = Instance.new("BoolValue",workspace)
  27. checker.Name = "COLISION CHECKER"
  28. LP = game.Players.LocalPlayer
  29. coroutine.wrap(function()
  30. while wait(3) do
  31. for i,v in pairs(game.Players:GetDescendants()) do
  32. if v:IsA("Player") and workspace:FindFirstChild(v.Name) and v ~= LP and workspace[v.Name]:FindFirstChild("CHECKER") == nil then
  33. checker = Instance.new("BoolValue",workspace[v.Name])
  34. checker.Name = "CHECKER"
  35. for i,v in pairs(workspace:WaitForChild(v.Name):GetDescendants()) do
  36. if v:IsA("Part") or v:IsA("MeshPart") then
  37. local collider = Instance.new("Part",v)
  38. collider.Size = v.Size
  39. collider.Position = v.Position
  40. collider.Transparency = 1
  41. local weld = Instance.new("Weld",v)
  42. weld.Part0 = v
  43. weld.Part1 = collider
  44. end
  45. end
  46. end
  47. end
  48. end
  49. end)()
  50. end
  51.  
  52.  
  53. me = workspace[game.Players.LocalPlayer.Name]
  54.  
  55. local rtype = 0
  56. if me.Humanoid.RigType == Enum.HumanoidRigType.R6 then
  57. rtype = 1
  58. end
  59.  
  60. local v3_net, v3_808 = Vector3.new(0.1, 25.1, 0.1), Vector3.new(8, 0, 8)
  61. local function getNetlessVelocity(realPartVelocity)
  62. if realPartVelocity.Magnitude > 1 then
  63. local unit = realPartVelocity.Unit
  64. if (unit.Y > 0.25) or (unit.Y < -0.75) then
  65. return unit * (25.1 / unit.Y)
  66. end
  67. end
  68. return v3_net + realPartVelocity * v3_808
  69. end
  70. local simradius = "shp" --simulation radius (net bypass) method
  71. --"shp" - sethiddenproperty
  72. --"ssr" - setsimulationradius
  73. --false - disable
  74. local simrad = math.huge --simulation radius value
  75. local healthHide = false --moves your head away every 3 seconds so players dont see your health bar (alignmode 4 only)
  76. local reclaim = true --if you lost control over a part this will move your primary part to the part so you get it back (alignmode 4)
  77. local novoid = true --prevents parts from going under workspace.FallenPartsDestroyHeight if you control them (alignmode 4 only)
  78. local physp = nil --PhysicalProperties.new(0.01, 0, 1, 0, 0) --sets .CustomPhysicalProperties to this for each part
  79. local noclipAllParts = false --set it to true if you want noclip
  80. local antiragdoll = true --removes hingeConstraints and ballSocketConstraints from your character
  81. local newanimate = true --disables the animate script and enables after reanimation
  82. local discharscripts = true --disables all localScripts parented to your character before reanimation
  83. local R15toR6 = true --tries to convert your character to r6 if its r15
  84. local hatcollide = true --makes hats cancollide (credit to ShownApe) (works only with reanimate method 0)
  85. local humState16 = true --enables collisions for limbs before the humanoid dies (using hum:ChangeState)
  86. local addtools = false --puts all tools from backpack to character and lets you hold them after reanimation
  87. local hedafterneck = true --disable aligns for head and enable after neck or torso is removed
  88. local loadtime = game:GetService("Players").RespawnTime + 0.5 --anti respawn delay
  89. local method = 3 --reanimation method
  90. --methods:
  91. --0 - breakJoints (takes [loadtime] seconds to load)
  92. --1 - limbs
  93. --2 - limbs + anti respawn
  94. --3 - limbs + breakJoints after [loadtime] seconds
  95. --4 - remove humanoid + breakJoints
  96. --5 - remove humanoid + limbs
  97. local alignmode = 1 --AlignPosition mode
  98. --modes:
  99. --1 - AlignPosition rigidity enabled true
  100. --2 - 2 AlignPositions rigidity enabled both true and false
  101. --3 - AlignPosition rigidity enabled false
  102. --4 - no AlignPosition, CFrame only
  103. local flingpart = "HumanoidRootPart" --name of the part or the hat used for flinging
  104. --the fling function
  105. --usage: fling(target, duration, velocity)
  106. --target can be set to: basePart, CFrame, Vector3, character model or humanoid (flings at mouse.Hit if argument not provided)
  107. --duration (fling time in seconds) can be set to a number or a string convertable to a number (0.5s if not provided)
  108. --velocity (fling part rotation velocity) can be set to a vector3 value (Vector3.new(20000, 20000, 20000) if not provided)
  109.  
  110. local lp = game:GetService("Players").LocalPlayer
  111. local rs, ws, sg = game:GetService("RunService"), game:GetService("Workspace"), game:GetService("StarterGui")
  112. local stepped, heartbeat, renderstepped = rs.Stepped, rs.Heartbeat, rs.RenderStepped
  113. local twait, tdelay, rad, inf, abs, clamp = task.wait, task.delay, math.rad, math.huge, math.abs, math.clamp
  114. local cf, v3, angles = CFrame.new, Vector3.new, CFrame.Angles
  115. local v3_0, cf_0 = v3(0, 0, 0), cf(0, 0, 0)
  116.  
  117. local c = lp.Character
  118. if not (c and c.Parent) then
  119. return
  120. end
  121.  
  122. c:GetPropertyChangedSignal("Parent"):Connect(function()
  123. if not (c and c.Parent) then
  124. c = nil
  125. end
  126. end)
  127.  
  128. local clone, destroy, getchildren, getdescendants, isa = c.Clone, c.Destroy, c.GetChildren, c.GetDescendants, c.IsA
  129.  
  130. local function gp(parent, name, className)
  131. if typeof(parent) == "Instance" then
  132. for i, v in pairs(getchildren(parent)) do
  133. if (v.Name == name) and isa(v, className) then
  134. return v
  135. end
  136. end
  137. end
  138. return nil
  139. end
  140.  
  141. local fenv = getfenv()
  142.  
  143. local shp = fenv.sethiddenproperty or fenv.set_hidden_property or fenv.set_hidden_prop or fenv.sethiddenprop
  144. local ssr = fenv.setsimulationradius or fenv.set_simulation_radius or fenv.set_sim_radius or fenv.setsimradius or fenv.setsimrad or fenv.set_sim_rad
  145.  
  146. healthHide = healthHide and ((method == 0) or (method == 2) or (method == 3)) and gp(c, "Head", "BasePart")
  147.  
  148. local reclaim, lostpart = reclaim and c.PrimaryPart, nil
  149.  
  150. local function align(Part0, Part1)
  151.  
  152. local att0 = Instance.new("Attachment")
  153. att0.Position, att0.Orientation, att0.Name = v3_0, v3_0, "att0_" .. Part0.Name
  154. local att1 = Instance.new("Attachment")
  155. att1.Position, att1.Orientation, att1.Name = v3_0, v3_0, "att1_" .. Part1.Name
  156.  
  157. if alignmode == 4 then
  158.  
  159. local hide = false
  160. if Part0 == healthHide then
  161. healthHide = false
  162. tdelay(0, function()
  163. while twait(2.9) and Part0 and c do
  164. hide = #Part0:GetConnectedParts() == 1
  165. twait(0.1)
  166. hide = false
  167. end
  168. end)
  169. end
  170.  
  171. local rot = rad(0.05)
  172. local con0, con1 = nil, nil
  173. con0 = stepped:Connect(function()
  174. if not (Part0 and Part1) then return con0:Disconnect() and con1:Disconnect() end
  175. Part0.RotVelocity = Part1.RotVelocity
  176. end)
  177. local lastpos = Part0.Position
  178. con1 = heartbeat:Connect(function(delta)
  179. if not (Part0 and Part1 and att1) then return con0:Disconnect() and con1:Disconnect() end
  180. if (not Part0.Anchored) and (Part0.ReceiveAge == 0) then
  181. if lostpart == Part0 then
  182. lostpart = nil
  183. end
  184. local newcf = Part1.CFrame * att1.CFrame
  185. if Part1.Velocity.Magnitude > 0.1 then
  186. Part0.Velocity = getNetlessVelocity(Part1.Velocity)
  187. else
  188. local vel = (newcf.Position - lastpos) / delta
  189. Part0.Velocity = getNetlessVelocity(vel)
  190. if vel.Magnitude < 1 then
  191. rot = -rot
  192. newcf *= angles(0, 0, rot)
  193. end
  194. end
  195. lastpos = newcf.Position
  196. if lostpart and (Part0 == reclaim) then
  197. newcf = lostpart.CFrame
  198. elseif hide then
  199. newcf += v3(0, 3000, 0)
  200. end
  201. if novoid and (newcf.Y < ws.FallenPartsDestroyHeight + 0.1) then
  202. newcf += v3(0, ws.FallenPartsDestroyHeight + 0.1 - newcf.Y, 0)
  203. end
  204. Part0.CFrame = newcf
  205. elseif (not Part0.Anchored) and (abs(Part0.Velocity.X) < 45) and (abs(Part0.Velocity.Y) < 25) and (abs(Part0.Velocity.Z) < 45) then
  206. lostpart = Part0
  207. end
  208. end)
  209.  
  210. else
  211.  
  212. Part0.CustomPhysicalProperties = physp
  213. if (alignmode == 1) or (alignmode == 2) then
  214. local ape = Instance.new("AlignPosition")
  215. ape.MaxForce, ape.MaxVelocity, ape.Responsiveness = inf, inf, inf
  216. ape.ReactionForceEnabled, ape.RigidityEnabled, ape.ApplyAtCenterOfMass = false, true, false
  217. ape.Attachment0, ape.Attachment1, ape.Name = att0, att1, "AlignPositionRtrue"
  218. ape.Parent = att0
  219. end
  220.  
  221. if (alignmode == 2) or (alignmode == 3) then
  222. local apd = Instance.new("AlignPosition")
  223. apd.MaxForce, apd.MaxVelocity, apd.Responsiveness = inf, inf, inf
  224. apd.ReactionForceEnabled, apd.RigidityEnabled, apd.ApplyAtCenterOfMass = false, false, false
  225. apd.Attachment0, apd.Attachment1, apd.Name = att0, att1, "AlignPositionRfalse"
  226. apd.Parent = att0
  227. end
  228.  
  229. local ao = Instance.new("AlignOrientation")
  230. ao.MaxAngularVelocity, ao.MaxTorque, ao.Responsiveness = inf, inf, inf
  231. ao.PrimaryAxisOnly, ao.ReactionTorqueEnabled, ao.RigidityEnabled = false, false, false
  232. ao.Attachment0, ao.Attachment1 = att0, att1
  233. ao.Parent = att0
  234.  
  235. local con0, con1 = nil, nil
  236. local vel = Part0.Velocity
  237. con0 = renderstepped:Connect(function()
  238. if not (Part0 and Part1) then return con0:Disconnect() and con1:Disconnect() end
  239. Part0.Velocity = vel
  240. end)
  241. local lastpos = Part0.Position
  242. con1 = heartbeat:Connect(function(delta)
  243. if not (Part0 and Part1) then return con0:Disconnect() and con1:Disconnect() end
  244. vel = Part0.Velocity
  245. if Part1.Velocity.Magnitude > 0.01 then
  246. Part0.Velocity = getNetlessVelocity(Part1.Velocity)
  247. else
  248. Part0.Velocity = getNetlessVelocity((Part0.Position - lastpos) / delta)
  249. end
  250. lastpos = Part0.Position
  251. end)
  252.  
  253. end
  254.  
  255. att0:GetPropertyChangedSignal("Parent"):Connect(function()
  256. Part0 = att0.Parent
  257. if not isa(Part0, "BasePart") then
  258. att0 = nil
  259. if lostpart == Part0 then
  260. lostpart = nil
  261. end
  262. Part0 = nil
  263. end
  264. end)
  265. att0.Parent = Part0
  266.  
  267. att1:GetPropertyChangedSignal("Parent"):Connect(function()
  268. Part1 = att1.Parent
  269. if not isa(Part1, "BasePart") then
  270. att1 = nil
  271. Part1 = nil
  272. end
  273. end)
  274. att1.Parent = Part1
  275. end
  276.  
  277. local function respawnrequest()
  278. local ccfr, c = ws.CurrentCamera.CFrame, lp.Character
  279. lp.Character = nil
  280. lp.Character = c
  281. local con = nil
  282. con = ws.CurrentCamera.Changed:Connect(function(prop)
  283. if (prop ~= "Parent") and (prop ~= "CFrame") then
  284. return
  285. end
  286. ws.CurrentCamera.CFrame = ccfr
  287. con:Disconnect()
  288. end)
  289. end
  290.  
  291. local destroyhum = (method == 4) or (method == 5)
  292. local breakjoints = (method == 0) or (method == 4)
  293. local antirespawn = (method == 0) or (method == 2) or (method == 3)
  294.  
  295. hatcollide = hatcollide and (method == 0)
  296.  
  297. addtools = addtools and lp:FindFirstChildOfClass("Backpack")
  298.  
  299. if type(simrad) ~= "number" then simrad = 1000 end
  300. if shp and (simradius == "shp") then
  301. tdelay(0, function()
  302. while c do
  303. shp(lp, "SimulationRadius", simrad)
  304. heartbeat:Wait()
  305. end
  306. end)
  307. elseif ssr and (simradius == "ssr") then
  308. tdelay(0, function()
  309. while c do
  310. ssr(simrad)
  311. heartbeat:Wait()
  312. end
  313. end)
  314. end
  315.  
  316. if antiragdoll then
  317. antiragdoll = function(v)
  318. if isa(v, "HingeConstraint") or isa(v, "BallSocketConstraint") then
  319. v.Parent = nil
  320. end
  321. end
  322. for i, v in pairs(getdescendants(c)) do
  323. antiragdoll(v)
  324. end
  325. c.DescendantAdded:Connect(antiragdoll)
  326. end
  327.  
  328. if antirespawn then
  329. respawnrequest()
  330. end
  331.  
  332. if method == 0 then
  333. twait(loadtime)
  334. if not c then
  335. return
  336. end
  337. end
  338.  
  339. if discharscripts then
  340. for i, v in pairs(getdescendants(c)) do
  341. if isa(v, "LocalScript") then
  342. v.Disabled = true
  343. end
  344. end
  345. elseif newanimate then
  346. local animate = gp(c, "Animate", "LocalScript")
  347. if animate and (not animate.Disabled) then
  348. animate.Disabled = true
  349. else
  350. newanimate = false
  351. end
  352. end
  353.  
  354. if addtools then
  355. for i, v in pairs(getchildren(addtools)) do
  356. if isa(v, "Tool") then
  357. v.Parent = c
  358. end
  359. end
  360. end
  361.  
  362. pcall(function()
  363. settings().Physics.AllowSleep = false
  364. settings().Physics.PhysicsEnvironmentalThrottle = Enum.EnviromentalPhysicsThrottle.Disabled
  365. end)
  366.  
  367. local OLDscripts = {}
  368.  
  369. for i, v in pairs(getdescendants(c)) do
  370. if v.ClassName == "Script" then
  371. OLDscripts[v.Name] = true
  372. end
  373. end
  374.  
  375. local scriptNames = {}
  376.  
  377. for i, v in pairs(getdescendants(c)) do
  378. if isa(v, "BasePart") then
  379. local newName, exists = tostring(i), true
  380. while exists do
  381. exists = OLDscripts[newName]
  382. if exists then
  383. newName = newName .. "_"
  384. end
  385. end
  386. table.insert(scriptNames, newName)
  387. Instance.new("Script", v).Name = newName
  388. end
  389. end
  390.  
  391. local hum = c:FindFirstChildOfClass("Humanoid")
  392. if hum then
  393. for i, v in pairs(hum:GetPlayingAnimationTracks()) do
  394. v:Stop()
  395. end
  396. end
  397. c.Archivable = true
  398. local cl = clone(c)
  399. if hum and humState16 then
  400. hum:ChangeState(Enum.HumanoidStateType.Physics)
  401. if destroyhum then
  402. twait(1.6)
  403. end
  404. end
  405. if destroyhum then
  406. pcall(destroy, hum)
  407. end
  408.  
  409. if not c then
  410. return
  411. end
  412.  
  413. local head, torso, root = gp(c, "Head", "BasePart"), gp(c, "Torso", "BasePart") or gp(c, "UpperTorso", "BasePart"), gp(c, "HumanoidRootPart", "BasePart")
  414. if hatcollide then
  415. pcall(destroy, torso)
  416. pcall(destroy, root)
  417. pcall(destroy, c:FindFirstChildOfClass("BodyColors") or gp(c, "Health", "Script"))
  418. end
  419.  
  420. local model = Instance.new("Model", c)
  421. model:GetPropertyChangedSignal("Parent"):Connect(function()
  422. if not (model and model.Parent) then
  423. model = nil
  424. end
  425. end)
  426.  
  427. for i, v in pairs(getchildren(c)) do
  428. if v ~= model then
  429. if addtools and isa(v, "Tool") then
  430. for i1, v1 in pairs(getdescendants(v)) do
  431. if v1 and v1.Parent and isa(v1, "BasePart") then
  432. local bv = Instance.new("BodyVelocity")
  433. bv.Velocity, bv.MaxForce, bv.P, bv.Name = v3_0, v3(1000, 1000, 1000), 1250, "bv_" .. v.Name
  434. bv.Parent = v1
  435. end
  436. end
  437. end
  438. v.Parent = model
  439. end
  440. end
  441.  
  442. if breakjoints then
  443. model:BreakJoints()
  444. else
  445. if head and torso then
  446. for i, v in pairs(getdescendants(model)) do
  447. if isa(v, "JointInstance") then
  448. local save = false
  449. if (v.Part0 == torso) and (v.Part1 == head) then
  450. save = true
  451. end
  452. if (v.Part0 == head) and (v.Part1 == torso) then
  453. save = true
  454. end
  455. if save then
  456. if hedafterneck then
  457. hedafterneck = v
  458. end
  459. else
  460. pcall(destroy, v)
  461. end
  462. end
  463. end
  464. end
  465. if method == 3 then
  466. task.delay(loadtime, pcall, model.BreakJoints, model)
  467. end
  468. end
  469.  
  470. cl.Parent = ws
  471. for i, v in pairs(getchildren(cl)) do
  472. v.Parent = c
  473. end
  474. pcall(destroy, cl)
  475.  
  476. local uncollide, noclipcon = nil, nil
  477. if noclipAllParts then
  478. uncollide = function()
  479. if c then
  480. for i, v in pairs(getdescendants(c)) do
  481. if isa(v, "BasePart") then
  482. v.CanCollide = false
  483. end
  484. end
  485. else
  486. noclipcon:Disconnect()
  487. end
  488. end
  489. else
  490. uncollide = function()
  491. if model then
  492. for i, v in pairs(getdescendants(model)) do
  493. if isa(v, "BasePart") then
  494. v.CanCollide = false
  495. end
  496. end
  497. else
  498. noclipcon:Disconnect()
  499. end
  500. end
  501. end
  502. noclipcon = stepped:Connect(uncollide)
  503. uncollide()
  504.  
  505. for i, scr in pairs(getdescendants(model)) do
  506. if (scr.ClassName == "Script") and table.find(scriptNames, scr.Name) then
  507. local Part0 = scr.Parent
  508. if isa(Part0, "BasePart") then
  509. for i1, scr1 in pairs(getdescendants(c)) do
  510. if (scr1.ClassName == "Script") and (scr1.Name == scr.Name) and (not scr1:IsDescendantOf(model)) then
  511. local Part1 = scr1.Parent
  512. if (Part1.ClassName == Part0.ClassName) and (Part1.Name == Part0.Name) then
  513. align(Part0, Part1)
  514. pcall(destroy, scr)
  515. pcall(destroy, scr1)
  516. break
  517. end
  518. end
  519. end
  520. end
  521. end
  522. end
  523.  
  524. for i, v in pairs(getdescendants(c)) do
  525. if v and v.Parent and (not v:IsDescendantOf(model)) then
  526. if isa(v, "Decal") then
  527. v.Transparency = 1
  528. elseif isa(v, "BasePart") then
  529. v.Transparency = 1
  530. v.Anchored = false
  531. elseif isa(v, "ForceField") then
  532. v.Visible = false
  533. elseif isa(v, "Sound") then
  534. v.Playing = false
  535. elseif isa(v, "BillboardGui") or isa(v, "SurfaceGui") or isa(v, "ParticleEmitter") or isa(v, "Fire") or isa(v, "Smoke") or isa(v, "Sparkles") then
  536. v.Enabled = false
  537. end
  538. end
  539. end
  540.  
  541. if newanimate then
  542. local animate = gp(c, "Animate", "LocalScript")
  543. if animate then
  544. animate.Disabled = false
  545. end
  546. end
  547.  
  548. if addtools then
  549. for i, v in pairs(getchildren(c)) do
  550. if isa(v, "Tool") then
  551. v.Parent = addtools
  552. end
  553. end
  554. end
  555.  
  556. local hum0, hum1 = model:FindFirstChildOfClass("Humanoid"), c:FindFirstChildOfClass("Humanoid")
  557. if hum0 then
  558. hum0:GetPropertyChangedSignal("Parent"):Connect(function()
  559. if not (hum0 and hum0.Parent) then
  560. hum0 = nil
  561. end
  562. end)
  563. end
  564. if hum1 then
  565. hum1:GetPropertyChangedSignal("Parent"):Connect(function()
  566. if not (hum1 and hum1.Parent) then
  567. hum1 = nil
  568. end
  569. end)
  570.  
  571. ws.CurrentCamera.CameraSubject = hum1
  572. local camSubCon = nil
  573. local function camSubFunc()
  574. camSubCon:Disconnect()
  575. if c and hum1 then
  576. ws.CurrentCamera.CameraSubject = hum1
  577. end
  578. end
  579. camSubCon = renderstepped:Connect(camSubFunc)
  580. if hum0 then
  581. hum0:GetPropertyChangedSignal("Jump"):Connect(function()
  582. if hum1 then
  583. hum1.Jump = hum0.Jump
  584. end
  585. end)
  586. else
  587. respawnrequest()
  588. end
  589. end
  590.  
  591. local rb = Instance.new("BindableEvent", c)
  592. rb.Event:Connect(function()
  593. pcall(destroy, rb)
  594. sg:SetCore("ResetButtonCallback", true)
  595. if destroyhum then
  596. if c then c:BreakJoints() end
  597. return
  598. end
  599. if model and hum0 and (hum0.Health > 0) then
  600. model:BreakJoints()
  601. hum0.Health = 0
  602. end
  603. if antirespawn then
  604. respawnrequest()
  605. end
  606. end)
  607. sg:SetCore("ResetButtonCallback", rb)
  608.  
  609. tdelay(0, function()
  610. while c do
  611. if hum0 and hum1 then
  612. hum1.Jump = hum0.Jump
  613. end
  614. wait()
  615. end
  616. sg:SetCore("ResetButtonCallback", true)
  617. end)
  618.  
  619. R15toR6 = R15toR6 and hum1 and (hum1.RigType == Enum.HumanoidRigType.R15)
  620. if R15toR6 then
  621. local part = gp(c, "HumanoidRootPart", "BasePart") or gp(c, "UpperTorso", "BasePart") or gp(c, "LowerTorso", "BasePart") or gp(c, "Head", "BasePart") or c:FindFirstChildWhichIsA("BasePart")
  622. if part then
  623. local cfr = part.CFrame
  624. local R6parts = {
  625. head = {
  626. Name = "Head",
  627. Size = v3(2, 1, 1),
  628. R15 = {
  629. Head = 0
  630. }
  631. },
  632. torso = {
  633. Name = "Torso",
  634. Size = v3(2, 2, 1),
  635. R15 = {
  636. UpperTorso = 0.2,
  637. LowerTorso = -0.8
  638. }
  639. },
  640. root = {
  641. Name = "HumanoidRootPart",
  642. Size = v3(2, 2, 1),
  643. R15 = {
  644. HumanoidRootPart = 0
  645. }
  646. },
  647. leftArm = {
  648. Name = "Left Arm",
  649. Size = v3(1, 2, 1),
  650. R15 = {
  651. LeftHand = -0.849,
  652. LeftLowerArm = -0.174,
  653. LeftUpperArm = 0.415
  654. }
  655. },
  656. rightArm = {
  657. Name = "Right Arm",
  658. Size = v3(1, 2, 1),
  659. R15 = {
  660. RightHand = -0.849,
  661. RightLowerArm = -0.174,
  662. RightUpperArm = 0.415
  663. }
  664. },
  665. leftLeg = {
  666. Name = "Left Leg",
  667. Size = v3(1, 2, 1),
  668. R15 = {
  669. LeftFoot = -0.85,
  670. LeftLowerLeg = -0.29,
  671. LeftUpperLeg = 0.49
  672. }
  673. },
  674. rightLeg = {
  675. Name = "Right Leg",
  676. Size = v3(1, 2, 1),
  677. R15 = {
  678. RightFoot = -0.85,
  679. RightLowerLeg = -0.29,
  680. RightUpperLeg = 0.49
  681. }
  682. }
  683. }
  684. for i, v in pairs(getchildren(c)) do
  685. if isa(v, "BasePart") then
  686. for i1, v1 in pairs(getchildren(v)) do
  687. if isa(v1, "Motor6D") then
  688. v1.Part0 = nil
  689. end
  690. end
  691. end
  692. end
  693. part.Archivable = true
  694. for i, v in pairs(R6parts) do
  695. local part = clone(part)
  696. part:ClearAllChildren()
  697. part.Name, part.Size, part.CFrame, part.Anchored, part.Transparency, part.CanCollide = v.Name, v.Size, cfr, false, 1, false
  698. for i1, v1 in pairs(v.R15) do
  699. local R15part = gp(c, i1, "BasePart")
  700. local att = gp(R15part, "att1_" .. i1, "Attachment")
  701. if R15part then
  702. local weld = Instance.new("Weld")
  703. weld.Part0, weld.Part1, weld.C0, weld.C1, weld.Name = part, R15part, cf(0, v1, 0), cf_0, "Weld_" .. i1
  704. weld.Parent = R15part
  705. R15part.Massless, R15part.Name = true, "R15_" .. i1
  706. R15part.Parent = part
  707. if att then
  708. att.Position = v3(0, v1, 0)
  709. att.Parent = part
  710. end
  711. end
  712. end
  713. part.Parent = c
  714. R6parts[i] = part
  715. end
  716. local R6joints = {
  717. neck = {
  718. Parent = R6parts.torso,
  719. Name = "Neck",
  720. Part0 = R6parts.torso,
  721. Part1 = R6parts.head,
  722. C0 = cf(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0),
  723. C1 = cf(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
  724. },
  725. rootJoint = {
  726. Parent = R6parts.root,
  727. Name = "RootJoint" ,
  728. Part0 = R6parts.root,
  729. Part1 = R6parts.torso,
  730. C0 = cf(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0),
  731. C1 = cf(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
  732. },
  733. rightShoulder = {
  734. Parent = R6parts.torso,
  735. Name = "Right Shoulder",
  736. Part0 = R6parts.torso,
  737. Part1 = R6parts.rightArm,
  738. C0 = cf(1, 0.5, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0),
  739. C1 = cf(-0.5, 0.5, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  740. },
  741. leftShoulder = {
  742. Parent = R6parts.torso,
  743. Name = "Left Shoulder",
  744. Part0 = R6parts.torso,
  745. Part1 = R6parts.leftArm,
  746. C0 = cf(-1, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0),
  747. C1 = cf(0.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  748. },
  749. rightHip = {
  750. Parent = R6parts.torso,
  751. Name = "Right Hip",
  752. Part0 = R6parts.torso,
  753. Part1 = R6parts.rightLeg,
  754. C0 = cf(1, -1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0),
  755. C1 = cf(0.5, 1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  756. },
  757. leftHip = {
  758. Parent = R6parts.torso,
  759. Name = "Left Hip" ,
  760. Part0 = R6parts.torso,
  761. Part1 = R6parts.leftLeg,
  762. C0 = cf(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0),
  763. C1 = cf(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  764. }
  765. }
  766. for i, v in pairs(R6joints) do
  767. local joint = Instance.new("Motor6D")
  768. for prop, val in pairs(v) do
  769. joint[prop] = val
  770. end
  771. R6joints[i] = joint
  772. end
  773. if hum1 then
  774. hum1.RigType, hum1.HipHeight = Enum.HumanoidRigType.R6, 0
  775. end
  776. end
  777. --the default roblox animate script edited and put in one line
  778. local script = gp(c, "Animate", "LocalScript") if not script.Disabled then script:ClearAllChildren() local Torso = gp(c, "Torso", "BasePart") local RightShoulder = gp(Torso, "Right Shoulder", "Motor6D") local LeftShoulder = gp(Torso, "Left Shoulder", "Motor6D") local RightHip = gp(Torso, "Right Hip", "Motor6D") local LeftHip = gp(Torso, "Left Hip", "Motor6D") local Neck = gp(Torso, "Neck", "Motor6D") local Humanoid = c:FindFirstChildOfClass("Humanoid") local pose = "Standing" local currentAnim = "" local currentAnimInstance = nil local currentAnimTrack = nil local currentAnimKeyframeHandler = nil local currentAnimSpeed = 1.0 local animTable = {} local animNames = { idle = { { id = "http://www.roblox.com/asset/?id=180435571", weight = 9 }, { id = "http://www.roblox.com/asset/?id=180435792", weight = 1 } }, walk = { { id = "http://www.roblox.com/asset/?id=180426354", weight = 10 } }, run = { { id = "run.xml", weight = 10 } }, jump = { { id = "http://www.roblox.com/asset/?id=125750702", weight = 10 } }, fall = { { id = "http://www.roblox.com/asset/?id=180436148", weight = 10 } }, climb = { { id = "http://www.roblox.com/asset/?id=180436334", weight = 10 } }, sit = { { id = "http://www.roblox.com/asset/?id=178130996", weight = 10 } }, toolnone = { { id = "http://www.roblox.com/asset/?id=182393478", weight = 10 } }, toolslash = { { id = "http://www.roblox.com/asset/?id=129967390", weight = 10 } }, toollunge = { { id = "http://www.roblox.com/asset/?id=129967478", weight = 10 } }, wave = { { id = "http://www.roblox.com/asset/?id=128777973", weight = 10 } }, point = { { id = "http://www.roblox.com/asset/?id=128853357", weight = 10 } }, dance1 = { { id = "http://www.roblox.com/asset/?id=182435998", weight = 10 }, { id = "http://www.roblox.com/asset/?id=182491037", weight = 10 }, { id = "http://www.roblox.com/asset/?id=182491065", weight = 10 } }, dance2 = { { id = "http://www.roblox.com/asset/?id=182436842", weight = 10 }, { id = "http://www.roblox.com/asset/?id=182491248", weight = 10 }, { id = "http://www.roblox.com/asset/?id=182491277", weight = 10 } }, dance3 = { { id = "http://www.roblox.com/asset/?id=182436935", weight = 10 }, { id = "http://www.roblox.com/asset/?id=182491368", weight = 10 }, { id = "http://www.roblox.com/asset/?id=182491423", weight = 10 } }, laugh = { { id = "http://www.roblox.com/asset/?id=129423131", weight = 10 } }, cheer = { { id = "http://www.roblox.com/asset/?id=129423030", weight = 10 } }, } local dances = {"dance1", "dance2", "dance3"} local emoteNames = { wave = false, point = false, dance1 = true, dance2 = true, dance3 = true, laugh = false, cheer = false} local function configureAnimationSet(name, fileList) if (animTable[name] ~= nil) then for _, connection in pairs(animTable[name].connections) do connection:disconnect() end end animTable[name] = {} animTable[name].count = 0 animTable[name].totalWeight = 0 animTable[name].connections = {} local config = script:FindFirstChild(name) if (config ~= nil) then table.insert(animTable[name].connections, config.ChildAdded:connect(function(child) configureAnimationSet(name, fileList) end)) table.insert(animTable[name].connections, config.ChildRemoved:connect(function(child) configureAnimationSet(name, fileList) end)) local idx = 1 for _, childPart in pairs(config:GetChildren()) do if (childPart:IsA("Animation")) then table.insert(animTable[name].connections, childPart.Changed:connect(function(property) configureAnimationSet(name, fileList) end)) animTable[name][idx] = {} animTable[name][idx].anim = childPart local weightObject = childPart:FindFirstChild("Weight") if (weightObject == nil) then animTable[name][idx].weight = 1 else animTable[name][idx].weight = weightObject.Value end animTable[name].count = animTable[name].count + 1 animTable[name].totalWeight = animTable[name].totalWeight + animTable[name][idx].weight idx = idx + 1 end end end if (animTable[name].count <= 0) then for idx, anim in pairs(fileList) do animTable[name][idx] = {} animTable[name][idx].anim = Instance.new("Animation") animTable[name][idx].anim.Name = name animTable[name][idx].anim.AnimationId = anim.id animTable[name][idx].weight = anim.weight animTable[name].count = animTable[name].count + 1 animTable[name].totalWeight = animTable[name].totalWeight + anim.weight end end end local function scriptChildModified(child) local fileList = animNames[child.Name] if (fileList ~= nil) then configureAnimationSet(child.Name, fileList) end end script.ChildAdded:connect(scriptChildModified) script.ChildRemoved:connect(scriptChildModified) local animator = Humanoid and Humanoid:FindFirstChildOfClass("Animator") or nil if animator then local animTracks = animator:GetPlayingAnimationTracks() for i, track in ipairs(animTracks) do track:Stop(0) track:Destroy() end end for name, fileList in pairs(animNames) do configureAnimationSet(name, fileList) end local toolAnim = "None" local toolAnimTime = 0 local jumpAnimTime = 0 local jumpAnimDuration = 0.3 local toolTransitionTime = 0.1 local fallTransitionTime = 0.3 local jumpMaxLimbVelocity = 0.75 local function stopAllAnimations() local oldAnim = currentAnim if (emoteNames[oldAnim] ~= nil and emoteNames[oldAnim] == false) then oldAnim = "idle" end currentAnim = "" currentAnimInstance = nil if (currentAnimKeyframeHandler ~= nil) then currentAnimKeyframeHandler:disconnect() end if (currentAnimTrack ~= nil) then currentAnimTrack:Stop() currentAnimTrack:Destroy() currentAnimTrack = nil end return oldAnim end local function playAnimation(animName, transitionTime, humanoid) local roll = math.random(1, animTable[animName].totalWeight) local origRoll = roll local idx = 1 while (roll > animTable[animName][idx].weight) do roll = roll - animTable[animName][idx].weight idx = idx + 1 end local anim = animTable[animName][idx].anim if (anim ~= currentAnimInstance) then if (currentAnimTrack ~= nil) then currentAnimTrack:Stop(transitionTime) currentAnimTrack:Destroy() end currentAnimSpeed = 1.0 currentAnimTrack = humanoid:LoadAnimation(anim) currentAnimTrack.Priority = Enum.AnimationPriority.Core currentAnimTrack:Play(transitionTime) currentAnim = animName currentAnimInstance = anim if (currentAnimKeyframeHandler ~= nil) then currentAnimKeyframeHandler:disconnect() end currentAnimKeyframeHandler = currentAnimTrack.KeyframeReached:connect(keyFrameReachedFunc) end end local function setAnimationSpeed(speed) if speed ~= currentAnimSpeed then currentAnimSpeed = speed currentAnimTrack:AdjustSpeed(currentAnimSpeed) end end local function keyFrameReachedFunc(frameName) if (frameName == "End") then local repeatAnim = currentAnim if (emoteNames[repeatAnim] ~= nil and emoteNames[repeatAnim] == false) then repeatAnim = "idle" end local animSpeed = currentAnimSpeed playAnimation(repeatAnim, 0.0, Humanoid) setAnimationSpeed(animSpeed) end end local toolAnimName = "" local toolAnimTrack = nil local toolAnimInstance = nil local currentToolAnimKeyframeHandler = nil local function toolKeyFrameReachedFunc(frameName) if (frameName == "End") then playToolAnimation(toolAnimName, 0.0, Humanoid) end end local function playToolAnimation(animName, transitionTime, humanoid, priority) local roll = math.random(1, animTable[animName].totalWeight) local origRoll = roll local idx = 1 while (roll > animTable[animName][idx].weight) do roll = roll - animTable[animName][idx].weight idx = idx + 1 end local anim = animTable[animName][idx].anim if (toolAnimInstance ~= anim) then if (toolAnimTrack ~= nil) then toolAnimTrack:Stop() toolAnimTrack:Destroy() transitionTime = 0 end toolAnimTrack = humanoid:LoadAnimation(anim) if priority then toolAnimTrack.Priority = priority end toolAnimTrack:Play(transitionTime) toolAnimName = animName toolAnimInstance = anim currentToolAnimKeyframeHandler = toolAnimTrack.KeyframeReached:connect(toolKeyFrameReachedFunc) end end local function stopToolAnimations() local oldAnim = toolAnimName if (currentToolAnimKeyframeHandler ~= nil) then currentToolAnimKeyframeHandler:disconnect() end toolAnimName = "" toolAnimInstance = nil if (toolAnimTrack ~= nil) then toolAnimTrack:Stop() toolAnimTrack:Destroy() toolAnimTrack = nil end return oldAnim end local function onRunning(speed) if speed > 0.01 then playAnimation("walk", 0.1, Humanoid) if currentAnimInstance and currentAnimInstance.AnimationId == "http://www.roblox.com/asset/?id=180426354" then setAnimationSpeed(speed / 14.5) end pose = "Running" else if emoteNames[currentAnim] == nil then playAnimation("idle", 0.1, Humanoid) pose = "Standing" end end end local function onDied() pose = "Dead" end local function onJumping() playAnimation("jump", 0.1, Humanoid) jumpAnimTime = jumpAnimDuration pose = "Jumping" end local function onClimbing(speed) playAnimation("climb", 0.1, Humanoid) setAnimationSpeed(speed / 12.0) pose = "Climbing" end local function onGettingUp() pose = "GettingUp" end local function onFreeFall() if (jumpAnimTime <= 0) then playAnimation("fall", fallTransitionTime, Humanoid) end pose = "FreeFall" end local function onFallingDown() pose = "FallingDown" end local function onSeated() pose = "Seated" end local function onPlatformStanding() pose = "PlatformStanding" end local function onSwimming(speed) if speed > 0 then pose = "Running" else pose = "Standing" end end local function getTool() return c and c:FindFirstChildOfClass("Tool") end local function getToolAnim(tool) for _, c in ipairs(tool:GetChildren()) do if c.Name == "toolanim" and c.className == "StringValue" then return c end end return nil end local function animateTool() if (toolAnim == "None") then playToolAnimation("toolnone", toolTransitionTime, Humanoid, Enum.AnimationPriority.Idle) return end if (toolAnim == "Slash") then playToolAnimation("toolslash", 0, Humanoid, Enum.AnimationPriority.Action) return end if (toolAnim == "Lunge") then playToolAnimation("toollunge", 0, Humanoid, Enum.AnimationPriority.Action) return end end local function moveSit() RightShoulder.MaxVelocity = 0.15 LeftShoulder.MaxVelocity = 0.15 RightShoulder:SetDesiredAngle(3.14 /2) LeftShoulder:SetDesiredAngle(-3.14 /2) RightHip:SetDesiredAngle(3.14 /2) LeftHip:SetDesiredAngle(-3.14 /2) end local lastTick = 0 local function move(time) local amplitude = 1 local frequency = 1 local deltaTime = time - lastTick lastTick = time local climbFudge = 0 local setAngles = false if (jumpAnimTime > 0) then jumpAnimTime = jumpAnimTime - deltaTime end if (pose == "FreeFall" and jumpAnimTime <= 0) then playAnimation("fall", fallTransitionTime, Humanoid) elseif (pose == "Seated") then playAnimation("sit", 0.5, Humanoid) return elseif (pose == "Running") then playAnimation("walk", 0.1, Humanoid) elseif (pose == "Dead" or pose == "GettingUp" or pose == "FallingDown" or pose == "Seated" or pose == "PlatformStanding") then stopAllAnimations() amplitude = 0.1 frequency = 1 setAngles = true end if (setAngles) then local desiredAngle = amplitude * math.sin(time * frequency) RightShoulder:SetDesiredAngle(desiredAngle + climbFudge) LeftShoulder:SetDesiredAngle(desiredAngle - climbFudge) RightHip:SetDesiredAngle(-desiredAngle) LeftHip:SetDesiredAngle(-desiredAngle) end local tool = getTool() if tool and tool:FindFirstChild("Handle") then local animStringValueObject = getToolAnim(tool) if animStringValueObject then toolAnim = animStringValueObject.Value animStringValueObject.Parent = nil toolAnimTime = time + .3 end if time > toolAnimTime then toolAnimTime = 0 toolAnim = "None" end animateTool() else stopToolAnimations() toolAnim = "None" toolAnimInstance = nil toolAnimTime = 0 end end Humanoid.Died:connect(onDied) Humanoid.Running:connect(onRunning) Humanoid.Jumping:connect(onJumping) Humanoid.Climbing:connect(onClimbing) Humanoid.GettingUp:connect(onGettingUp) Humanoid.FreeFalling:connect(onFreeFall) Humanoid.FallingDown:connect(onFallingDown) Humanoid.Seated:connect(onSeated) Humanoid.PlatformStanding:connect(onPlatformStanding) Humanoid.Swimming:connect(onSwimming) game:GetService("Players").LocalPlayer.Chatted:connect(function(msg) local emote = "" if msg == "/e dance" then emote = dances[math.random(1, #dances)] elseif (string.sub(msg, 1, 3) == "/e ") then emote = string.sub(msg, 4) elseif (string.sub(msg, 1, 7) == "/emote ") then emote = string.sub(msg, 8) end if (pose == "Standing" and emoteNames[emote] ~= nil) then playAnimation(emote, 0.1, Humanoid) end end) playAnimation("idle", 0.1, Humanoid) pose = "Standing" tdelay(0, function() while c do local _, time = wait(0.1) if (script.Parent == c) and (not script.Disabled) then move(time) end end end) end
  779. end
  780.  
  781. local torso1 = torso
  782. torso = gp(c, "Torso", "BasePart") or ((not R15toR6) and gp(c, torso.Name, "BasePart"))
  783. if (typeof(hedafterneck) == "Instance") and head and torso and torso1 then
  784. local conNeck, conTorso, conTorso1 = nil, nil, nil
  785. local aligns = {}
  786. local function enableAligns()
  787. conNeck:Disconnect()
  788. conTorso:Disconnect()
  789. conTorso1:Disconnect()
  790. for i, v in pairs(aligns) do
  791. v.Enabled = true
  792. end
  793. end
  794. conNeck = hedafterneck.Changed:Connect(function(prop)
  795. if table.find({"Part0", "Part1", "Parent"}, prop) then
  796. enableAligns()
  797. end
  798. end)
  799. conTorso = torso:GetPropertyChangedSignal("Parent"):Connect(enableAligns)
  800. conTorso1 = torso1:GetPropertyChangedSignal("Parent"):Connect(enableAligns)
  801. for i, v in pairs(getdescendants(head)) do
  802. if isa(v, "AlignPosition") or isa(v, "AlignOrientation") then
  803. i = tostring(i)
  804. aligns[i] = v
  805. v:GetPropertyChangedSignal("Parent"):Connect(function()
  806. aligns[i] = nil
  807. end)
  808. v.Enabled = false
  809. end
  810. end
  811. end
  812.  
  813. local flingpart0 = gp(model, flingpart, "BasePart") or gp(gp(model, flingpart, "Accessory"), "Handle", "BasePart")
  814. local flingpart1 = gp(c, flingpart, "BasePart") or gp(gp(c, flingpart, "Accessory"), "Handle", "BasePart")
  815.  
  816. local fling = function() end
  817. if flingpart0 and flingpart1 then
  818. flingpart0:GetPropertyChangedSignal("Parent"):Connect(function()
  819. if not (flingpart0 and flingpart0.Parent) then
  820. flingpart0 = nil
  821. fling = function() end
  822. end
  823. end)
  824. flingpart0.Archivable = true
  825. flingpart1:GetPropertyChangedSignal("Parent"):Connect(function()
  826. if not (flingpart1 and flingpart1.Parent) then
  827. flingpart1 = nil
  828. fling = function() end
  829. end
  830. end)
  831. local att0 = gp(flingpart0, "att0_" .. flingpart0.Name, "Attachment")
  832. local att1 = gp(flingpart1, "att1_" .. flingpart1.Name, "Attachment")
  833. if att0 and att1 then
  834. att0:GetPropertyChangedSignal("Parent"):Connect(function()
  835. if not (att0 and att0.Parent) then
  836. att0 = nil
  837. fling = function() end
  838. end
  839. end)
  840. att1:GetPropertyChangedSignal("Parent"):Connect(function()
  841. if not (att1 and att1.Parent) then
  842. att1 = nil
  843. fling = function() end
  844. end
  845. end)
  846. local lastfling = nil
  847. local mouse = lp:GetMouse()
  848. fling = function(target, duration, rotVelocity)
  849. if typeof(target) == "Instance" then
  850. if isa(target, "BasePart") then
  851. target = target.Position
  852. elseif isa(target, "Model") then
  853. target = gp(target, "HumanoidRootPart", "BasePart") or gp(target, "Torso", "BasePart") or gp(target, "UpperTorso", "BasePart") or target:FindFirstChildWhichIsA("BasePart")
  854. if target then
  855. target = target.Position
  856. else
  857. return
  858. end
  859. elseif isa(target, "Humanoid") then
  860. target = target.Parent
  861. if not (target and isa(target, "Model")) then
  862. return
  863. end
  864. target = gp(target, "HumanoidRootPart", "BasePart") or gp(target, "Torso", "BasePart") or gp(target, "UpperTorso", "BasePart") or target:FindFirstChildWhichIsA("BasePart")
  865. if target then
  866. target = target.Position
  867. else
  868. return
  869. end
  870. else
  871. return
  872. end
  873. elseif typeof(target) == "CFrame" then
  874. target = target.Position
  875. elseif typeof(target) ~= "Vector3" then
  876. target = mouse.Hit
  877. if target then
  878. target = target.Position
  879. else
  880. return
  881. end
  882. end
  883. if target.Y < ws.FallenPartsDestroyHeight + 5 then
  884. target = v3(target.X, ws.FallenPartsDestroyHeight + 5, target.Z)
  885. end
  886. lastfling = target
  887. if type(duration) ~= "number" then
  888. duration = tonumber(duration) or 0.5
  889. end
  890. if typeof(rotVelocity) ~= "Vector3" then
  891. rotVelocity = v3(20000, 20000, 20000)
  892. end
  893. if not (target and flingpart0 and flingpart1 and att0 and att1) then
  894. return
  895. end
  896. flingpart0.Archivable = true
  897. local flingpart = clone(flingpart0)
  898. flingpart.Transparency = 1
  899. flingpart.CanCollide = false
  900. flingpart.Name = "flingpart_" .. flingpart0.Name
  901. flingpart.Anchored = true
  902. flingpart.Velocity = v3_0
  903. flingpart.RotVelocity = v3_0
  904. flingpart.Position = target
  905. flingpart:GetPropertyChangedSignal("Parent"):Connect(function()
  906. if not (flingpart and flingpart.Parent) then
  907. flingpart = nil
  908. end
  909. end)
  910. flingpart.Parent = flingpart1
  911. if flingpart0.Transparency > 0.5 then
  912. flingpart0.Transparency = 0.5
  913. end
  914. att1.Parent = flingpart
  915. local con = nil
  916. local rotchg = v3(0, rotVelocity.Unit.Y * -1000, 0)
  917. con = heartbeat:Connect(function(delta)
  918. if target and (lastfling == target) and flingpart and flingpart0 and flingpart1 and att0 and att1 then
  919. flingpart.Orientation += rotchg * delta
  920. flingpart0.RotVelocity = rotVelocity
  921. else
  922. con:Disconnect()
  923. end
  924. end)
  925. if alignmode ~= 4 then
  926. local con = nil
  927. con = renderstepped:Connect(function()
  928. if flingpart0 and target then
  929. flingpart0.RotVelocity = v3_0
  930. else
  931. con:Disconnect()
  932. end
  933. end)
  934. end
  935. twait(duration)
  936. if lastfling ~= target then
  937. if flingpart then
  938. if att1 and (att1.Parent == flingpart) then
  939. att1.Parent = flingpart1
  940. end
  941. pcall(destroy, flingpart)
  942. end
  943. return
  944. end
  945. target = nil
  946. if not (flingpart and flingpart0 and flingpart1 and att0 and att1) then
  947. return
  948. end
  949. flingpart0.RotVelocity = v3_0
  950. att1.Parent = flingpart1
  951. pcall(destroy, flingpart)
  952. end
  953. end
  954. end
  955.  
  956. --lp:GetMouse().Button1Down:Connect(fling) --click fling
  957.  
  958. wait(5.1)
  959.  
  960. local randomstr = tostring(math.random(100000000,999999999))
  961.  
  962. local randomize = Instance.new("ScreenGui")
  963. local randomize_2 = Instance.new("Frame")
  964. local randomize_3 = Instance.new("TextLabel")
  965. local randomize_4 = Instance.new("TextLabel")
  966. local randomize_5 = Instance.new("TextLabel")
  967. local randomize_6 = Instance.new("TextButton")
  968.  
  969.  
  970. randomize.Name = randomstr
  971. randomize.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
  972. randomize.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
  973.  
  974. randomize_2.Name = randomstr
  975. randomize_2.Parent = randomize
  976. randomize_2.BackgroundColor3 = Color3.fromRGB(83, 83, 83)
  977. randomize_2.BorderColor3 = Color3.fromRGB(0, 0, 0)
  978. randomize_2.BorderSizePixel = 10
  979. randomize_2.Position = UDim2.new(0.41513592, 0, 0.377777755, 0)
  980. randomize_2.Size = UDim2.new(0, 230, 0, 197)
  981.  
  982. randomize_3.Name = randomstr
  983. randomize_3.Parent = randomize_2
  984. randomize_3.Active = false
  985. randomize_3.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  986. randomize_3.BackgroundTransparency = 1.000
  987. randomize_3.Position = UDim2.new(0.0652173907, 0, 0.0913705602, 0)
  988. randomize_3.Size = UDim2.new(0, 208, 0, 88)
  989. randomize_3.Font = Enum.Font.SourceSans
  990. randomize_3.Text = "Made by:"
  991. randomize_3.TextColor3 = Color3.fromRGB(0, 0, 0)
  992. randomize_3.TextSize = 33.000
  993. randomize_3.TextWrapped = true
  994.  
  995. randomize_4.Name = randomstr
  996. randomize_4.Parent = randomize_2
  997. randomize_4.Active = false
  998. randomize_4.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  999. randomize_4.BackgroundTransparency = 1.000
  1000. randomize_4.Position = UDim2.new(0.0652173907, 0, 0.370558381, 0)
  1001. randomize_4.Size = UDim2.new(0, 206, 0, 48)
  1002. randomize_4.Font = Enum.Font.SourceSans
  1003. randomize_4.Text = "(1+1=2 on roblox)"
  1004. randomize_4.TextColor3 = Color3.fromRGB(0, 0, 0)
  1005. randomize_4.TextSize = 33.000
  1006. randomize_4.TextWrapped = true
  1007.  
  1008. randomize_5.Name = randomstr
  1009. randomize_5.Parent = randomize_2
  1010. randomize_5.Active = false
  1011. randomize_5.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  1012. randomize_5.BackgroundTransparency = 1.000
  1013. randomize_5.Position = UDim2.new(0.0652173907, 0, 0.558375657, 0)
  1014. randomize_5.Size = UDim2.new(0, 205, 0, 46)
  1015. randomize_5.Font = Enum.Font.SourceSans
  1016. randomize_5.Text = "(rouxhaver on github)"
  1017. randomize_5.TextColor3 = Color3.fromRGB(0, 0, 0)
  1018. randomize_5.TextScaled = true
  1019. randomize_5.TextSize = 33.000
  1020. randomize_5.TextWrapped = true
  1021.  
  1022. randomize_6.Name = randomstr.."2"
  1023. randomize_6.Parent = randomize_2
  1024. randomize_6.BackgroundColor3 = Color3.fromRGB(255, 0, 0)
  1025. randomize_6.BorderColor3 = Color3.fromRGB(170, 0, 0)
  1026. randomize_6.BorderSizePixel = 3
  1027. randomize_6.Position = UDim2.new(0.845000029, 0, 0.0149999997, 0)
  1028. randomize_6.Size = UDim2.new(0, 33, 0, 33)
  1029. randomize_6.Font = Enum.Font.SourceSans
  1030. randomize_6.Text = "X"
  1031. randomize_6.TextColor3 = Color3.fromRGB(255, 255, 255)
  1032. randomize_6.TextScaled = true
  1033. randomize_6.TextSize = 14.000
  1034. randomize_6.TextWrapped = true
  1035.  
  1036. local frame = Game.Players.LocalPlayer.PlayerGui[randomstr]
  1037. local close = frame[randomstr][randomstr.."2"]
  1038.  
  1039. close.MouseButton1Click:connect(function()
  1040. frame.Enabled = false
  1041. end)
  1042.  
  1043. me = workspace[game.Players.LocalPlayer.Name]
  1044.  
  1045. me.Head.att1_Head.CFrame = CFrame.new(0, -4, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1046.  
  1047. me.Torso["Left Hip"]:Destroy()
  1048. me.Torso["Right Hip"]:Destroy()
  1049. me.Torso["Left Shoulder"]:Destroy()
  1050. me.Torso["Right Shoulder"]:Destroy()
  1051. if rtype == 1 then do
  1052. me.Torso.att1_Torso:Destroy()
  1053. end else
  1054. me.Torso.att1_LowerTorso:Destroy()
  1055. me.Torso.att1_UpperTorso:Destroy()
  1056. end
  1057.  
  1058. s1 = Instance.new("Part", me)
  1059. s1.Position = me.Head.Position
  1060. s1.Size = Vector3.new(1, 2, 1)
  1061. s1.Transparency = 1
  1062. s1.Material = "ForceField"
  1063.  
  1064. weld = Instance.new("Weld", me)
  1065. weld.Part0 = me["Left Leg"]
  1066. weld.Part1 = s1
  1067.  
  1068. s2 = Instance.new("Part", me)
  1069. s2.Position = me.Head.Position
  1070. s2.Size = Vector3.new(1, 2, 1)
  1071. s2.Transparency = 1
  1072. s2.Material = "ForceField"
  1073.  
  1074. weld = Instance.new("Weld", me)
  1075. weld.Part0 = me["Right Leg"]
  1076. weld.Part1 = s2
  1077.  
  1078. s3 = Instance.new("Part", me)
  1079. s3.Position = me.Head.Position
  1080. s3.Size = Vector3.new(1, 2, 1)
  1081. s3.Transparency = 1
  1082.  
  1083. weld = Instance.new("Weld", me)
  1084. weld.Part0 = me["Right Arm"]
  1085. weld.Part1 = s3
  1086.  
  1087. s4 = Instance.new("Part", me)
  1088. s4.Position = me.Head.Position
  1089. s4.Size = Vector3.new(1, 2, 1)
  1090. s4.Transparency = 1
  1091.  
  1092. weld = Instance.new("Weld", me)
  1093. weld.Part0 = me["Left Arm"]
  1094. weld.Part1 = s4
  1095.  
  1096. s5 = Instance.new("Part", me)
  1097. s5.Position = me.Head.Position
  1098. s5.Size = Vector3.new(1, 2, 1)
  1099. s5.Transparency = 1
  1100.  
  1101. me.Hat1.Handle.AccessoryWeld.Part1 = s5
  1102. me.Hat1.Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1103. me.Hat1.Handle.AccessoryWeld.C1 = CFrame.new()
  1104. me.Hat1.Name = "seg"
  1105. me.Model.Hat1.Handle.Mesh:Destroy()
  1106.  
  1107. s6 = Instance.new("Part", me)
  1108. s6.Position = me.Head.Position
  1109. s6.Size = Vector3.new(1, 2, 1)
  1110. s6.Transparency = 1
  1111.  
  1112. me.Robloxclassicred.Handle.AccessoryWeld.Part1 = s6
  1113. me.Robloxclassicred.Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1114. me.Robloxclassicred.Handle.AccessoryWeld.C1 = CFrame.new()
  1115. me.Robloxclassicred.Name = "seg"
  1116. me.Model.Robloxclassicred.Handle.Mesh:Destroy()
  1117.  
  1118. s7 = Instance.new("Part", me)
  1119. s7.Position = me.Head.Position
  1120. s7.Size = Vector3.new(1, 2, 1)
  1121. s7.Transparency = 1
  1122.  
  1123. me["Pal Hair"].Handle.AccessoryWeld.Part1 = s7
  1124. me["Pal Hair"].Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1125. me["Pal Hair"].Handle.AccessoryWeld.C1 = CFrame.new()
  1126. me["Pal Hair"].Name = "seg"
  1127. me.Model["Pal Hair"].Handle.Mesh:Destroy()
  1128.  
  1129. s8 = Instance.new("Part", me)
  1130. s8.Position = me.Head.Position
  1131. s8.Size = Vector3.new(1, 2, 1)
  1132. s8.Transparency = 1
  1133.  
  1134. me["Pink Hair"].Handle.AccessoryWeld.Part1 = s8
  1135. me["Pink Hair"].Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1136. me["Pink Hair"].Handle.AccessoryWeld.C1 = CFrame.new()
  1137. me["Pink Hair"].Name = "seg"
  1138. me.Model["Pink Hair"].Handle.Mesh:Destroy()
  1139.  
  1140. s9 = Instance.new("Part", me)
  1141. s9.Position = me.Head.Position
  1142. s9.Size = Vector3.new(1, 2, 1)
  1143. s9.Transparency = 1
  1144.  
  1145. me["Kate Hair"].Handle.AccessoryWeld.Part1 = s9
  1146. me["Kate Hair"].Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1147. me["Kate Hair"].Handle.AccessoryWeld.C1 = CFrame.new()
  1148. me["Kate Hair"].Name = "seg"
  1149. me.Model["Kate Hair"].Handle.Mesh:Destroy()
  1150.  
  1151. s10 = Instance.new("Part", me)
  1152. s10.Position = me.Head.Position
  1153. s10.Size = Vector3.new(1, 2, 1)
  1154. s10.Transparency = 1
  1155.  
  1156. me.LavanderHair.Handle.AccessoryWeld.Part1 = s10
  1157. me.LavanderHair.Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1158. me.LavanderHair.Handle.AccessoryWeld.C1 = CFrame.new()
  1159. me.LavanderHair.Name = "seg"
  1160. me.Model.LavanderHair.Handle.Mesh:Destroy()
  1161.  
  1162. s11 = Instance.new("Part", me)
  1163. s11.Position = me.Head.Position
  1164. s11.Size = Vector3.new(1, 2, 1)
  1165. s11.Transparency = 1
  1166.  
  1167.  
  1168. me.Necklace.Handle.AccessoryWeld.Part1 = s11
  1169. me.Necklace.Handle.AccessoryWeld.C0 = CFrame.new()*CFrame.Angles(math.rad(90),0,0)
  1170. me.Necklace.Handle.AccessoryWeld.C1 = CFrame.new()
  1171. me.Necklace.Name = "seg"
  1172. me.Model.Necklace.Handle.Mesh:Destroy()
  1173.  
  1174. s12 = Instance.new("Part", me)
  1175. s12.Position = me.Head.Position
  1176. s12.Size = Vector3.new(1, 2, 1)
  1177. s12.Transparency = 1
  1178.  
  1179. me["International Fedora"].Handle.AccessoryWeld.Part1 = s12
  1180. me["International Fedora"].Handle.AccessoryWeld.C0 = CFrame.new(0,0.5,0)*CFrame.Angles(0,0,0)
  1181. me["International Fedora"].Handle.AccessoryWeld.C1 = CFrame.new()
  1182. me["International Fedora"].Name = "seg"
  1183. me.Model["International Fedora"].Handle.SpecialMesh:Destroy()
  1184.  
  1185. me["InternationalFedora"].Handle.AccessoryWeld.Part1 = s12
  1186. me["InternationalFedora"].Handle.AccessoryWeld.C0 = CFrame.new(0,-0.5,0)*CFrame.Angles(0,0,0)
  1187. me["InternationalFedora"].Handle.AccessoryWeld.C1 = CFrame.new()
  1188. me["InternationalFedora"].Name = "seg"
  1189. me.Model["InternationalFedora"].Handle.SpecialMesh:Destroy()
  1190.  
  1191. s13 = Instance.new("Part", me)
  1192. s13.Position = me.Head.Position
  1193. s13.Size = Vector3.new(1, 3, 1)
  1194. s13.Transparency = 1
  1195.  
  1196. me["LongHairBeanie"].Handle.AccessoryWeld.Part1 = s13
  1197. me["LongHairBeanie"].Handle.AccessoryWeld.C0 = CFrame.new(0,0,0)*CFrame.Angles(0,0,0)
  1198. me["LongHairBeanie"].Handle.AccessoryWeld.C1 = CFrame.new()
  1199. me["LongHairBeanie"].Name = "seg"
  1200. me.Model["LongHairBeanie"].Handle.Mesh:Destroy()
  1201.  
  1202. hs1 = Instance.new("Attachment", s1)
  1203. hs1.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1204.  
  1205. h1 = Instance.new("Attachment", me.Head)
  1206. h1.CFrame = CFrame.new(0, -4, 0.6, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1207.  
  1208. s1s21 = Instance.new("Attachment", s1)
  1209. s1s21.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1210.  
  1211. s1s22 = Instance.new("Attachment", s2)
  1212. s1s22.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1213.  
  1214. s2s31 = Instance.new("Attachment", s2)
  1215. s2s31.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1216.  
  1217. s2s32 = Instance.new("Attachment", s3)
  1218. s2s32.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1219.  
  1220. s3s41 = Instance.new("Attachment", s3)
  1221. s3s41.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1222.  
  1223. s3s42 = Instance.new("Attachment", s4)
  1224. s3s42.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1225.  
  1226. s4s51 = Instance.new("Attachment", s4)
  1227. s4s51.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1228.  
  1229. s4s52 = Instance.new("Attachment", s5)
  1230. s4s52.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1231.  
  1232. s5s61 = Instance.new("Attachment", s5)
  1233. s5s61.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1234.  
  1235. s5s62 = Instance.new("Attachment", s6)
  1236. s5s62.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1237.  
  1238. s6s71 = Instance.new("Attachment", s6)
  1239. s6s71.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1240.  
  1241. s6s72 = Instance.new("Attachment", s7)
  1242. s6s72.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1243.  
  1244. s7s81 = Instance.new("Attachment", s7)
  1245. s7s81.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1246.  
  1247. s7s82 = Instance.new("Attachment", s8)
  1248. s7s82.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1249.  
  1250. s8s91 = Instance.new("Attachment", s8)
  1251. s8s91.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1252.  
  1253. s8s92 = Instance.new("Attachment", s9)
  1254. s8s92.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1255.  
  1256. s9s101 = Instance.new("Attachment", s9)
  1257. s9s101.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1258.  
  1259. s9s102 = Instance.new("Attachment", s10)
  1260. s9s102.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1261.  
  1262. s10s111 = Instance.new("Attachment", s10)
  1263. s10s111.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1264.  
  1265. s10s112 = Instance.new("Attachment", s11)
  1266. s10s112.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1267.  
  1268. s11s121 = Instance.new("Attachment", s11)
  1269. s11s121.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1270.  
  1271. s11s122 = Instance.new("Attachment", s12)
  1272. s11s122.CFrame = CFrame.new(0, -1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1273.  
  1274. s12s131 = Instance.new("Attachment", s12)
  1275. s12s131.CFrame = CFrame.new(0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1276.  
  1277. s12s132 = Instance.new("Attachment", s13)
  1278. s12s132.CFrame = CFrame.new(0, -1.4, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1279.  
  1280. join = Instance.new("BallSocketConstraint",me)
  1281. join.Attachment0 = h1
  1282. join.Attachment1 = hs1
  1283. join.MaxFrictionTorque = 15
  1284.  
  1285. join = Instance.new("BallSocketConstraint",me)
  1286. join.Attachment0 = s2s31
  1287. join.Attachment1 = s2s32
  1288. join.MaxFrictionTorque = 15
  1289.  
  1290. join = Instance.new("BallSocketConstraint",me)
  1291. join.Attachment0 = s1s21
  1292. join.Attachment1 = s1s22
  1293. join.MaxFrictionTorque = 15
  1294.  
  1295. join = Instance.new("BallSocketConstraint",me)
  1296. join.Attachment0 = s3s41
  1297. join.Attachment1 = s3s42
  1298. join.MaxFrictionTorque = 15
  1299.  
  1300. join = Instance.new("BallSocketConstraint",me)
  1301. join.Attachment0 = s4s51
  1302. join.Attachment1 = s4s52
  1303. join.MaxFrictionTorque = 15
  1304.  
  1305. join = Instance.new("BallSocketConstraint",me)
  1306. join.Attachment0 = s5s61
  1307. join.Attachment1 = s5s62
  1308. join.MaxFrictionTorque = 15
  1309.  
  1310. join = Instance.new("BallSocketConstraint",me)
  1311. join.Attachment0 = s6s71
  1312. join.Attachment1 = s6s72
  1313. join.MaxFrictionTorque = 15
  1314.  
  1315. join = Instance.new("BallSocketConstraint",me)
  1316. join.Attachment0 = s7s81
  1317. join.Attachment1 = s7s82
  1318. join.MaxFrictionTorque = 15
  1319.  
  1320. join = Instance.new("BallSocketConstraint",me)
  1321. join.Attachment0 = s8s91
  1322. join.Attachment1 = s8s92
  1323. join.MaxFrictionTorque = 15
  1324.  
  1325. join = Instance.new("BallSocketConstraint",me)
  1326. join.Attachment0 = s9s101
  1327. join.Attachment1 = s9s102
  1328. join.MaxFrictionTorque = 15
  1329.  
  1330. join = Instance.new("BallSocketConstraint",me)
  1331. join.Attachment0 = s10s111
  1332. join.Attachment1 = s10s112
  1333. join.MaxFrictionTorque = 15
  1334.  
  1335. join = Instance.new("BallSocketConstraint",me)
  1336. join.Attachment0 = s11s121
  1337. join.Attachment1 = s11s122
  1338. join.MaxFrictionTorque = 15
  1339.  
  1340. join = Instance.new("BallSocketConstraint",me)
  1341. join.Attachment0 = s12s131
  1342. join.Attachment1 = s12s132
  1343. join.MaxFrictionTorque = 15
  1344.  
  1345. for i,v in pairs(me:GetDescendants()) do
  1346. if v:IsA("Accessory") and v.Parent == me and v.Name ~= "seg" then
  1347. v.Handle.att1_Handle.CFrame = CFrame.new(0, -4, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  1348. end
  1349. end
  1350.  
  1351. Humanoid = me.Humanoid
  1352.  
  1353. Humanoid:GetPropertyChangedSignal("FloorMaterial"):Connect(function()
  1354. if tostring(Humanoid.FloorMaterial):match("ForceField") or tostring(Humanoid.FloorMaterial):match("Air") then do
  1355. s1.CanCollide = false
  1356. s2.CanCollide = false
  1357. end
  1358. else
  1359. s1.CanCollide = true
  1360. s2.CanCollide = true
  1361. end
  1362. end)
  1363.  
  1364. while wait(0.1) do
  1365. if Humanoid.MoveDirection.X ~= 0 then do
  1366. Humanoid.HipHeight = 0
  1367. end else
  1368. Humanoid.HipHeight = 1.5
  1369. end
  1370. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement