Advertisement
Deyer

Untitled

Mar 23rd, 2023
20
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 34.99 KB | None | 0 0
  1. game.Players.LocalPlayer.Character["Robloxclassicred"].Handle.Mesh:Destroy()
  2. game.Players.LocalPlayer.Character["LavanderHair"].Handle.Mesh:Destroy()
  3. game.Players.LocalPlayer.Character["Kate Hair"].Handle.Mesh:Destroy()
  4. game.Players.LocalPlayer.Character["Hat1"].Handle.Mesh:Destroy()
  5. game.Players.LocalPlayer.Character["Pal Hair"].Handle.Mesh:Destroy()
  6. game.Players.LocalPlayer.Character["Pink Hair"].Handle.Mesh:Destroy()
  7.  
  8.  
  9. --reanimate by MyWorld#4430 discord.gg/pYVHtSJmEY
  10. local v3_net, v3_808 = Vector3.new(0, 25.1, 0), Vector3.new(8, 0, 8)
  11. local function getNetlessVelocity(realPartVelocity)
  12. local mag = realPartVelocity.Magnitude
  13. if mag > 1 then
  14. local unit = realPartVelocity.Unit
  15. if (unit.Y > 0.25) or (unit.Y < -0.75) then
  16. return unit * (25.1 / unit.Y)
  17. end
  18. end
  19. return v3_net + realPartVelocity * v3_808
  20. end
  21. local simradius = "shp" --simulation radius (net bypass) method
  22. --"shp" - sethiddenproperty
  23. --"ssr" - setsimulationradius
  24. --false - disable
  25. local simrad = 1000 --simulation radius value
  26. local healthHide = false --moves your head away every 3 seconds so players dont see your health bar (alignmode 4 only)
  27. 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)
  28. local novoid = true --prevents parts from going under workspace.FallenPartsDestroyHeight if you control them (alignmode 4 only)
  29. local physp = nil --PhysicalProperties.new(0.01, 0, 1, 0, 0) --sets .CustomPhysicalProperties to this for each part
  30. local noclipAllParts = true --set it to true if you want noclip
  31. local antiragdoll = true --removes hingeConstraints and ballSocketConstraints from your character
  32. local newanimate = false --disables the animate script and enables after reanimation
  33. local discharscripts = true --disables all localScripts parented to your character before reanimation
  34. local R15toR6 = true --tries to convert your character to r6 if its r15
  35. local hatcollide = true --makes hats cancollide (credit to ShownApe) (works only with reanimate method 0)
  36. local humState16 = true --enables collisions for limbs before the humanoid dies (using hum:ChangeState)
  37. local addtools = false --puts all tools from backpack to character and lets you hold them after reanimation
  38. local hedafterneck = true --disable aligns for head and enable after neck or torso is removed
  39. local loadtime = game:GetService("Players").RespawnTime + 0.5 --anti respawn delay
  40. local method = 0 --reanimation method
  41. --methods:
  42. --0 - breakJoints (takes [loadtime] seconds to load)
  43. --1 - limbs
  44. --2 - limbs + anti respawn
  45. --3 - limbs + breakJoints after [loadtime] seconds
  46. --4 - remove humanoid + breakJoints
  47. --5 - remove humanoid + limbst
  48. local alignmode = 3 --AlignPosition mode
  49. --modes:
  50. --1 - AlignPosition rigidity enabled true
  51. --2 - 2 AlignPositions rigidity enabled both true and false
  52. --3 - AlignPosition rigidity enabled false
  53. --4 - CFrame
  54. local flingpart = "HumanoidRootPart" --name of the part or the hat used for flinging
  55. --the fling function
  56. --usage: fling(target, duration, velocity)
  57. --target can be set to: basePart, CFrame, Vector3, character model or humanoid (flings at mouse.Hit if argument not provided))
  58. --duration (fling time in seconds) can be set to a number or a string convertable to the number (0.5s if not provided),
  59. --velocity (fling part rotation velocity) can be set to a vector3 value (Vector3.new(20000, 20000, 20000) if not provided)
  60.  
  61. local lp = game:GetService("Players").LocalPlayer
  62. local rs, ws, sg = game:GetService("RunService"), game:GetService("Workspace"), game:GetService("StarterGui")
  63. local stepped, heartbeat, renderstepped = rs.Stepped, rs.Heartbeat, rs.RenderStepped
  64. local twait, tdelay, rad, inf, abs, clamp = task.wait, task.delay, math.rad, math.huge, math.abs, math.clamp
  65. local cf, v3 = CFrame.new, Vector3.new
  66. local angles = CFrame.Angles
  67. local v3_0, cf_0 = v3(0, 0, 0), cf(0, 0, 0)
  68.  
  69. local c = lp.Character
  70. if not (c and c.Parent) then
  71. return
  72. end
  73.  
  74. c:GetPropertyChangedSignal("Parent"):Connect(function()
  75. if not (c and c.Parent) then
  76. c = nil
  77. end
  78. end)
  79.  
  80. local clone, destroy, getchildren, getdescendants, isa = c.Clone, c.Destroy, c.GetChildren, c.GetDescendants, c.IsA
  81.  
  82. local function gp(parent, name, className)
  83. if typeof(parent) == "Instance" then
  84. for i, v in pairs(getchildren(parent)) do
  85. if (v.Name == name) and isa(v, className) then
  86. return v
  87. end
  88. end
  89. end
  90. return nil
  91. end
  92.  
  93. local fenv = getfenv()
  94.  
  95. local shp = fenv.sethiddenproperty or fenv.set_hidden_property or fenv.set_hidden_prop or fenv.sethiddenprop
  96. 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
  97.  
  98. healthHide = healthHide and ((method == 0) or (method == 3)) and gp(c, "Head", "BasePart")
  99.  
  100. local reclaim, lostpart = reclaim and c.PrimaryPart, nil
  101.  
  102. local function align(Part0, Part1)
  103.  
  104. local att0 = Instance.new("Attachment")
  105. att0.Position, att0.Orientation, att0.Name = v3_0, v3_0, "att0_" .. Part0.Name
  106. local att1 = Instance.new("Attachment")
  107. att1.Position, att1.Orientation, att1.Name = v3_0, v3_0, "att1_" .. Part1.Name
  108.  
  109. if alignmode == 4 then
  110.  
  111. local hide = false
  112. if Part0 == healthHide then
  113. healthHide = false
  114. tdelay(0, function()
  115. while twait(2.9) and Part0 and c do
  116. hide = #Part0:GetConnectedParts() == 1
  117. twait(0.1)
  118. hide = false
  119. end
  120. end)
  121. end
  122.  
  123. local rot = rad(0.05)
  124. local con0, con1 = nil, nil
  125. con0 = stepped:Connect(function()
  126. if not (Part0 and Part1) then return con0:Disconnect() and con1:Disconnect() end
  127. Part0.RotVelocity = Part1.RotVelocity
  128. end)
  129. local lastpos = Part0.Position
  130. con1 = heartbeat:Connect(function(delta)
  131. if not (Part0 and Part1 and att1) then return con0:Disconnect() and con1:Disconnect() end
  132. if (not Part0.Anchored) and (Part0.ReceiveAge == 0) then
  133. if lostpart == Part0 then
  134. lostpart = nil
  135. end
  136. rot = -rot
  137. local newcf = Part1.CFrame * att1.CFrame * angles(0, 0, rot)
  138. if Part1.Velocity.Magnitude > 0.01 then
  139. Part0.Velocity = getNetlessVelocity(Part1.Velocity)
  140. else
  141. Part0.Velocity = getNetlessVelocity((newcf.Position - lastpos) / delta)
  142. end
  143. lastpos = newcf.Position
  144. if lostpart and (Part0 == reclaim) then
  145. newcf = lostpart.CFrame
  146. elseif hide then
  147. newcf += v3(0, 3000, 0)
  148. end
  149. if novoid and (newcf.Y < ws.FallenPartsDestroyHeight + 0.1) then
  150. newcf += v3(0, ws.FallenPartsDestroyHeight + 0.1 - newcf.Y, 0)
  151. end
  152. Part0.CFrame = newcf
  153. elseif (not Part0.Anchored) and (abs(Part0.Velocity.X) < 45) and (abs(Part0.Velocity.Y) < 25) and (abs(Part0.Velocity.Z) < 45) then
  154. lostpart = Part0
  155. end
  156. end)
  157.  
  158. else
  159.  
  160. Part0.CustomPhysicalProperties = physp
  161. if (alignmode == 1) or (alignmode == 2) then
  162. local ape = Instance.new("AlignPosition")
  163. ape.MaxForce, ape.MaxVelocity, ape.Responsiveness = inf, inf, inf
  164. ape.ReactionForceEnabled, ape.RigidityEnabled, ape.ApplyAtCenterOfMass = false, true, false
  165. ape.Attachment0, ape.Attachment1, ape.Name = att0, att1, "AlignPositionRtrue"
  166. ape.Parent = att0
  167. end
  168.  
  169. if (alignmode == 2) or (alignmode == 3) then
  170. local apd = Instance.new("AlignPosition")
  171. apd.MaxForce, apd.MaxVelocity, apd.Responsiveness = inf, inf, inf
  172. apd.ReactionForceEnabled, apd.RigidityEnabled, apd.ApplyAtCenterOfMass = false, false, false
  173. apd.Attachment0, apd.Attachment1, apd.Name = att0, att1, "AlignPositionRfalse"
  174. apd.Parent = att0
  175. end
  176.  
  177. local ao = Instance.new("AlignOrientation")
  178. ao.MaxAngularVelocity, ao.MaxTorque, ao.Responsiveness = inf, inf, inf
  179. ao.PrimaryAxisOnly, ao.ReactionTorqueEnabled, ao.RigidityEnabled = false, false, false
  180. ao.Attachment0, ao.Attachment1 = att0, att1
  181. ao.Parent = att0
  182.  
  183. local con0, con1 = nil, nil
  184. local vel = Part0.Velocity
  185. con0 = renderstepped:Connect(function()
  186. if not (Part0 and Part1) then return con0:Disconnect() and con1:Disconnect() end
  187. Part0.Velocity = vel
  188. end)
  189. local lastpos = Part0.Position
  190. con1 = heartbeat:Connect(function(delta)
  191. if not (Part0 and Part1) then return con0:Disconnect() and con1:Disconnect() end
  192. vel = Part0.Velocity
  193. if Part1.Velocity.Magnitude > 0.01 then
  194. Part0.Velocity = getNetlessVelocity(Part1.Velocity)
  195. else
  196. Part0.Velocity = getNetlessVelocity((Part0.Position - lastpos) / delta)
  197. end
  198. lastpos = Part0.Position
  199. end)
  200.  
  201. end
  202.  
  203. att0:GetPropertyChangedSignal("Parent"):Connect(function()
  204. Part0 = att0.Parent
  205. if not isa(Part0, "BasePart") then
  206. att0 = nil
  207. if lostpart == Part0 then
  208. lostpart = nil
  209. end
  210. Part0 = nil
  211. end
  212. end)
  213. att0.Parent = Part0
  214.  
  215. att1:GetPropertyChangedSignal("Parent"):Connect(function()
  216. Part1 = att1.Parent
  217. if not isa(Part1, "BasePart") then
  218. att1 = nil
  219. Part1 = nil
  220. end
  221. end)
  222. att1.Parent = Part1
  223. end
  224.  
  225. local function respawnrequest()
  226. local ccfr, c = ws.CurrentCamera.CFrame, lp.Character
  227. lp.Character = nil
  228. lp.Character = c
  229. local con = nil
  230. con = ws.CurrentCamera.Changed:Connect(function(prop)
  231. if (prop ~= "Parent") and (prop ~= "CFrame") then
  232. return
  233. end
  234. ws.CurrentCamera.CFrame = ccfr
  235. con:Disconnect()
  236. end)
  237. end
  238.  
  239. local destroyhum = (method == 4) or (method == 5)
  240. local breakjoints = (method == 0) or (method == 4)
  241. local antirespawn = (method == 0) or (method == 2) or (method == 3)
  242.  
  243. hatcollide = hatcollide and (method == 0)
  244.  
  245. addtools = addtools and lp:FindFirstChildOfClass("Backpack")
  246.  
  247. if type(simrad) ~= "number" then simrad = 1000 end
  248. if shp and (simradius == "shp") then
  249. tdelay(0, function()
  250. while c do
  251. shp(lp, "SimulationRadius", simrad)
  252. heartbeat:Wait()
  253. end
  254. end)
  255. elseif ssr and (simradius == "ssr") then
  256. tdelay(0, function()
  257. while c do
  258. ssr(simrad)
  259. heartbeat:Wait()
  260. end
  261. end)
  262. end
  263.  
  264. if antiragdoll then
  265. antiragdoll = function(v)
  266. if isa(v, "HingeConstraint") or isa(v, "BallSocketConstraint") then
  267. v.Parent = nil
  268. end
  269. end
  270. for i, v in pairs(getdescendants(c)) do
  271. antiragdoll(v)
  272. end
  273. c.DescendantAdded:Connect(antiragdoll)
  274. end
  275.  
  276. if antirespawn then
  277. respawnrequest()
  278. end
  279.  
  280. if method == 0 then
  281. twait(loadtime)
  282. if not c then
  283. return
  284. end
  285. end
  286.  
  287. if discharscripts then
  288. for i, v in pairs(getdescendants(c)) do
  289. if isa(v, "LocalScript") then
  290. v.Disabled = true
  291. end
  292. end
  293. elseif newanimate then
  294. local animate = gp(c, "Animate", "LocalScript")
  295. if animate and (not animate.Disabled) then
  296. animate.Disabled = true
  297. else
  298. newanimate = false
  299. end
  300. end
  301.  
  302. if addtools then
  303. for i, v in pairs(getchildren(addtools)) do
  304. if isa(v, "Tool") then
  305. v.Parent = c
  306. end
  307. end
  308. end
  309.  
  310. pcall(function()
  311. settings().Physics.AllowSleep = false
  312. settings().Physics.PhysicsEnvironmentalThrottle = Enum.EnviromentalPhysicsThrottle.Disabled
  313. end)
  314.  
  315. local OLDscripts = {}
  316.  
  317. for i, v in pairs(getdescendants(c)) do
  318. if v.ClassName == "Script" then
  319. OLDscripts[v.Name] = true
  320. end
  321. end
  322.  
  323. local scriptNames = {}
  324.  
  325. for i, v in pairs(getdescendants(c)) do
  326. if isa(v, "BasePart") then
  327. local newName, exists = tostring(i), true
  328. while exists do
  329. exists = OLDscripts[newName]
  330. if exists then
  331. newName = newName .. "_"
  332. end
  333. end
  334. table.insert(scriptNames, newName)
  335. Instance.new("Script", v).Name = newName
  336. end
  337. end
  338.  
  339. local hum = c:FindFirstChildOfClass("Humanoid")
  340. if hum then
  341. for i, v in pairs(hum:GetPlayingAnimationTracks()) do
  342. v:Stop()
  343. end
  344. end
  345. c.Archivable = true
  346. local cl = clone(c)
  347. if hum and humState16 then
  348. hum:ChangeState(Enum.HumanoidStateType.Physics)
  349. if destroyhum then
  350. twait(1.6)
  351. end
  352. end
  353. if destroyhum then
  354. pcall(destroy, hum)
  355. end
  356.  
  357. if not c then
  358. return
  359. end
  360.  
  361. local head, torso, root = gp(c, "Head", "BasePart"), gp(c, "Torso", "BasePart") or gp(c, "UpperTorso", "BasePart"), gp(c, "HumanoidRootPart", "BasePart")
  362. if hatcollide then
  363. pcall(destroy, torso)
  364. pcall(destroy, root)
  365. pcall(destroy, c:FindFirstChildOfClass("BodyColors") or gp(c, "Health", "Script"))
  366. end
  367.  
  368. local model = Instance.new("Model", c)
  369. model:GetPropertyChangedSignal("Parent"):Connect(function()
  370. if not (model and model.Parent) then
  371. model = nil
  372. end
  373. end)
  374.  
  375. for i, v in pairs(getchildren(c)) do
  376. if v ~= model then
  377. if addtools and isa(v, "Tool") then
  378. for i1, v1 in pairs(getdescendants(v)) do
  379. if v1 and v1.Parent and isa(v1, "BasePart") then
  380. local bv = Instance.new("BodyVelocity")
  381. bv.Velocity, bv.MaxForce, bv.P, bv.Name = v3_0, v3(1000, 1000, 1000), 1250, "bv_" .. v.Name
  382. bv.Parent = v1
  383. end
  384. end
  385. end
  386. v.Parent = model
  387. end
  388. end
  389.  
  390. if breakjoints then
  391. model:BreakJoints()
  392. else
  393. if head and torso then
  394. for i, v in pairs(getdescendants(model)) do
  395. if isa(v, "JointInstance") then
  396. local save = false
  397. if (v.Part0 == torso) and (v.Part1 == head) then
  398. save = true
  399. end
  400. if (v.Part0 == head) and (v.Part1 == torso) then
  401. save = true
  402. end
  403. if save then
  404. if hedafterneck then
  405. hedafterneck = v
  406. end
  407. else
  408. pcall(destroy, v)
  409. end
  410. end
  411. end
  412. end
  413. if method == 3 then
  414. task.delay(loadtime, pcall, model.BreakJoints, model)
  415. end
  416. end
  417.  
  418. cl.Parent = ws
  419. for i, v in pairs(getchildren(cl)) do
  420. v.Parent = c
  421. end
  422. pcall(destroy, cl)
  423.  
  424. local uncollide, noclipcon = nil, nil
  425. if noclipAllParts then
  426. uncollide = function()
  427. if c then
  428. for i, v in pairs(getdescendants(c)) do
  429. if isa(v, "BasePart") then
  430. v.CanCollide = false
  431. end
  432. end
  433. else
  434. noclipcon:Disconnect()
  435. end
  436. end
  437. else
  438. uncollide = function()
  439. if model then
  440. for i, v in pairs(getdescendants(model)) do
  441. if isa(v, "BasePart") then
  442. v.CanCollide = false
  443. end
  444. end
  445. else
  446. noclipcon:Disconnect()
  447. end
  448. end
  449. end
  450. noclipcon = stepped:Connect(uncollide)
  451. uncollide()
  452.  
  453. for i, scr in pairs(getdescendants(model)) do
  454. if (scr.ClassName == "Script") and table.find(scriptNames, scr.Name) then
  455. local Part0 = scr.Parent
  456. if isa(Part0, "BasePart") then
  457. for i1, scr1 in pairs(getdescendants(c)) do
  458. if (scr1.ClassName == "Script") and (scr1.Name == scr.Name) and (not scr1:IsDescendantOf(model)) then
  459. local Part1 = scr1.Parent
  460. if (Part1.ClassName == Part0.ClassName) and (Part1.Name == Part0.Name) then
  461. align(Part0, Part1)
  462. pcall(destroy, scr)
  463. pcall(destroy, scr1)
  464. break
  465. end
  466. end
  467. end
  468. end
  469. end
  470. end
  471.  
  472. for i, v in pairs(getdescendants(c)) do
  473. if v and v.Parent and (not v:IsDescendantOf(model)) then
  474. if isa(v, "Decal") then
  475. v.Transparency = 1
  476. elseif isa(v, "BasePart") then
  477. v.Transparency = 1
  478. v.Anchored = false
  479. elseif isa(v, "ForceField") then
  480. v.Visible = false
  481. elseif isa(v, "Sound") then
  482. v.Playing = false
  483. 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
  484. v.Enabled = false
  485. end
  486. end
  487. end
  488.  
  489. if newanimate then
  490. local animate = gp(c, "Animate", "LocalScript")
  491. if animate then
  492. animate.Disabled = false
  493. end
  494. end
  495.  
  496. if addtools then
  497. for i, v in pairs(getchildren(c)) do
  498. if isa(v, "Tool") then
  499. v.Parent = addtools
  500. end
  501. end
  502. end
  503.  
  504. local hum0, hum1 = model:FindFirstChildOfClass("Humanoid"), c:FindFirstChildOfClass("Humanoid")
  505. if hum0 then
  506. hum0:GetPropertyChangedSignal("Parent"):Connect(function()
  507. if not (hum0 and hum0.Parent) then
  508. hum0 = nil
  509. end
  510. end)
  511. end
  512. if hum1 then
  513. hum1:GetPropertyChangedSignal("Parent"):Connect(function()
  514. if not (hum1 and hum1.Parent) then
  515. hum1 = nil
  516. end
  517. end)
  518.  
  519. ws.CurrentCamera.CameraSubject = hum1
  520. local camSubCon = nil
  521. local function camSubFunc()
  522. camSubCon:Disconnect()
  523. if c and hum1 then
  524. ws.CurrentCamera.CameraSubject = hum1
  525. end
  526. end
  527. camSubCon = renderstepped:Connect(camSubFunc)
  528. if hum0 then
  529. hum0:GetPropertyChangedSignal("Jump"):Connect(function()
  530. if hum1 then
  531. hum1.Jump = hum0.Jump
  532. end
  533. end)
  534. else
  535. respawnrequest()
  536. end
  537. end
  538.  
  539. local rb = Instance.new("BindableEvent", c)
  540. rb.Event:Connect(function()
  541. pcall(destroy, rb)
  542. sg:SetCore("ResetButtonCallback", true)
  543. if destroyhum then
  544. if c then c:BreakJoints() end
  545. return
  546. end
  547. if model and hum0 and (hum0.Health > 0) then
  548. model:BreakJoints()
  549. hum0.Health = 0
  550. end
  551. if antirespawn then
  552. respawnrequest()
  553. end
  554. end)
  555. sg:SetCore("ResetButtonCallback", rb)
  556.  
  557. tdelay(0, function()
  558. while c do
  559. if hum0 and hum1 then
  560. hum1.Jump = hum0.Jump
  561. end
  562. wait()
  563. end
  564. sg:SetCore("ResetButtonCallback", true)
  565. end)
  566.  
  567. R15toR6 = R15toR6 and hum1 and (hum1.RigType == Enum.HumanoidRigType.R15)
  568. if R15toR6 then
  569. 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")
  570. if part then
  571. local cfr = part.CFrame
  572. local R6parts = {
  573. head = {
  574. Name = "Head",
  575. Size = v3(2, 1, 1),
  576. R15 = {
  577. Head = 0
  578. }
  579. },
  580. torso = {
  581. Name = "Torso",
  582. Size = v3(2, 2, 1),
  583. R15 = {
  584. UpperTorso = 0.2,
  585. LowerTorso = -0.8
  586. }
  587. },
  588. root = {
  589. Name = "HumanoidRootPart",
  590. Size = v3(2, 2, 1),
  591. R15 = {
  592. HumanoidRootPart = 0
  593. }
  594. },
  595. leftArm = {
  596. Name = "Left Arm",
  597. Size = v3(1, 2, 1),
  598. R15 = {
  599. LeftHand = -0.849,
  600. LeftLowerArm = -0.174,
  601. LeftUpperArm = 0.415
  602. }
  603. },
  604. rightArm = {
  605. Name = "Right Arm",
  606. Size = v3(1, 2, 1),
  607. R15 = {
  608. RightHand = -0.849,
  609. RightLowerArm = -0.174,
  610. RightUpperArm = 0.415
  611. }
  612. },
  613. leftLeg = {
  614. Name = "Left Leg",
  615. Size = v3(1, 2, 1),
  616. R15 = {
  617. LeftFoot = -0.85,
  618. LeftLowerLeg = -0.29,
  619. LeftUpperLeg = 0.49
  620. }
  621. },
  622. rightLeg = {
  623. Name = "Right Leg",
  624. Size = v3(1, 2, 1),
  625. R15 = {
  626. RightFoot = -0.85,
  627. RightLowerLeg = -0.29,
  628. RightUpperLeg = 0.49
  629. }
  630. }
  631. }
  632. for i, v in pairs(getchildren(c)) do
  633. if isa(v, "BasePart") then
  634. for i1, v1 in pairs(getchildren(v)) do
  635. if isa(v1, "Motor6D") then
  636. v1.Part0 = nil
  637. end
  638. end
  639. end
  640. end
  641. part.Archivable = true
  642. for i, v in pairs(R6parts) do
  643. local part = clone(part)
  644. part:ClearAllChildren()
  645. part.Name, part.Size, part.CFrame, part.Anchored, part.Transparency, part.CanCollide = v.Name, v.Size, cfr, false, 1, false
  646. for i1, v1 in pairs(v.R15) do
  647. local R15part = gp(c, i1, "BasePart")
  648. local att = gp(R15part, "att1_" .. i1, "Attachment")
  649. if R15part then
  650. local weld = Instance.new("Weld")
  651. weld.Part0, weld.Part1, weld.C0, weld.C1, weld.Name = part, R15part, cf(0, v1, 0), cf_0, "Weld_" .. i1
  652. weld.Parent = R15part
  653. R15part.Massless, R15part.Name = true, "R15_" .. i1
  654. R15part.Parent = part
  655. if att then
  656. att.Position = v3(0, v1, 0)
  657. att.Parent = part
  658. end
  659. end
  660. end
  661. part.Parent = c
  662. R6parts[i] = part
  663. end
  664. local R6joints = {
  665. neck = {
  666. Parent = R6parts.torso,
  667. Name = "Neck",
  668. Part0 = R6parts.torso,
  669. Part1 = R6parts.head,
  670. C0 = cf(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0),
  671. C1 = cf(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
  672. },
  673. rootJoint = {
  674. Parent = R6parts.root,
  675. Name = "RootJoint" ,
  676. Part0 = R6parts.root,
  677. Part1 = R6parts.torso,
  678. C0 = cf(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0),
  679. C1 = cf(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0)
  680. },
  681. rightShoulder = {
  682. Parent = R6parts.torso,
  683. Name = "Right Shoulder",
  684. Part0 = R6parts.torso,
  685. Part1 = R6parts.rightArm,
  686. C0 = cf(1, 0.5, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0),
  687. C1 = cf(-0.5, 0.5, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  688. },
  689. leftShoulder = {
  690. Parent = R6parts.torso,
  691. Name = "Left Shoulder",
  692. Part0 = R6parts.torso,
  693. Part1 = R6parts.leftArm,
  694. C0 = cf(-1, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0),
  695. C1 = cf(0.5, 0.5, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  696. },
  697. rightHip = {
  698. Parent = R6parts.torso,
  699. Name = "Right Hip",
  700. Part0 = R6parts.torso,
  701. Part1 = R6parts.rightLeg,
  702. C0 = cf(1, -1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0),
  703. C1 = cf(0.5, 1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0)
  704. },
  705. leftHip = {
  706. Parent = R6parts.torso,
  707. Name = "Left Hip" ,
  708. Part0 = R6parts.torso,
  709. Part1 = R6parts.leftLeg,
  710. C0 = cf(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0),
  711. C1 = cf(-0.5, 1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  712. }
  713. }
  714. for i, v in pairs(R6joints) do
  715. local joint = Instance.new("Motor6D")
  716. for prop, val in pairs(v) do
  717. joint[prop] = val
  718. end
  719. R6joints[i] = joint
  720. end
  721. if hum1 then
  722. hum1.RigType, hum1.HipHeight = Enum.HumanoidRigType.R6, 0
  723. end
  724. end
  725. end
  726.  
  727. local torso1 = torso
  728. torso = gp(c, "Torso", "BasePart") or ((not R15toR6) and gp(c, torso.Name, "BasePart"))
  729. if (typeof(hedafterneck) == "Instance") and head and torso and torso1 then
  730. local conNeck, conTorso, conTorso1 = nil, nil, nil
  731. local aligns = {}
  732. local function enableAligns()
  733. conNeck:Disconnect()
  734. conTorso:Disconnect()
  735. conTorso1:Disconnect()
  736. for i, v in pairs(aligns) do
  737. v.Enabled = true
  738. end
  739. end
  740. conNeck = hedafterneck.Changed:Connect(function(prop)
  741. if table.find({"Part0", "Part1", "Parent"}, prop) then
  742. enableAligns()
  743. end
  744. end)
  745. conTorso = torso:GetPropertyChangedSignal("Parent"):Connect(enableAligns)
  746. conTorso1 = torso1:GetPropertyChangedSignal("Parent"):Connect(enableAligns)
  747. for i, v in pairs(getdescendants(head)) do
  748. if isa(v, "AlignPosition") or isa(v, "AlignOrientation") then
  749. i = tostring(i)
  750. aligns[i] = v
  751. v:GetPropertyChangedSignal("Parent"):Connect(function()
  752. aligns[i] = nil
  753. end)
  754. v.Enabled = false
  755. end
  756. end
  757. end
  758.  
  759.  
  760.  
  761.  
  762.  
  763.  
  764.  
  765. --body parts
  766.  
  767. local head = gp(c, "Head", "BasePart")
  768. if not head then return print("head not found") end
  769.  
  770. local torso = gp(c, "Torso", "BasePart")
  771. if not torso then return print("torso not found") end
  772.  
  773. local humanoidRootPart = gp(c, "HumanoidRootPart", "BasePart")
  774. if not humanoidRootPart then return print("humanoid root part not found") end
  775.  
  776. local leftArm = gp(c, "Left Arm", "BasePart")
  777. if not leftArm then return print("left arm not found") end
  778.  
  779. local rightArm = gp(c, "Right Arm", "BasePart")
  780. if not rightArm then return print("right arm not found") end
  781.  
  782. local leftLeg = gp(c, "Left Leg", "BasePart")
  783. if not leftLeg then return print("left leg not found") end
  784.  
  785. local rightLeg = gp(c, "Right Leg", "BasePart")
  786. if not rightLeg then return print("right leg not found") end
  787.  
  788. --rig joints
  789.  
  790. local Neck = gp(torso, "Neck", "Motor6D")
  791. if not Neck then return print("Neck not found") end
  792.  
  793. local RootJoint = gp(humanoidRootPart, "RootJoint", "Motor6D")
  794. if not RootJoint then return print("root joint not found") end
  795.  
  796. local LeftShoulder = gp(torso, "Left Shoulder", "Motor6D")
  797. if not LeftShoulder then return print("left shoulder not found") end
  798.  
  799. local RightShoulder = gp(torso, "Right Shoulder", "Motor6D")
  800. if not RightShoulder then return print("right shoulder not found") end
  801.  
  802. local LeftHip = gp(torso, "Left Hip", "Motor6D")
  803. if not LeftHip then return print("left hip not found") end
  804.  
  805. local RightHip = gp(torso, "Right Hip", "Motor6D")
  806. if not RightHip then return print("right hip not found") end
  807.  
  808.  
  809. local armroot = Instance.new("Part")
  810. local weldroot = Instance.new("Weld")
  811. weldroot.Parent = torso
  812. weldroot.Part0 = torso
  813. weldroot.Part1 = armroot
  814. armroot.Parent = weldroot
  815. armroot.Transparency = 1
  816. armroot.Size = Vector3.new(0.5, 0.5, 0.5)
  817. local weldrootmotor = Instance.new("Motor6D")
  818. weldrootmotor.C0 = cf()
  819.  
  820. local part1 = Instance.new("Part")
  821. local weld1 = Instance.new("Weld")
  822. weld1.Parent = armroot
  823. weld1.Part0 = armroot
  824. weld1.Part1 = part1
  825. part1.Parent = weld1
  826. part1.Size = Vector3.new(1, 1, 1)
  827. part1.Transparency = 1
  828. local weld1motor = Instance.new("Motor6D")
  829. weld1motor.C0 = cf()
  830.  
  831. local part2 = Instance.new("Part")
  832. local weld2 = Instance.new("Weld")
  833. weld2.Parent = part1
  834. weld2.Part0 = part1
  835. weld2.Part1 = part2
  836. part2.Parent = weld2
  837. part2.Transparency = 1
  838. part2.Size = Vector3.new(1.2, 2, 1.2)
  839. local weld2motor = Instance.new("Motor6D")
  840. weld2motor.C0 = cf()
  841.  
  842.  
  843. local A1 = Instance.new("Attachment", part2)
  844. local A2 = Instance.new("Attachment", part2)
  845. A1.Position = Vector3.new(0, 0, -1)
  846. A2.Position = Vector3.new(0, 0, -4)
  847. local ts1 = Instance.new('Trail', part2)
  848. ts1.Attachment0 = A1
  849. ts1.Attachment1 = A2
  850. ts1.Texture = "http://www.roblox.com/asset/?id=19787048530"
  851. ts1.LightEmission = 1
  852. ts1.Transparency = NumberSequence.new(0, 0.5, 1)
  853. ts1.Color = ColorSequence.new(BrickColor.new('Royal Blue').Color,BrickColor.new('Cyan').Color)
  854. ts1.Lifetime = 0.1
  855. ts1.Enabled = true
  856.  
  857.  
  858. local targetAccessory = "HatAccessory"
  859. local targetHandle = nil
  860. for i, v in pairs(c:GetChildren()) do
  861. if v:IsA("Accessory") and v.Name == targetAccessory then
  862. targetHandle = gp(v, "Handle", "BasePart")
  863. break
  864. end
  865. end
  866.  
  867. if not targetHandle then
  868. return
  869. end
  870.  
  871. local handle1 = gp(gp(model, targetHandle.Parent.Name, "Accessory"), "Handle", "BasePart")
  872. if not handle1 then
  873. return
  874. end
  875.  
  876. handle1.Destroying:Connect(function()
  877. handle1 = nil
  878. end)
  879. targetHandle.Destroying:Connect(function()
  880. targetHandle = nil
  881. end)
  882.  
  883. targetHandle:BreakJoints()
  884. targetHandle.Anchored = true
  885.  
  886. for i, v in pairs(handle1:GetDescendants()) do
  887. if v:IsA("AlignOrientation") then
  888. v.Enabled = false
  889. end
  890. end
  891.  
  892. --local mouse = lp:GetMouse()
  893. --local fling = false
  894. --mouse.Button1Down:Connect(function()
  895. --fling = true
  896. --end)
  897. --mouse.Button1Up:Connect(function()
  898. --fling = false
  899. --end)
  900. local function doForSignal(signal, vel)
  901. spawn(function()
  902. while signal:Wait() and c and handle1 and targetHandle do
  903. if fling and mouse.Target then
  904. targetHandle.Position = mouse.Hit.Position
  905. end
  906. handle1.RotVelocity = vel
  907. end
  908. end)
  909. end
  910.  
  911. doForSignal(stepped, v3(100, 100, 100))
  912. doForSignal(renderstepped, v3(100, 100, 100))
  913. doForSignal(heartbeat, v3(-2000000000000000000, 2000000000000000, 200000000000000))
  914.  
  915.  
  916. local lp = game:GetService("Players").LocalPlayer
  917.  
  918.  
  919. local ch = lp.Character
  920.  
  921. local v3 = Vector3.new
  922.  
  923. local function gp(parent, name, className)
  924. if typeof(parent) == "Instance" then
  925. for i, v in pairs(parent:GetChildren()) do
  926. if (v.Name == name) and v:IsA(className) then
  927. return v
  928. end
  929. end
  930. end
  931. return nil
  932. end
  933.  
  934. local hat1 = gp(ch, "Pal Hair", "Accessory")
  935. local handle1 = gp(hat1, "Handle", "BasePart")
  936. local att1 = gp(handle1, "att1_Handle", "Attachment")
  937. att1.Parent = rightArm
  938. att1.Position = Vector3.new(0, 0, 0)
  939. att1.Rotation = Vector3.new(90, 0, 0)
  940.  
  941. local hat2 = gp(ch, "Pink Hair", "Accessory")
  942. local handle2 = gp(hat2, "Handle", "BasePart")
  943. local att2 = gp(handle2, "att1_Handle", "Attachment")
  944. att2.Parent = leftArm
  945. att2.Position = Vector3.new(0, 0, 0)
  946. att2.Rotation = Vector3.new(90, 0, 0)
  947.  
  948. local hat3 = gp(ch, "LavanderHair", "Accessory")
  949. local handle3 = gp(hat3, "Handle", "BasePart")
  950. local att3 = gp(handle3, "att1_Handle", "Attachment")
  951. att3.Parent = torso
  952. att3.Position = Vector3.new(0, -0.5, 0)
  953. att3.Rotation = Vector3.new(0, 90, 0)
  954.  
  955. local hat4 = gp(ch, "Kate Hair", "Accessory")
  956. local handle4 = gp(hat4, "Handle", "BasePart")
  957. local att4 = gp(handle4, "att1_Handle", "Attachment")
  958. att4.Parent = torso
  959. att4.Position = Vector3.new(0, 0.5, 0)
  960. att4.Rotation = Vector3.new(0, 90, 0)
  961.  
  962. local hat5 = gp(ch, "Robloxclassicred", "Accessory")
  963. local handle5 = gp(hat5, "Handle", "BasePart")
  964. local att5 = gp(handle5, "att1_Handle", "Attachment")
  965. att5.Parent = leftLeg
  966. att5.Position = Vector3.new(0, 0, 0)
  967. att5.Rotation = Vector3.new(90, 0, 0)
  968.  
  969. local hat6 = gp(ch, "Hat1", "Accessory")
  970. local handle6 = gp(hat6, "Handle", "BasePart")
  971. local att6 = gp(handle6, "att1_Handle", "Attachment")
  972. att6.Parent = rightLeg
  973. att6.Position = Vector3.new(0, 0, 0)
  974. att6.Rotation = Vector3.new(90, 0, 0)
  975.  
  976. local hat7 = gp(ch, "HatAccessory", "Accessory")
  977. local handle7 = gp(hat7, "Handle", "BasePart")
  978. local att7 = gp(handle7, "att1_Handle", "Attachment")
  979. att7.Parent = part2
  980. att7.Position = Vector3.new(0, -0, -4)
  981. att7.Rotation = Vector3.new(0, -0, -0)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement