Advertisement
refrop

disco ball

Feb 23rd, 2018
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 53.29 KB | None | 0 0
  1. local verlet = {}
  2. verlet.step_time = 1 / 50
  3. verlet.gravity = Vector3.new(0, -10, 0)
  4.  
  5. local char = game.Players.LocalPlayer.Character
  6. local torso = char:WaitForChild("Torso")
  7. local parts = {}
  8. local render = game:GetService("RunService").RenderStepped
  9.  
  10. wait(2)
  11.  
  12. local point = {}
  13. local link = {}
  14. local rope = {}
  15.  
  16. local function ccw(A,B,C)
  17. return (C.y-A.y) * (B.x-A.x) > (B.y-A.y) * (C.x-A.x)
  18. end
  19.  
  20. local function intersect(A,B,C,D)
  21. return ccw(A,C,D) ~= ccw(B,C,D) and ccw(A,B,C) ~= ccw(A,B,D)
  22. end
  23.  
  24. local function vec2(v)
  25. return Vector2.new(v.x, v.z)
  26. end
  27.  
  28. function point:step()
  29. if not self.fixed then
  30. local derivative = (self.position - self.last_position) * 0.95
  31. self.last_position = self.position
  32. self.position = self.position + derivative + (self.velocity * verlet.step_time ^ 2)
  33. --[[local torsoP = torso.CFrame * CFrame.new(-1, 0, 0.5)
  34. local torsoE = torso.CFrame * CFrame.new(1, 0, 0.5)
  35. local pointE = self.position + torso.CFrame.lookVector * 100
  36. local doIntersect = intersect(vec2(torsoP.p), vec2(torsoE.p), vec2(self.position), vec2(pointE))
  37. if not doIntersect then
  38. self.postition = self.position - torso.CFrame.lookVector * 10
  39. end]]
  40. end
  41. end
  42.  
  43. function link:step()
  44. for i = 1, 1 do
  45. local distance = self.point1.position - self.point2.position
  46. local magnitude = distance.magnitude
  47. local differance = (self.length - magnitude) / magnitude
  48. local translation = ((self.point1.fixed or self.point2.fixed) and 1 or 0.6) * distance * differance
  49. if not self.point1.fixed then
  50. self.point1.position = self.point1.position + translation
  51. end
  52. if not self.point2.fixed then
  53. self.point2.position = self.point2.position - translation
  54. end
  55. end
  56. end
  57.  
  58. function verlet.new(class, a, b, c)
  59. if class == "Point" then
  60. local new = {}
  61. setmetatable(new, {__index = point})
  62. new.class = class
  63. new.position = a or Vector3.new()
  64. new.last_position = new.position
  65. new.velocity = verlet.gravity
  66. new.fixed = false
  67. return new
  68. elseif class == "Link" then
  69. local new = {}
  70. setmetatable(new, {__index = link})
  71. new.class = class
  72. new.point1 = a
  73. new.point2 = b
  74. new.length = c or (a.position - b.position).magnitude
  75. return new
  76. elseif class == "Rope" then
  77. local new = {}
  78. setmetatable(new, {__index = link})
  79. new.class = class
  80. new.start_point = a
  81. new.finish_point = b
  82. new.points = {}
  83. new.links = {}
  84. local inc = (b - a) / 10
  85. for i = 0, 10 do
  86. table.insert(new.points, verlet.new("Point", a + (i * inc)))
  87. end
  88. for i = 2, #new.points do
  89. table.insert(new.links, verlet.new("Link", new.points[i - 1], new.points[i]))
  90. end
  91. return new
  92. end
  93. end
  94.  
  95. local tris = {}
  96. local triParts = {}
  97.  
  98. local function GetDiscoColor(hue)
  99. local section = hue % 1 * 3
  100. local secondary = 0.5 * math.pi * (section % 1)
  101. if section < 1 then
  102. return Color3.new(248, 248 - math.cos(secondary), 248 - math.sin(secondary))
  103. elseif section < 2 then
  104. return Color3.new(248 - math.sin(secondary), 248, 248 - math.cos(secondary))
  105. else
  106. return Color3.new(248 - math.cos(secondary), 248 - math.sin(secondary), 1)
  107. end
  108. end
  109.  
  110. local function setupPart(part)
  111. part.Anchored = true
  112. part.FormFactor = 3
  113. part.CanCollide = false
  114. part.TopSurface = 10
  115. part.BottomSurface = 10
  116. part.LeftSurface = 10
  117. part.RightSurface = 10
  118. part.FrontSurface = 10
  119. part.BackSurface = 10
  120. part.Material = "Neon"
  121. local m = Instance.new("SpecialMesh", part)
  122. m.MeshType = "Wedge"
  123. m.Scale = Vector3.new(0.2, 1, 1)
  124. return part
  125. end
  126.  
  127. local function CFrameFromTopBack(at, top, back)
  128. local right = top:Cross(back)
  129. return CFrame.new(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
  130. end
  131.  
  132. local function drawTri(parent, a, b, c)
  133. local this = {}
  134. local mPart1 = table.remove(triParts, 1) or setupPart(Instance.new("Part"))
  135. local mPart2 = table.remove(triParts, 1) or setupPart(Instance.new("Part"))
  136. function this:Set(a, b, c)
  137. local ab, bc, ca = b-a, c-b, a-c
  138. local abm, bcm, cam = ab.magnitude, bc.magnitude, ca.magnitude
  139. local edg1 = math.abs(0.5 + ca:Dot(ab)/(abm*abm))
  140. local edg2 = math.abs(0.5 + ab:Dot(bc)/(bcm*bcm))
  141. local edg3 = math.abs(0.5 + bc:Dot(ca)/(cam*cam))
  142. if edg1 < edg2 then
  143. if edg1 >= edg3 then
  144. a, b, c = c, a, b
  145. ab, bc, ca = ca, ab, bc
  146. abm = cam
  147. end
  148. else
  149. if edg2 < edg3 then
  150. a, b, c = b, c, a
  151. ab, bc, ca = bc, ca, ab
  152. abm = bcm
  153. else
  154. a, b, c = c, a, b
  155. ab, bc, ca = ca, ab, bc
  156. abm = cam
  157. end
  158. end
  159.  
  160. local len1 = -ca:Dot(ab)/abm
  161. local len2 = abm - len1
  162. local width = (ca + ab.unit*len1).magnitude
  163.  
  164. local maincf = CFrameFromTopBack(a, ab:Cross(bc).unit, -ab.unit)
  165.  
  166. if len1 > 0.2 then
  167. mPart1.Parent = parent
  168. mPart1.Size = Vector3.new(248, width, len1)
  169. mPart1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2)
  170. else
  171. mPart1.Parent = nil
  172. end
  173.  
  174. if len2 > 0.2 then
  175. mPart2.Parent = parent
  176. mPart2.Size = Vector3.new(0.2, width, len2)
  177. mPart2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2)
  178. else
  179. mPart2.Parent = nil
  180. end
  181. end
  182. function this:SetProperty(prop, value)
  183. mPart1[prop] = value
  184. mPart2[prop] = value
  185. end
  186. this:Set(a, b, c)
  187. function this:Destroy()
  188. mPart1:Destroy()
  189. mPart2:Destroy()
  190. end
  191. this.p1 = mPart1
  192. this.p2 = mPart2
  193. this.p1.BrickColor = BrickColor.new(GetDiscoColor(math.noise(0.5, 0.5, this.p1.CFrame.Y * 0.5 + time())))
  194. this.p2.BrickColor = BrickColor.new(GetDiscoColor(math.noise(0.5, 0.5, this.p2.CFrame.Y * 0.5 + time())))
  195. return this
  196. end
  197.  
  198. function verlet.draw(object, id)
  199. if object.class == "Point" then
  200. local part = parts[id]
  201. part.BrickColor = BrickColor.new(248, 248, 248)
  202. part.Transparency = 0
  203. part.formFactor = 3
  204. part.Anchored = true
  205. part.CanCollide = false
  206. part.TopSurface = 0
  207. part.BottomSurface = 0
  208. part.Size = Vector3.new(0.35, 0.35, 0.35)
  209. part.Material = "Neon"
  210. part.CFrame = CFrame.new(object.position)
  211. part.Parent = torso
  212. return part
  213. elseif object.class == "Link" then
  214. local part = parts[id]
  215. local dist = (object.point1.position - object.point2.position).magnitude
  216. part.Size = Vector3.new(0.2, 0.2, dist)
  217. part.CFrame = CFrame.new(object.point1.position, object.point2.position) * CFrame.new(0, 0, dist * -0.5)
  218. part.Parent = torso
  219. return part
  220. end
  221. end
  222.  
  223. function verlet.clear()
  224. for _, v in pairs(workspace:GetChildren()) do
  225. if v.Name == "Part" then
  226. v:Destroy()
  227. end
  228. end
  229. end
  230.  
  231. local points = {}
  232. local links = {}
  233.  
  234. for x = 0, 2 do
  235. points[x] = {}
  236. for y = 0, 3 do
  237. points[x][y] = verlet.new("Point", torso.Position + Vector3.new(x * 0.8 - 2, 2 - y * 0.8, 5 + y * 0.4))
  238. points[x][y].fixed = y == 0
  239. end
  240. end
  241.  
  242. for x = 1, 2 do
  243. for y = 0, 3 do
  244. links[#links + 1] = verlet.new("Link", points[x][y], points[x - 1][y], 1 + y * 0.08)
  245. end
  246. end
  247.  
  248. for x = 0, 2 do
  249. for y = 1, 3 do
  250. links[#links + 1] = verlet.new("Link", points[x][y], points[x][y - 1], 1.2 + y * 0.03)
  251. end
  252. end
  253.  
  254. render:connect(function()
  255. for x = 0, 2 do
  256. for y = 0, 3 do
  257. if y == 0 then
  258. points[x][y].position = (torso.CFrame * CFrame.new(x * 1 - 1, 1, 0.5)).p
  259. else
  260. points[x][y]:step()
  261. end
  262. end
  263. end
  264. for i = 1, #links do
  265. links[i]:step()
  266. end
  267. for i = 1, #tris do
  268. triParts[#triParts + 1] = tris[i].p1
  269. triParts[#triParts + 1] = tris[i].p2
  270. end
  271. tris = {}
  272. for x = 1, 2 do
  273. for y = 1, 3 do
  274. tris[#tris + 1] = drawTri(torso, points[x - 1][y - 1].position, points[x - 1][y].position, points[x][y - 1].position)
  275. tris[#tris + 1] = drawTri(torso, points[x][y].position, points[x - 1][y].position, points[x][y - 1].position)
  276. end
  277. end
  278. end)
  279. local ran,err = ypcall(function()
  280. plr = game:service'Players'.LocalPlayer
  281. char = plr.Character
  282. mouse = plr:GetMouse()
  283. humanoid = char:findFirstChild("Humanoid")
  284. torso = char:findFirstChild("Torso")
  285. head = char.Head
  286. ra = char:findFirstChild("Right Arm")
  287. la = char:findFirstChild("Left Arm")
  288. rl = char:findFirstChild("Right Leg")
  289. ll = char:findFirstChild("Left Leg")
  290. rs = torso:findFirstChild("Right Shoulder")
  291. ls = torso:findFirstChild("Left Shoulder")
  292. rh = torso:findFirstChild("Right Hip")
  293. lh = torso:findFirstChild("Left Hip")
  294. neck = torso:findFirstChild("Neck")
  295. rj = char:findFirstChild("HumanoidRootPart"):findFirstChild("RootJoint")
  296. anim = char:findFirstChild("Animate")
  297. rootpart = char:findFirstChild("HumanoidRootPart")
  298. camera = workspace.CurrentCamera
  299. do --Removing ROBLOX's new Looped bug >_>
  300. local function rec(x)
  301. for i,v in pairs(x:children()) do
  302. if v:IsA'Animation' then
  303. v.AnimationId = 'rbxassetid://28159255'
  304. end
  305. rec(v)
  306. end
  307. end
  308. rec(anim) --the Animate script
  309. end
  310.  
  311. humanoid.Jump = true
  312.  
  313. wait(.4)
  314.  
  315.  
  316. if anim then
  317. anim:Destroy()
  318. end
  319.  
  320.  
  321. rj.C0 = CFrame.new()
  322. rj.C1 = CFrame.new()
  323.  
  324.  
  325. super_annoying = Instance.new("Sound", head)
  326. super_annoying.SoundId = "http://www.roblox.com/asset/?id=265576262"
  327. super_annoying.Volume = 50.6
  328. super_annoying.Looped = true
  329. barrel_roll = Instance.new("Sound", head)
  330. barrel_roll.SoundId = "http://www.roblox.com/asset/?id=298676114"
  331. barrel_roll.Volume = 50
  332. barrel_roll.Looped = true
  333. dubstep_gun = Instance.new("Sound", head)
  334. dubstep_gun.SoundId = "http://www.roblox.com/asset/?id=446666978"
  335. dubstep_gun.Volume = 0.6
  336. dubstep_gun.Looped = true
  337. you_are_pirate = Instance.new("Sound", head)
  338. you_are_pirate.SoundId = "http://www.roblox.com/asset/?id=404698306"
  339. you_are_pirate.Volume = 0.6
  340. you_are_pirate.Looped = true
  341. cant_touch = Instance.new("Sound", head)
  342. cant_touch.SoundId = "http://www.roblox.com/asset/?id=305234447"
  343. cant_touch.Volume = 1
  344. cant_touch.Looped = true
  345. gangy_style = Instance.new("Sound", head)
  346. gangy_style.SoundId = "http://www.roblox.com/asset/?id=333361404"
  347. gangy_style.Volume = 0.6
  348. gangy_style.Looped = true
  349. fox_say = Instance.new("Sound", head)
  350. fox_say.SoundId = "http://www.roblox.com/asset/?id=169827397"
  351. fox_say.Volume = 0.5
  352. fox_say.Looped = true
  353. durk = Instance.new("Sound", head)
  354. durk.SoundId = "http://www.roblox.com/asset/?id=222274242"
  355. durk.Volume = 0.8
  356. durk.Looped = true
  357. sax_guy = Instance.new("Sound", head)
  358. sax_guy.SoundId = "http://www.roblox.com/asset/?id=142435403"
  359. sax_guy.Volume = 0.6
  360. sax_guy.Looped = true
  361. heman = Instance.new("Sound", head)
  362. heman.SoundId = "http://www.roblox.com/asset/?id=458008883"
  363. heman.Volume = 1
  364. heman.Looped = true
  365. justin = Instance.new("Sound", head)
  366. justin.SoundId = "http://www.roblox.com/asset/?id=373307815"
  367. justin.Volume = 0.8
  368. justin.Looped = true
  369. brony_music = Instance.new("Sound", head)
  370. brony_music.SoundId = "http://www.roblox.com/asset/?id=379496294"
  371. brony_music.Volume = 1
  372. brony_music.Looped = true
  373. spitfire = Instance.new("Sound", head)
  374. spitfire.SoundId = "http://www.roblox.com/asset/?id=406250345"
  375. spitfire.Volume = 0.8
  376. spitfire.Looped = true
  377. burn_dem = Instance.new("Sound", head)
  378. burn_dem.SoundId = "http://www.roblox.com/asset/?id=143808239"
  379. burn_dem.Volume = 1
  380. burn_dem.Looped = true
  381. aj = Instance.new("Sound", head)
  382. aj.SoundId = "rbxassetid://414845336"
  383. aj.Volume = 1
  384. aj.Looped = true
  385.  
  386. Instance.new("HumanoidController", game:service'ControllerService')
  387. Instance.new("SkateboardController", game:service'ControllerService')
  388. Instance.new("VehicleController", game:service'ControllerService')
  389.  
  390.  
  391.  
  392.  
  393. --minimize
  394. rh.Parent = nil
  395. lh.Parent = nil
  396. rs.Parent = nil
  397. ls.Parent = nil
  398. neck.Parent = nil
  399. rj.Parent = nil
  400.  
  401.  
  402. rl.FormFactor = "Custom"
  403. ll.FormFactor = "Custom"
  404. ra.FormFactor = "Custom"
  405. la.FormFactor = "Custom"
  406. torso.FormFactor = "Custom"
  407. head.FormFactor = "Custom"
  408. rootpart.FormFactor = "Custom"
  409.  
  410.  
  411.  
  412.  
  413. rootpart.Size = Vector3.new(80.4, 80.4, 80.2)
  414. rl.Size = Vector3.new(80.4, 80.4, 80.2)
  415. ll.Size = Vector3.new(80.4, 80.4, 80.2)
  416. ra.Size = Vector3.new(80.4, 80.4, 80.2)
  417. la.Size = Vector3.new(80.4, 80.4, 80.2)
  418. torso.Size = Vector3.new(80.4, 80.4, 80.2)
  419. head.Size = Vector3.new(80.4, 80.4, 80.2)
  420.  
  421. rh.Parent = torso
  422. lh.Parent = torso
  423. rs.Parent = torso
  424. ls.Parent = torso
  425. neck.Parent = torso
  426. rj.Parent = rootpart
  427.  
  428.  
  429. if torso:findFirstChild("roblox") then
  430. local p = Instance.new("Part", char)
  431. p.FormFactor = "Custom"
  432. p.Size = torso.Size
  433. p.Transparency = 1
  434. p:BreakJoints()
  435. local w = Instance.new("Weld", char)
  436. w.Part0 = p
  437. w.Part1 = torso
  438. torso:findFirstChild("roblox").Parent = p
  439. end
  440.  
  441.  
  442. --[[mesh1 = Instance.new("SpecialMesh", torso)
  443. mesh1.Name = "Mesh"
  444. mesh1.Scale = torso.Size - Vector3.new(torso.Size.x/2, torso.Size.y/2, 0)
  445. mesh1.MeshId = "rbxasset://fonts/torso.mesh"
  446. mesh2 = Instance.new("SpecialMesh", la)
  447. mesh2.Name = "Mesh"
  448. mesh2.Scale = la.Size - Vector3.new(0, la.Size.y/2, 0)
  449. mesh2.MeshId = "rbxasset://fonts/leftarm.mesh"
  450. mesh3 = Instance.new("SpecialMesh", ra)
  451. mesh3.Name = "Mesh"
  452. mesh3.Scale = ra.Size - Vector3.new(0, ra.Size.y/2, 0)
  453. mesh3.MeshId = "rbxasset://fonts/rightarm.mesh"
  454. mesh4 = Instance.new("SpecialMesh", ll)
  455. mesh4.Name = "Mesh"
  456. mesh4.Scale = ll.Size - Vector3.new(0, ll.Size.y/2, 0)
  457. mesh4.MeshId = "rbxasset://fonts/leftleg.mesh"
  458. mesh5 = Instance.new("SpecialMesh", rl)
  459. mesh5.Name = "Mesh"
  460. mesh5.Scale = rl.Size - Vector3.new(0, rl.Size.y/2, 0)
  461. mesh5.MeshId = "rbxasset://fonts/rightleg.mesh"--]]
  462.  
  463.  
  464. --0.3 = 1.5, 0.1 = 0.5, 0.2 = 1
  465.  
  466. ls.C0 = CFrame.new(-.3,.1,0)
  467. ls.C1 = CFrame.new(0,.1,0)
  468. rs.C0 = CFrame.new(.3,.1,0)
  469. rs.C1 = CFrame.new(0,.1,0)
  470. rh.C0 = CFrame.new(.1,-.2,0)
  471. rh.C1 = CFrame.new(0, .2, 0)
  472. lh.C0 = CFrame.new(-.1,-.2,0)
  473. lh.C1 = CFrame.new(0, .2, 0)
  474. neck.C0 = CFrame.new(0,.2,0)
  475. neck.C1 = CFrame.new(0,-.1,0)
  476.  
  477. bodyc = char:findFirstChild("Body Colors")
  478. if bodyc then
  479. bodyc:Destroy()
  480. end
  481.  
  482. wait(1)
  483.  
  484. local body = {}
  485. for i,v in pairs(char:children()) do
  486. if v:IsA'BasePart' then
  487. print(v.Name)
  488. body[v.Name] = {Color = v.BrickColor}
  489. end
  490. end
  491.  
  492. print(body.Torso)
  493. function restorecolors()
  494. for _,bp in pairs(char:children()) do
  495. if bp:IsA("BasePart") then
  496. bp.BrickColor = body[bp.Name].Color
  497. end
  498. end
  499. end
  500.  
  501.  
  502. local LightForTorso = Instance.new("PointLight", head)
  503. LightForTorso.Color = torso.BrickColor.Color
  504. LightForTorso.Range = 7
  505. LightForTorso.Brightness = 1.5
  506.  
  507.  
  508.  
  509.  
  510. local slidecount = 0
  511. local slidecountmax = 0
  512. local anim = ""
  513. local lastanim = anim
  514. local speed = 0
  515. local looking = false
  516. local dancing = false
  517. local superannoying = false
  518. local barrelroll = false
  519. local dubstepgun = false
  520. local foxie = false
  521. local durka = false
  522. local saxguy = false
  523. local heya = false
  524. local jb = false
  525. local bronymusic = false
  526. local sheddy = false
  527. local burndem = false
  528. local global_wait = 0
  529.  
  530. count = 0
  531. countspeed = 1
  532. sine = 0
  533. sinespeed = 1
  534.  
  535.  
  536.  
  537. humanoid.WalkSpeed = 11
  538.  
  539.  
  540. local controllerService = game:GetService("ControllerService")
  541. local controller = controllerService:GetChildren()[1]
  542.  
  543.  
  544. local colors = {"White", "Really black"}
  545.  
  546. humanoid.Died:connect(function()
  547. for cframe_parts = 0, 100 do
  548. local p = Instance.new("Part")
  549. p.FormFactor = "Custom"
  550. p.BrickColor = BrickColor.new(colors[math.random(1, #colors)])
  551. p.Size = Vector3.new(1, 1, 1)
  552. Instance.new("BlockMesh", p).Scale = Vector3.new(0.05, 0.05, 0.05)
  553. p.Locked = true
  554. p.CanCollide = false
  555. p.Anchored = true
  556. p.CFrame = torso.CFrame * CFrame.Angles(math.random(-36, 36),math.random(-36, 36),math.random(-36, 36))
  557. p.Parent = workspace
  558. game:service'Debris':AddItem(p, 5)
  559. coroutine.wrap(function()
  560. while wait() do
  561. if p ~= nil then
  562. p.CFrame = p.CFrame * CFrame.new(0, 0.085, 0)
  563. p.Mesh.Scale = p.Mesh.Scale - Vector3.new(0.005, 0, 0.005) + Vector3.new(0, 0.01, 0)
  564. p.Transparency = p.Transparency + 0.015
  565. else
  566. break
  567. end
  568. end
  569. end)()
  570. end
  571. for _,v in pairs(char:children()) do
  572. if v:IsA("Part") then
  573. v:Destroy()
  574. end
  575. end
  576.  
  577. end)
  578.  
  579.  
  580. mouse.KeyDown:connect(function(k)
  581.  
  582. if string.byte(k) == 50 then
  583.  
  584. if dancing then return end
  585. sitting = not sitting
  586. if sitting then
  587. local ray = Ray.new(torso.Position, Vector3.new(0, -1, 0))
  588. local hitz,enz = workspace:FindPartOnRay(ray, char)
  589.  
  590.  
  591. if hitz then
  592. controller.Parent = nil
  593. humanoid.WalkSpeed = 0
  594. coroutine.wrap(function()
  595. while wait() do
  596. humanoid.PlatformStand = true
  597. if sitting == false then humanoid.PlatformStand = false break end
  598. end
  599. end)()
  600. rj.C0 = CFrame.new(0, -0.35, 0) * CFrame.Angles(math.rad(10), 0, 0)
  601. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.pi/2-math.rad(10), 0, -math.pi/16)
  602. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(math.pi/2-math.rad(10), 0, math.pi/16)
  603. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(-math.rad(10), 0, -math.pi/10)
  604. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(-math.rad(10), 0, math.pi/10)
  605.  
  606. miniweld = Instance.new("Weld", char)
  607. miniweld.C0 = hitz.CFrame:toObjectSpace(rootpart.CFrame)
  608. miniweld.Part0 = hitz
  609. miniweld.Part1 = rootpart
  610. else
  611. sitting = false
  612. return
  613. end
  614. else
  615. if miniweld then
  616. miniweld:Destroy()
  617. end
  618. controller.Parent = controllerService
  619. humanoid.PlatformStand = false
  620. humanoid.WalkSpeed = 11
  621. end
  622. end
  623.  
  624. if k == "w" or k == "a" or k == "s" or k == "d" or string.byte(k) == 32 then
  625. superannoying = false
  626. barrelroll = false
  627. heya = false
  628. dubstepgun = false
  629. youpirate = false
  630. canttouch = false
  631. gangnam = false
  632. sheddy = false
  633. durka = false
  634. saxguy = false
  635. foxie = false
  636. burndem = false
  637. bronymusic = false
  638. brony_music:stop()
  639. fox_say:stop()
  640. spitfire:stop()
  641. heman:stop()
  642. justin:stop()
  643. jb = false
  644. durk:stop()
  645. restorecolors()
  646. burn_dem:stop()
  647. if hat then
  648. hat:Destroy()
  649. end
  650. sax_guy:stop()
  651. gangy_style:stop()
  652. cant_touch:stop()
  653. you_are_pirate:stop()
  654. dubstep_gun:stop()
  655. super_annoying:stop()
  656. barrel_roll:stop()
  657. dancing = false
  658. global_wait = 0
  659. LightForTorso.Color = torso.BrickColor.Color
  660. end
  661.  
  662. if k == "z" then
  663. if dancing then return end
  664. if not sitting then
  665. dancing = true
  666. superannoying = true
  667. super_annoying:play()
  668. end
  669. end
  670. if k == "k" then
  671. if dancing then return end
  672. if not sitting then
  673. dancing = true
  674. sheddy = true
  675. spitfire:play()
  676. end
  677. end
  678.  
  679. if k == "n" then
  680. if dancing then return end
  681. if not sitting then
  682. dancing = true
  683. gangnam = true
  684. gangy_style:play()
  685. end
  686. end
  687.  
  688. if k == "r" then
  689. if dancing then return end
  690. if not sitting then
  691. dancing = true
  692. burndem = true
  693. burn_dem:play()
  694. end
  695. end
  696.  
  697.  
  698. if k == "x" then
  699. if dancing then return end
  700. if not sitting then
  701. dancing = true
  702. barrelroll = true
  703. barrel_roll:play()
  704. hat = Instance.new("Part", char)
  705. hat.FormFactor = "Custom"
  706. hat.CanCollide = false
  707. hat.Size = torso.Size
  708. hat.Locked = true
  709. hat:breakJoints()
  710. local hatmesh = Instance.new("SpecialMesh", hat)
  711. hatmesh.MeshId = "http://www.roblox.com/asset/?id=29873142"
  712. hatmesh.TextureId = "http://www.roblox.com/asset/?id=31467063"
  713. hatmesh.Scale = Vector3.new(.22, .2, .22)
  714. local hatweld = Instance.new("Weld", hat)
  715. hatweld.Part0 = hat
  716. hatweld.Part1 = torso
  717. end
  718. end
  719. if k == "h" then
  720. if dancing then return end
  721. if not sitting then
  722. dancing = true
  723. heman:play()
  724. heya = true
  725. hat = Instance.new("Part", char)
  726. hat.FormFactor = "Custom"
  727. hat.CanCollide = false
  728. hat.Size = torso.Size + Vector3.new(0.01, 0.01, 0.01)
  729. hat.Locked = true
  730. hat.BrickColor = BrickColor.new("Hot pink")
  731. hat:breakJoints()
  732. local hatweld = Instance.new("Weld", hat)
  733. hatweld.Part0 = hat
  734. hatweld.Part1 = torso
  735. end
  736. end
  737. if k == "j" then
  738. if dancing then return end
  739. if not sitting then
  740. dancing = true
  741. justin:play()
  742. jb = true
  743. hat = Instance.new("Part", char)
  744. hat.FormFactor = "Custom"
  745. hat.CanCollide = false
  746. hat.Size = head.Size
  747. hat.Locked = true
  748. hat.BrickColor = BrickColor.new("Hot pink")
  749. hat:breakJoints()
  750. local hatmesh = Instance.new("SpecialMesh", hat)
  751. hatmesh.MeshId = "http://www.roblox.com/asset/?id=19999424"
  752. hatmesh.TextureId = "http://www.roblox.com/asset/?id=20571982"
  753. hatmesh.Scale = Vector3.new(.23, .23, .23)
  754. local hatweld = Instance.new("Weld", hat)
  755. hatweld.Part0 = hat
  756. hatweld.Part1 = head
  757. hatweld.C0 = CFrame.new(0.025, -0.05, 0)
  758. end
  759. end
  760. if k == "c" then
  761. if dancing then return end
  762. if not sitting then
  763. dancing = true
  764. dubstepgun = true
  765. dubstep_gun:play()
  766. end
  767. end
  768. if k == "v" then
  769. if dancing then return end
  770. if not sitting then
  771. dancing = true
  772. youpirate = true
  773. you_are_pirate:play()
  774. hat = Instance.new("Part", char)
  775. hat.FormFactor = "Custom"
  776. hat.CanCollide = false
  777. hat.Size = head.Size
  778. hat.Locked = true
  779. hat:breakJoints()
  780. local hatmesh = Instance.new("SpecialMesh", hat)
  781. hatmesh.MeshId = "http://www.roblox.com/asset/?id=1028848"
  782. hatmesh.TextureId = "http://www.roblox.com/asset/?id=1028847"
  783. hatmesh.Scale = Vector3.new(.2, .2, .2)
  784. local hatweld = Instance.new("Weld", hat)
  785. hatweld.Part0 = hat
  786. hatweld.Part1 = head
  787. hatweld.C0 = CFrame.new(0, -0.15, 0)
  788. end
  789. end
  790. if k == "m" then
  791. if dancing then return end
  792. if not sitting then
  793. dancing = true
  794. canttouch = true
  795. cant_touch:play()
  796. end
  797. end
  798. if k == "b" then
  799. if dancing then return end
  800. if not sitting then
  801. dancing = true
  802. bronymusic = true
  803. brony_music:play()
  804. for _,bp in pairs(char:children()) do
  805. if bp:IsA("BasePart") then
  806. bp.BrickColor = BrickColor.new("Lavender")
  807. end
  808. end
  809. hat = Instance.new("Part", char)
  810. hat.FormFactor = "Custom"
  811. hat.CanCollide = false
  812. hat.Size = head.Size
  813. hat.Locked = true
  814. hat.BrickColor = BrickColor.new("Lavender")
  815. hat:breakJoints()
  816. local hatmesh = Instance.new("SpecialMesh", hat)
  817. hatmesh.MeshId = "http://www.roblox.com/asset/?id=118186643"
  818. hatmesh.Scale = Vector3.new(.1, .2, .1)
  819. local hatweld = Instance.new("Weld", hat)
  820. hatweld.Part0 = hat
  821. hatweld.Part1 = head
  822. hatweld.C0 = CFrame.new(0, -0.1, 0.05)
  823. end
  824. end
  825.  
  826. if k == "l" then
  827. if dancing then return end
  828. if not sitting then
  829. dancing = true
  830. foxie = true
  831. fox_say:play()
  832. hat = Instance.new("Part", char)
  833. hat.FormFactor = "Custom"
  834. hat.CanCollide = false
  835. hat.Size = head.Size
  836. hat.Locked = true
  837. hat:breakJoints()
  838. local hatmesh = Instance.new("SpecialMesh", hat)
  839. hatmesh.MeshId = "http://www.roblox.com/asset/?id=25266225"
  840. hatmesh.TextureId = "http://www.roblox.com/asset/?id=25266210"
  841. hatmesh.Scale = Vector3.new(.2, .2, .2)
  842. local hatweld = Instance.new("Weld", hat)
  843. hatweld.Part0 = hat
  844. hatweld.Part1 = head
  845. hatweld.C0 = CFrame.new(0, -0.1, 0)
  846. end
  847.  
  848. end
  849. if k == "f" then
  850. if dancing then return end
  851. if not sitting then
  852. dancing = true
  853. durka = true
  854. durk:play()
  855. end
  856. end
  857. if k == "g" then
  858. if dancing then return end
  859. if not sitting then
  860. dancing = true
  861. saxguy = true
  862. sax_guy:play()
  863. hat = Instance.new("Part", char)
  864. hat.FormFactor = "Custom"
  865. hat.CanCollide = false
  866. hat.Size = head.Size
  867. hat.Locked = true
  868. hat:breakJoints()
  869. local hatmesh = Instance.new("SpecialMesh", hat)
  870. hatmesh.MeshId = "http://www.roblox.com/asset/?id=44410178"
  871. hatmesh.TextureId = "http://www.roblox.com/asset/?id=44410320"
  872. hatmesh.Scale = Vector3.new(.25, .25, .25)
  873. local hatweld = Instance.new("Weld", hat)
  874. hatweld.Part0 = hat
  875. hatweld.Part1 = la
  876. hatweld.C0 = CFrame.new(-0.18, -0.05, .04) * CFrame.Angles(math.pi - math.rad(18), 0, math.pi/4)
  877. end
  878. end
  879.  
  880.  
  881.  
  882.  
  883. if k == "q" then
  884. if Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude >= 14 then return end
  885. if sitting then return end
  886. looking = true
  887. rj.C0 = CFrame.new(-math.pi/6, 0,0) * CFrame.Angles(0, 0, math.pi/4)
  888. end
  889. if k == "e" then
  890. if Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude >= 14 then return end
  891. if sitting then return end
  892. looking = true
  893. rj.C0 = CFrame.new(math.pi/6, 0,0) * CFrame.Angles(0, 0, -math.pi/4)
  894. end
  895. if k == "t" then
  896. if dancing then return end
  897. if sitting then return end
  898. dancing = true
  899. aj:play()
  900. end
  901. if string.byte(k) == 48 or string.byte(k) == 47 then
  902. if sitting then return end
  903. humanoid.WalkSpeed = 18
  904. end
  905. if string.byte(k) == 52 then
  906. if sitting then return end
  907. humanoid.WalkSpeed = 6
  908. end
  909. end)
  910.  
  911. mouse.KeyUp:connect(function(k)
  912. if string.byte(k) == 48 or string.byte(k) == 47 then
  913. if sitting then return end
  914. humanoid.WalkSpeed = 11
  915. end
  916. if k == "w" or k == "a" or k == "s" or k == "d" or string.byte(k) == 32 then
  917. superannoying = false
  918. barrelroll = false
  919. heya = false
  920. dubstepgun = false
  921. youpirate = false
  922. canttouch = false
  923. gangnam = false
  924. sheddy = false
  925. durka = false
  926. saxguy = false
  927. foxie = false
  928. burndem = false
  929. bronymusic = false
  930. aj:stop()
  931. brony_music:stop()
  932. fox_say:stop()
  933. spitfire:stop()
  934. heman:stop()
  935. justin:stop()
  936. jb = false
  937. durk:stop()
  938. restorecolors()
  939. burn_dem:stop()
  940. if hat then
  941. hat:Destroy()
  942. end
  943. sax_guy:stop()
  944. gangy_style:stop()
  945. cant_touch:stop()
  946. you_are_pirate:stop()
  947. dubstep_gun:stop()
  948. super_annoying:stop()
  949. barrel_roll:stop()
  950. dancing = false
  951. global_wait = 0
  952. LightForTorso.Color = torso.BrickColor.Color
  953. end
  954.  
  955.  
  956. if k == "q" then
  957. if looking then
  958. if sitting then return end
  959. rj.C0 = CFrame.new()
  960. looking = false
  961. end
  962. end
  963.  
  964. if k == "e" then
  965. if looking then
  966. if sitting then return end
  967. rj.C0 = CFrame.new()
  968. looking = false
  969. end
  970. end
  971. end)
  972.  
  973.  
  974. game:service'RunService'.Stepped:connect(function()
  975. count = (count % 100) + (countspeed/2)
  976. angle = math.pi * math.sin(math.pi*2/100*count)
  977.  
  978. if slidecount < slidecountmax then
  979. slidecount = slidecount + speed
  980. end
  981. if slidecount > slidecountmax then
  982. slidecount = slidecount - speed
  983. end
  984. if global_wait == 380 then global_wait = 0 end
  985.  
  986. sine = sine + sinespeed
  987. if not dancing then
  988. if not sitting then
  989. local ray = Ray.new(rootpart.Position, Vector3.new(0, -1, 0))
  990. local hitz, enz = workspace:FindPartOnRay(ray, char)
  991. if not hitz then
  992. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles((math.pi/8/5*slidecount) + math.pi + angle*0.05, 0, 0)
  993. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles((math.pi/8/5*slidecount) + math.pi + -angle*0.05, 0, 0)
  994. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(-angle*0.28, 0, 0)
  995. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(angle*0.28, 0, 0)
  996. if not looking then
  997. rj.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(-math.pi/8/5*slidecount, 0, 0)
  998. end
  999. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.pi/8/5*slidecount, 0, 0)
  1000. elseif Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude < 2 then
  1001.  
  1002. -- idle anim
  1003.  
  1004. anim = "Idle"
  1005. if anim ~= lastanim then
  1006. if lastanim == "Walking" then
  1007. speed = 0.5
  1008. slidecount = 1
  1009. slidecountmax = 0
  1010. elseif lastanim == "Running" then
  1011. speed = 2.5
  1012. slidecount = 5
  1013. slidecountmax = 0
  1014. else
  1015. slidecount = 0
  1016. slidecountmax = 0
  1017. end
  1018. end
  1019. countspeed = 1
  1020. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(angle*0.02, 0, 0)
  1021. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(-angle*0.02, 0, 0)
  1022. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(-angle*0.01, 0, 0)
  1023. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(angle*0.01, 0, 0)
  1024. if not looking then
  1025. rj.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(-math.pi/8/5*slidecount, 0, 0)
  1026. end
  1027. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.pi/8/5*slidecount, 0, 0)
  1028. elseif Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude < 14 then
  1029. looking = false
  1030. -- walk anim
  1031. anim = "Walking"
  1032. if anim ~= lastanim then
  1033. speed = 0.2
  1034. slidecount = 0
  1035. slidecountmax = 1
  1036. if lastanim == "Running" then
  1037. slidecount = 5
  1038. end
  1039. end
  1040. countspeed = 6
  1041. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(angle*0.3, 0, math.abs(angle*0.02))
  1042. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(-angle*0.3, 0, -math.abs(angle*0.02))
  1043. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(-angle*0.28, 0, -math.abs(angle*0.01))
  1044. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(angle*0.28, 0, math.abs(angle*0.01))
  1045. rj.C0 = CFrame.new(0, math.abs(-angle*0.035), 0) * CFrame.Angles(-math.pi/8/5*slidecount, 0, 0)
  1046. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.pi/8/5*slidecount, 0, 0)
  1047. elseif Vector3.new(torso.Velocity.x, 0, torso.Velocity.z).magnitude >= 14 then
  1048. --run anim
  1049. anim = "Running"
  1050. if anim ~= lastanim then
  1051. speed = 1
  1052. slidecount = 0
  1053. slidecountmax = 5
  1054. if lastanim == "Walking" then
  1055. slidecount = 1
  1056. end
  1057. end
  1058.  
  1059. looking = false
  1060. countspeed = 9
  1061. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(angle*0.4, 0, math.abs(angle*0.07))
  1062. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(-angle*0.4, 0, -math.abs(angle*0.07))
  1063. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(-angle*0.38, 0, -math.abs(angle*0.03))
  1064. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(angle*0.38, 0, math.abs(angle*0.03))
  1065. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.pi/8/5*slidecount, 0, 0)
  1066. rj.C0 = CFrame.new(0, math.abs(-angle*.055), 0) * CFrame.Angles(-math.pi/8/5*slidecount, math.sin(angle*0.05), 0)
  1067. end
  1068.  
  1069. lastanim = anim
  1070. else
  1071. countspeed = 1
  1072. local ray = Ray.new(rootpart.Position, Vector3.new(0, -2, 0))
  1073. local hitz, enz = workspace:FindPartOnRay(ray, char)
  1074. if not hitz then
  1075. rj.C0 = CFrame.new(0, -0.5, 0) * CFrame.Angles(-math.pi/2, 0, 0)
  1076. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.rad(30), 0, -math.pi/16)
  1077. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(math.rad(30), 0, math.pi/16)
  1078. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(-math.pi-math.rad(30), 0, -math.pi/10)
  1079. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(-math.pi-math.rad(30), 0, math.pi/10)
  1080. else
  1081. rj.C0 = CFrame.new(0, -0.35, 0) * CFrame.Angles(math.rad(10), 0, 0)
  1082. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.pi/2-math.rad(10), 0, -math.pi/16)
  1083. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(math.pi/2-math.rad(10), 0, math.pi/16)
  1084. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(-math.rad(10), 0, -math.pi/10)
  1085. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(-math.rad(10), 0, math.pi/10)
  1086. end
  1087.  
  1088. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(angle*0.055, 0, 0)
  1089. end
  1090. else
  1091. if superannoying then
  1092. countspeed = 5
  1093. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, math.abs(angle*0.07))
  1094. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, -math.abs(angle*0.07))
  1095. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.03))
  1096. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.03))
  1097. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1098. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.sin(angle*0.15), 0)
  1099. elseif barrelroll then
  1100. countspeed = 5
  1101. sinespeed = 0.1
  1102. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi + angle*0.2, 0, math.abs(angle*0.07))
  1103. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi + angle*0.2, 0, -math.abs(angle*0.07))
  1104. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(0, 0, -math.abs(angle*0.03))
  1105. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(0, 0, math.abs(angle*0.03))
  1106. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1107. rj.C0 = CFrame.new(math.sin(sine)*2.5, 0, 0) * CFrame.Angles(-math.pi/2, math.sin(sine)*4.5, 0)
  1108. elseif dubstepgun then
  1109. global_wait = (global_wait % 380) + 1
  1110. countspeed = 5
  1111. if global_wait < 249 - 40 then
  1112. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, -math.abs(angle*0.27))
  1113. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, math.abs(angle*0.27))
  1114. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.03))
  1115. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.03))
  1116. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1117. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.sin(angle*0.15), 0)
  1118. elseif global_wait > 249 - 40 then
  1119. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.4, 0, math.abs(angle*0.11))
  1120. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi + angle*0.2, 0, -math.abs(angle*0.11))
  1121. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.09))
  1122. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.09))
  1123. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1124. rj.C0 = CFrame.new(0, math.abs(-angle*.075), 0) * CFrame.Angles(0, math.pi/3 + math.sin(angle*0.15), 0)
  1125. end
  1126. elseif youpirate then
  1127. global_wait = (global_wait % 380) + 1
  1128. countspeed = 5
  1129. if global_wait < 79 then
  1130. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.1, 0, -math.abs(angle*0.07))
  1131. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(angle*0.2, 0, math.abs(angle*0.07))
  1132. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.03))
  1133. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.03))
  1134. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1135. rj.C0 = CFrame.new(0, math.abs(-angle*.02), 0) * CFrame.Angles(0, math.sin(angle*0.15), 0)
  1136. elseif global_wait < 299 then
  1137. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi + angle*0.2, 0, math.abs(angle*0.11))
  1138. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi + angle*0.2, 0, -math.abs(angle*0.11))
  1139. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.2, 0, -math.abs(angle*0.1))
  1140. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.2, 0, math.abs(angle*0.1))
  1141. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), math.sin(angle*0.19), 0)
  1142. rj.C0 = CFrame.new(0, math.abs(-angle*.055+0.2), 0) * CFrame.Angles(0, math.sin(angle*0.15), 0)
  1143. elseif global_wait > 299 then
  1144. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.1, 0, -math.abs(angle*0.07))
  1145. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(angle*0.2, 0, math.abs(angle*0.07))
  1146. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.03))
  1147. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.03))
  1148. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1149. rj.C0 = CFrame.new(0, math.abs(-angle*.02), 0) * CFrame.Angles(0, math.sin(angle*0.15), 0)
  1150. end
  1151. elseif canttouch then
  1152. countspeed = 5
  1153. global_wait = (global_wait % 160) + 1
  1154. if global_wait == 160 then global_wait = 0 end
  1155. if global_wait < 39 then
  1156. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, -math.abs(angle*0.07))
  1157. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, math.abs(angle*0.07))
  1158. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.03))
  1159. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.03))
  1160. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1161. rj.C0 = CFrame.new(0, math.abs(-angle*.03), 0) * CFrame.Angles(0, -math.pi/6, 0)
  1162. elseif global_wait < 79 then
  1163. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, -math.abs(angle*0.07))
  1164. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, 0, math.abs(angle*0.07))
  1165. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.03))
  1166. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.1, 0, math.abs(angle*0.03))
  1167. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1168. rj.C0 = CFrame.new(0, math.abs(-angle*.03), 0) * CFrame.Angles(0, math.pi/6, 0)
  1169. elseif global_wait < 119 then
  1170. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(0.01, 0, 0.17)
  1171. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(0.01, 0, -0.17)
  1172. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(0, -math.abs(angle*0.05), -math.abs(angle*0.06))
  1173. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(0, -math.abs(angle*0.05), math.abs(angle*0.06))
  1174. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1175. rj.C0 = CFrame.new(0, math.abs(-angle*.02), 0) * CFrame.Angles(0, 0, 0)
  1176. torso.CFrame = torso.CFrame * CFrame.new(0.05, 0, 0)
  1177. elseif global_wait > 119 then
  1178. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(0.01, 0, 0.17)
  1179. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(0.01, 0, -0.17)
  1180. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(0, -math.abs(angle*0.05), -math.abs(angle*0.06))
  1181. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(0, -math.abs(angle*0.05), math.abs(angle*0.06))
  1182. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1183. rj.C0 = CFrame.new(0, math.abs(-angle*.02), 0) * CFrame.Angles(0, 0, 0)
  1184. torso.CFrame = torso.CFrame * CFrame.new(-0.05, 0, 0)
  1185. end
  1186. elseif gangnam then
  1187. countspeed = 5
  1188. if global_wait == 180 then global_wait = 0 end
  1189. global_wait = (global_wait % 180) + 1
  1190. if global_wait < 89 then
  1191. ls.C0 = CFrame.new(-.2,.1,-.1) * CFrame.Angles(math.pi/2.5 + math.abs(angle*0.2), 0, math.pi/3 + math.abs(angle*0.05))
  1192. rs.C0 = CFrame.new(.2,.1,-.1) * CFrame.Angles(math.pi/2.5 + math.abs(angle*0.2), 0, -math.pi/3 + -math.abs(angle*0.05))
  1193. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, -math.abs(angle*0.03))
  1194. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-math.abs(angle*0.1), 0, math.abs(angle*0.03))
  1195. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1196. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.sin(angle*0.05), 0)
  1197. elseif global_wait > 89 then
  1198. ls.C0 = CFrame.new(-.2,.1,-.1) * CFrame.Angles(math.pi/2.5 + math.abs(angle*0.2), 0, math.pi/3 + math.abs(angle*0.05))
  1199. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi + math.sin(angle*0.1), 0, -math.sin(angle*0.1))
  1200. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, -math.abs(angle*0.03))
  1201. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-math.abs(angle*0.1), 0, math.abs(angle*0.03))
  1202. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1203. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.sin(angle*0.05), 0)
  1204. end
  1205. elseif foxie then
  1206. countspeed = 5
  1207. global_wait = (global_wait % 380) + 2
  1208. if global_wait < 89 then
  1209. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi + math.abs(angle*0.1), 0, -math.abs(angle*0.2))
  1210. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi + math.abs(angle*0.1), 0, math.abs(angle*0.2))
  1211. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, -math.abs(angle*0.03))
  1212. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-math.abs(angle*0.1), 0, math.abs(angle*0.03))
  1213. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1214. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.rad(global_wait*4), 0)
  1215. elseif global_wait > 89 then
  1216. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + math.abs(angle*0.2), 0, math.abs(angle*0.05))
  1217. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/2 + math.abs(angle*0.2), 0, -math.abs(angle*0.05))
  1218. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, -math.abs(angle*0.03))
  1219. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-math.abs(angle*0.1), 0, math.abs(angle*0.03))
  1220. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, math.sin(angle*0.1))
  1221. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.sin(angle*0.05), 0)
  1222. end
  1223. elseif durka then
  1224. countspeed = 2
  1225. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + math.abs(angle*0.2), 0, math.abs(angle*0.07))
  1226. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(angle*0.1, 0, -math.abs(angle*0.07))
  1227. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.05, 0, -math.abs(angle*0.03))
  1228. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.05, 0, math.abs(angle*0.03))
  1229. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1230. rj.C0 = CFrame.new(0, math.abs(-angle*.035), 0) * CFrame.Angles(0, math.sin(angle*0.05), 0)
  1231. elseif saxguy then
  1232. countspeed = 5
  1233. ls.C0 = CFrame.new(-.25,.1,-.1) * CFrame.Angles(math.pi/2.5, 0, math.pi/4)
  1234. rs.C0 = CFrame.new(.25,.1,-.1) * CFrame.Angles(math.rad(60), 0, -math.pi/4)
  1235. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(-math.abs(angle*0.1), 0, -0.06)
  1236. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-math.abs(angle*0.1), 0, 0.06)
  1237. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(0, 0, 0)
  1238. rj.C0 = CFrame.new(0, -math.abs(angle*0.01), math.abs(angle*0.01)) * CFrame.Angles(math.abs(angle*0.1), 0, 0)
  1239. elseif heya then
  1240. countspeed = 5
  1241. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi + -angle*0.2, -angle*0.1, 0)
  1242. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi + angle*0.2, angle*0.1, 0)
  1243. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.05, angle*0.1, -0.06)
  1244. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.05, -angle*0.1, 0.06)
  1245. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(0.2), 0, 0)
  1246. rj.C0 = CFrame.new(0, math.abs(angle*0.05), 0) * CFrame.Angles(0, math.sin(angle*0.07), 0)
  1247. elseif jb then
  1248. countspeed = 5
  1249. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/2 + -angle*0.2, -angle*0.1, 0)
  1250. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/2 + angle*0.2, angle*0.1, 0)
  1251. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.05, angle*0.1, -0.06)
  1252. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.05, -angle*0.1, 0.06)
  1253. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(0.2), 0, 0)
  1254. rj.C0 = CFrame.new(0, math.abs(angle*0.05), 0) * CFrame.Angles(0, math.abs(angle*0.1), 0)
  1255. elseif bronymusic then
  1256. countspeed = 5
  1257. ls.C0 = CFrame.new(-.1,.1,-.15) * CFrame.Angles(math.pi/2 + -angle*0.1, -angle*0.1, 0)
  1258. rs.C0 = CFrame.new(.1,.1,-.15) * CFrame.Angles(math.pi/2 + angle*0.1, angle*0.1, 0)
  1259. lh.C0 = CFrame.new(-.1,-.25,0) * CFrame.Angles(math.pi/2 + angle*0.1, 0, 0)
  1260. rh.C0 = CFrame.new(.1,-.25,0) * CFrame.Angles(math.pi/2 + -angle*0.1, 0, 0)
  1261. neck.C0 = CFrame.new(0,.25,0) * CFrame.Angles(math.pi/2 + math.abs(angle*0.25), 0, 0)
  1262. rj.C0 = CFrame.new(0, -0.2 + math.abs(angle*0.05), 0) * CFrame.Angles(-math.rad(85), 0, 0)
  1263. elseif sheddy then
  1264. countspeed = 7
  1265. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/4 + -angle*0.4, -angle*0.1, 0)
  1266. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/4 + angle*0.4, angle*0.1, 0)
  1267. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.05, angle*0.1, -0.06)
  1268. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.05, -angle*0.1, 0.06)
  1269. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(0.2), 0, 0)
  1270. rj.C0 = CFrame.new(0, math.abs(angle*0.05), 0) * CFrame.Angles(0, math.abs(angle*0.1), 0)
  1271. elseif burndem then
  1272. countspeed = 4
  1273. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/4 + -angle*0.4, -angle*0.1, 0)
  1274. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/4 + angle*0.4, angle*0.1, 0)
  1275. lh.C0 = CFrame.new(-.1,-.2,0) * CFrame.Angles(angle*0.05, angle*0.1, -0.06)
  1276. rh.C0 = CFrame.new(.1,-.2,0) * CFrame.Angles(-angle*0.05, -angle*0.1, 0.06)
  1277. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(0.2), 0, 0)
  1278. rj.C0 = CFrame.new(0, math.abs(angle*0.05), 0) * CFrame.Angles(0, math.abs(angle*0.1), 0)
  1279. elseif aj.IsPlaying then
  1280. countspeed = 5
  1281. ls.C0 = CFrame.new(-.3,.1,0) * CFrame.Angles(math.pi/4 + -(angle)*0.4, -angle*0.1, 0)
  1282. rs.C0 = CFrame.new(.3,.1,0) * CFrame.Angles(math.pi/4 + (angle)*0.4, -angle*0.1, 0)
  1283. lh.C0 = CFrame.new(-.1,-.2 - math.cos(count*.025)*.02,0) * CFrame.Angles(angle*0.05, 0, -0.06)
  1284. rh.C0 = CFrame.new(.1,-.2+math.cos(count*.025)*.02,0) * CFrame.Angles(-angle*0.05, 0, 0.06)
  1285. neck.C0 = CFrame.new(0,.2,0) * CFrame.Angles(math.abs(0.2), 0, 0)
  1286. rj.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(0, math.cos(angle*0.1), 0)
  1287. end
  1288. end
  1289. end)
  1290.  
  1291.  
  1292. plr.Chatted:connect(function(msg)
  1293. game:service'Chat':Chat(head, msg, 1)
  1294. if msg == "die/" then
  1295. char:breakJoints()
  1296. end
  1297. end)
  1298.  
  1299. end)
  1300. if not ran and err then
  1301. print(err)
  1302. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement