Advertisement
voidman

Untitled

Dec 27th, 2018
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 71.90 KB | None | 0 0
  1. --]]
  2. --https://github.com/Mokiros/roblox-FE-compatibility
  3. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  4. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  5. local RealPlayer = Player
  6. do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end
  7. Player = game.Players.LocalPlayer
  8. char = Player.Character
  9. Cha = char
  10. Mau5 = Player:GetMouse()
  11. hed = char.Head
  12. rarm = char["Right Arm"]
  13. function nooutline(part)
  14. part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10
  15. end
  16. Cha.Head.face.Texture = "http://www.roblox.com/asset/?id=101765221"
  17. Cha.Shirt:Remove()
  18. Cha.Pants:Remove()
  19.  
  20. Shirt = Instance.new("Shirt",Character)
  21. Shirt.Parent = Cha
  22. Shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=249639658"
  23.  
  24. Pant = Instance.new("Pants",Character)
  25. Pant.Parent = Cha
  26. Pant.PantsTemplate = "http://www.roblox.com/asset/?id=249639685"
  27. lite = Instance.new("PointLight")
  28. lite.Parent = Cha.Torso
  29. lite.Brightness = 100
  30. lite.Range = 8
  31. lite.Color = Color3.new(1,1,1)
  32. -------------Chakra Balls--------------------
  33. Sphere = Instance.new("Part",Cha)
  34. Sphere.TopSurface = "Smooth"
  35. Sphere.BottomSurface = "Smooth"
  36. Sphere.FormFactor = "Custom"
  37. Sphere.Size = Vector3.new(1,1,1)
  38. Sphere.CanCollide = True
  39. Sphere.BrickColor = BrickColor.new("Really black")
  40. SphereMesh = Instance.new("SpecialMesh", Sphere)
  41. SphereMesh.MeshType = "Sphere"
  42. SphereMesh.Scale = Vector3.new(1,1,1)
  43. SphereWeld = Instance.new("Weld",Cha)
  44. SphereWeld.Part0 = Cha.Torso
  45. SphereWeld.Part1 = Sphere
  46. SphereWeld.C1 = CFrame.new(3, 0, 0)*CFrame.fromEulerAnglesXYZ(0, 0, 0)
  47. Sphere2 = Instance.new("Part",Cha)
  48. Sphere2.TopSurface = "Smooth"
  49. Sphere2.BottomSurface = "Smooth"
  50. Sphere2.FormFactor = "Custom"
  51. Sphere2.Size = Vector3.new(1,1,1)
  52. Sphere2.CanCollide = True
  53. Sphere2.BrickColor = BrickColor.new("Really black")
  54. Sphere2Mesh = Instance.new("SpecialMesh", Sphere2)
  55. Sphere2Mesh.MeshType = "Sphere"
  56. Sphere2Mesh.Scale = Vector3.new(1,1,1)
  57. Sphere2Weld = Instance.new("Weld",Cha)
  58. Sphere2Weld.Part0 = Cha.Torso
  59. Sphere2Weld.Part1 = Sphere2
  60. Sphere2Weld.C1 = CFrame.new(-3, 0, 0)*CFrame.fromEulerAnglesXYZ(0, 0, 0)
  61. Sphere3 = Instance.new("Part",Cha)
  62. Sphere3.TopSurface = "Smooth"
  63. Sphere3.BottomSurface = "Smooth"
  64. Sphere3.FormFactor = "Custom"
  65. Sphere3.Size = Vector3.new(1,1,1)
  66. Sphere3.CanCollide = True
  67. Sphere3.BrickColor = BrickColor.new("Really black")
  68. Sphere3Mesh = Instance.new("SpecialMesh", Sphere3)
  69. Sphere3Mesh.MeshType = "Sphere"
  70. Sphere3Mesh.Scale = Vector3.new(1,1,1)
  71. Sphere3Weld = Instance.new("Weld",Cha)
  72. Sphere3Weld.Part0 = Cha.Torso
  73. Sphere3Weld.Part1 = Sphere3
  74. Sphere3Weld.C1 = CFrame.new(-2, -2, 0)*CFrame.fromEulerAnglesXYZ(0, 0, 0)
  75. Sphere4 = Instance.new("Part",Cha)
  76. Sphere4.TopSurface = "Smooth"
  77. Sphere4.BottomSurface = "Smooth"
  78. Sphere4.FormFactor = "Custom"
  79. Sphere4.Size = Vector3.new(1,1,1)
  80. Sphere4.CanCollide = True
  81. Sphere4.BrickColor = BrickColor.new("Really black")
  82. Sphere4Mesh = Instance.new("SpecialMesh", Sphere4)
  83. Sphere4Mesh.MeshType = "Sphere"
  84. Sphere4Mesh.Scale = Vector3.new(1,1,1)
  85. Sphere4Weld = Instance.new("Weld",Cha)
  86. Sphere4Weld.Part0 = Cha.Torso
  87. Sphere4Weld.Part1 = Sphere4
  88. Sphere4Weld.C1 = CFrame.new(2, -2, 0)*CFrame.fromEulerAnglesXYZ(0, 0, 0)
  89. Sphere5 = Instance.new("Part",Cha)
  90. Sphere5.TopSurface = "Smooth"
  91. Sphere5.BottomSurface = "Smooth"
  92. Sphere5.FormFactor = "Custom"
  93. Sphere5.Size = Vector3.new(1,1,1)
  94. Sphere5.CanCollide = True
  95. Sphere5.BrickColor = BrickColor.new("Really black")
  96. Sphere5Mesh = Instance.new("SpecialMesh", Sphere5)
  97. Sphere5Mesh.MeshType = "Sphere"
  98. Sphere5Mesh.Scale = Vector3.new(1,1,1)
  99. Sphere5Weld = Instance.new("Weld",Cha)
  100. Sphere5Weld.Part0 = Cha.Torso
  101. Sphere5Weld.Part1 = Sphere5
  102. Sphere5Weld.C1 = CFrame.new(0, -4, 0)*CFrame.fromEulerAnglesXYZ(0, 0, 0)
  103. ----------------------------------------------------
  104. local m = Instance.new("Model")
  105. m.Name = "Hair"
  106. p1 = Instance.new("Part", m)
  107. p1.BrickColor = BrickColor.new("Institutional white")
  108. p1.FormFactor = Enum.FormFactor.Symmetric
  109. p1.Size = Vector3.new(1, 1, 1)
  110. p1.CFrame = CFrame.new(12.5095692, 22.9280014, 28.5988674, -1.79592973e-007, -0.978694081, 0.205298647, -1.48348063e-008, -0.205299929, -0.978699148, 0.999994814, 2.38417414e-007, -2.98021181e-008)
  111. p1.CanCollide = false
  112. p1.Locked = true
  113. p1.BottomSurface = Enum.SurfaceType.Smooth
  114. p1.TopSurface = Enum.SurfaceType.Smooth
  115. b1 = Instance.new("SpecialMesh", p1)
  116. b1.MeshId = "http://www.roblox.com/asset/?id=12212520"
  117. b1.TextureId = ""
  118. b1.MeshType = Enum.MeshType.FileMesh
  119. b1.Name = "Mesh"
  120. b1.VertexColor = Vector3.new(0, 0, 0)
  121. b1.Scale = Vector3.new(1, 1.60000002, 1.29999995)
  122. p2 = Instance.new("Part", m)
  123. p2.BrickColor = BrickColor.new("Pastel brown")
  124. p2.Transparency = 1
  125. p2.Name = "Head"
  126. p2.FormFactor = Enum.FormFactor.Symmetric
  127. p2.Size = Vector3.new(2, 1, 1)
  128. p2.CFrame = CFrame.new(13.299921, 22.8300076, 28.5998688, -1.19988712e-007, 8.94068393e-008, -0.999995589, -1.48348125e-008, 1, -8.94068108e-008, 0.999995589, -1.48348231e-008, 2.39197504e-007)
  129. p2.CanCollide = false
  130. p2.Locked = true
  131. p2.TopSurface = Enum.SurfaceType.Smooth
  132. b2 = Instance.new("SpecialMesh", p2)
  133. b2.MeshType = Enum.MeshType.Head
  134. b2.Name = "Mesh"
  135. b2.Scale = Vector3.new(1.25, 1.25, 1.25)
  136. p3 = Instance.new("Part", m)
  137. p3.BrickColor = BrickColor.new("Institutional white")
  138. p3.FormFactor = Enum.FormFactor.Symmetric
  139. p3.Size = Vector3.new(2, 2, 2)
  140. p3.CFrame = CFrame.new(13.2999649, 23.4000015, 28.5999584, -1.19728938e-007, 5.96046092e-008, -0.999997199, -9.88988447e-009, 1, -5.96045844e-008, 0.999997199, -9.88988802e-009, 1.19728938e-007)
  141. p3.CanCollide = false
  142. p3.Locked = true
  143. p3.BottomSurface = Enum.SurfaceType.Smooth
  144. p3.TopSurface = Enum.SurfaceType.Smooth
  145. b3 = Instance.new("SpecialMesh", p3)
  146. b3.MeshId = "http://www.roblox.com/asset/?id=16627529"
  147. b3.TextureId = ""
  148. b3.MeshType = Enum.MeshType.FileMesh
  149. b3.Name = "Mesh"
  150. b3.VertexColor = Vector3.new(0, 0, 0)
  151. b3.Scale = Vector3.new(1.04999995, 1.04999995, 1.04999995)
  152. p4 = Instance.new("Part", m)
  153. p4.BrickColor = BrickColor.new("Institutional white")
  154. p4.FormFactor = Enum.FormFactor.Symmetric
  155. p4.Size = Vector3.new(1, 1, 1)
  156. p4.CFrame = CFrame.new(13.220191, 23.5300064, 28.5998363, -2.39457108e-007, 1.19209027e-007, -0.99999398, -1.97797441e-008, 1, -1.19208977e-007, 0.99999398, -1.97797512e-008, 2.39457108e-007)
  157. p4.CanCollide = false
  158. p4.Locked = true
  159. p4.BottomSurface = Enum.SurfaceType.Smooth
  160. p4.TopSurface = Enum.SurfaceType.Smooth
  161. b4 = Instance.new("SpecialMesh", p4)
  162. b4.MeshId = "http://www.roblox.com/asset/?id=19326912"
  163. b4.TextureId = ""
  164. b4.MeshType = Enum.MeshType.FileMesh
  165. b4.Name = "Mesh"
  166. b4.VertexColor = Vector3.new(0, 0, 0)
  167. p5 = Instance.new("Part", m)
  168. p5.BrickColor = BrickColor.new("Institutional white")
  169. p5.FormFactor = Enum.FormFactor.Symmetric
  170. p5.Size = Vector3.new(1, 1, 1)
  171. p5.CFrame = CFrame.new(13.299963, 23.1500015, 28.5999584, -4.78911147e-007, 2.384173e-007, -0.999987543, -3.95593887e-008, 1, -2.38417186e-007, 0.999987543, -3.95594029e-008, 4.78911147e-007)
  172. p5.CanCollide = false
  173. p5.Locked = true
  174. p5.BottomSurface = Enum.SurfaceType.Smooth
  175. p5.TopSurface = Enum.SurfaceType.Smooth
  176. b5 = Instance.new("SpecialMesh", p5)
  177. b5.MeshId = "http://www.roblox.com/asset/?id=45916884"
  178. b5.TextureId = ""
  179. b5.MeshType = Enum.MeshType.FileMesh
  180. b5.Name = "Mesh"
  181. b5.VertexColor = Vector3.new(0, 0, 0)
  182. b5.Scale = Vector3.new(1, 0.899999976, 1)
  183. p6 = Instance.new("Part", m)
  184. p6.BrickColor = BrickColor.new("Institutional white")
  185. p6.FormFactor = Enum.FormFactor.Symmetric
  186. p6.Size = Vector3.new(1, 1, 1)
  187. p6.CFrame = CFrame.new(13.1003246, 23.2700119, 28.5500946, -9.57822294e-007, 4.76831474e-007, -0.999987543, -7.91193955e-008, 1, -2.84217094e-014, 0.999987543, -4.04650001e-015, 5.68434189e-014)
  188. p6.CanCollide = false
  189. p6.Locked = true
  190. p6.BottomSurface = Enum.SurfaceType.Smooth
  191. p6.TopSurface = Enum.SurfaceType.Smooth
  192. b6 = Instance.new("SpecialMesh", p6)
  193. b6.MeshId = "http://www.roblox.com/asset/?id=62246019"
  194. b6.TextureId = ""
  195. b6.MeshType = Enum.MeshType.FileMesh
  196. b6.Name = "Mesh"
  197. b6.VertexColor = Vector3.new(0, 0, 0)
  198. p7 = Instance.new("Part", m)
  199. p7.BrickColor = BrickColor.new("Institutional white")
  200. p7.FormFactor = Enum.FormFactor.Symmetric
  201. p7.Size = Vector3.new(1, 1, 1)
  202. p7.CFrame = CFrame.new(13.1008148, 23.0000076, 28.4990215, -9.57822294e-007, 4.76831502e-007, -0.999987543, -7.91194026e-008, 1, 3.5914197e-019, 0.999987543, 3.05883884e-015, 5.68434189e-014)
  203. p7.CanCollide = false
  204. p7.Locked = true
  205. p7.BottomSurface = Enum.SurfaceType.Smooth
  206. p7.TopSurface = Enum.SurfaceType.Smooth
  207. b7 = Instance.new("SpecialMesh", p7)
  208. b7.MeshId = "http://www.roblox.com/asset/?id=76056263"
  209. b7.TextureId = ""
  210. b7.MeshType = Enum.MeshType.FileMesh
  211. b7.Name = "Mesh"
  212. b7.VertexColor = Vector3.new(0, 0, 0)
  213. p8 = Instance.new("Part", m)
  214. p8.BrickColor = BrickColor.new("Institutional white")
  215. p8.FormFactor = Enum.FormFactor.Symmetric
  216. p8.Size = Vector3.new(1, 1, 1)
  217. p8.CFrame = CFrame.new(12.3756638, 22.3460064, 28.5989819, -9.57822294e-007, -0.80510509, 0.593111277, -7.91194026e-008, -0.593119025, -0.805114806, 0.999987543, -1.28919533e-014, 2.06653508e-014)
  218. p8.CanCollide = false
  219. p8.Locked = true
  220. p8.BottomSurface = Enum.SurfaceType.Smooth
  221. p8.TopSurface = Enum.SurfaceType.Smooth
  222. b8 = Instance.new("SpecialMesh", p8)
  223. b8.MeshId = "http://www.roblox.com/asset/?id=12212520"
  224. b8.TextureId = ""
  225. b8.MeshType = Enum.MeshType.FileMesh
  226. b8.Name = "Mesh"
  227. b8.VertexColor = Vector3.new(0, 0, 0)
  228. b8.Scale = Vector3.new(1, 1.60000002, 1.29999995)
  229. p9 = Instance.new("Part", m)
  230. p9.BrickColor = BrickColor.new("Institutional white")
  231. p9.FormFactor = Enum.FormFactor.Symmetric
  232. p9.Size = Vector3.new(2, 1, 2)
  233. p9.CFrame = CFrame.new(13.2349396, 23.2430096, 28.5993462, -9.57822294e-007, -0.0995007455, -0.995025039, -7.91194097e-008, 0.995037317, -0.0995024443, 0.999987543, -5.41274382e-016, -2.16294996e-014)
  234. p9.CanCollide = false
  235. p9.Locked = true
  236. p9.BottomSurface = Enum.SurfaceType.Smooth
  237. p9.TopSurface = Enum.SurfaceType.Smooth
  238. b9 = Instance.new("SpecialMesh", p9)
  239. b9.MeshId = "http://www.roblox.com/asset/?id=12259089"
  240. b9.TextureId = ""
  241. b9.MeshType = Enum.MeshType.FileMesh
  242. b9.Name = "Mesh"
  243. b9.VertexColor = Vector3.new(0, 0, 0)
  244. b9.Scale = Vector3.new(1.01999998, 1.04999995, 1.04999995)
  245. p10 = Instance.new("Part", m)
  246. p10.BrickColor = BrickColor.new("Institutional white")
  247. p10.FormFactor = Enum.FormFactor.Symmetric
  248. p10.Size = Vector3.new(1, 1, 1)
  249. p10.CFrame = CFrame.new(12.9792271, 23.7430058, 28.6003838, -9.57822294e-007, -0.68356514, -0.729872584, -7.91194097e-008, 0.729881346, -0.683573902, 0.999987543, -1.35710662e-014, -1.68509463e-014)
  250. p10.CanCollide = false
  251. p10.Locked = true
  252. p10.BottomSurface = Enum.SurfaceType.Smooth
  253. p10.TopSurface = Enum.SurfaceType.Smooth
  254. b10 = Instance.new("SpecialMesh", p10)
  255. b10.MeshId = "http://www.roblox.com/asset/?id=12212520"
  256. b10.TextureId = ""
  257. b10.MeshType = Enum.MeshType.FileMesh
  258. b10.Name = "Mesh"
  259. b10.VertexColor = Vector3.new(0, 0, 0)
  260. b10.Scale = Vector3.new(1, 1.60000002, 1.29999995)
  261. p11 = Instance.new("Part", m)
  262. p11.BrickColor = BrickColor.new("Institutional white")
  263. p11.FormFactor = Enum.FormFactor.Symmetric
  264. p11.Size = Vector3.new(1, 1, 1)
  265. p11.CFrame = CFrame.new(12.8353081, 23.4680061, 28.5991058, -9.57822294e-007, -0.989463568, -0.144696504, -7.91194026e-008, 0.144697905, -0.989475906, 0.999987543, -2.11154641e-014, -4.7186215e-015)
  266. p11.CanCollide = false
  267. p11.Locked = true
  268. p11.BottomSurface = Enum.SurfaceType.Smooth
  269. p11.TopSurface = Enum.SurfaceType.Smooth
  270. b11 = Instance.new("SpecialMesh", p11)
  271. b11.MeshId = "http://www.roblox.com/asset/?id=12212520"
  272. b11.TextureId = ""
  273. b11.MeshType = Enum.MeshType.FileMesh
  274. b11.Name = "Mesh"
  275. b11.VertexColor = Vector3.new(0, 0, 0)
  276. b11.Scale = Vector3.new(1, 1.60000002, 1.29999995)
  277. w1 = Instance.new("Weld", p1)
  278. w1.Name = "Head_Weld"
  279. w1.Part0 = p1
  280. w1.C0 = CFrame.new(-28.5990181, 16.950285, 19.8713875, 0, 0, 0.999999583, -0.97869873, -0.205299839, 5.96046448e-008, 0.20529972, -0.978699148, -7.4505806e-009)
  281. w1.Part1 = p2
  282. w1.C1 = CFrame.new(-28.5999966, -22.8300076, 13.2999811, 5.96046448e-008, 0, 0.999999642, 0, 1, 0, -0.999999642, 0, 5.96046448e-008)
  283. w2 = Instance.new("Weld", p2)
  284. w2.Name = "Weld"
  285. w2.Part0 = p2
  286. w2.C0 = CFrame.new(-28.5999527, -22.8300056, 13.2999592, -2.5997493e-010, -4.94494357e-009, 0.999998808, 2.98023224e-008, 1, -4.94494712e-009, -0.999998808, -2.98023224e-008, 1.19469163e-007)
  287. w2.Part1 = p3
  288. w2.C1 = CFrame.new(-28.5999947, -23.3999996, 13.2999821, 0, 0, 0.999999583, 0, 1, 0, -0.999999583, 0, 0)
  289. w3 = Instance.new("Weld", p3)
  290. w3.Name = "Weld"
  291. w3.Part0 = p3
  292. w3.C0 = CFrame.new(-28.5999012, -23.3999996, 13.2999363, -1.19728938e-007, -9.88988447e-009, 0.999997199, 5.96046092e-008, 1, -9.88988802e-009, -0.999997199, -5.96045844e-008, 1.19728938e-007)
  293. w3.Part1 = p4
  294. w3.C1 = CFrame.new(-28.5998726, -23.5300045, 13.2202082, 0, 0, 0.999999583, 0, 1, 0, -0.999999583, 0, 0)
  295. w4 = Instance.new("Weld", p4)
  296. w4.Name = "Weld"
  297. w4.Part0 = p4
  298. w4.C0 = CFrame.new(-28.5996857, -23.5300064, 13.2201195, -2.39457108e-007, -1.97797441e-008, 0.99999398, 1.19209027e-007, 1, -1.97797512e-008, -0.99999398, -1.19208977e-007, 2.39457108e-007)
  299. w4.Part1 = p5
  300. w4.C1 = CFrame.new(-28.5999947, -23.1499996, 13.2999821, 0, 0, 0.999999583, 0, 1, 0, -0.999999583, 0, 0)
  301. w5 = Instance.new("Weld", p5)
  302. w5.Name = "Weld"
  303. w5.Part0 = p5
  304. w5.C0 = CFrame.new(-28.5996189, -23.1500015, 13.2998009, -4.78911147e-007, -3.95593887e-008, 0.999987543, 2.384173e-007, 1, -3.95594029e-008, -0.999987543, -2.38417186e-007, 4.78911147e-007)
  305. w5.Part1 = p6
  306. w5.C1 = CFrame.new(-28.5501289, -23.27001, 13.1003361, 0, 0, 0.999999583, 0, 1, 0, -0.999999583, 0, 0)
  307. w6 = Instance.new("Weld", p6)
  308. w6.Name = "Weld"
  309. w6.Part0 = p6
  310. w6.C0 = CFrame.new(-28.5497494, -23.2700157, 13.100173, -9.57822294e-007, -7.91193955e-008, 0.999987543, 4.76831474e-007, 1, -4.04650001e-015, -0.999987543, -2.84217094e-014, 5.68434189e-014)
  311. w6.Part1 = p7
  312. w6.C1 = CFrame.new(-28.4990501, -23.0000057, 13.1008282, 0, 0, 0.999999881, 0, 1, 0, -0.999999881, 0, 0)
  313. w7 = Instance.new("Weld", p7)
  314. w7.Name = "Weld"
  315. w7.Part0 = p7
  316. w7.C0 = CFrame.new(-28.4986763, -23.0000114, 13.1006632, -9.57822294e-007, -7.91194026e-008, 0.999987543, 4.76831502e-007, 1, 3.05883884e-015, -0.999987543, 3.5914197e-019, 5.68434189e-014)
  317. w7.Part1 = p8
  318. w7.C1 = CFrame.new(-28.5990181, 23.2175999, 10.6510067, 0, 0, 0.999999583, -0.805118203, -0.59311378, -5.96046448e-008, 0.593113363, -0.80511874, 0)
  319. w8 = Instance.new("Weld", p8)
  320. w8.Name = "Weld"
  321. w8.Part0 = p8
  322. w8.C0 = CFrame.new(-28.5986366, 23.2175598, 10.6509457, -9.57822294e-007, -7.91194026e-008, 0.999987543, -0.80510509, -0.593119025, -1.28919533e-014, 0.593111277, -0.805114806, 2.06653508e-014)
  323. w8.Part1 = p9
  324. w8.C1 = CFrame.new(-28.5993843, -21.8107243, 15.4820604, 0, 0, 0.999999583, -0.0995036662, 0.995037258, 0, -0.995036721, -0.0995037258, 0)
  325. w9 = Instance.new("Weld", p9)
  326. w9.Name = "Weld"
  327. w9.Part0 = p9
  328. w9.C0 = CFrame.new(-28.598999, -21.8107738, 15.4818439, -9.57822294e-007, -7.91194097e-008, 0.999987543, -0.0995007455, 0.995037317, -5.41274382e-016, -0.995025039, -0.0995024443, -2.16294996e-014)
  329. w9.Part1 = p10
  330. w9.C1 = CFrame.new(-28.6004219, -8.45714283, 25.703455, 0, 0, 0.999999583, -0.683578134, 0.729877055, 2.98023224e-008, -0.729876637, -0.683578491, 8.94069672e-008)
  331. w10 = Instance.new("Weld", p10)
  332. w10.Name = "Weld"
  333. w10.Part0 = p10
  334. w10.C0 = CFrame.new(-28.6000366, -8.4574213, 25.703289, -9.57822294e-007, -7.91194097e-008, 0.999987543, -0.68356514, 0.729881346, -1.35710662e-014, -0.729872584, -0.683573902, -1.68509463e-014)
  335. w10.Part1 = p11
  336. w10.C1 = CFrame.new(-28.5991402, 9.30450344, 25.0782566, 0, 0, 0.999999583, -0.989475787, 0.144696504, 8.94069672e-008, -0.144696444, -0.989476025, 7.4505806e-009)
  337. m.Parent = char
  338. m:MakeJoints()
  339. ----------------------------------------------------
  340. local cor = Instance.new("Part", char.Hair)
  341. cor.Name = "Link"
  342. cor.Locked = true
  343. cor.BottomSurface = 0
  344. cor.CanCollide = false
  345. cor.Size = Vector3.new(1, 9, 1)
  346. cor.Transparency = 1
  347. cor.TopSurface = 0
  348. corw = Instance.new("Weld", cor)
  349. corw.Part0 = hed
  350. corw.Part1 = cor
  351. corw.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  352. corw.C1 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  353. weld1 = Instance.new("Weld", char.Hair)
  354. weld1.Part0 = cor
  355. weld1.Part1 = char.Hair.Head
  356. weld1.C0 = CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0))
  357. ----------------------------------------------------
  358. local Pole = Instance.new("Part",char)
  359. Pole.Locked = true
  360. Pole.Size = Vector3.new(1,1,1)
  361. Pole.BrickColor = BrickColor.new("Really black")
  362. Pole.Material = "SmoothPlastic"
  363. Pole.CanCollide = false
  364. local pm = Instance.new("CylinderMesh",Pole)
  365. pm.Scale = Vector3.new(.3,7,.3)
  366. nooutline(Pole)
  367. local PoleWeld = Instance.new("Weld")
  368. PoleWeld.Part0 = rarm
  369. PoleWeld.Part1 = Pole
  370. PoleWeld.C0 = CFrame.new(0,-1,-0.65) * CFrame.Angles(math.rad(-90),math.rad(90),0)
  371. PoleWeld.Parent = Pole
  372.  
  373. for i = 1,360*(3/4),5 do
  374. local Part = Instance.new("Part",char)
  375. local pm = Instance.new("CylinderMesh", Part)
  376. Part.BrickColor = BrickColor.new("Really black")
  377. Part.FormFactor = "Custom"
  378. Part.Size = Vector3.new(0.2,0.2,0.2)
  379. Part.CanCollide = false
  380. Part.Locked = true
  381. Part.Material = "SmoothPlastic"
  382. nooutline(Part)
  383. pm.Scale = Vector3.new(0.3/0.2,0.8,0.3/0.2)
  384. local Weld2 = Instance.new("Weld")
  385. Weld2.Part0 = Pole
  386. Weld2.Part1 = Part
  387. Weld2.C0 = CFrame.new(0,4.75,0) * CFrame.Angles(math.rad(90),math.rad(i-45),0) * CFrame.new(0,0,-1) * CFrame.Angles(0,0,math.rad(90))
  388. Weld2.Parent = PoleWeld.Part0
  389. end
  390. -----------------------------------------
  391. ----------------
  392. Player=game:GetService("Players").LocalPlayer
  393. Character=Player.Character
  394. PlayerGui=Player.PlayerGui
  395. Backpack=Player.Backpack
  396. Torso=Character.Torso
  397. Head=Character.Head
  398. Humanoid=Character.Humanoid
  399. m=Instance.new('Model',Character)
  400. LeftArm=Character["Left Arm"]
  401. LeftLeg=Character["Left Leg"]
  402. RightArm=Character["Right Arm"]
  403. RightLeg=Character["Right Leg"]
  404. LS=Torso["Left Shoulder"]
  405. LH=Torso["Left Hip"]
  406. RS=Torso["Right Shoulder"]
  407. RH=Torso["Right Hip"]
  408. Face = Head.face
  409. Neck=Torso.Neck
  410. it=Instance.new
  411. attacktype=1
  412. vt=Vector3.new
  413. cf=CFrame.new
  414. euler=CFrame.fromEulerAnglesXYZ
  415. angles=CFrame.Angles
  416. cloaked=false
  417. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  418. necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  419. LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
  420. LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
  421. RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
  422. RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
  423. RootPart=Character.HumanoidRootPart
  424. RootJoint=RootPart.RootJoint
  425. RootCF=euler(-1.57,0,3.14)
  426. attack = false
  427. attackdebounce = false
  428. deb=false
  429. equipped=true
  430. hand=false
  431. MMouse=nil
  432. combo=0
  433. mana=0
  434. trispeed=.2
  435. attackmode='none'
  436. local idle=0
  437. local Anim="Idle"
  438. local Effects={}
  439. local gun=false
  440. local shoot=false
  441. player=nil
  442. mana=0
  443. Attacking=false
  444. asset = "http://www.roblox.com/asset/?id="
  445. meshes = {["blast"] = 20329976,["ring"] = 3270017,["spike"] = 1033714,["cone"] = 1082802,["crown"] = 20329976,["cloud"] = 1095708,["diamond"] = 9756362}
  446. sounds = {["explode"] = 130792180;}
  447. torsomesh = "rbxasset://fonts/torso.mesh"
  448. colours = {"Tr. Red","Black","Tr. Blue","Black","Phosph. White","Royal purple"}
  449. local ASpeed = 10
  450. Humanoid.MaxHealth = 500
  451. wait()
  452. Humanoid.Health=500
  453.  
  454. mouse=Player:GetMouse()
  455. --save shoulders
  456. RSH, LSH=nil, nil
  457. --welds
  458. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  459. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  460. LH=Torso["Left Hip"]
  461. RH=Torso["Right Hip"]
  462. TorsoColor=Torso.BrickColor
  463. function NoOutline(Part)
  464. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  465. end
  466. player=Player
  467. ch=Character
  468. RSH=ch.Torso["Right Shoulder"]
  469. LSH=ch.Torso["Left Shoulder"]
  470. --
  471. --RSH.Parent=nil
  472. --LSH.Parent=nil
  473. --
  474. RW.Name="Right Shoulder"
  475. RW.Part0=ch.Torso
  476. RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
  477. RW.C1=cf(0, 0.5, 0)
  478. RW.Part1=ch["Right Arm"]
  479. RW.Parent=ch.Torso
  480. --
  481. LW.Name="Left Shoulder"
  482. LW.Part0=ch.Torso
  483. LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  484. LW.C1=cf(0, 0.5, 0)
  485. LW.Part1=ch["Left Arm"]
  486. LW.Parent=ch.Torso
  487. newWeld = function(wp0, wp1, wc0x, wc0y, wc0z)
  488. wld = Instance.new("Weld", wp1)
  489. wld.Part0 = wp0
  490. wld.Part1 = wp1
  491. wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
  492. end
  493. local larm = char["Left Arm"]
  494. local rarm = char["Right Arm"]
  495. local lleg = char["Left Leg"]
  496. local rleg = char["Right Leg"]
  497. local hed = char.Head
  498. local torso = char.Torso
  499. local root = char.HumanoidRootPart
  500. newWeld(torso, lleg, -0.5, -1, 0)
  501. lleg.Weld.C1 = CFrame.new(0, 1, 0)
  502. newWeld(torso, rleg, 0.5, -1, 0)
  503. rleg.Weld.C1 = CFrame.new(0, 1, 0)
  504. Player=game:GetService('Players').LocalPlayer
  505. Character=Player.Character
  506. Mouse=Player:GetMouse()
  507. m=Instance.new('Model',Character)
  508.  
  509.  
  510. local function weldBetween(a, b)
  511. local weldd = Instance.new("ManualWeld")
  512. weldd.Part0 = a
  513. weldd.Part1 = b
  514. weldd.C0 = CFrame.new()
  515. weldd.C1 = b.CFrame:inverse() * a.CFrame
  516. weldd.Parent = a
  517. return weldd
  518. end
  519.  
  520. it=Instance.new
  521.  
  522. function nooutline(part)
  523. part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10
  524. end
  525.  
  526. function part(formfactor,parent,material,reflectance,transparency,brickcolor,name,size)
  527. local fp=it("Part")
  528. fp.formFactor=formfactor
  529. fp.Parent=parent
  530. fp.Reflectance=reflectance
  531. fp.Transparency=transparency
  532. fp.CanCollide=false
  533. fp.Locked=true
  534. fp.BrickColor=BrickColor.new(tostring(brickcolor))
  535. fp.Name=name
  536. fp.Size=size
  537. fp.Position=Character.Torso.Position
  538. nooutline(fp)
  539. fp.Material=material
  540. fp:BreakJoints()
  541. return fp
  542. end
  543.  
  544. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  545. local mesh=it(Mesh)
  546. mesh.Parent=part
  547. if Mesh=="SpecialMesh" then
  548. mesh.MeshType=meshtype
  549. mesh.MeshId=meshid
  550. end
  551. mesh.Offset=offset
  552. mesh.Scale=scale
  553. return mesh
  554. end
  555.  
  556. function weld(parent,part0,part1,c0,c1)
  557. local weld=it("Weld")
  558. weld.Parent=parent
  559. weld.Part0=part0
  560. weld.Part1=part1
  561. weld.C0=c0
  562. weld.C1=c1
  563. return weld
  564. end
  565.  
  566.  
  567. Player=game:GetService('Players').LocalPlayer
  568. Character=Player.Character
  569. Mouse=Player:GetMouse()
  570. m=Instance.new('Model',Character)
  571.  
  572.  
  573. local function weldBetween(a, b)
  574. local weldd = Instance.new("ManualWeld")
  575. weldd.Part0 = a
  576. weldd.Part1 = b
  577. weldd.C0 = CFrame.new()
  578. weldd.C1 = b.CFrame:inverse() * a.CFrame
  579. weldd.Parent = a
  580. return weldd
  581. end
  582.  
  583. it=Instance.new
  584.  
  585. function nooutline(part)
  586. part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10
  587. end
  588.  
  589.  
  590. function swait(num)
  591. if num==0 or num==nil then
  592. game:service'RunService'.Heartbeat:wait(0)
  593. else
  594. for i=0,num do
  595. game:service'RunService'.Heartbeat:wait(0)
  596. end
  597. end
  598. end
  599.  
  600. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  601. local mesh=it(Mesh)
  602. mesh.Parent=part
  603. if Mesh=="SpecialMesh" then
  604. mesh.MeshType=meshtype
  605. mesh.MeshId=meshid
  606. end
  607. mesh.Offset=offset
  608. mesh.Scale=scale
  609. return mesh
  610. end
  611.  
  612. function weld(parent,part0,part1,c0,c1)
  613. local weld=it("Weld")
  614. weld.Parent=parent
  615. weld.Part0=part0
  616. weld.Part1=part1
  617. weld.C0=c0
  618. weld.C1=c1
  619. return weld
  620. end
  621.  
  622.  
  623. local function CFrameFromTopBack(at, top, back)
  624. local right = top:Cross(back)
  625. return CFrame.new(at.x, at.y, at.z,
  626. right.x, top.x, back.x,
  627. right.y, top.y, back.y,
  628. right.z, top.z, back.z)
  629. end
  630.  
  631. function Triangle(a, b, c)
  632. local edg1 = (c-a):Dot((b-a).unit)
  633. local edg2 = (a-b):Dot((c-b).unit)
  634. local edg3 = (b-c):Dot((a-c).unit)
  635. if edg1 <= (b-a).magnitude and edg1 >= 0 then
  636. a, b, c = a, b, c
  637. elseif edg2 <= (c-b).magnitude and edg2 >= 0 then
  638. a, b, c = b, c, a
  639. elseif edg3 <= (a-c).magnitude and edg3 >= 0 then
  640. a, b, c = c, a, b
  641. else
  642. assert(false, "unreachable")
  643. end
  644.  
  645. local len1 = (c-a):Dot((b-a).unit)
  646. local len2 = (b-a).magnitude - len1
  647. local width = (a + (b-a).unit*len1 - c).magnitude
  648.  
  649. local maincf = CFrameFromTopBack(a, (b-a):Cross(c-b).unit, -(b-a).unit)
  650.  
  651. local list = {}
  652.  
  653. local Color = BrickColor.new("Really black")
  654.  
  655. if len1 > 0.01 then
  656. local w1 = Instance.new('WedgePart', m)
  657. game:GetService("Debris"):AddItem(w1,5)
  658. w1.Material = "SmoothPlastic"
  659. w1.FormFactor = 'Custom'
  660. w1.BrickColor = Color
  661. w1.Transparency = 0
  662. w1.Reflectance = 0
  663. w1.Material = "SmoothPlastic"
  664. w1.CanCollide = false
  665. NoOutline(w1)
  666. local sz = Vector3.new(0.2, width, len1)
  667. w1.Size = sz
  668. local sp = Instance.new("SpecialMesh",w1)
  669. sp.MeshType = "Wedge"
  670. sp.Scale = Vector3.new(0,1,1) * sz/w1.Size
  671. w1:BreakJoints()
  672. w1.Anchored = true
  673. w1.Parent = workspace
  674. w1.Transparency = 0.7
  675. table.insert(Effects,{w1,"Disappear",.01})
  676. w1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2)
  677. table.insert(list,w1)
  678. end
  679.  
  680. if len2 > 0.01 then
  681. local w2 = Instance.new('WedgePart', m)
  682. game:GetService("Debris"):AddItem(w2,5)
  683. w2.Material = "SmoothPlastic"
  684. w2.FormFactor = 'Custom'
  685. w2.BrickColor = Color
  686. w2.Transparency = 0
  687. w2.Reflectance = 0
  688. w2.Material = "SmoothPlastic"
  689. w2.CanCollide = false
  690. NoOutline(w2)
  691. local sz = Vector3.new(0.2, width, len2)
  692. w2.Size = sz
  693. local sp = Instance.new("SpecialMesh",w2)
  694. sp.MeshType = "Wedge"
  695. sp.Scale = Vector3.new(0,1,1) * sz/w2.Size
  696. w2:BreakJoints()
  697. w2.Anchored = true
  698. w2.Parent = workspace
  699. w2.Transparency = 0.7
  700. table.insert(Effects,{w2,"Disappear",.01})
  701. w2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2)
  702. table.insert(list,w2)
  703. end
  704. return unpack(list)
  705. end
  706.  
  707.  
  708. so = function(id,par,vol,pit)
  709. coroutine.resume(coroutine.create(function()
  710. local sou = Instance.new("Sound",par or workspace)
  711. sou.Volume=vol
  712. sou.Pitch=pit or 1
  713. sou.SoundId=id
  714. swait()
  715. sou:play()
  716. game:GetService("Debris"):AddItem(sou,6)
  717. end))
  718. end
  719.  
  720. function clerp(a,b,t)
  721. local qa = {QuaternionFromCFrame(a)}
  722. local qb = {QuaternionFromCFrame(b)}
  723. local ax, ay, az = a.x, a.y, a.z
  724. local bx, by, bz = b.x, b.y, b.z
  725. local _t = 1-t
  726. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  727. end
  728.  
  729. function QuaternionFromCFrame(cf)
  730. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  731. local trace = m00 + m11 + m22
  732. if trace > 0 then
  733. local s = math.sqrt(1 + trace)
  734. local recip = 0.5/s
  735. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  736. else
  737. local i = 0
  738. if m11 > m00 then
  739. i = 1
  740. end
  741. if m22 > (i == 0 and m00 or m11) then
  742. i = 2
  743. end
  744. if i == 0 then
  745. local s = math.sqrt(m00-m11-m22+1)
  746. local recip = 0.5/s
  747. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  748. elseif i == 1 then
  749. local s = math.sqrt(m11-m22-m00+1)
  750. local recip = 0.5/s
  751. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  752. elseif i == 2 then
  753. local s = math.sqrt(m22-m00-m11+1)
  754. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  755. end
  756. end
  757. end
  758.  
  759. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  760. local xs, ys, zs = x + x, y + y, z + z
  761. local wx, wy, wz = w*xs, w*ys, w*zs
  762. local xx = x*xs
  763. local xy = x*ys
  764. local xz = x*zs
  765. local yy = y*ys
  766. local yz = y*zs
  767. local zz = z*zs
  768. 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))
  769. end
  770.  
  771. function QuaternionSlerp(a, b, t)
  772. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  773. local startInterp, finishInterp;
  774. if cosTheta >= 0.0001 then
  775. if (1 - cosTheta) > 0.0001 then
  776. local theta = math.acos(cosTheta)
  777. local invSinTheta = 1/math.sin(theta)
  778. startInterp = math.sin((1-t)*theta)*invSinTheta
  779. finishInterp = math.sin(t*theta)*invSinTheta
  780. else
  781. startInterp = 1-t
  782. finishInterp = t
  783. end
  784. else
  785. if (1+cosTheta) > 0.0001 then
  786. local theta = math.acos(-cosTheta)
  787. local invSinTheta = 1/math.sin(theta)
  788. startInterp = math.sin((t-1)*theta)*invSinTheta
  789. finishInterp = math.sin(t*theta)*invSinTheta
  790. else
  791. startInterp = t-1
  792. finishInterp = t
  793. end
  794. end
  795. 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
  796. end
  797.  
  798. function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  799. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  800. end
  801.  
  802. local function CFrameFromTopBack(at, top, back)
  803. local right = top:Cross(back)
  804. return CFrame.new(at.x, at.y, at.z,
  805. right.x, top.x, back.x,
  806. right.y, top.y, back.y,
  807. right.z, top.z, back.z)
  808. end
  809.  
  810. function Triangle(a, b, c)
  811. local edg1 = (c-a):Dot((b-a).unit)
  812. local edg2 = (a-b):Dot((c-b).unit)
  813. local edg3 = (b-c):Dot((a-c).unit)
  814. if edg1 <= (b-a).magnitude and edg1 >= 0 then
  815. a, b, c = a, b, c
  816. elseif edg2 <= (c-b).magnitude and edg2 >= 0 then
  817. a, b, c = b, c, a
  818. elseif edg3 <= (a-c).magnitude and edg3 >= 0 then
  819. a, b, c = c, a, b
  820. else
  821. assert(false, "unreachable")
  822. end
  823.  
  824. local len1 = (c-a):Dot((b-a).unit)
  825. local len2 = (b-a).magnitude - len1
  826. local width = (a + (b-a).unit*len1 - c).magnitude
  827.  
  828. local maincf = CFrameFromTopBack(a, (b-a):Cross(c-b).unit, -(b-a).unit)
  829.  
  830. local list = {}
  831.  
  832. if len1 > 0.01 then
  833. local w1 = Instance.new('WedgePart', m)
  834. game:GetService("Debris"):AddItem(w1,5)
  835. w1.Material = "SmoothPlastic"
  836. w1.FormFactor = 'Custom'
  837. w1.BrickColor = BrickColor.new("Really black")
  838. w1.Transparency = 0
  839. w1.Reflectance = 0
  840. w1.Material = "SmoothPlastic"
  841. w1.CanCollide = false
  842. NoOutline(w1)
  843. local sz = Vector3.new(0.2, width, len1)
  844. w1.Size = sz
  845. local sp = Instance.new("SpecialMesh",w1)
  846. sp.MeshType = "Wedge"
  847. sp.Scale = Vector3.new(0,1,1) * sz/w1.Size
  848. w1:BreakJoints()
  849. w1.Anchored = true
  850. w1.Parent = workspace
  851. w1.Transparency = 0.7
  852. table.insert(Effects,{w1,"Disappear",.01})
  853. w1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2)
  854. table.insert(list,w1)
  855. end
  856.  
  857. if len2 > 0.01 then
  858. local w2 = Instance.new('WedgePart', m)
  859. game:GetService("Debris"):AddItem(w2,5)
  860. w2.Material = "SmoothPlastic"
  861. w2.FormFactor = 'Custom'
  862. w2.BrickColor = BrickColor.new("Really black")
  863. w2.Transparency = 0
  864. w2.Reflectance = 0
  865. w2.Material = "SmoothPlastic"
  866. w2.CanCollide = false
  867. NoOutline(w2)
  868. local sz = Vector3.new(0.2, width, len2)
  869. w2.Size = sz
  870. local sp = Instance.new("SpecialMesh",w2)
  871. sp.MeshType = "Wedge"
  872. sp.Scale = Vector3.new(0,1,1) * sz/w2.Size
  873. w2:BreakJoints()
  874. w2.Anchored = true
  875. w2.Parent = workspace
  876. w2.Transparency = 0.7
  877. table.insert(Effects,{w2,"Disappear",.01})
  878. w2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2)
  879. table.insert(list,w2)
  880. end
  881. return unpack(list)
  882. end
  883.  
  884. Damagefunc=function(hit,minim,maxim,knockback,Type,Property,Delay,KnockbackType,decreaseblock)
  885. if hit.Parent==nil then
  886. return
  887. end
  888. h=hit.Parent:FindFirstChild("Humanoid")
  889. for _,v in pairs(hit.Parent:children()) do
  890. if v:IsA("Humanoid") then
  891. h=v
  892. end
  893. end
  894. if hit.Parent.Parent:FindFirstChild("Torso")~=nil then
  895. h=hit.Parent.Parent:FindFirstChild("Humanoid")
  896. end
  897. if hit.Parent.className=="Hat" then
  898. hit=hit.Parent.Parent:findFirstChild("Head")
  899. end
  900. if h~=nil and hit.Parent.Name~=Character.Name and hit.Parent:FindFirstChild("Torso")~=nil then
  901. if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
  902. --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
  903. return
  904. end]]
  905. -- hs(hit,1.2)
  906. c=Instance.new("ObjectValue")
  907. c.Name="creator"
  908. c.Value=game:service("Players").LocalPlayer
  909. c.Parent=h
  910. game:GetService("Debris"):AddItem(c,.5)
  911. Damage=math.random(minim,maxim)
  912. -- h:TakeDamage(Damage)
  913. blocked=false
  914. block=hit.Parent:findFirstChild("Block")
  915. if block~=nil then
  916. print(block.className)
  917. if block.className=="NumberValue" then
  918. if block.Value>0 then
  919. blocked=true
  920. if decreaseblock==nil then
  921. block.Value=block.Value-1
  922. end
  923. end
  924. end
  925. if block.className=="IntValue" then
  926. if block.Value>0 then
  927. blocked=true
  928. if decreaseblock~=nil then
  929. block.Value=block.Value-1
  930. end
  931. end
  932. end
  933. end
  934. if blocked==false then
  935. -- h:TakeDamage(Damage)
  936. h.Health=h.Health-Damage
  937. showDamage(hit.Parent,Damage,.5,BrickColor.new("Dark stone grey"))
  938. else
  939. h.Health=h.Health-(Damage/2)
  940. showDamage(hit.Parent,Damage/2,.5,BrickColor.new("Bright blue"))
  941. end
  942. if Type=="Knockdown" then
  943. hum=hit.Parent.Humanoid
  944. hum.PlatformStand=true
  945. coroutine.resume(coroutine.create(function(HHumanoid)
  946. swait(1)
  947. HHumanoid.PlatformStand=false
  948. end),hum)
  949. local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
  950. --hit.CFrame=CFrame.new(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
  951. local bodvol=Instance.new("BodyVelocity")
  952. bodvol.velocity=angle*knockback
  953. bodvol.P=5000
  954. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  955. bodvol.Parent=hit
  956. rl=Instance.new("BodyAngularVelocity")
  957. rl.P=3000
  958. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  959. rl.angularvelocity=Vector3.new(math.random(-10,10),math.random(-10,10),math.random(-10,10))
  960. rl.Parent=hit
  961. game:GetService("Debris"):AddItem(bodvol,.5)
  962. game:GetService("Debris"):AddItem(rl,.5)
  963. elseif Type=="Normal" then
  964. vp=Instance.new("BodyVelocity")
  965. vp.P=500
  966. vp.maxForce=Vector3.new(math.huge,0,math.huge)
  967. -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback
  968. if KnockbackType==1 then
  969. vp.velocity=Property.CFrame.lookVector*knockback+Property.Velocity/1.05
  970. elseif KnockbackType==2 then
  971. vp.velocity=Property.CFrame.lookVector*knockback
  972. end
  973. if knockback>0 then
  974. vp.Parent=hit.Parent.Torso
  975. end
  976. game:GetService("Debris"):AddItem(vp,.5)
  977. elseif Type=="Up" then
  978. local bodyVelocity=Instance.new("BodyVelocity")
  979. bodyVelocity.velocity=vt(0,60,0)
  980. bodyVelocity.P=5000
  981. bodyVelocity.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  982. bodyVelocity.Parent=hit
  983. game:GetService("Debris"):AddItem(bodyVelocity,1)
  984. rl=Instance.new("BodyAngularVelocity")
  985. rl.P=3000
  986. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  987. rl.angularvelocity=Vector3.new(math.random(-30,30),math.random(-30,30),math.random(-30,30))
  988. rl.Parent=hit
  989. game:GetService("Debris"):AddItem(rl,.5)
  990. elseif Type=="Snare" then
  991. bp=Instance.new("BodyPosition")
  992. bp.P=2000
  993. bp.D=100
  994. bp.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  995. bp.position=hit.Parent.Torso.Position
  996. bp.Parent=hit.Parent.Torso
  997. game:GetService("Debris"):AddItem(bp,1)
  998. elseif Type=="Target" then
  999. if Targetting==false then
  1000. ZTarget=hit.Parent.Torso
  1001. coroutine.resume(coroutine.create(function(Part)
  1002. so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  1003. swait(5)
  1004. so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  1005. end),ZTarget)
  1006. TargHum=ZTarget.Parent:findFirstChild("Humanoid")
  1007. targetgui=Instance.new("BillboardGui")
  1008. targetgui.Parent=ZTarget
  1009. targetgui.Size=UDim2.new(10,100,10,100)
  1010. targ=Instance.new("ImageLabel")
  1011. targ.Parent=targetgui
  1012. targ.BackgroundTransparency=1
  1013. targ.Image="rbxassetid://4834067"
  1014. targ.Size=UDim2.new(1,0,1,0)
  1015. cam.CameraType="Scriptable"
  1016. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  1017. dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  1018. workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  1019. Targetting=true
  1020. RocketTarget=ZTarget
  1021. for i=1,Property do
  1022. --while Targetting==true and Humanoid.Health>0 and Character.Parent~=nil do
  1023. if Humanoid.Health>0 and Character.Parent~=nil and TargHum.Health>0 and TargHum.Parent~=nil and Targetting==true then
  1024. swait()
  1025. end
  1026. --workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,Head.CFrame.p+rmdir*100)
  1027. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  1028. dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  1029. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)*cf(0,5,10)*euler(-0.3,0,0)
  1030. end
  1031. Targetting=false
  1032. RocketTarget=nil
  1033. targetgui.Parent=nil
  1034. cam.CameraType="Custom"
  1035. end
  1036. end
  1037. debounce=Instance.new("BoolValue")
  1038. debounce.Name="DebounceHit"
  1039. debounce.Parent=hit.Parent
  1040. debounce.Value=true
  1041. game:GetService("Debris"):AddItem(debounce,Delay)
  1042. c=Instance.new("ObjectValue")
  1043. c.Name="creator"
  1044. c.Value=Player
  1045. c.Parent=h
  1046. game:GetService("Debris"):AddItem(c,.5)
  1047. CRIT=false
  1048. hitDeb=true
  1049. AttackPos=6
  1050. end
  1051. end
  1052.  
  1053. showDamage=function(Char,Dealt,du,Color)
  1054. m=Instance.new("Model")
  1055. m.Name=tostring(Dealt)
  1056. h=Instance.new("Humanoid")
  1057. h.Health=0
  1058. h.MaxHealth=0
  1059. h.Parent=m
  1060. c=Instance.new("Part")
  1061. c.Transparency=0
  1062. c.BrickColor=Color
  1063. c.Name="Head"
  1064. c.TopSurface=0
  1065. c.BottomSurface=0
  1066. c.formFactor="Plate"
  1067. c.Size=Vector3.new(1,.4,1)
  1068. ms=Instance.new("CylinderMesh")
  1069. ms.Scale=Vector3.new(.8,.8,.8)
  1070. if CRIT==true then
  1071. ms.Scale=Vector3.new(1,1.25,1)
  1072. end
  1073. ms.Parent=c
  1074. c.Reflectance=0
  1075. Instance.new("BodyGyro").Parent=c
  1076. c.Parent=m
  1077. if Char:findFirstChild("Head")~=nil then
  1078. c.CFrame=CFrame.new(Char["Head"].CFrame.p+Vector3.new(0,1.5,0))
  1079. elseif Char.Parent:findFirstChild("Head")~=nil then
  1080. c.CFrame=CFrame.new(Char.Parent["Head"].CFrame.p+Vector3.new(0,1.5,0))
  1081. end
  1082. f=Instance.new("BodyPosition")
  1083. f.P=2000
  1084. f.D=100
  1085. f.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  1086. f.position=c.Position+Vector3.new(0,3,0)
  1087. f.Parent=c
  1088. game:GetService("Debris"):AddItem(m,.5+du)
  1089. c.CanCollide=false
  1090. m.Parent=workspace
  1091. c.CanCollide=false
  1092. end
  1093.  
  1094. for i,v in pairs (char:GetChildren()) do if v:IsA("Hat") then
  1095. v:remove()
  1096. end
  1097. end
  1098. local player = game.Players.LocalPlayer
  1099. local pchar = player.Character
  1100. local mouse = player:GetMouse()
  1101. local cam = workspace.CurrentCamera
  1102.  
  1103. local rad = math.rad
  1104.  
  1105. local keysDown = {}
  1106. local flySpeed = 0
  1107. local MAX_FLY_SPEED = 50
  1108.  
  1109. local canFly = false
  1110. local flyToggled = false
  1111.  
  1112. local forward, side = 0, 0
  1113. local lastForward, lastSide = 0, 0
  1114.  
  1115. local floatBP = Instance.new("BodyPosition")
  1116. floatBP.maxForce = Vector3.new(0, math.huge, 0)
  1117. local flyBV = Instance.new("BodyVelocity")
  1118. flyBV.maxForce = Vector3.new(9e9, 9e9, 9e9)
  1119. local turnBG = Instance.new("BodyGyro")
  1120. turnBG.maxTorque = Vector3.new(math.huge, math.huge, math.huge)
  1121. mouse.KeyDown:connect(function(key)
  1122. keysDown[key] = true
  1123.  
  1124. if key == "f" then
  1125. flyToggled = not flyToggled
  1126.  
  1127. if not flyToggled then
  1128. floatBP.Parent = nil
  1129. flyBV.Parent = nil
  1130. turnBG.Parent = nil
  1131. pchar.Torso.Velocity = Vector3.new()
  1132. pchar.Humanoid.PlatformStand = false
  1133. end
  1134. end
  1135.  
  1136. end)
  1137. mouse.KeyUp:connect(function(key)
  1138. keysDown[key] = nil
  1139. end)
  1140. local function updateFly()
  1141.  
  1142. if not flyToggled then return end
  1143.  
  1144. lastForward = forward
  1145. lastSide = side
  1146.  
  1147. forward = 0
  1148. side = 0
  1149.  
  1150. if keysDown.w then
  1151. forward = forward + 1
  1152. end
  1153. if keysDown.s then
  1154. forward = forward - 1
  1155. end
  1156. if keysDown.a then
  1157. side = side - 1
  1158. end
  1159. if keysDown.d then
  1160. side = side + 1
  1161. end
  1162.  
  1163. canFly = (forward ~= 0 or side ~= 0)
  1164.  
  1165. if canFly then
  1166. turnBG.Parent = pchar.Torso
  1167. floatBP.Parent = nil
  1168. flyBV.Parent = pchar.Torso
  1169.  
  1170. flySpeed = flySpeed + 1 + (flySpeed / MAX_FLY_SPEED)
  1171. if flySpeed > MAX_FLY_SPEED then flySpeed = MAX_FLY_SPEED end
  1172. else
  1173. floatBP.position = pchar.Torso.Position
  1174. floatBP.Parent = pchar.Torso
  1175.  
  1176. flySpeed = flySpeed - 1
  1177. if flySpeed < 0 then flySpeed = 0 end
  1178. end
  1179.  
  1180. local camCF = cam.CoordinateFrame
  1181. local in_forward = canFly and forward or lastForward
  1182. local in_side = canFly and side or lastSide
  1183.  
  1184. flyBV.velocity = ((camCF.lookVector * in_forward) + (camCF * CFrame.new(in_side,
  1185. in_forward * 0.2, 0).p) - camCF.p) * flySpeed
  1186.  
  1187. turnBG.cframe = camCF * CFrame.Angles(-rad(forward * (flySpeed / MAX_FLY_SPEED)), 0,
  1188. 0)
  1189. end
  1190.  
  1191. game:service'RunService'.RenderStepped:connect(function()
  1192. if flyToggled then
  1193. pchar.Humanoid.PlatformStand = true
  1194. end
  1195. updateFly()
  1196. end)
  1197. ----------------------------------------------------
  1198. mouse.KeyDown:connect(function(key)
  1199. if key == "e" then
  1200. for i,v in pairs(game.Players:getPlayers()) do
  1201. if v.Name~=char.Name then
  1202. for j,k in pairs(v.Character:GetChildren()) do
  1203. if k:IsA("BasePart") and k.Transparency <= 1 then
  1204. Chakra=Instance.new("SelectionBox",cam)
  1205. Chakra.Color = BrickColor.new("Really blue")
  1206. Chakra.Transparency = .5
  1207. Chakra.Adornee = k
  1208. end
  1209. end
  1210. end
  1211. end
  1212. end
  1213. end)
  1214. ----------------------------------------------------
  1215. mouse.KeyUp:connect(function(key)
  1216. if key == "e" then
  1217. for i, v in pairs(cam:children()) do
  1218. if v:IsA("SelectionBox") then
  1219. v:Destroy()
  1220. end
  1221. end
  1222. end
  1223. end)
  1224. local plrs=game:service"Players"
  1225. local p=plrs.LocalPlayer
  1226. local lam=char["Left Arm"]
  1227. local ram=char["Right Arm"]
  1228. local llg=char["Left Leg"]
  1229. local rlg=char["Right Leg"]
  1230. local hed=char.Head
  1231. local tor=char.Torso
  1232. local Cn=CFrame.new
  1233. local CA=CFrame.Angles
  1234. local hrp=char.HumanoidRootPart
  1235. local mr=math.rad
  1236. local mc=math.cos
  1237. local Vn=Vector3.new
  1238. local wrk=game:service"Workspace"
  1239. local deb=game:service"Debris"
  1240. function nwWld(wp0,wp1,wc0)
  1241. wld = Instance.new("Weld",wp1)
  1242. wld.Part0=wp0
  1243. wld.Part1=wp1
  1244. wld.C0=wc0
  1245. return wld
  1246. end
  1247. function FndHm(flnm)
  1248. for i,v in pairs(flnm:GetChildren()) do
  1249. if v:IsA("Humanoid") then
  1250. return v
  1251. end
  1252. end
  1253. end
  1254. local hum=FndHm(char)
  1255. function get(a)
  1256. local cont={}
  1257. for i,v in pairs(a:GetChildren()) do
  1258. if v==char then
  1259. else
  1260. table.insert(cont,v)
  1261. pcall(function()
  1262. for _,b in pairs(get(v)) do
  1263. table.insert(cont,b)
  1264. end
  1265. end)
  1266. end
  1267. end
  1268. return cont
  1269. end
  1270.  
  1271. --
  1272. function inT(qur,tbl)
  1273. local a=false
  1274. for i,v in pairs(tbl) do
  1275. if v==qur then
  1276. a=true
  1277. break
  1278. else
  1279. a=false
  1280. end
  1281. end
  1282. return a
  1283. end
  1284. function nwPrt(prnt,siz,cf,col)
  1285. local prt=Instance.new("Part")
  1286. prt.Parent=prnt
  1287. prt.FormFactor=3
  1288. prt.Name="Part"
  1289. prt.Size=siz
  1290. prt.CanCollide=false
  1291. prt.Anchored=true
  1292. prt.Locked=true
  1293. prt.TopSurface=0
  1294. prt.BottomSurface=0
  1295. prt:BreakJoints()
  1296. prt.CFrame=cf or CFrame.new(30,10,30)
  1297. prt.Material="SmoothPlastic"
  1298. prt.BrickColor=BrickColor.new(col)
  1299. m=Instance.new("SpecialMesh",prt)
  1300. m.MeshType=6
  1301. return prt
  1302. end
  1303. function newRay(start,face,range,wat)
  1304. local rey=Ray.new(start.p,(face.p-start.p).Unit*range)
  1305. hit,pos=Workspace:FindPartOnRayWithIgnoreList(rey,wat)
  1306. return rey,hit,pos
  1307. end
  1308. function ChakraBeam()
  1309. attack=true
  1310. local sine = 0
  1311. local change = 1
  1312. for i = 0,1,0.005 do
  1313. sine = sine + change
  1314. swait()
  1315. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1316. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1317. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(-50),math.rad(0),math.rad(0)),.05)
  1318. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(0)),.05)
  1319. PoleWeld.C0=clerp(PoleWeld.C0,cf(0,-1,-1)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1320. SphereWeld.C1=clerp(SphereWeld.C1,cf(3,0-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1321. Sphere2Weld.C1=clerp(Sphere2Weld.C1,cf(-3,0-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1322. Sphere3Weld.C1=clerp(Sphere3Weld.C1,cf(-2,-2-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1323. Sphere4Weld.C1=clerp(Sphere4Weld.C1,cf(2,-2-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1324. Sphere5Weld.C1=clerp(Sphere5Weld.C1,cf(0,-4-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1325. end
  1326. local int=0
  1327. local cho=nwPrt(char,Vn(3,3,3),lam.CFrame*Cn(0,-0.7,0),"Really black")
  1328. cho.Transparency=0.2
  1329. cho.Reflectance=0.1
  1330. cho.Mesh.MeshType=3
  1331. deb:AddItem(cho,20)
  1332. local lfx1=nwPrt(char,Vn(1,1,1),cho.CFrame,"Really black")
  1333. lfx1.Transparency=1
  1334. lfx1.Mesh.MeshId="rbxassetid://9982590"
  1335. lfx1.Mesh.Scale=Vn(2,2,2)
  1336. deb:AddItem(lfx1,20)
  1337. local lfx2=nwPrt(char,Vn(1,1,1),cho.CFrame,"Really black")
  1338. lfx2.Transparency=1
  1339. lfx2.Mesh.MeshType=3
  1340. lfx2.Mesh.Scale=Vn(4,4,4)
  1341. deb:AddItem(lfx2,20)
  1342. local bem=nwPrt(wrk,Vn(0.2,cho.Size.X,cho.Size.X),cho.CFrame,"Really black")
  1343. bem.Name="Bem"
  1344. bem.Transparency=0.2
  1345. bem.Reflectance=0.1
  1346. bem.Mesh.MeshType=4
  1347. deb:AddItem(bem,8)
  1348. local ent=0
  1349. local unt=0
  1350. local ant=0
  1351. local ryt={bem}
  1352. for _,v in pairs(plrs:GetChildren()) do
  1353. pcall(function()
  1354. table.insert(ryt,v.Character)
  1355. end)
  1356. end
  1357. for i=1,300,4 do
  1358. ent=ent+1
  1359. int=int+1
  1360. unt=unt+1
  1361. if ent==2 then
  1362. local htd={char,bem}
  1363. local function het(ofs)
  1364. con1=bem.Touched:connect(function(hit) Damagefunc(hit,10,20,math.random(20,40),"Normal",RootPart,.2,1) end)
  1365. local r1,h1,p1=newRay(bem.CFrame*ofs*Cn(-bem.Size.X/2,0,0),cho.CFrame,bem.Size.X+1,htd)
  1366. if h1~=nil and h1.Parent~=nil then
  1367. if h1.Parent:IsA("Model") then
  1368. pcall(function()
  1369. local ht=h1.Parent
  1370. FndHm(ht).Health=FndHm(ht).Health-4
  1371. coroutine.wrap(function()
  1372. local bv=Instance.new("BodyVelocity",ht:FindFirstChild("Torso"))
  1373. bv.maxForce=Vn(math.huge,math.huge,math.huge)
  1374. local hrpasd=hrp.CFrame
  1375. bv.velocity=hrpasd.lookVector
  1376. wait(0.1)
  1377. bv:Destroy()
  1378. end)()
  1379. table.insert(htd,ht)
  1380. het(ofs)
  1381. end)
  1382. if FndHm(h1.Parent)==nil then
  1383. table.insert(htd,h1)
  1384. het(ofs)
  1385. end
  1386. end
  1387. end
  1388. end
  1389. het(Cn(0,1,0))
  1390. het(Cn(0,0,1))
  1391. het(Cn(0,-1,0))
  1392. het(Cn(0,0,-1))
  1393. ent=0
  1394. end
  1395. if unt==8 then
  1396. local fx1=nwPrt(wrk,Vn(0.2,1,1),bem.CFrame*Cn(-bem.Size.X/2,0,0)*CA(0,0,mr(90)),"Really black")
  1397. fx1.Mesh.MeshId="rbxassetid://20329976"
  1398. fx1.Mesh.Scale=Vn(bem.Size.Y,bem.Size.Y,bem.Size.Y)
  1399. deb:AddItem(fx1,1)
  1400. fx1.Transparency=0.6
  1401. table.insert(ryt,fx1)
  1402. local fx2=nwPrt(wrk,Vn(0.2,1,1),bem.CFrame*Cn(bem.Size.X/2,0,0)*CA(0,0,mr(90)),"Really black")
  1403. fx2.Mesh.MeshId="rbxassetid://20329976"
  1404. fx2.Mesh.Scale=Vn(bem.Size.Y,bem.Size.Y,bem.Size.Y)
  1405. deb:AddItem(fx2,1)
  1406. fx2.Transparency=0.6
  1407. table.insert(ryt,fx2)
  1408. coroutine.wrap(function()
  1409. for i=0.8,1,0.02 do
  1410. fx1.Transparency=i
  1411. local fx1s=fx1.Mesh.Scale
  1412. fx1.Mesh.Scale=Vn(fx1s.X+0.2,fx1s.Y+0.2,fx1s.Z+0.2)
  1413. fx2.Transparency=i
  1414. local fx2s=fx2.Mesh.Scale
  1415. fx2.Mesh.Scale=Vn(fx2s.X+0.2,fx2s.Y+0.2,fx2s.Z+0.2)
  1416. wait()
  1417. end
  1418. fx1:Destroy()
  1419. fx2:Destroy()
  1420. end)()
  1421. unt=0
  1422. end
  1423. local function chk()
  1424. local r2,h2,p2=newRay(bem.CFrame*Cn(-bem.Size.X/2,0,0),cho.CFrame,bem.Size.X,ryt)
  1425. if h2~=nil then
  1426. if h2.Parent~=nil then
  1427. if FndHm(h2.Parent)==nil then
  1428. bem.Size=Vn(((bem.CFrame*Cn(-bem.Size.X/2,0,0)).p-p2).magnitude,bem.Size.Y,bem.Size.Z)
  1429. if h2.Name=="Bem" and unt==7 then
  1430. local p1=nwPrt(bem,Vn(1,5,5),bem.CFrame*Cn(bem.Size.X/2-2,0,0)*CA(0,mr(90),0),"Bright blue")
  1431. p1.Anchored=true
  1432. p1.Transparency=0.6
  1433. local m1=p1.Mesh
  1434. m1.MeshId="rbxassetid://3270017"
  1435. local p2=nwPrt(bem,Vn(1,5,5),bem.CFrame*Cn(bem.Size.X/2-2,0,0)*CA(0,mr(90),0),"Bright blue")
  1436. p2.Anchored=true
  1437. p2.Transparency=0.6
  1438. local m2=p2.Mesh
  1439. m2.MeshId="rbxassetid://3270017"
  1440. m2.Scale=Vector3.new(0.1,0.1,0.1)
  1441. local p3=nwPrt(bem,Vn(1,5,5),bem.CFrame*Cn(bem.Size.X/2-2,0,0)*CA(0,mr(90),0),"Bright blue")
  1442. p3.Anchored=true
  1443. p3.Transparency=0.6
  1444. local m3=p3.Mesh
  1445. m3.MeshId="rbxassetid://3270017"
  1446. m3.Scale=Vector3.new(2,2,2)
  1447. deb:AddItem(p1,5)
  1448. deb:AddItem(p2,5)
  1449. deb:AddItem(p3,5)
  1450. coroutine.wrap(function()
  1451. for i=1,200 do
  1452. m1.Scale=Vector3.new(m1.Scale.X+1,m1.Scale.Y+1,m1.Scale.Z+0.5)
  1453. m2.Scale=Vector3.new(m2.Scale.X+1.25,m2.Scale.Y+1.25,m2.Scale.Z+0.5)
  1454. m3.Scale=Vector3.new(m3.Scale.X+0.75,m3.Scale.Y+0.75,m3.Scale.Z+0.5)
  1455. p1.Transparency=p1.Transparency+0.03
  1456. p2.Transparency=p2.Transparency+0.035
  1457. p3.Transparency=p3.Transparency+0.025
  1458. wait()
  1459. end
  1460. end)()
  1461. end
  1462. else
  1463. table.insert(ryt,h2.Parent)
  1464. chk()
  1465. end
  1466. end
  1467. else
  1468. bem.Size=Vn(bem.Size.X+4,bem.Size.Y,bem.Size.Z)
  1469. end
  1470. end
  1471. chk()
  1472. bem.CFrame=hrp.CFrame*Cn(-1.5,0.3,-1.2-bem.Size.X/2)*CA(0,mr(90),0)
  1473. lfx1.Mesh.Scale=Vn(2+(1*mc(int/18)),2+(1*mc(int/18)),2+(1*mc(int/18)))
  1474. lfx2.Mesh.Scale=Vn(4+(3*mc(int/18)),4+(3*mc(int/18)),4+(3*mc(int/18)))
  1475. lfx1.CFrame=cho.CFrame*CA(mr(10*mc(int/20)),mr(10*mc(int/20)),mr(10*mc(int/20)))
  1476. lfx2.CFrame=cho.CFrame*CA(mr(10*mc(int/18)),mr(10*mc(int/18)),mr(10*mc(int/18)))
  1477. wait()
  1478. end
  1479. pcall(function()
  1480. bem:Destroy()
  1481. cho:Destroy()
  1482. lfx1:Destroy()
  1483. lfx2:Destroy()
  1484. end)
  1485. attack=false
  1486. con1:disconnect()
  1487. end
  1488. function fadein(part)
  1489. part.Transparency=1
  1490. for i=1,100 do
  1491. wait()
  1492. part.Transparency = part.Transparency - 0.01
  1493. end
  1494. end
  1495.  
  1496. function ChakraBall()
  1497. attack=true
  1498. local sine = 0
  1499. local change = 1
  1500. for i = 0,1,0.005 do
  1501. sine = sine + change
  1502. swait()
  1503. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1504. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1505. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(-50),math.rad(0),math.rad(0)),.05)
  1506. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(0)),.05)
  1507. PoleWeld.C0=clerp(PoleWeld.C0,cf(0,-1,-1)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1508. SphereWeld.C1=clerp(SphereWeld.C1,cf(3,0-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1509. Sphere2Weld.C1=clerp(Sphere2Weld.C1,cf(-3,0-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1510. Sphere3Weld.C1=clerp(Sphere3Weld.C1,cf(-2,-2-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1511. Sphere4Weld.C1=clerp(Sphere4Weld.C1,cf(2,-2-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1512. Sphere5Weld.C1=clerp(Sphere5Weld.C1,cf(0,-4-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1513. end
  1514. FireBall=Instance.new('Part',Workspace)
  1515. FireBall.Size=Vector3.new(3,3,3)
  1516. FireBall.BrickColor=BrickColor.new("Really black")
  1517. FireBall.CanCollide = True
  1518. FireBall.TopSurface = "Smooth"
  1519. FireBall.BottomSurface = "Smooth"
  1520. FireBall.Position=torso.Position+torso.CFrame.lookVector*20
  1521. FireBall.Transparency = 0
  1522. FireBall.Reflectance = 0.3
  1523. FireBall:BreakJoints()
  1524. FireBallMesh = Instance.new("SpecialMesh", FireBall)
  1525. FireBallMesh.MeshType = "Sphere"
  1526. FireBallMesh.Scale = Vector3.new(1,1,1)
  1527. Shooter = Instance.new('BodyVelocity',FireBall)
  1528. Shooter.maxForce = Vector3.new()*math.huge
  1529. Shooter.velocity = torso.CFrame.lookVector*100
  1530. con1=FireBall.Touched:connect(function(hit) Damagefunc(hit,10,20,math.random(20,40),"Normal",RootPart,.2,1) end)
  1531. wait(5)
  1532. FireBall:Destroy()
  1533. con1:disconnect()
  1534. attack=false
  1535. end
  1536. function InfiniteTsukyomi()
  1537. attack = true
  1538. for i = 0,1,0.005 do
  1539. swait()
  1540. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,100)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1541. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1542. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(-50)),.05)
  1543. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(50)),.05)
  1544. PoleWeld.C0=clerp(PoleWeld.C0,cf(0,10,0)*angles(math.rad(20),math.rad(100),math.rad(40)),.05)
  1545. end
  1546. Head.face.Texture = "http://www.roblox.com/asset?id=159181532"
  1547. game.Lighting.TimeOfDay = "07:00:00"
  1548. game.Lighting.Ambient = Color3.new(0,0,0)
  1549. sky = Instance.new("Sky")
  1550. sky.Parent = game.Lighting
  1551. sky.SkyboxBk = "http://www.roblox.com/asset/?id=22079760"
  1552. sky.SkyboxDn = "http://www.roblox.com/asset/?id=22079760"
  1553. sky.SkyboxFt = "http://www.roblox.com/asset/?id=22079760"
  1554. sky.SkyboxLf = "http://www.roblox.com/asset/?id=22079760"
  1555. sky.SkyboxRt = "http://www.roblox.com/asset/?id=22079760"
  1556. sky.SkyboxUp = "http://www.roblox.com/asset/?id=22079760"
  1557. attack=false
  1558. end
  1559.  
  1560. attacktype=1
  1561. mouse.Button1Down:connect(function()
  1562. if attacktype == 1 then
  1563. print("You can't attack with your staff yet!")
  1564. end
  1565. end)
  1566.  
  1567. colours = {"Tr. Red","Black","Tr. Blue","Black","Phosph. White","Royal purple"}
  1568. mouse.KeyDown:connect(function(k)
  1569. k:lower()
  1570. if k=="r" and attack == false then
  1571. ChakraBeam()
  1572. end
  1573. if k=="q" and attack == false then
  1574. ChakraBall()
  1575. end
  1576. if k=="p" and attack == false then
  1577. InfiniteTsukyomi()
  1578. end
  1579. if k==" " and attack == false then
  1580. Humanoid.Jump = false
  1581. Torso.Velocity = Vector3.new(0,100,0)
  1582. end
  1583. end)
  1584. function Tween(a,b,c)
  1585. return a+(b-a)*c
  1586. end
  1587.  
  1588. --
  1589. function Avg(a,b)
  1590. return CFrame.new((a.X+b.X)/2,(a.Y+b.Y)/2,(a.Z+b.Z)/2)
  1591. end
  1592.  
  1593. --
  1594. function Lerp(c1,c2,tim)
  1595. local com1={c1.C0.X,c1.C0.Y,c1.C0.Z,c1.C0:toEulerAnglesXYZ()}
  1596. local com2={c2.X,c2.Y,c2.Z,c2:toEulerAnglesXYZ()}
  1597. for i,v in pairs(com1) do
  1598. com1[i]=v+(com2[i]-v)*tim
  1599. end
  1600. return Cn(com1[1],com1[2],com1[3])*CA(select(4,unpack(com1)))
  1601. end
  1602. hld=false
  1603. mouse.KeyDown:connect(function(key)
  1604. key:lower()
  1605. if key == "t" and attack == false then
  1606. attack = true
  1607. hld=true
  1608. for i = 0,1,0.005 do
  1609. swait()
  1610. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.03)
  1611. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),.03)
  1612. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(-50)),.03)
  1613. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(50)),.03)
  1614. PoleWeld.C0=clerp(PoleWeld.C0,cf(10,0,0)*angles(math.rad(100),math.rad(10),math.rad(40)),.03)
  1615. end
  1616. local cho=nwPrt(char,Vn(1,1,1),ram.CFrame*Cn(0,-0.7,0),"Really black")
  1617. cho.Transparency=0.2
  1618. cho.Reflectance=0.1
  1619. cho.Mesh.MeshType=3
  1620. deb:AddItem(cho,20)
  1621. local lfx1=nwPrt(char,Vn(1,1,1),cho.CFrame,"Really black")
  1622. lfx1.Transparency=0.985
  1623. lfx1.Mesh.MeshId="rbxassetid://9982590"
  1624. lfx1.Mesh.Scale=Vn(2,2,2)
  1625. deb:AddItem(lfx1,20)
  1626. local lfx2=nwPrt(char,Vn(1,1,1),cho.CFrame,"Really black")
  1627. lfx2.Transparency=0.9
  1628. lfx2.Mesh.MeshType=3
  1629. lfx2.Mesh.Scale=Vn(4,4,4)
  1630. deb:AddItem(lfx2,20)
  1631. local int=0
  1632. while hld==true do
  1633. int=int+1
  1634. if cho.Size.X<30 then
  1635. local chs=cho.Size
  1636. cho.Size=Vn(chs.X+0.01,chs.Y+0.01,chs.Z+0.01)
  1637. cho.CFrame=ram.CFrame*Cn(0,-1.4,0)
  1638. else
  1639. cho.CFrame=ram.CFrame*Cn(0,-1.4,0)
  1640. end
  1641. cho.Mesh.Scale=Vn(1+(0.05*mc(int/6)),1+(0.05*mc(int/6)),1+(0.05*mc(int/6)))
  1642. lfx1.Mesh.Scale=Vn(2+(1*mc(int/18)),2+(1*mc(int/18)),2+(1*mc(int/18)))
  1643. lfx2.Mesh.Scale=Vn(4+(3*mc(int/18)),4+(3*mc(int/18)),4+(3*mc(int/18)))
  1644. lfx1.CFrame=cho.CFrame*CA(mr(10*mc(int/20)),mr(10*mc(int/20)),mr(10*mc(int/20)))
  1645. lfx2.CFrame=cho.CFrame*CA(mr(10*mc(int/18)),mr(10*mc(int/18)),mr(10*mc(int/18)))
  1646. if int>300 then
  1647. hld=false
  1648. end
  1649. wait()
  1650. end
  1651. for i=1,6 do
  1652. int=int+1
  1653. cho.CFrame=ram.CFrame*Cn(-0.2,-1.4,0)
  1654. lfx1.Mesh.Scale=Vn(2+(1*mc(int/18)),2+(1*mc(int/18)),2+(1*mc(int/18)))
  1655. lfx2.Mesh.Scale=Vn(4+(3*mc(int/18)),4+(3*mc(int/18)),4+(3*mc(int/18)))
  1656. lfx1.CFrame=cho.CFrame*CA(mr(10*mc(int/20)),mr(10*mc(int/20)),mr(10*mc(int/20)))
  1657. lfx2.CFrame=cho.CFrame
  1658. wait()
  1659. end
  1660. local bem=nwPrt(wrk,Vn(0.2,cho.Size.X,cho.Size.X),hrp.CFrame*Cn(0,0.3,-1.4)*CA(0,mr(90),0),"Really black")
  1661. bem.Name="Bem"
  1662. bem.Transparency=0.2
  1663. bem.Reflectance=0.1
  1664. bem.Mesh.MeshType=4
  1665. deb:AddItem(bem,8)
  1666. local ent=0
  1667. local unt=0
  1668. local ant=0
  1669. local ryt={bem}
  1670. for _,v in pairs(plrs:GetChildren()) do
  1671. pcall(function()
  1672. table.insert(ryt,v.Character)
  1673. end)
  1674. end
  1675. for i=1,850,4 do
  1676. ent=ent+1
  1677. int=int+1
  1678. unt=unt+1
  1679. if ent==2 then
  1680. local htd={char,bem}--This is the table
  1681. local function het(ofs)
  1682. local r1,h1,p1=newRay(bem.CFrame*ofs*Cn(-bem.Size.X/2,0,0),bem.CFrame*ofs*Cn(1,0,0),bem.Size.X+1,htd)--The end variable is the table
  1683. if h1~=nil and h1.Parent~=nil then
  1684. if h1.Parent:IsA("Model") then
  1685. pcall(function()
  1686. local ht=h1.Parent
  1687. FndHm(ht).Health=FndHm(ht).Health-(cho.Size.X)
  1688. coroutine.wrap(function()
  1689. local bv=Instance.new("BodyVelocity",ht:FindFirstChild("Torso"))
  1690. bv.maxForce=Vn(math.huge,math.huge,math.huge)
  1691. local hrpasd=hrp.CFrame
  1692. bv.velocity=hrpasd.lookVector * 100
  1693. wait(0.1)
  1694. bv:Destroy()
  1695. end)()
  1696. table.insert(htd,ht)
  1697. het(ofs)
  1698. end)
  1699. if FndHm(h1.Parent)==nil then
  1700. table.insert(htd,h1)
  1701. het(ofs)
  1702. end
  1703. end
  1704. end
  1705. end
  1706. het(Cn(0,1,0))
  1707. het(Cn(0,0,1))
  1708. het(Cn(0,-1,0))
  1709. het(Cn(0,0,-1))
  1710. ent=0
  1711. end
  1712. if unt==44 then
  1713. local fx1=nwPrt(wrk,Vn(0.2,1,1),bem.CFrame*Cn(-bem.Size.X/2,0,0)*CA(0,0,mr(90)),"Really black")
  1714. fx1.Mesh.MeshId="rbxassetid://20329976"
  1715. fx1.Mesh.Scale=Vn(bem.Size.Y,bem.Size.Y,bem.Size.Y)
  1716. deb:AddItem(fx1,1)
  1717. fx1.Transparency=0.6
  1718. table.insert(ryt,fx1)
  1719. local fx2=nwPrt(wrk,Vn(0.2,1,1),bem.CFrame*Cn(bem.Size.X/2,0,0)*CA(0,0,mr(90)),"Really black")
  1720. fx2.Mesh.MeshId="rbxassetid://20329976"
  1721. fx2.Mesh.Scale=Vn(bem.Size.Y,bem.Size.Y,bem.Size.Y)
  1722. deb:AddItem(fx2,1)
  1723. fx2.Transparency=0.6
  1724. table.insert(ryt,fx2)
  1725. coroutine.wrap(function()
  1726. for i=0.8,1,0.02 do
  1727. fx1.Transparency=i
  1728. local fx1s=fx1.Mesh.Scale
  1729. fx1.Mesh.Scale=Vn(fx1s.X+0.2,fx1s.Y+0.2,fx1s.Z+0.2)
  1730. fx2.Transparency=i
  1731. local fx2s=fx2.Mesh.Scale
  1732. fx2.Mesh.Scale=Vn(fx2s.X+0.2,fx2s.Y+0.2,fx2s.Z+0.2)
  1733. wait()
  1734. end
  1735. fx1:Destroy()
  1736. fx2:Destroy()
  1737. end)()
  1738. unt=0
  1739. end
  1740. local function chk()
  1741. local r2,h2,p2=newRay(bem.CFrame*Cn(-bem.Size.X/2,0,0),bem.CFrame*Cn(1,0,0),bem.Size.X,ryt)
  1742. if h2~=nil then
  1743. if h2.Parent~=nil then
  1744. if FndHm(h2.Parent)==nil then
  1745. bem.Size=Vn(((bem.CFrame*Cn(-bem.Size.X/2,0,0)).p-p2).magnitude,bem.Size.Y,bem.Size.Z)
  1746. if h2.Name=="Bem" and unt==7 then
  1747. local p1=nwPrt(bem,Vn(1,5,5),bem.CFrame*Cn(bem.Size.X/2-2,0,0)*CA(0,mr(90),0),"Really black")
  1748. p1.Anchored=true
  1749. p1.Transparency=0.6
  1750. local m1=p1.Mesh
  1751. m1.MeshId="rbxassetid://3270017"
  1752. local p2=nwPrt(bem,Vn(1,5,5),bem.CFrame*Cn(bem.Size.X/2-2,0,0)*CA(0,mr(90),0),"Really black")
  1753. p2.Anchored=true
  1754. p2.Transparency=0.6
  1755. local m2=p2.Mesh
  1756. m2.MeshId="rbxassetid://3270017"
  1757. m2.Scale=Vector3.new(0.1,0.1,0.1)
  1758. local p3=nwPrt(bem,Vn(1,5,5),bem.CFrame*Cn(bem.Size.X/2-2,0,0)*CA(0,mr(90),0),"Really black")
  1759. p3.Anchored=true
  1760. p3.Transparency=0.6
  1761. local m3=p3.Mesh
  1762. m3.MeshId="rbxassetid://3270017"
  1763. m3.Scale=Vector3.new(2,2,2)
  1764. deb:AddItem(p1,5)
  1765. deb:AddItem(p2,5)
  1766. deb:AddItem(p3,5)
  1767. coroutine.wrap(function()
  1768. for i=1,200 do
  1769. m1.Scale=Vector3.new(m1.Scale.X+1,m1.Scale.Y+1,m1.Scale.Z+0.5)
  1770. m2.Scale=Vector3.new(m2.Scale.X+1.25,m2.Scale.Y+1.25,m2.Scale.Z+0.5)
  1771. m3.Scale=Vector3.new(m3.Scale.X+0.75,m3.Scale.Y+0.75,m3.Scale.Z+0.5)
  1772. p1.Transparency=p1.Transparency+0.03
  1773. p2.Transparency=p2.Transparency+0.035
  1774. p3.Transparency=p3.Transparency+0.025
  1775. wait()
  1776. end
  1777. end)()
  1778. end
  1779. else
  1780. table.insert(ryt,h2.Parent)
  1781. chk()
  1782. end
  1783. end
  1784. else
  1785. bem.Size=Vn(bem.Size.X+4,bem.Size.Y,bem.Size.Z)
  1786. end
  1787. end
  1788. chk()
  1789. bem.CFrame=hrp.CFrame*Cn(0,0.3,-1.2-bem.Size.X/2)*CA(0,mr(90),0)
  1790. lfx1.Mesh.Scale=Vn(2+(1*mc(int/18)),2+(1*mc(int/18)),2+(1*mc(int/18)))
  1791. lfx2.Mesh.Scale=Vn(4+(3*mc(int/18)),4+(3*mc(int/18)),4+(3*mc(int/18)))
  1792. lfx1.CFrame=cho.CFrame*CA(mr(10*mc(int/20)),mr(10*mc(int/20)),mr(10*mc(int/20)))
  1793. lfx2.CFrame=cho.CFrame*CA(mr(10*mc(int/18)),mr(10*mc(int/18)),mr(10*mc(int/18)))
  1794. wait()
  1795. end
  1796. pcall(function()
  1797. bem:Destroy()
  1798. cho:Destroy()
  1799. lfx1:Destroy()
  1800. lfx2:Destroy()
  1801. end)
  1802. attack=false
  1803. end
  1804. end)
  1805. mouse.KeyUp:connect(function(key)
  1806. key:lower()
  1807. if key == "t" then
  1808. hld=false
  1809. end
  1810. end)
  1811. mouse.KeyDown:connect(function(key)
  1812. key:lower()
  1813. if key:byte() == 48 then
  1814. Humanoid.WalkSpeed=70
  1815. end
  1816. end)
  1817. mouse.KeyUp:connect(function(key)
  1818. key:lower()
  1819. if key:byte() == 48 then
  1820. Humanoid.WalkSpeed=6
  1821. end
  1822. end)
  1823.  
  1824. Humanoid.WalkSpeed=6
  1825. local sine = 0
  1826. local change = 1
  1827. local val = 0
  1828. --game:GetService("RunService").Heartbeat:connect(function()
  1829. while true do
  1830. swait()
  1831. sine = sine + change
  1832. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1833. local velderp=RootPart.Velocity.y
  1834. hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1835. if equipped==true or equipped==false then
  1836. if attack==false then
  1837. idle=idle+1
  1838. else
  1839. idle=0
  1840. end
  1841. if idle>=500 then
  1842. if attack==false then
  1843. --Sheath()
  1844. end
  1845. end
  1846. if RootPart.Velocity.y > 1 and hitfloor==nil then
  1847. Anim="Jump"
  1848. if attack==false then
  1849. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(10),math.rad(0),math.rad(0)),.3)
  1850. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(-20),math.rad(0),math.rad(0)),.3)
  1851. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(-50),math.rad(-100),math.rad(30)),.3)
  1852. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(-50),math.rad(100),math.rad(-30)),.3)
  1853. lleg.Weld.C0=clerp(lleg.Weld.C0,cf(-0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1854. rleg.Weld.C0=clerp(rleg.Weld.C0,cf(0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1855. PoleWeld.C0 =clerp(PoleWeld.C0,CFrame.new(0,-1,-0.65)*CFrame.Angles(math.rad(-90),math.rad(90),0),.05)
  1856. end
  1857. elseif RootPart.Velocity.y < -1 and hitfloor==nil then
  1858. Anim="Fall"
  1859. if attack==false then
  1860. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(10),math.rad(0),math.rad(0)),.3)
  1861. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
  1862. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(-50),math.rad(-100),math.rad(30)),.3)
  1863. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(-50),math.rad(100),math.rad(-30)),.3)
  1864. lleg.Weld.C0=clerp(lleg.Weld.C0,cf(-0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1865. rleg.Weld.C0=clerp(rleg.Weld.C0,cf(0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1866. PoleWeld.C0 =clerp(PoleWeld.C0,CFrame.new(0,-1,-0.65)*CFrame.Angles(math.rad(-90),math.rad(90),0),.05)
  1867. end
  1868. elseif torvel<1 and hitfloor~=nil then
  1869. Anim="Idle"
  1870. if attack==false then
  1871. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,1-0.14*math.cos(sine/14))*angles(math.rad(0),math.rad(0),math.rad(20)),.05)
  1872. SphereWeld.C1=clerp(SphereWeld.C1,cf(3,0-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1873. Sphere2Weld.C1=clerp(Sphere2Weld.C1,cf(-3,0-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1874. Sphere3Weld.C1=clerp(Sphere3Weld.C1,cf(-2,-2-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1875. Sphere4Weld.C1=clerp(Sphere4Weld.C1,cf(2,-2-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1876. Sphere5Weld.C1=clerp(Sphere5Weld.C1,cf(0,-4-0.14*math.cos(-sine/14),0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1877. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(-20)),.05)
  1878. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(20)),.05)
  1879. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(-10),math.rad(0),math.rad(-10)),.05)
  1880. lleg.Weld.C0=clerp(lleg.Weld.C0,cf(-0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1881. rleg.Weld.C0=clerp(rleg.Weld.C0,cf(0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1882. PoleWeld.C0 =clerp(PoleWeld.C0,CFrame.new(0,-1,-0.65)*CFrame.Angles(math.rad(-90),math.rad(90),0),.05)
  1883. end
  1884. elseif torvel>2 and torvel<22 and hitfloor~=nil then
  1885. Anim="Walk"
  1886. if attack==false then
  1887. change=3
  1888. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,1-0.14*math.cos(sine/14))*angles(math.rad(0),math.rad(0),math.rad(0)),.05)
  1889. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(10),math.rad(0),math.rad(0)),.3)
  1890. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(-20),math.rad(0),math.rad(10)),.3)
  1891. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(-20),math.rad(0),math.rad(-10)),.3)
  1892. lleg.Weld.C0=clerp(lleg.Weld.C0,cf(-0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1893. rleg.Weld.C0=clerp(rleg.Weld.C0,cf(0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1894. PoleWeld.C0 =clerp(PoleWeld.C0,CFrame.new(0,-1,-0.65)*CFrame.Angles(math.rad(-90),math.rad(90),0),.05)
  1895. end
  1896. elseif torvel>=22 and hitfloor~=nil then
  1897. Anim="Run"
  1898. if attack==false then
  1899. change=5
  1900. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,1-0.14*math.cos(sine/14))*angles(math.rad(20),math.rad(0),math.rad(0)),.3)
  1901. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
  1902. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(math.rad(-20),math.rad(-100),math.rad(30)),.3)
  1903. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(-20),math.rad(100),math.rad(-30)),.3)
  1904. lleg.Weld.C0=clerp(lleg.Weld.C0,cf(-0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1905. rleg.Weld.C0=clerp(rleg.Weld.C0,cf(0.5,-1,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1906. PoleWeld.C0 =clerp(PoleWeld.C0,CFrame.new(0,-1,-0.65)*CFrame.Angles(math.rad(-90),math.rad(90),0),.05)
  1907. end
  1908. end
  1909. end
  1910. end
  1911. --end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement