Advertisement
TheEmberWarrior

Untitled

Jun 18th, 2019
92
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- This script has been converted to FE by iPxter
  2.  
  3.  
  4. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  5. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  6. do
  7. print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
  8. script.Parent = Player.Character
  9.  
  10. --RemoteEvent for communicating
  11. local Event = Instance.new("RemoteEvent")
  12. Event.Name = "UserInput_Event"
  13.  
  14. --Fake event to make stuff like Mouse.KeyDown work
  15. local function fakeEvent()
  16. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  17. t.connect = t.Connect
  18. return t
  19. end
  20.  
  21. --Creating fake input objects with fake variables
  22. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  23. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  24. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  25. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  26. end}
  27. --Merged 2 functions into one by checking amount of arguments
  28. CAS.UnbindAction = CAS.BindAction
  29.  
  30. --This function will trigger the events that have been :Connect()'ed
  31. local function te(self,ev,...)
  32. local t = m[ev]
  33. if t and t._fakeEvent and t.Function then
  34. t.Function(...)
  35. end
  36. end
  37. m.TrigEvent = te
  38. UIS.TrigEvent = te
  39.  
  40. Event.OnServerEvent:Connect(function(plr,io)
  41. if plr~=Player then return end
  42. if io.isMouse then
  43. m.Target = io.Target
  44. m.Hit = io.Hit
  45. else
  46. local b = io.UserInputState == Enum.UserInputState.Begin
  47. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  48. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  49. end
  50. for _,t in pairs(CAS.Actions) do
  51. for _,k in pairs(t.Keys) do
  52. if k==io.KeyCode then
  53. t.Function(t.Name,io.UserInputState,io)
  54. end
  55. end
  56. end
  57. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  58. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  59. end
  60. end)
  61. Event.Parent = NLS([==[
  62. local Player = game:GetService("Players").LocalPlayer
  63. local Event = script:WaitForChild("UserInput_Event")
  64.  
  65. local UIS = game:GetService("UserInputService")
  66. local input = function(io,a)
  67. if a then return end
  68. --Since InputObject is a client-side instance, we create and pass table instead
  69. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  70. end
  71. UIS.InputBegan:Connect(input)
  72. UIS.InputEnded:Connect(input)
  73.  
  74. local Mouse = Player:GetMouse()
  75. local h,t
  76. --Give the server mouse data 30 times every second, but only if the values changed
  77. --If player is not moving their mouse, client won't fire events
  78. while wait(1/30) do
  79. if h~=Mouse.Hit or t~=Mouse.Target then
  80. h,t=Mouse.Hit,Mouse.Target
  81. Event:FireServer({isMouse=true,Target=t,Hit=h})
  82. end
  83. end]==],Player.Character)
  84. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  85. end
  86. ----------------------------------
  87.  
  88. --Made by goodguyaiden------------
  89. --Infinity war gauntlet-----------
  90. --prob my biggest project---------
  91. --sorry i couldnt do reality------
  92.  
  93. ----------------------------------
  94.  
  95. wait(0.2)
  96. plr = owner
  97. repeat wait() until plr.Character
  98. char = plr.Character
  99. local Player = owner
  100. local chara = Player.Character
  101. Player=owner
  102. Character=Player.Character
  103. PlayerGui=Player.PlayerGui
  104. Backpack=Player.Backpack
  105. Torso=Character.Torso
  106. Head=Character.Head
  107. Humanoid=Character.Humanoid
  108. m=Instance.new('Model',Character)
  109. LeftArm=Character["Left Arm"]
  110. LeftLeg=Character["Left Leg"]
  111. RightArm=Character["Right Arm"]
  112. RightLeg=Character["Right Leg"]
  113. LS=Torso["Left Shoulder"]
  114. LH=Torso["Left Hip"]
  115. RS=Torso["Right Shoulder"]
  116. RH=Torso["Right Hip"]
  117. Face = Head.face
  118. Neck=Torso.Neck
  119. it=Instance.new
  120. attacktype=1
  121. vt=Vector3.new
  122. cf=CFrame.new
  123. cl3=Color3.new
  124. rgb=Color3.fromRGB
  125. bcn=BrickColor.new
  126. euler=CFrame.fromEulerAnglesXYZ
  127. angles=CFrame.Angles
  128. Humanoid.WalkSpeed = 16
  129. Player = owner
  130. PlayerGui = Player.PlayerGui
  131. Cam = workspace.CurrentCamera
  132. Backpack = Player.Backpack
  133. Character = Player.Character
  134. Humanoid = Character.Humanoid
  135. RootPart = Character["HumanoidRootPart"]
  136. Torso = Character["Torso"]
  137. Head = Character["Head"]
  138. RightArm = Character["Right Arm"]
  139. LeftArm = Character["Left Arm"]
  140. RightLeg = Character["Right Leg"]
  141. LeftLeg = Character["Left Leg"]
  142. RootJoint = RootPart["RootJoint"]
  143. Neck = Torso["Neck"]
  144. RightShoulder = Torso["Right Shoulder"]
  145. LeftShoulder = Torso["Left Shoulder"]
  146. RightHip = Torso["Right Hip"]
  147. LeftHip = Torso["Left Hip"]
  148. pumpk = Instance.new("Sound")
  149. pumpk.Parent = owner
  150. pumpk.SoundId = "rbxassetid://1771675015"
  151. pumpk.Volume = 2
  152. pumpk.Looped = true
  153. pumpk:Play()
  154. game.Players.LocalPlayer.Character.Humanoid.MaxHealth = 99999999999999999
  155. game.Players.LocalPlayer.Character.Humanoid.Health = 99999999999999
  156.  
  157. IT = Instance.new
  158. CF = CFrame.new
  159. VT = Vector3.new
  160. RAD = math.rad
  161. C3 = Color3.new
  162. UD2 = UDim2.new
  163. BRICKC = BrickColor.new
  164. ANGLES = CFrame.Angles
  165. EULER = CFrame.fromEulerAnglesXYZ
  166. COS = math.cos
  167. ACOS = math.acos
  168. SIN = math.sin
  169. ASIN = math.asin
  170. ABS = math.abs
  171. MRANDOM = math.random
  172. FLOOR = math.floor
  173. Animation_Speed = 3
  174. Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
  175. local Speed = 12
  176. local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  177. local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  178. local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
  179. local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
  180. local DAMAGEMULTIPLIER = 1
  181. local ANIM = "Idle"
  182. local ATTACK = false
  183. local EQUIPPED = false
  184. local HOLD = false
  185. local COMBO = 1
  186. local Rooted = false
  187. local SINE = 0
  188. local KEYHOLD = false
  189. local CHANGE = 2 / Animation_Speed
  190. local WALKINGANIM = false
  191. local VALUE1 = false
  192. local VALUE2 = false
  193. local ROBLOXIDLEANIMATION = IT("Animation")
  194. ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
  195. ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571"
  196. --ROBLOXIDLEANIMATION.Parent = Humanoid
  197. local WEAPONGUI = IT("ScreenGui", PlayerGui)
  198. WEAPONGUI.Name = "Weapon GUI"
  199. local Weapon = IT("Model")
  200. Weapon.Name = "Adds"
  201. local Effects = IT("Folder", Weapon)
  202. Effects.Name = "Effects"
  203. local ANIMATOR = Humanoid.Animator
  204. local ANIMATE = Character.Animate
  205. local UNANCHOR = true
  206. local PLAYANIMS = true
  207. ArtificialHB = Instance.new("BindableEvent", script)
  208. ArtificialHB.Name = "ArtificialHB"
  209.  
  210.  
  211. Player_Size = 1 --Size of the player.
  212. Animation_Speed = 3
  213. Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
  214.  
  215. local Speed = 16
  216. local Effects2 = {}
  217.  
  218.  
  219.  
  220. script:WaitForChild("ArtificialHB")
  221.  
  222. frame = Frame_Speed
  223. tf = 0
  224. allowframeloss = false
  225. tossremainder = false
  226. lastframe = tick()
  227. script.ArtificialHB:Fire()
  228.  
  229. function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  230. return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  231. end
  232.  
  233. function PositiveAngle(NUMBER)
  234. if NUMBER >= 0 then
  235. NUMBER = 0
  236. end
  237. return NUMBER
  238. end
  239.  
  240. function NegativeAngle(NUMBER)
  241. if NUMBER <= 0 then
  242. NUMBER = 0
  243. end
  244. return NUMBER
  245. end
  246.  
  247. function Swait(NUMBER)
  248. if NUMBER == 0 or NUMBER == nil then
  249. ArtificialHB.Event:wait()
  250. else
  251. for i = 1, NUMBER do
  252. ArtificialHB.Event:wait()
  253. end
  254. end
  255. end
  256.  
  257. function QuaternionFromCFrame(cf)
  258. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  259. local trace = m00 + m11 + m22
  260. if trace > 0 then
  261. local s = math.sqrt(1 + trace)
  262. local recip = 0.5 / s
  263. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  264. else
  265. local i = 0
  266. if m11 > m00 then
  267. i = 1
  268. end
  269. if m22 > (i == 0 and m00 or m11) then
  270. i = 2
  271. end
  272. if i == 0 then
  273. local s = math.sqrt(m00 - m11 - m22 + 1)
  274. local recip = 0.5 / s
  275. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  276. elseif i == 1 then
  277. local s = math.sqrt(m11 - m22 - m00 + 1)
  278. local recip = 0.5 / s
  279. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  280. elseif i == 2 then
  281. local s = math.sqrt(m22 - m00 - m11 + 1)
  282. local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  283. end
  284. end
  285. end
  286.  
  287. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  288. local xs, ys, zs = x + x, y + y, z + z
  289. local wx, wy, wz = w * xs, w * ys, w * zs
  290. local xx = x * xs
  291. local xy = x * ys
  292. local xz = x * zs
  293. local yy = y * ys
  294. local yz = y * zs
  295. local zz = z * zs
  296. return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
  297. end
  298.  
  299. function QuaternionSlerp(a, b, t)
  300. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  301. local startInterp, finishInterp;
  302. if cosTheta >= 0.0001 then
  303. if (1 - cosTheta) > 0.0001 then
  304. local theta = ACOS(cosTheta)
  305. local invSinTheta = 1 / SIN(theta)
  306. startInterp = SIN((1 - t) * theta) * invSinTheta
  307. finishInterp = SIN(t * theta) * invSinTheta
  308. else
  309. startInterp = 1 - t
  310. finishInterp = t
  311. end
  312. else
  313. if (1 + cosTheta) > 0.0001 then
  314. local theta = ACOS(-cosTheta)
  315. local invSinTheta = 1 / SIN(theta)
  316. startInterp = SIN((t - 1) * theta) * invSinTheta
  317. finishInterp = SIN(t * theta) * invSinTheta
  318. else
  319. startInterp = t - 1
  320. finishInterp = t
  321. end
  322. end
  323. return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
  324. end
  325.  
  326. function Clerp(a, b, t)
  327. local qa = {QuaternionFromCFrame(a)}
  328. local qb = {QuaternionFromCFrame(b)}
  329. local ax, ay, az = a.x, a.y, a.z
  330. local bx, by, bz = b.x, b.y, b.z
  331. local _t = 1 - t
  332. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  333. end
  334.  
  335. function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
  336. local frame = IT("Frame")
  337. frame.BackgroundTransparency = TRANSPARENCY
  338. frame.BorderSizePixel = BORDERSIZEPIXEL
  339. frame.Position = POSITION
  340. frame.Size = SIZE
  341. frame.BackgroundColor3 = COLOR
  342. frame.BorderColor3 = BORDERCOLOR
  343. frame.Name = NAME
  344. frame.Parent = PARENT
  345. return frame
  346. end
  347.  
  348. function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
  349. local label = IT("TextLabel")
  350. label.BackgroundTransparency = 1
  351. label.Size = UD2(1, 0, 1, 0)
  352. label.Position = UD2(0, 0, 0, 0)
  353. label.TextColor3 = TEXTCOLOR
  354. label.TextStrokeTransparency = STROKETRANSPARENCY
  355. label.TextTransparency = TRANSPARENCY
  356. label.FontSize = TEXTFONTSIZE
  357. label.Font = TEXTFONT
  358. label.BorderSizePixel = BORDERSIZEPIXEL
  359. label.TextScaled = false
  360. label.Text = TEXT
  361. label.Name = NAME
  362. label.Parent = PARENT
  363. return label
  364. end
  365.  
  366. function NoOutlines(PART)
  367. PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
  368. end
  369.  
  370.  
  371. function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
  372. local NEWWELD = IT(TYPE)
  373. NEWWELD.Part0 = PART0
  374. NEWWELD.Part1 = PART1
  375. NEWWELD.C0 = C0
  376. NEWWELD.C1 = C1
  377. NEWWELD.Parent = PARENT
  378. return NEWWELD
  379. end
  380.  
  381. local S = IT("Sound")
  382.  
  383. function CreateSound(ID, PARENT, VOLUME, PITCH)
  384. local NEWSOUND = nil
  385. coroutine.resume(coroutine.create(function()
  386. NEWSOUND = S:Clone()
  387. NEWSOUND.Parent = PARENT
  388. NEWSOUND.Volume = VOLUME
  389. NEWSOUND.Pitch = PITCH
  390. NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
  391. Swait()
  392. NEWSOUND:play()
  393. game:GetService("Debris"):AddItem(NEWSOUND, 10)
  394. end))
  395. return NEWSOUND
  396. end
  397.  
  398. function CFrameFromTopBack(at, top, back)
  399. local right = top:Cross(back)
  400. return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
  401. end
  402.  
  403. function CreateWave(SIZE,WAIT,CFRAME,DOESROT,ROT,COLOR,GROW)
  404. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0))
  405. local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8))
  406. wave.CFrame = CFRAME
  407. coroutine.resume(coroutine.create(function(PART)
  408. for i = 1, WAIT do
  409. Swait()
  410. mesh.Scale = mesh.Scale + GROW
  411. mesh.Offset = VT(0,0,-(mesh.Scale.X/8))
  412. if DOESROT == true then
  413. wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0)
  414. end
  415. wave.Transparency = wave.Transparency + (0.5/WAIT)
  416. if wave.Transparency > 0.99 then
  417. wave:remove()
  418. end
  419. end
  420. end))
  421. end
  422.  
  423. function CreateRing(SIZE,DOESROT,ROT,WAIT,CFRAME,COLOR,GROW)
  424. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0,0,0))
  425. local mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "559831844", "", SIZE, VT(0,0,0))
  426. wave.CFrame = CFRAME
  427. coroutine.resume(coroutine.create(function(PART)
  428. for i = 1, WAIT do
  429. Swait()
  430. mesh.Scale = mesh.Scale + GROW
  431. if DOESROT == true then
  432. wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0,ROT,0)
  433. end
  434. wave.Transparency = wave.Transparency + (0.5/WAIT)
  435. if wave.Transparency > 0.99 then
  436. wave:remove()
  437. end
  438. end
  439. end))
  440. end
  441.  
  442. function MagicSphere(SIZE,WAIT,CFRAME,COLOR,GROW)
  443. local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(1,1,1), true)
  444. local mesh = CreateMesh("SpecialMesh", wave, "Sphere", "", "", SIZE, VT(0,0,0))
  445. wave.CFrame = CFRAME
  446. coroutine.resume(coroutine.create(function(PART)
  447. for i = 1, WAIT do
  448. Swait()
  449. mesh.Scale = mesh.Scale + GROW
  450. wave.Transparency = wave.Transparency + (1/WAIT)
  451. if wave.Transparency > 0.99 then
  452. wave:remove()
  453. end
  454. end
  455. end))
  456. end
  457.  
  458. function Slice(KIND,SIZE,WAIT,CFRAME,COLOR,GROW)
  459. local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(1,1,1), true)
  460. local mesh = nil
  461. if KIND == "Base" then
  462. mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "448386996", "", VT(0,SIZE/10,SIZE/10), VT(0,0,0))
  463. elseif KIND == "Thin" then
  464. mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "662586858", "", VT(SIZE/10,0,SIZE/10), VT(0,0,0))
  465. elseif KIND == "Round" then
  466. mesh = CreateMesh("SpecialMesh", wave, "FileMesh", "662585058", "", VT(SIZE/10,0,SIZE/10), VT(0,0,0))
  467. end
  468. wave.CFrame = CFRAME
  469. coroutine.resume(coroutine.create(function(PART)
  470. for i = 1, WAIT do
  471. Swait()
  472. mesh.Scale = mesh.Scale + GROW/10
  473. wave.Transparency = wave.Transparency + (0.5/WAIT)
  474. if wave.Transparency > 0.99 then
  475. wave:remove()
  476. end
  477. end
  478. end))
  479. end
  480.  
  481. function MakeForm(PART,TYPE)
  482. if TYPE == "Cyl" then
  483. local MSH = IT("CylinderMesh",PART)
  484. elseif TYPE == "Ball" then
  485. local MSH = IT("SpecialMesh",PART)
  486. MSH.MeshType = "Sphere"
  487. elseif TYPE == "Wedge" then
  488. local MSH = IT("SpecialMesh",PART)
  489. MSH.MeshType = "Wedge"
  490. end
  491. end
  492.  
  493.  
  494. function CheckTableForString(Table, String)
  495. for i, v in pairs(Table) do
  496. if string.find(string.lower(String), string.lower(v)) then
  497. return true
  498. end
  499. end
  500. return false
  501. end
  502.  
  503. function CheckIntangible(Hit)
  504. local ProjectileNames = {"Water", "Arrow", "Projectile", "Effect", "Rail", "Lightning", "Bullet"}
  505. if Hit and Hit.Parent then
  506. if ((not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid")) then
  507. return true
  508. end
  509. end
  510. return false
  511. end
  512.  
  513. Debris = game:GetService("Debris")
  514.  
  515. function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit)
  516. local Direction = CFrame.new(StartPos, Vec).lookVector
  517. local Ignore = ((type(Ignore) == "table" and Ignore) or {Ignore})
  518. local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore)
  519. if RayHit and CheckIntangible(RayHit) then
  520. if DelayIfHit then
  521. wait()
  522. end
  523. RayHit, RayPos, RayNormal = CastZapRay((RayPos + (Vec * 0.01)), Vec, (Length - ((StartPos - RayPos).magnitude)), Ignore, DelayIfHit)
  524. end
  525. return RayHit, RayPos, RayNormal
  526. end
  527.  
  528. function turnto(position)
  529. RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0)
  530. end
  531.  
  532.  
  533.  
  534. game:GetService("RunService").Heartbeat:connect(function(s, p)
  535. tf = tf + s
  536. if tf >= frame then
  537. if allowframeloss then
  538. script.ArtificialHB:Fire()
  539. lastframe = tick()
  540. else
  541. for i = 1, math.floor(tf / frame) do
  542. script.ArtificialHB:Fire()
  543. end
  544. lastframe = tick()
  545. end
  546. if tossremainder then
  547. tf = 0
  548. else
  549. tf = tf - frame * math.floor(tf / frame)
  550. end
  551. end
  552. end)
  553. function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  554. return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  555. end
  556.  
  557. function PositiveAngle(NUMBER)
  558. if NUMBER >= 0 then
  559. NUMBER = 0
  560. end
  561. return NUMBER
  562. end
  563.  
  564. function NegativeAngle(NUMBER)
  565. if NUMBER <= 0 then
  566. NUMBER = 0
  567. end
  568. return NUMBER
  569. end
  570.  
  571. function Swait(NUMBER)
  572. if NUMBER == 0 or NUMBER == nil then
  573. ArtificialHB.Event:wait()
  574. else
  575. for i = 1, NUMBER do
  576. ArtificialHB.Event:wait()
  577. end
  578. end
  579. end
  580.  
  581. function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
  582. local NEWMESH = IT(MESH)
  583. if MESH == "SpecialMesh" then
  584. NEWMESH.MeshType = MESHTYPE
  585. if MESHID ~= "nil" and MESHID ~= "" then
  586. NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
  587. end
  588. if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
  589. NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
  590. end
  591. end
  592. NEWMESH.Offset = OFFSET or VT(0, 0, 0)
  593. NEWMESH.Scale = SCALE
  594. NEWMESH.Parent = PARENT
  595. return NEWMESH
  596. end
  597.  
  598. function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR)
  599. local NEWPART = IT("Part")
  600. NEWPART.formFactor = FORMFACTOR
  601. NEWPART.Reflectance = REFLECTANCE
  602. NEWPART.Transparency = TRANSPARENCY
  603. NEWPART.CanCollide = false
  604. NEWPART.Locked = true
  605. NEWPART.Anchored = true
  606. if ANCHOR == false then
  607. NEWPART.Anchored = false
  608. end
  609. NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
  610. NEWPART.Name = NAME
  611. NEWPART.Size = SIZE
  612. NEWPART.Position = Torso.Position
  613. NEWPART.Material = MATERIAL
  614. NEWPART:BreakJoints()
  615. NEWPART.Parent = PARENT
  616. return NEWPART
  617. end
  618.  
  619. local function weldBetween(a, b)
  620. local weldd = Instance.new("ManualWeld")
  621. weldd.Part0 = a
  622. weldd.Part1 = b
  623. weldd.C0 = CFrame.new()
  624. weldd.C1 = b.CFrame:inverse() * a.CFrame
  625. weldd.Parent = a
  626. return weldd
  627. end
  628.  
  629.  
  630. function QuaternionFromCFrame(cf)
  631. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  632. local trace = m00 + m11 + m22
  633. if trace > 0 then
  634. local s = math.sqrt(1 + trace)
  635. local recip = 0.5 / s
  636. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  637. else
  638. local i = 0
  639. if m11 > m00 then
  640. i = 1
  641. end
  642. if m22 > (i == 0 and m00 or m11) then
  643. i = 2
  644. end
  645. if i == 0 then
  646. local s = math.sqrt(m00 - m11 - m22 + 1)
  647. local recip = 0.5 / s
  648. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  649. elseif i == 1 then
  650. local s = math.sqrt(m11 - m22 - m00 + 1)
  651. local recip = 0.5 / s
  652. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  653. elseif i == 2 then
  654. local s = math.sqrt(m22 - m00 - m11 + 1)
  655. local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  656. end
  657. end
  658. end
  659.  
  660. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  661. local xs, ys, zs = x + x, y + y, z + z
  662. local wx, wy, wz = w * xs, w * ys, w * zs
  663. local xx = x * xs
  664. local xy = x * ys
  665. local xz = x * zs
  666. local yy = y * ys
  667. local yz = y * zs
  668. local zz = z * zs
  669. return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy))
  670. end
  671.  
  672. function QuaternionSlerp(a, b, t)
  673. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  674. local startInterp, finishInterp;
  675. if cosTheta >= 0.0001 then
  676. if (1 - cosTheta) > 0.0001 then
  677. local theta = ACOS(cosTheta)
  678. local invSinTheta = 1 / SIN(theta)
  679. startInterp = SIN((1 - t) * theta) * invSinTheta
  680. finishInterp = SIN(t * theta) * invSinTheta
  681. else
  682. startInterp = 1 - t
  683. finishInterp = t
  684. end
  685. else
  686. if (1 + cosTheta) > 0.0001 then
  687. local theta = ACOS(-cosTheta)
  688. local invSinTheta = 1 / SIN(theta)
  689. startInterp = SIN((t - 1) * theta) * invSinTheta
  690. finishInterp = SIN(t * theta) * invSinTheta
  691. else
  692. startInterp = t - 1
  693. finishInterp = t
  694. end
  695. end
  696. return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp
  697. end
  698.  
  699. function Clerp(a, b, t)
  700. local qa = {QuaternionFromCFrame(a)}
  701. local qb = {QuaternionFromCFrame(b)}
  702. local ax, ay, az = a.x, a.y, a.z
  703. local bx, by, bz = b.x, b.y, b.z
  704. local _t = 1 - t
  705. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  706. end
  707.  
  708. function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
  709. local frame = IT("Frame")
  710. frame.BackgroundTransparency = TRANSPARENCY
  711. frame.BorderSizePixel = BORDERSIZEPIXEL
  712. frame.Position = POSITION
  713. frame.Size = SIZE
  714. frame.BackgroundColor3 = COLOR
  715. frame.BorderColor3 = BORDERCOLOR
  716. frame.Name = NAME
  717. frame.Parent = PARENT
  718. return frame
  719. end
  720.  
  721. function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
  722. local label = IT("TextLabel")
  723. label.BackgroundTransparency = 1
  724. label.Size = UD2(1, 0, 1, 0)
  725. label.Position = UD2(0, 0, 0, 0)
  726. label.TextColor3 = TEXTCOLOR
  727. label.TextStrokeTransparency = STROKETRANSPARENCY
  728. label.TextTransparency = TRANSPARENCY
  729. label.FontSize = TEXTFONTSIZE
  730. label.Font = TEXTFONT
  731. label.BorderSizePixel = BORDERSIZEPIXEL
  732. label.TextScaled = false
  733. label.Text = TEXT
  734. label.Name = NAME
  735. label.Parent = PARENT
  736. return label
  737. end
  738.  
  739. function NoOutlines(PART)
  740. PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
  741. end
  742.  
  743. function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
  744. local NEWWELD = IT(TYPE)
  745. NEWWELD.Part0 = PART0
  746. NEWWELD.Part1 = PART1
  747. NEWWELD.C0 = C0
  748. NEWWELD.C1 = C1
  749. NEWWELD.Parent = PARENT
  750. return NEWWELD
  751. end
  752.  
  753. local S = IT("Sound")
  754. function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP)
  755. local NEWSOUND = nil
  756. coroutine.resume(coroutine.create(function()
  757. NEWSOUND = S:Clone()
  758. NEWSOUND.Parent = PARENT
  759. NEWSOUND.Volume = VOLUME
  760. NEWSOUND.Pitch = PITCH
  761. NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
  762. NEWSOUND:play()
  763. if DOESLOOP == true then
  764. NEWSOUND.Looped = true
  765. else
  766. repeat wait(1) until NEWSOUND.Playing == false
  767. NEWSOUND:remove()
  768. end
  769. end))
  770. return NEWSOUND
  771. end
  772.  
  773. function MakeForm(PART,TYPE)
  774. if TYPE == "Cyl" then
  775. local MSH = IT("CylinderMesh",PART)
  776. elseif TYPE == "Ball" then
  777. local MSH = IT("SpecialMesh",PART)
  778. MSH.MeshType = "Sphere"
  779. elseif TYPE == "Wedge" then
  780. local MSH = IT("SpecialMesh",PART)
  781. MSH.MeshType = "Wedge"
  782. end
  783. end
  784.  
  785. function CFrameFromTopBack(at, top, back)
  786. local right = top:Cross(back)
  787. return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
  788. end
  789.  
  790. function PuddleOfBlood(Position,MaxDrop,Model,MaxSize)
  791. local HITFLOOR, HITPOS, NORMAL = Raycast(Position, (CF(Position, Position + VT(0, -1, 0))).lookVector, MaxDrop, Model)
  792. if HITFLOOR ~= nil then
  793. if HITFLOOR.Parent ~= Weapon and HITFLOOR.Parent ~= Character then
  794. if HITFLOOR.Name == "BloodPuddle" then
  795. local DIST = (Position - HITFLOOR.Position).Magnitude
  796. if (HITFLOOR.Size.Z <= 5 and HITFLOOR.Size.Z < MaxSize) or (HITFLOOR.Size.Z > 5 and HITFLOOR.Size.Z < MaxSize and DIST < HITFLOOR.Size.Z/3) then
  797. HITFLOOR.Size = HITFLOOR.Size + VT(0.1,0,0.1)
  798. end
  799. else
  800. if HITFLOOR.Anchored == true then
  801. local BLOOD = CreatePart(3, Effects, "Glass", 0, 0, "Maroon", "BloodPuddle", VT(2,0,2))
  802. BLOOD.CFrame = CF(HITPOS,HITPOS+NORMAL)*ANGLES(RAD(90),RAD(0),RAD(0))
  803. MakeForm(BLOOD,"Cyl")
  804. coroutine.resume(coroutine.create(function()
  805. Swait(75)
  806. while true do
  807. Swait()
  808. BLOOD.Size = BLOOD.Size - VT(0.02,0,0.02)
  809. if BLOOD.Size.Z < 0.051 then
  810. BLOOD:remove()
  811. break
  812. end
  813. end
  814. end))
  815. end
  816. end
  817. end
  818. end
  819. end
  820.  
  821. function SprayBlood(POSITION,DIRECTION,BloodSize)
  822. local BLOOD = CreatePart(3, Effects, "Glass", 0, 0, "Maroon", "BloodPuddle", VT(0.3,0.3,0.3),false)
  823. BLOOD.CFrame = CF(POSITION)
  824. MakeForm(BLOOD,"Ball")
  825. local bv = Instance.new("BodyVelocity",BLOOD)
  826. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  827. bv.velocity = CF(POSITION,DIRECTION+VT(MRANDOM(-3,3)/30,MRANDOM(-3,3)/30,MRANDOM(-3,3)/30)).lookVector*75
  828. bv.Name = "MOVE"
  829. Debris:AddItem(bv,0.05)
  830. coroutine.resume(coroutine.create(function()
  831. local HASTOUCHEDGROUND = false
  832. local HIT = BLOOD.Touched:Connect(function(hit)
  833. if hit.Anchored == true then
  834. HASTOUCHEDGROUND = true
  835. PuddleOfBlood(BLOOD.Position+VT(0,1,0),2,BLOOD,BloodSize)
  836. end
  837. end)
  838. wait(5)
  839. if HASTOUCHEDGROUND == false then
  840. BLOOD:remove()
  841. end
  842. end))
  843. end
  844.  
  845. Debris = game:GetService("Debris")
  846.  
  847. function CastProperRay(StartPos, EndPos, Distance, Ignore)
  848. local DIRECTION = CF(StartPos,EndPos).lookVector
  849. return Raycast(StartPos, DIRECTION, Distance, Ignore)
  850. end
  851.  
  852. function turnto(position)
  853. RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0)
  854. end
  855.  
  856. function recurse(root,callback,i)
  857. i= i or 0
  858. for _,v in pairs(root:GetChildren()) do
  859. i = i + 1
  860. callback(i,v)
  861.  
  862. if #v:GetChildren() > 0 then
  863. i = recurse(v,callback,i)
  864. end
  865. end
  866.  
  867. return i
  868. end
  869.  
  870. function ragdollJoint(character, part0, part1, attachmentName, className, properties)
  871. attachmentName = attachmentName.."RigAttachment"
  872. local constraint = Instance.new(className.."Constraint")
  873. constraint.Attachment0 = part0:FindFirstChild(attachmentName)
  874. constraint.Attachment1 = part1:FindFirstChild(attachmentName)
  875. constraint.Name = "RagdollConstraint"..part1.Name
  876.  
  877. for _,propertyData in next,properties or {} do
  878. constraint[propertyData[1]] = propertyData[2]
  879. end
  880.  
  881. constraint.Parent = character
  882. end
  883.  
  884. function getAttachment0(character, attachmentName)
  885. for _,child in next,character:GetChildren() do
  886. local attachment = child:FindFirstChild(attachmentName)
  887. if attachment then
  888. return attachment
  889. end
  890. end
  891. end
  892.  
  893. function R15Ragdoll(character)
  894. recurse(character, function(_,v)
  895. if v:IsA("Attachment") then
  896. v.Axis = Vector3.new(0, 1, 0)
  897. v.SecondaryAxis = Vector3.new(0, 0, 1)
  898. v.Rotation = Vector3.new(0, 0, 0)
  899. end
  900. end)
  901. for _,child in next,character:GetChildren() do
  902. if child:IsA("Accoutrement") then
  903. for _,part in next,child:GetChildren() do
  904. if part:IsA("BasePart") and part.Name ~= "HumanoidRootPart" then
  905. local attachment1 = part:FindFirstChildOfClass("Attachment")
  906. local attachment0 = getAttachment0(character,attachment1.Name)
  907. if attachment0 and attachment1 then
  908. local constraint = Instance.new("HingeConstraint")
  909. constraint.Attachment0 = attachment0
  910. constraint.Attachment1 = attachment1
  911. constraint.LimitsEnabled = true
  912. constraint.UpperAngle = 0
  913. constraint.LowerAngle = 0
  914. constraint.Parent = character
  915. end
  916. elseif part.Name == "HumanoidRootPart" then
  917. part:remove()
  918. end
  919. end
  920. end
  921. end
  922.  
  923. ragdollJoint(character,character.LowerTorso, character.UpperTorso, "Waist", "BallSocket", {
  924. {"LimitsEnabled",true};
  925. {"UpperAngle",5};
  926. })
  927. ragdollJoint(character,character.UpperTorso, character.Head, "Neck", "BallSocket", {
  928. {"LimitsEnabled",true};
  929. {"UpperAngle",15};
  930. })
  931.  
  932. local handProperties = {
  933. {"LimitsEnabled", true};
  934. {"UpperAngle",0};
  935. {"LowerAngle",0};
  936. }
  937. ragdollJoint(character,character.LeftLowerArm, character.LeftHand, "LeftWrist", "Hinge", handProperties)
  938. ragdollJoint(character,character.RightLowerArm, character.RightHand, "RightWrist", "Hinge", handProperties)
  939.  
  940. local shinProperties = {
  941. {"LimitsEnabled", true};
  942. {"UpperAngle", 0};
  943. {"LowerAngle", -75};
  944. }
  945. ragdollJoint(character,character.LeftUpperLeg, character.LeftLowerLeg, "LeftKnee", "Hinge", shinProperties)
  946. ragdollJoint(character,character.RightUpperLeg, character.RightLowerLeg, "RightKnee", "Hinge", shinProperties)
  947.  
  948. local footProperties = {
  949. {"LimitsEnabled", true};
  950. {"UpperAngle", 15};
  951. {"LowerAngle", -45};
  952. }
  953. ragdollJoint(character,character.LeftLowerLeg, character.LeftFoot, "LeftAnkle", "Hinge", footProperties)
  954. ragdollJoint(character,character.RightLowerLeg, character.RightFoot, "RightAnkle", "Hinge", footProperties)
  955.  
  956. ragdollJoint(character,character.UpperTorso, character.LeftUpperArm, "LeftShoulder", "BallSocket")
  957. ragdollJoint(character,character.LeftUpperArm, character.LeftLowerArm, "LeftElbow", "BallSocket")
  958. ragdollJoint(character,character.UpperTorso, character.RightUpperArm, "RightShoulder", "BallSocket")
  959. ragdollJoint(character,character.RightUpperArm, character.RightLowerArm, "RightElbow", "BallSocket")
  960. ragdollJoint(character,character.LowerTorso, character.LeftUpperLeg, "LeftHip", "BallSocket")
  961. ragdollJoint(character,character.LowerTorso, character.RightUpperLeg, "RightHip", "BallSocket")
  962. end
  963.  
  964. function Ragdoll(Character2,CharTorso)
  965. Character2:BreakJoints()
  966. local hum = Character2:findFirstChild("Humanoid")
  967. hum:remove()
  968. local function Scan(ch)
  969. local e
  970. for e = 1,#ch do
  971. Scan(ch[e]:GetChildren())
  972. if ch[e].ClassName == "Weld" or ch[e].ClassName == "Motor6D" then
  973. ch[e]:remove()
  974. end
  975. end
  976. end
  977. local NEWHUM = IT("Humanoid")
  978. NEWHUM.Name = "Corpse"
  979. NEWHUM.Health = 0
  980. NEWHUM.MaxHealth = 0
  981. NEWHUM.PlatformStand = true
  982. NEWHUM.Parent = Character2
  983. NEWHUM.DisplayDistanceType = "None"
  984.  
  985. local ch = Character2:GetChildren()
  986. local i
  987. for i = 1,#ch do
  988. if ch[i].Name == "THandle1" or ch[i].Name == "THandle2" then
  989. ch[i]:remove()
  990. end
  991. end
  992.  
  993. local Torso2 = Character2.Torso
  994. local movevector = Vector3.new()
  995.  
  996. if Torso2 then
  997. movevector = CFrame.new(CharTorso.Position,Torso2.Position).lookVector
  998. local Head = Character2:FindFirstChild("Head")
  999. if Head then
  1000. local Neck = Instance.new("Weld")
  1001. Neck.Name = "Neck"
  1002. Neck.Part0 = Torso2
  1003. Neck.Part1 = Head
  1004. Neck.C0 = CFrame.new(0, 1.5, 0)
  1005. Neck.C1 = CFrame.new()
  1006. Neck.Parent = Torso2
  1007.  
  1008. end
  1009. local Limb = Character2:FindFirstChild("Right Arm")
  1010. if Limb then
  1011.  
  1012. Limb.CFrame = Torso2.CFrame * CFrame.new(1.5, 0, 0)
  1013. local Joint = Instance.new("Glue")
  1014. Joint.Name = "RightShoulder"
  1015. Joint.Part0 = Torso2
  1016. Joint.Part1 = Limb
  1017. Joint.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  1018. Joint.C1 = CFrame.new(-0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  1019. Joint.Parent = Torso2
  1020.  
  1021. local B = Instance.new("Part")
  1022. B.TopSurface = 0
  1023. B.BottomSurface = 0
  1024. B.formFactor = "Symmetric"
  1025. B.Size = Vector3.new(1, 1, 1)
  1026. B.Transparency = 1
  1027. B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
  1028. B.Parent = Character2
  1029. local W = Instance.new("Weld")
  1030. W.Part0 = Limb
  1031. W.Part1 = B
  1032. W.C0 = CFrame.new(0, -0.5, 0)
  1033. W.Parent = Limb
  1034.  
  1035. end
  1036. local Limb = Character2:FindFirstChild("Left Arm")
  1037. if Limb then
  1038.  
  1039. Limb.CFrame = Torso2.CFrame * CFrame.new(-1.5, 0, 0)
  1040. local Joint = Instance.new("Glue")
  1041. Joint.Name = "LeftShoulder"
  1042. Joint.Part0 = Torso2
  1043. Joint.Part1 = Limb
  1044. Joint.C0 = CFrame.new(-1.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  1045. Joint.C1 = CFrame.new(0, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  1046. Joint.Parent = Torso2
  1047.  
  1048. local B = Instance.new("Part")
  1049. B.TopSurface = 0
  1050. B.BottomSurface = 0
  1051. B.formFactor = "Symmetric"
  1052. B.Size = Vector3.new(1, 1, 1)
  1053. B.Transparency = 1
  1054. B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
  1055. B.Parent = Character2
  1056. local W = Instance.new("Weld")
  1057. W.Part0 = Limb
  1058. W.Part1 = B
  1059. W.C0 = CFrame.new(0, -0.5, 0)
  1060. W.Parent = Limb
  1061.  
  1062. end
  1063. local Limb = Character2:FindFirstChild("Right Leg")
  1064. if Limb then
  1065.  
  1066. Limb.CFrame = Torso2.CFrame * CFrame.new(0.5, -2, 0)
  1067. local Joint = Instance.new("Glue")
  1068. Joint.Name = "RightHip"
  1069. Joint.Part0 = Torso2
  1070. Joint.Part1 = Limb
  1071. Joint.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  1072. Joint.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
  1073. Joint.Parent = Torso2
  1074.  
  1075. local B = Instance.new("Part")
  1076. B.TopSurface = 0
  1077. B.BottomSurface = 0
  1078. B.formFactor = "Symmetric"
  1079. B.Size = Vector3.new(1, 1, 1)
  1080. B.Transparency = 1
  1081. B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
  1082. B.Parent = Character2
  1083. local W = Instance.new("Weld")
  1084. W.Part0 = Limb
  1085. W.Part1 = B
  1086. W.C0 = CFrame.new(0, -0.5, 0)
  1087. W.Parent = Limb
  1088.  
  1089. end
  1090. local Limb = Character2:FindFirstChild("Left Leg")
  1091. if Limb then
  1092.  
  1093. Limb.CFrame = Torso2.CFrame * CFrame.new(-0.5, -2, 0)
  1094. local Joint = Instance.new("Glue")
  1095. Joint.Name = "LeftHip"
  1096. Joint.Part0 = Torso2
  1097. Joint.Part1 = Limb
  1098. Joint.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  1099. Joint.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
  1100. Joint.Parent = Torso2
  1101.  
  1102. local B = Instance.new("Part")
  1103. B.TopSurface = 0
  1104. B.BottomSurface = 0
  1105. B.formFactor = "Symmetric"
  1106. B.Size = Vector3.new(1, 1, 1)
  1107. B.Transparency = 1
  1108. B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
  1109. B.Parent = Character2
  1110. local W = Instance.new("Weld")
  1111. W.Part0 = Limb
  1112. W.Part1 = B
  1113. W.C0 = CFrame.new(0, -0.5, 0)
  1114. W.Parent = Limb
  1115.  
  1116. end
  1117. --[
  1118. local Bar = Instance.new("Part")
  1119. Bar.TopSurface = 0
  1120. Bar.BottomSurface = 0
  1121. Bar.formFactor = "Symmetric"
  1122. Bar.Size = Vector3.new(1, 1, 1)
  1123. Bar.Transparency = 1
  1124. Bar.CFrame = Torso2.CFrame * CFrame.new(0, 0.5, 0)
  1125. Bar.Parent = Character2
  1126. local Weld = Instance.new("Weld")
  1127. Weld.Part0 = Torso2
  1128. Weld.Part1 = Bar
  1129. Weld.C0 = CFrame.new(0, 0.5, 0)
  1130. Weld.Parent = Torso2
  1131. --]]
  1132. end
  1133. Character2.Parent = workspace
  1134. Debris:AddItem(Character2,5)
  1135.  
  1136. return Character2,Torso2
  1137. end
  1138.  
  1139. local Gun = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Gun", VT(0, 0, 0),false)
  1140. local HandleMesh = CreateMesh("SpecialMesh", Gun, "FileMesh", "1757389224", "1757405356", VT(0.07,0.07,0.07), VT(0,0, 0))
  1141. local Weld = CreateWeldOrSnapOrMotor("Weld", Gun, LeftArm, Gun, CF(0.2, -1, 0.2) * ANGLES(RAD(330), RAD(0), RAD(20)), CF(0, 0, 0))
  1142.  
  1143. canworld = true
  1144.  
  1145. we = true
  1146.  
  1147. function time()
  1148. CreateSound("907330619", Head, 10, 1)
  1149. wait(1)
  1150. local function weld(lol)
  1151. local weld = Instance.new("Weld", plr.Character.Torso)
  1152. weld.Part0 = plr.Character.Torso
  1153. weld.Part1 = lol
  1154. weld.C0 = plr.Character.Torso.CFrame:inverse()
  1155. weld.C1 = lol.CFrame:inverse()
  1156. end
  1157. wait(1.4)
  1158.  
  1159. for i, v in pairs(game.Players:GetChildren()) do
  1160. t = v.Character:FindFirstChild("Torso")
  1161. if t then
  1162. t.Anchored = true
  1163. plr.Character:FindFirstChild("Torso").Anchored = false
  1164. end
  1165. RA = v.Character:FindFirstChild("Right Arm")
  1166. if RA then
  1167. RA.Anchored = true
  1168. plr.Character:FindFirstChild("Right Arm").Anchored = false
  1169. end
  1170. LA = v.Character:FindFirstChild("Left Arm")
  1171. if LA then
  1172. LA.Anchored = true
  1173. plr.Character:FindFirstChild("Left Arm").Anchored = false
  1174. end
  1175. RL = v.Character:FindFirstChild("Right Leg")
  1176. if RL then
  1177. RL.Anchored = true
  1178. plr.Character:FindFirstChild("Right Leg").Anchored = false
  1179. end
  1180. LL = v.Character:FindFirstChild("Left Leg")
  1181. if LL then
  1182. LL.Anchored = true
  1183. plr.Character:FindFirstChild("Left Leg").Anchored = false
  1184. end
  1185. end
  1186.  
  1187. game.Lighting.TimeOfDay="00:00:00"
  1188. game.Lighting.OutdoorAmbient=Color3.new(50,0,350)
  1189. wait(0.1)
  1190. game.Lighting.OutdoorAmbient=Color3.new(0,114,235)
  1191. wait(0.1)
  1192. game.Lighting.OutdoorAmbient=Color3.new(0,0,235)
  1193. wait(0.1)
  1194. game.Lighting.OutdoorAmbient=Color3.new(0,114,0)
  1195. wait(0.1)
  1196. game.Lighting.OutdoorAmbient=Color3.new(255, 255, 355)
  1197. wait(10)
  1198. for i, v in pairs(game.Players:GetChildren()) do
  1199. t = v.Character:FindFirstChild("Torso")
  1200. if t then
  1201. t.Anchored = false
  1202. end
  1203. RA = v.Character:FindFirstChild("Right Arm")
  1204. if RA then
  1205. RA.Anchored = false
  1206. end
  1207. LA = v.Character:FindFirstChild("Left Arm")
  1208. if LA then
  1209. LA.Anchored = false
  1210. end
  1211. RL = v.Character:FindFirstChild("Right Leg")
  1212. if RL then
  1213. RL.Anchored = false
  1214. end
  1215. LL = v.Character:FindFirstChild("Left Leg")
  1216. if LL then
  1217. LL.Anchored = false
  1218. end
  1219. end
  1220.  
  1221.  
  1222. game.Lighting.OutdoorAmbient=Color3.new(0,114,0)
  1223. wait(0.1)
  1224. game.Lighting.OutdoorAmbient=Color3.new(50,0,350)
  1225. wait(0.1)
  1226. game.Lighting.OutdoorAmbient=Color3.new(0,114,235)
  1227. wait(0.1)
  1228. game.Lighting.OutdoorAmbient=Color3.new(0,0,235)
  1229.  
  1230. game.Lighting.OutdoorAmbient=Color3.new(135/255, 135/255, 128/255)
  1231. game.Lighting.TimeOfDay="15:00:00"
  1232.  
  1233. end
  1234.  
  1235. function Space()
  1236. sky = Instance.new('Sky', game.Lighting)
  1237. sky.MoonTextureId = 'rbxasset://sky/moon.png'
  1238. sky.SkyboxBk = 'http://www.roblox.com/asset/?id=159248188'
  1239. sky.SkyboxDn = 'http://www.roblox.com/asset/?id=159248183'
  1240. sky.SkyboxFt = 'http://www.roblox.com/asset/?id=159248187'
  1241. sky.SkyboxLf = 'http://www.roblox.com/asset/?id=159248173'
  1242. sky.SkyboxRt = 'http://www.roblox.com/asset/?id=159248192'
  1243. sky.SkyboxUp = 'http://www.roblox.com/asset/?id=159248176'
  1244. sky.Name = 'Space'
  1245.  
  1246. for i,v in pairs(workspace:getChildren()) do
  1247. if v.ClassName == 'Part' and v.Name == 'Base' then
  1248. v.Transparency = 1
  1249. v.Size = Vector3.new(2048, 1, 2048)
  1250. end
  1251. end
  1252. workspace.Gravity = 10
  1253. end
  1254.  
  1255.  
  1256. function Space2()
  1257. sky = game.Lighting:findFirstChild('Space')
  1258. sky:Destroy()
  1259.  
  1260. for i,v in pairs(workspace:getChildren()) do
  1261. if v.ClassName == 'Part' and v.Name == 'Base' then
  1262. v.Transparency = 0
  1263. v.Size = Vector3.new(2048, 1, 2048)
  1264. end
  1265. end
  1266. workspace.Gravity = 196.5
  1267. end
  1268. function Mind()
  1269. ATTACK = true
  1270. Rooted = true
  1271. CreateSound("907332856", Head, 10, 1)
  1272. for i=0, 1, 0.1 / Animation_Speed do
  1273. Swait()
  1274. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(-20), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1275. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1276. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(90), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1277. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1278. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1279. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1280. end
  1281. for i=0, 1, 0.1 / Animation_Speed do
  1282. Swait()
  1283. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(30), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1284. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1285. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(180), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1286. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(180), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1287. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1288. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1289. end
  1290. local Wind = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Wind", VT(0, 0, 0),false)
  1291. local HandleMesh = CreateMesh("SpecialMesh", Wind, "FileMesh", "495572467", "495572476", VT(1,1,1), VT(0,0, 0))
  1292. local Weld = CreateWeldOrSnapOrMotor("Weld", Wind, Torso, Wind, CF(0, 0, -15) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1293. for i=0, 1, 0.1 / Animation_Speed do
  1294. Swait()
  1295. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1296. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1297. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(180), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1298. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1299. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1300. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1301. end
  1302. Wind:remove()
  1303. local broken = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "broken", VT(0, 0, 0),false)
  1304. local HandleMesh = CreateMesh("SpecialMesh", broken, "FileMesh", "926826971", "926827014", VT(1,1,1), VT(0,0, 0))
  1305. local Weld = CreateWeldOrSnapOrMotor("Weld", broken, Torso, broken, CF(0, 0, -15) * ANGLES(RAD(0), RAD(0), RAD(0)), CF(0, 0, 0))
  1306. for i=0, 1, 0.1 / Animation_Speed do
  1307. Swait()
  1308. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1309. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1310. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(180), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1311. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1312. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1313. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1314. end
  1315. broken:remove()
  1316. ATTACK = false
  1317. Rooted = false
  1318. end
  1319.  
  1320. function power2()
  1321. we = true
  1322. ATTACK = true
  1323. Rooted = true
  1324. CreateSound("1843115950", Head, 10, 1)
  1325. for i=0, 1, 0.1 / Animation_Speed do
  1326. Swait()
  1327. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(-20), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1328. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1329. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1330. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(40), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1331. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1332. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1333. end
  1334. for i=0, 1, 0.1 / Animation_Speed do
  1335. Swait()
  1336. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(30), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1337. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1338. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1339. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(90), RAD(444), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1340. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1341. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1342. end
  1343. local Wind = CreatePart(3, Character, "SmoothPlastic", 0, 0, "Really black", "Wind", VT(0, 0, 0),false)
  1344. local HandleMesh = CreateMesh("SpecialMesh", Wind, "FileMesh", "433838302", "1031083476", VT(3,3,3), VT(0,0, 0))
  1345. local Weld = CreateWeldOrSnapOrMotor("Weld", Wind, Torso, Wind, CF(0, 0, -5) * ANGLES(RAD(-90), RAD(0), RAD(0)), CF(0, 0, 0))
  1346. game.Players.LocalPlayer.Character["Wind"].Touched:connect(function(hit)
  1347. local humanoid = hit.Parent:findFirstChild("Humanoid")
  1348. if we == true then
  1349. humanoid:TakeDamage(50)
  1350. end
  1351. end)
  1352. for i=0, 1, 0.1 / Animation_Speed do
  1353. Swait()
  1354. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1355. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1356. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1357. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(90), RAD(444), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1358. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1359. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1360. end
  1361. for i=0, 1, 0.1 / Animation_Speed do
  1362. Swait()
  1363. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1364. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1365. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1366. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(90), RAD(444), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1367. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1368. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1369. end
  1370. we = false
  1371. Wind:remove()
  1372. ATTACK = false
  1373. Rooted = false
  1374. end
  1375.  
  1376. function all_together_now()
  1377. ATTACK = true
  1378. Rooted = true
  1379. CreateSound("907329532", Head, 10, 1)
  1380. for i=0, 1, 0.1 / Animation_Speed do
  1381. Swait()
  1382. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1383. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1384. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1385. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1386. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1387. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1388. end
  1389. for i=0, 1, 0.1 / Animation_Speed do
  1390. Swait()
  1391. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1392. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1393. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1394. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1395. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1396. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1397. end
  1398. for i=0, 1, 0.1 / Animation_Speed do
  1399. Swait()
  1400. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1401. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1402. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1403. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1404. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1405. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1406. end
  1407. for i=0, 1, 0.1 / Animation_Speed do
  1408. Swait()
  1409. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1410. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1411. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1412. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1413. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1414. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1415. end
  1416. CreateSound("217767125", Head, 10, 1)
  1417. for i,v in pairs(workspace:GetChildren()) do
  1418. if v.ClassName == "Model" then
  1419. local human = v:FindFirstChildOfClass("Humanoid")
  1420. if human and human.Parent.Name ~= chara.Name then
  1421. human.Parent:BreakJoints()
  1422. end
  1423. end
  1424. end
  1425.  
  1426. for i=0, 1, 0.1 / Animation_Speed do
  1427. Swait()
  1428. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1429. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1430. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1431. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(444), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1432. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1433. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1434. end
  1435. CreateSound("907333294", Head, 10, 1)
  1436. for i=0, 1, 0.1 / Animation_Speed do
  1437. Swait()
  1438. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(20), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1439. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1440. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1441. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(180), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1442. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(20), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1443. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(20), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1444. end
  1445. for i=0, 1, 0.1 / Animation_Speed do
  1446. Swait()
  1447. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(20), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1448. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1449. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1450. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(444), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1451. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(20), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1452. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(20), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1453. end
  1454. for i=0, 1, 0.1 / Animation_Speed do
  1455. Swait()
  1456. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(20), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1457. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1458. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1459. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(90), RAD(444), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1460. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(20), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1461. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(20), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1462. end
  1463. ATTACK = false
  1464. Rooted = false
  1465. end
  1466.  
  1467. function Taunt()
  1468. ATTACK = true
  1469. Rooted = true
  1470. CreateSound("907331038", Head, 10, 1)
  1471. for i=0, 1, 0.1 / Animation_Speed do
  1472. Swait()
  1473. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1474. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1475. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(180), RAD(0), RAD(30)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1476. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(180), RAD(0), RAD(30)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1477. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1478. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1479. end
  1480. for i=0, 1, 0.1 / Animation_Speed do
  1481. Swait()
  1482. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1483. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1484. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(180), RAD(0), RAD(30)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1485. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(180), RAD(0), RAD(30)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1486. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1487. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1488. end
  1489. for i=0, 1, 0.1 / Animation_Speed do
  1490. Swait()
  1491. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1492. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1493. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(180), RAD(0), RAD(30)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1494. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(180), RAD(0), RAD(30)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1495. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1496. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1497. end
  1498. for i=0, 1, 0.1 / Animation_Speed do
  1499. Swait()
  1500. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1501. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1502. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(180), RAD(0), RAD(30)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1503. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(180), RAD(0), RAD(30)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1504. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1505. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1506. end
  1507. ATTACK = false
  1508. Rooted = false
  1509. end
  1510.  
  1511. function power()
  1512. we = true
  1513. ATTACK = true
  1514. Rooted = true
  1515. CreateSound("1843115950", Head, 10, 1)
  1516. for i=0, 1, 0.1 / Animation_Speed do
  1517. Swait()
  1518. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(-20), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1519. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.15 / Animation_Speed)
  1520. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, -1) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1521. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 1) * ANGLES(RAD(40), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1522. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1523. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1524. end
  1525. game.Players.LocalPlayer.Character["Gun"].Touched:connect(function(hit)
  1526. local humanoid = hit.Parent:findFirstChild("Humanoid")
  1527. if we == true then
  1528. humanoid:TakeDamage(50)
  1529. end
  1530. end)
  1531. for i=0, 1, 0.1 / Animation_Speed do
  1532. Swait()
  1533. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(30), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1534. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1535. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-30), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1536. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, -1) * ANGLES(RAD(40), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1537. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1538. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1539. end
  1540. we = false
  1541. ATTACK = false
  1542. Rooted = false
  1543. end
  1544.  
  1545. function MouseDown(Mouse)
  1546. end
  1547.  
  1548. function MouseUp(Mouse)
  1549. HOLD = false
  1550. end
  1551.  
  1552. function KeyDown(Key)
  1553. KEYHOLD = true
  1554. if Key == "f" and ATTACK == false then
  1555. Taunt()
  1556. end
  1557. if Key == "h" and ATTACK == false then
  1558. all_together_now()
  1559. end
  1560. if Key == "g" and ATTACK == false then
  1561. Mind()
  1562. end
  1563. if Key == "q" and ATTACK == false then
  1564. power()
  1565. end
  1566. if Key == "r" and ATTACK == false then
  1567. Space()
  1568. end
  1569. if Key == "p" and ATTACK == false then
  1570. time()
  1571. end
  1572. if Key == "t" and ATTACK == false then
  1573. Space2()
  1574. end
  1575. if Key == "e" and ATTACK == false then
  1576. power2()
  1577. end
  1578. end
  1579.  
  1580. function KeyUp(Key)
  1581. KEYHOLD = false
  1582. end
  1583.  
  1584. Mouse.Button1Down:connect(function(NEWKEY)
  1585. MouseDown(NEWKEY)
  1586. end)
  1587. Mouse.Button1Up:connect(function(NEWKEY)
  1588. MouseUp(NEWKEY)
  1589. end)
  1590. Mouse.KeyDown:connect(function(NEWKEY)
  1591. KeyDown(NEWKEY)
  1592. end)
  1593. Mouse.KeyUp:connect(function(NEWKEY)
  1594. KeyUp(NEWKEY)
  1595. end)
  1596.  
  1597. while true do
  1598. Swait()
  1599. script.Parent = WEAPONGUI
  1600. ANIMATE.Parent = nil
  1601. for _,v in next, Humanoid:GetPlayingAnimationTracks() do
  1602. v:Stop();
  1603. end
  1604. SINE = SINE + CHANGE
  1605. local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
  1606. local TORSOVERTICALVELOCITY = RootPart.Velocity.y
  1607. local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 4, Character)
  1608. local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16)
  1609. if ANIM == "Walk" and TORSOVELOCITY > 1 then
  1610. RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.15 * COS(SINE / (WALKSPEEDVALUE / 2))) * ANGLES(RAD(0), RAD(0) - RootPart.RotVelocity.Y / 75, RAD(0)), 2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1611. Neck.C1 = Clerp(Neck.C1, CF(0, -0.5, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0) - Head.RotVelocity.Y / 30), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1612. RightHip.C1 = Clerp(RightHip.C1, CF(0.5, 0.875 - 0.125 * SIN(SINE / WALKSPEEDVALUE) - 0.15 * COS(SINE / WALKSPEEDVALUE*2), -0.125 * COS(SINE / WALKSPEEDVALUE) +0.2+ 0.2 * COS(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0) - RightLeg.RotVelocity.Y / 75, RAD(0), RAD(76 * COS(SINE / WALKSPEEDVALUE))), 0.3 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1613. LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5, 0.875 + 0.125 * SIN(SINE / WALKSPEEDVALUE) - 0.15 * COS(SINE / WALKSPEEDVALUE*2), 0.125 * COS(SINE / WALKSPEEDVALUE) +0.2+ -0.2 * COS(SINE / WALKSPEEDVALUE)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0) + LeftLeg.RotVelocity.Y / 75, RAD(0), RAD(76 * COS(SINE / WALKSPEEDVALUE))), 0.3 * (Humanoid.WalkSpeed / 16) / Animation_Speed)
  1614. elseif (ANIM ~= "Walk") or (TORSOVELOCITY < 1) then
  1615. RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1616. Neck.C1 = Clerp(Neck.C1, CF(0, -0.5, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1617. RightHip.C1 = Clerp(RightHip.C1, CF(0.5, 1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1618. LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5, 1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1619. end
  1620. if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then
  1621. ANIM = "Jump"
  1622. if PLAYANIMS == true then
  1623. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1624. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-20), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1625. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-40), RAD(0), RAD(20)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
  1626. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-40), RAD(0), RAD(-20)) * LEFTSHOULDERC0, 0.2 / Animation_Speed)
  1627. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.3) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 0.2 / Animation_Speed)
  1628. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.3) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 0.2 / Animation_Speed)
  1629. end
  1630. elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then
  1631. ANIM = "Fall"
  1632. if PLAYANIMS == true then
  1633. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 ) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1634. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0 , 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed)
  1635. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(100), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.2 / Animation_Speed)
  1636. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-100), RAD(0), RAD(0)) * LEFTSHOULDERC0, 0.2 / Animation_Speed)
  1637. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.2 / Animation_Speed)
  1638. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed)
  1639. end
  1640. elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then
  1641. ANIM = "Idle"
  1642. if PLAYANIMS == true then
  1643. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1644. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1645. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1646. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-180), RAD(0), RAD(-30)) * LEFTSHOULDERC0, 0.15 / Animation_Speed)
  1647. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1648. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1649. end
  1650. elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then
  1651. ANIM = "Walk"
  1652. if PLAYANIMS == true then
  1653. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1654. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed)
  1655. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(-90 * COS(SINE / WALKSPEEDVALUE)), RAD(0), RAD(30)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed)
  1656. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(-180), RAD(0), RAD(-30)) * LEFTSHOULDERC0, 0.35 / Animation_Speed)
  1657. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0.2) * ANGLES(RAD(90 * COS(SINE / WALKSPEEDVALUE)), RAD(90), RAD(0)), 1)
  1658. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0.2) * ANGLES(RAD(-90 * COS(SINE / WALKSPEEDVALUE)), RAD(-90), RAD(0)), 1)
  1659. end
  1660. end
  1661. end
  1662. if Rooted == false then
  1663. Disable_Jump = false
  1664. Humanoid.WalkSpeed = Speed
  1665. elseif Rooted == true then
  1666. Disable_Jump = true
  1667. Humanoid.WalkSpeed = 0
  1668. end
  1669.  
  1670. Humanoid.Health = Humanoid.Health + 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement