Advertisement
voidman

Untitled

Dec 27th, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 61.47 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.  
  8. if script.Parent~=game.Workspace then
  9. script.Parent=game.Workspace
  10. script.Disabled=false
  11. end
  12.  
  13.  
  14. --New boss for Black Magic
  15. it=Instance.new
  16. vt=Vector3.new
  17. cf=CFrame.new
  18. euler=CFrame.fromEulerAnglesXYZ
  19. angles=CFrame.Angles
  20. if workspace:findFirstChild("Vanta",true) ~= nil then
  21. workspace:findFirstChild("Vanta",true).Parent = nil
  22. end
  23. function NoOutline(Part)
  24. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  25. end
  26. function swait(num)
  27. if num==0 or num==nil then
  28. game:service'RunService'.RenderStepped:wait()
  29. else
  30. for i=0,num do
  31. game:service'RunService'.RenderStepped:wait()
  32. end
  33. end
  34. end
  35. function part(formfactor,parent,reflectance,transparency,brickcolor,name,size)
  36. local fp=it("Part")
  37. fp.formFactor=formfactor
  38. fp.Parent=parent
  39. fp.Reflectance=reflectance
  40. fp.Transparency=transparency
  41. fp.CanCollide=false
  42. fp.Locked=true
  43. fp.BrickColor=brickcolor
  44. fp.Name=name
  45. fp.Size=size
  46. NoOutline(fp)
  47. fp.Material="SmoothPlastic"
  48. fp:BreakJoints()
  49. return fp
  50. end
  51. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  52. local mesh=it(Mesh)
  53. mesh.Parent=part
  54. if Mesh=="SpecialMesh" then
  55. mesh.MeshType=meshtype
  56. mesh.MeshId=meshid
  57. end
  58. mesh.Offset=offset
  59. mesh.Scale=scale
  60. return mesh
  61. end
  62. function weld(parent,part0,part1,c0)
  63. local weld=it("Weld")
  64. weld.Parent=parent
  65. weld.Part0=part0
  66. weld.Part1=part1
  67. weld.C0=c0
  68. return weld
  69. end
  70. local Character=Instance.new("Model")
  71. Character.Parent=workspace
  72. Character.Name="Vanta"
  73. local Head=part(0,Character,0,1,BrickColor.new("Black"),"Head",vt(2,1,1))
  74. local Torso=part(0,Character,0,1,BrickColor.new("Black"),"Torso",vt(2,2,1))
  75. local LeftArm=part(0,Character,0,1,BrickColor.new("Black"),"Left Arm",vt(1,2,1))
  76. local RightArm=part(0,Character,0,1,BrickColor.new("Black"),"Right Arm",vt(1,2,1))
  77. local LeftLeg=part(0,Character,0,1,BrickColor.new("Black"),"Left Leg",vt(1,2,1))
  78. local RightLeg=part(0,Character,0,1,BrickColor.new("Black"),"Right Leg",vt(1,2,1))
  79. local RootPart=part(0,Character,0,1,BrickColor.new("White"),"HumanoidRootPart",vt(2,2,1))
  80. Head.CanCollide=true
  81. Torso.CanCollide=true
  82. LeftArm.CanCollide=true
  83. RightArm.CanCollide=true
  84. LeftLeg.CanCollide=true
  85. RightLeg.CanCollide=true
  86. RootPart.CanCollide=false
  87. local HMesh=mesh("SpecialMesh",Head,"Head","",vt(0,0,0),vt(1.25,1.25,1.25))
  88. --[[local Neck=weld(Torso,Torso,Head,cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0))
  89. Neck.C1=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)]]
  90. local Neck=weld(Torso,Torso,Head,cf(0,1,0))
  91. Neck.C1=cf(0,-0.5,0)
  92. local RW=weld(Torso,Torso,RightArm,cf(1.5,0.5,0))
  93. RW.C1=cf(0,0.5,0)
  94. local LW=weld(Torso,Torso,LeftArm,cf(-1.5,0.5,0))
  95. LW.C1=cf(0,0.5,0)
  96. local RH=weld(Torso,Torso,RightLeg,cf(0.5,-1,0))
  97. RH.C1=cf(0,1,0)
  98. local LH=weld(Torso,Torso,LeftLeg,cf(-0.5,-1,0))
  99. LH.C1=cf(0,1,0)
  100. local RootJoint=weld(Torso,Torso,RootPart,cf(0,0,0))
  101. local Humanoid=Instance.new("Humanoid")
  102. Humanoid.Parent=Character
  103. Humanoid.MaxHealth=math.huge
  104. Humanoid.Health=math.huge
  105. coroutine.resume(coroutine.create(function()
  106. for i=1,20 do
  107. Humanoid.Health=Humanoid.MaxHealth
  108. end
  109. Humanoid:TakeDamage(1)
  110. end))
  111. local MainPosition=workspace.Baseplate.CFrame*cf(0,100,0)*euler(0,1.57,0)
  112. Torso.CFrame=MainPosition
  113. local Mode=Instance.new("IntValue")
  114. Mode.Parent=Character
  115. Mode.Value=2
  116. Mode.Name="ModeValue"
  117. so = function(id,par,vol,pit)
  118. coroutine.resume(coroutine.create(function()
  119. local sou = Instance.new("Sound",par or workspace)
  120. sou.Volume=vol
  121. sou.Pitch=pit or 1
  122. sou.SoundId=id
  123. wait()
  124. sou:play()
  125. game:GetService("Debris"):AddItem(sou,6)
  126. end))
  127. end
  128. function MagicBlock(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  129. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  130. prt.Anchored=true
  131. prt.CFrame=cframe
  132. msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  133. game:GetService("Debris"):AddItem(prt,2)
  134. coroutine.resume(coroutine.create(function(Part,Mesh)
  135. for i=0,1,delay do
  136. wait()
  137. Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  138. Part.Transparency=i
  139. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  140. end
  141. Part.Parent=nil
  142. end),prt,msh)
  143. end
  144. function MagicBlock2(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  145. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  146. prt.Anchored=true
  147. prt.CFrame=cframe
  148. msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  149. game:GetService("Debris"):AddItem(prt,2)
  150. coroutine.resume(coroutine.create(function(Part,Mesh)
  151. for i=0,1,delay do
  152. wait()
  153. Part.Transparency=i
  154. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  155. end
  156. Part.Parent=nil
  157. end),prt,msh)
  158. end
  159. function MagicCircle(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  160. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  161. prt.Anchored=true
  162. prt.CFrame=cframe
  163. local msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
  164. game:GetService("Debris"):AddItem(prt,2)
  165. coroutine.resume(coroutine.create(function(Part,Mesh)
  166. local wld=nil
  167. for i=0,1,delay do
  168. wait()
  169. Part.CFrame=Part.CFrame
  170. Part.Transparency=i
  171. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  172. end
  173. Part.Parent=nil
  174. end),prt,msh)
  175. end
  176. function MagicCircle2(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  177. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
  178. prt.Anchored=true
  179. prt.CFrame=cframe
  180. local msh=mesh("CylinderMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  181. game:GetService("Debris"):AddItem(prt,5)
  182. coroutine.resume(coroutine.create(function(Part,Mesh)
  183. for i=0,1,delay do
  184. wait()
  185. Part.CFrame=Part.CFrame
  186. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  187. local prt2=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
  188. prt2.Anchored=true
  189. prt2.CFrame=cframe*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  190. local msh2=mesh("SpecialMesh",prt2,"Sphere","",vt(0,0,0),vt(0.5,0.5,0.5))
  191. game:GetService("Debris"):AddItem(prt2,2)
  192. coroutine.resume(coroutine.create(function(Part,Mesh)
  193. for i=0,1,0.05 do
  194. wait()
  195. Part.CFrame=Part.CFrame*cf(0,0.5,0)
  196. end
  197. Part.Parent=nil
  198. end),prt2,msh2)
  199. end
  200. for i=0,1,delay do
  201. wait()
  202. Part.CFrame=Part.CFrame
  203. Part.Transparency=i
  204. Mesh.Scale=Mesh.Scale-vt(x3,y3,z3)
  205. end
  206. Part.Parent=nil
  207. end),prt,msh)
  208. end
  209. function MagicCrystal(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  210. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  211. prt.Anchored=true
  212. prt.CFrame=cframe
  213. local msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=9756362",vt(0,0,0),vt(x1,y1,z1))
  214. game:GetService("Debris"):AddItem(prt,4)
  215. coroutine.resume(coroutine.create(function(Part,Mesh)
  216. local wld=nil
  217. for i=0,1,delay do
  218. wait()
  219. Part.CFrame=Part.CFrame
  220. Part.Transparency=i
  221. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  222. end
  223. Part.Parent=nil
  224. end),prt,msh)
  225. end
  226. function MagicCylinder(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  227. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.2,0.2,0.2))
  228. prt.Anchored=true
  229. prt.CFrame=cframe
  230. msh=mesh("SpecialMesh",prt,"Head","",vt(0,0,0),vt(x1,y1,z1))
  231. game:GetService("Debris"):AddItem(prt,5)
  232. coroutine.resume(coroutine.create(function(Part,Mesh)
  233. for i=0,1,delay do
  234. wait()
  235. Part.CFrame=Part.CFrame
  236. Part.Transparency=i
  237. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  238. end
  239. Part.Parent=nil
  240. end),prt,msh)
  241. end
  242. function MagicRing(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  243. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
  244. prt.Anchored=true
  245. prt.CFrame=cframe
  246. msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=3270017",vt(0,0,0),vt(x1,y1,z1))
  247. game:GetService("Debris"):AddItem(prt,5)
  248. coroutine.resume(coroutine.create(function(Part,Mesh)
  249. for i=0,1,delay do
  250. wait()
  251. Part.CFrame=Part.CFrame
  252. Part.Transparency=i
  253. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  254. end
  255. Part.Parent=nil
  256. end),prt,msh)
  257. end
  258. function MagicWaveThing(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  259. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
  260. prt.Anchored=true
  261. prt.CFrame=cframe
  262. msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=1051557",vt(0,0,0),vt(x1,y1,z1))
  263. game:GetService("Debris"):AddItem(prt,5)
  264. coroutine.resume(coroutine.create(function(Part,Mesh)
  265. for i=0,1,delay do
  266. wait()
  267. Part.CFrame=Part.CFrame*euler(0,0.7,0)
  268. Part.Transparency=i
  269. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  270. end
  271. Part.Parent=nil
  272. end),prt,msh)
  273. end
  274. function WaveEffect2(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  275. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5))
  276. prt.Anchored=true
  277. prt.CFrame=cframe
  278. msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=1323306",vt(0,0,0),vt(x1,y1,z1))
  279. game:GetService("Debris"):AddItem(prt,2)
  280. coroutine.resume(coroutine.create(function(Part,Mesh)
  281. for i=0,1,delay do
  282. wait()
  283. Part.CFrame=Part.CFrame
  284. Part.Transparency=i
  285. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  286. end
  287. Part.Parent=nil
  288. end),prt,msh)
  289. end
  290. function SummonCrystals()
  291. local Cryst={}
  292. Part1=workspace.Baseplate
  293. local numbah=0
  294. for i=1,4 do
  295. Crys=Instance.new("Model")
  296. Crys.Parent=workspace
  297. Crys.Name="Crystal"
  298. CHead=part(0,Crys,0,0,BrickColor.new("Black"),"Head",vt(8,8,8))
  299. CTorso=part(0,Crys,0,1,BrickColor.new("Black"),"Torso",vt())
  300. CHMesh=mesh("SpecialMesh",CHead,"FileMesh","http://www.roblox.com/asset/?id=9756362",vt(0,0,0),vt(10,11,10))
  301. local Neck=weld(CTorso,CTorso,CHead,cf(0,0,0))
  302. Hum=Instance.new("Humanoid")
  303. Hum.Parent=Crys
  304. CTorso.CFrame=Part1.CFrame*cf(5,10,0)*euler(0,numbah,0)
  305. MagicCircle(BrickColor.new("Really black"),CHead.CFrame,50,50,50,1,12,1,0.05)
  306. wait(0)
  307. CTorso.Anchored=true
  308. coroutine.resume(coroutine.create(function(Model,CrysHum)
  309. while CrysHum.Health>0 do
  310. wait()
  311. end
  312. print("ded")
  313. Tors=Model.Torso
  314. Hed=Model.Head
  315. for i=0,1,0.1 do
  316. wait()
  317. Hed.Transparency=i
  318. end
  319. print("ez ded")
  320. Model.Parent=nil
  321. end),Crys,Hum)
  322. numbah=numbah+1.57
  323. wait(0.875)
  324. end
  325. coroutine.resume(coroutine.create(function(ModeVal)
  326. while ModeVal.Value==2 do
  327. wait()
  328. local dedcrystals=true
  329. model=workspace
  330. for _,c in pairs(model:children()) do
  331. if c.Name=="Crystal" then
  332. dedcrystals=false
  333. end
  334. end
  335. if dedcrystals==true then
  336. ModeVal.Value=3
  337. print("CRYSTALS ARE DED")
  338. end
  339. end
  340. print("goe keel vanta nao")
  341. end),Mode)
  342. end
  343. local BodPos=Instance.new("BodyPosition")
  344. BodPos.P=500
  345. BodPos.D=100
  346. BodPos.Name="VantaPos"
  347. BodPos.maxForce=vt(math.huge,math.huge,math.huge)
  348. BodPos.position=workspace.Baseplate.Position+vt(0,50,0)
  349. BodPos.Parent=RootPart
  350. local BPRef=part(3,Character,0,0.5,BrickColor.new("Black"),"Reference",vt())
  351. BPRef.Anchored=true
  352. for i=0,1,0.1 do
  353. wait()
  354. end
  355. BPRef.CFrame=Torso.CFrame
  356. BodPos.position=BPRef.Position
  357. local BodGy=Instance.new("BodyGyro")
  358. BodGy.maxTorque=Vector3.new(4e+005,4e+005,4e+005)*math.huge
  359. BodGy.P=2000
  360. BodGy.D=100
  361. BodGy.Name="VantaGyro"
  362. CF=RootPart.CFrame
  363. BodGy.Parent=RootPart
  364. BodGy.cframe=CF
  365. --local music=workspace.PlayMusic
  366. local intro=true
  367. local DarkLegEffect=true
  368. wait(1)
  369. if intro==true then
  370. wait(5)
  371. --music.Value=true
  372. coroutine.resume(coroutine.create(function(Leg1,Leg2)
  373. while DarkLegEffect==true do
  374. wait(0.1)
  375. MagicBlock(BrickColor.new("Really black"),Leg1.CFrame*cf(0,-1,0),5,5,5,0.5,0.5,0.5,0.1)
  376. MagicBlock(BrickColor.new("Really black"),Leg2.CFrame*cf(0,-1,0),5,5,5,0.5,0.5,0.5,0.1)
  377. end
  378. end),RightLeg,LeftLeg)
  379. MagicCircle2(BrickColor.new("Black"),Torso.CFrame*euler(1.57,0,0),10,0.1,10,0.1,0,0.1,0.02)
  380. for _,c in pairs(Character:children()) do
  381. if c.className=="Part" and c.Name~="HumanoidRootPart" and c.Name~="Reference" then
  382. c.Transparency=1
  383. coroutine.resume(coroutine.create(function(Part)
  384. for i=1,0,-0.05 do
  385. wait()
  386. Part.Transparency=i
  387. end
  388. Part.Transparency=0
  389. end),c)
  390. end
  391. end
  392. for i=0,1,0.01 do
  393. wait()
  394. RootJoint.C0=cf(0,0,0)*euler(1-0.8*i,0,0)
  395. RW.C0=cf(1.5,0.5,0)*euler(-0.5+0.2*i,0,1.57-1.37*i)
  396. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  397. LW.C0=cf(-1.5,0.5,0)*euler(-0.5+0.2*i,0,-1.57+1.37*i)
  398. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  399. RH.C0=cf(0.5,-1,0)*euler(-1+0.7*i,0,0.2)
  400. RH.C1=cf(0,1,0)
  401. LH.C0=cf(-0.5,-1,0)*euler(-1+0.7*i,0,-0.2)
  402. LH.C1=cf(0,1,0)
  403. BPRef.CFrame=BPRef.CFrame*cf(0,0,-0.1)
  404. BodPos.position=BPRef.Position
  405. end
  406. --wait(0.5)
  407. for i=0,1,0.02 do
  408. wait()
  409. Neck.C0=cf(0,1,0)*euler(0.2*i,0,0)
  410. RW.C0=cf(1.5,0.5,0)*euler(-0.3+1.5*i,0,0.2+0.2*i)
  411. LW.C0=cf(-1.5,0.5,0)*euler(-0.3+1.5*i,0,-0.2-0.2*i)
  412. end
  413. for i=0,1,0.1 do
  414. wait()
  415. RW.C0=cf(1.5-0.3*i,0.5,-0.5*i)*euler(1.2+0.37*i,0,0.4-1.57*i)
  416. LW.C0=cf(-1.5+0.3*i,0.5,-0.5*i)*euler(1.2+0.37*i,0,-0.4+1.57*i)
  417. end
  418. MagicCircle(BrickColor.new("Really black"),RootPart.CFrame,4,4,4,3,3,3,0.04)
  419. Crystals={}
  420. numb=0
  421. for i=1,4 do
  422. local Cryst1=part(3,Character,0,0,BrickColor.new("Black"),"Crystal",vt())
  423. local CrystMsh=mesh("SpecialMesh",Cryst1,"FileMesh","http://www.roblox.com/asset/?id=9756362",vt(0,0,0),vt(1.5,2,1.5))
  424. Cryst1.Anchored=true
  425. Cryst1.CFrame=RootPart.CFrame*euler(0,numb,0)*cf(0,0,5)
  426. MagicCrystal(BrickColor.new("Really black"),Cryst1.CFrame,1,1,1,0.2,0.4,0.2,0.1)
  427. numb=numb+1.57
  428. table.insert(Crystals,Cryst1)
  429. end
  430. wait(0.5)
  431. for i=0,1,0.05 do
  432. wait()
  433. Neck.C0=cf(0,1,0)*euler(0.2-0.2*i,0,0)
  434. RW.C0=cf(1.2+0.3*i,0.5,-0.5+0.5*i)*euler(1.57-1.57*i,0,-1.17+1.27*i)
  435. LW.C0=cf(-1.2-0.3*i,0.5,-0.5+0.5*i)*euler(1.57-1.67*i,0,1.17-1.27*i)
  436. end
  437. for i=0,1,0.1 do
  438. wait()
  439. RW.C0=cf(1.5,0.5,0)*euler(3.2*i,0,0.1-0.1*i)
  440. LW.C0=cf(-1.5,0.5,0)*euler(-0.1+0.1*i,0,-0.1-0.3*i)
  441. end
  442. wait(0.5)
  443. for i=1,#Crystals do
  444. Crystals[i].Parent=nil
  445. MagicCircle(BrickColor.new("Really black"),Crystals[i].CFrame,10,10,10,0.5,8,0.5,0.1)
  446. wait(0.2)
  447. end
  448. for i=0,1,0.04 do
  449. wait()
  450. RW.C0=cf(1.5,0.5,0)*euler(3.2-3.2*i,0,0.1)
  451. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-0.1-0.3+0.3*i)
  452. end
  453. wait(0.5)
  454. for i=0,1,0.05 do
  455. wait()
  456. RW.C0=cf(1.5,0.5,0)*euler(0,0,0.1+1.37*i)
  457. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-0.1-1.37*i)
  458. end
  459. numb=2
  460. for i=0,1,0.1 do
  461. wait()
  462. RW.C0=cf(1.5,0.5,0)*euler(0,0,1.47+0.1*i*numb)
  463. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-1.47-0.1*i*numb)
  464. numb=numb-0.1
  465. end
  466. RW.C0=cf(1.5,0.5,0)*euler(0,0,1.57)
  467. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-1.57)
  468. SummonCrystals()
  469. --wait(3.5)
  470. for i=0,1,0.1 do
  471. wait()
  472. RW.C0=cf(1.5,0.5,0)*euler(0.1*i,0,1.57-1.47*i)
  473. LW.C0=cf(-1.5,0.5,0)*euler(0.1*i,0,-1.57+1.47*i)
  474. end
  475. for i=0,1,0.1 do
  476. wait()
  477. RootJoint.C0=cf(0,0,0)*euler(0.2-0.1*i,0,0)
  478. RW.C0=cf(1.5-0.5*i,0.5,-0.5*i)*euler(0.1+1.37*i,0,0.1-1.37*i)
  479. LW.C0=cf(-1.5+0.5*i,0.5,-0.5*i)*euler(0.1+1.07*i,0,-0.1+1.17*i)
  480. end
  481. n=2
  482. for i=0,1,0.1 do
  483. wait()
  484. Neck.C0=cf(0,1,0)*euler(-0.2*i*n,0,0)
  485. RootJoint.C0=cf(0,0,0)*euler(0.1-0.1*i*n,0,0)
  486. RW.C0=cf(1,0.5,-0.5)*euler(1.47+0.1*i*n,0,-1.27-0.1*i*n)
  487. LW.C0=cf(-1,0.5,-0.5)*euler(1.17+0.1*i*n,0,1.07+0.1*i*n)
  488. n=n-0.1
  489. end
  490. --[[local Shield1=part(3,Character,0,1,BrickColor.new("Dark stone grey"),"Shield1",vt())
  491. local Smsh1=mesh("SpecialMesh",Shield1,"FileMesh","http://www.roblox.com/asset/?id=90782182",vt(0,0,0),vt(0.4,0.5,0.4))
  492. Smsh1.TextureId="http://www.roblox.com/asset/?id=90782359"
  493. Smsh1.VertexColor=vt(0.5,0.5,0.5)
  494. local swld1=weld(Torso,Torso,Shield1,cf(0,1.45,0))
  495. local Shield2=part(3,Character,0,1,BrickColor.new("Dark stone grey"),"Shield2",vt())
  496. local Smsh2=mesh("SpecialMesh",Shield2,"FileMesh","http://www.roblox.com/asset/?id=90782182",vt(0,0,0),vt(0.4,0.5,0.4))
  497. Smsh2.TextureId="http://www.roblox.com/asset/?id=90782359"
  498. Smsh2.VertexColor=vt(0.5,0.5,0.5)
  499. local swld1=weld(Torso,Torso,Shield2,cf(0,-1.45,0)*euler(3.14,0,0))
  500. coroutine.resume(coroutine.create(function(Part1,Mesh1,Part2,Mesh2)
  501. for i=1,0.5,-0.02 do
  502. wait()
  503. Part1.Transparency=i
  504. Part2.Transparency=i
  505. end
  506. wait(1)
  507. for i=0.5,1,0.01 do
  508. wait()
  509. Part1.Transparency=i
  510. Part2.Transparency=i
  511. end
  512. end),Shield1,Smsh1,Shield2,Smsh2)]]
  513. wait(1)
  514. n=2
  515. num=1
  516. for i=0,1,0.02 do
  517. wait()
  518. RW.C0=cf(1+0.5*i*n,0.5,-0.5+0.5*i*n)*euler(1.57-1.57*i*n,0,-1.37+1.57*i*n)
  519. LW.C0=cf(-1-0.5*i*n,0.5,-0.5+0.5*i*n)*euler(1.27-1.27*i*n,0,1.17-1.37*i*n)
  520. n=n-0.02
  521. end
  522. wait(5)
  523. else
  524. print("NOE INTRO")
  525. --music.Value=true
  526. coroutine.resume(coroutine.create(function(Leg1,Leg2)
  527. while DarkLegEffect==true do
  528. wait(0.1)
  529. MagicBlock(BrickColor.new("Really black"),Leg1.CFrame*cf(0,-1,0),5,5,5,0.5,0.5,0.5,0.1)
  530. MagicBlock(BrickColor.new("Really black"),Leg2.CFrame*cf(0,-1,0),5,5,5,0.5,0.5,0.5,0.1)
  531. end
  532. end),RightLeg,LeftLeg)
  533. for _,c in pairs(Character:children()) do
  534. if c.className=="Part" and c.Name~="HumanoidRootPart" and c.Name~="Reference" then
  535. c.Transparency=0
  536. end
  537. end
  538. Neck.C0=cf(0,1,0)*euler(-0.2,0,0)
  539. RootJoint.C0=cf(0,0,0)*euler(0,0,0)
  540. RW.C0=cf(1.5,0.5,0)*euler(0,0,0.2)
  541. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  542. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-0.2)
  543. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  544. RH.C0=cf(0.5,-1,0)*euler(-0.3,0,0.2)
  545. RH.C1=cf(0,1,0)
  546. LH.C0=cf(-0.5,-1,0)*euler(-0.3,0,-0.2)
  547. LH.C1=cf(0,1,0)
  548. wait(1)
  549. end
  550. print("START BOSS BATTLE")
  551. function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  552. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  553. end
  554. function findNearestTorso(pos)
  555. local list = game.Workspace:children()
  556. local torso = nil
  557. local dist = 1000
  558. local temp = nil
  559. local human = nil
  560. local temp2 = nil
  561. for x = 1, #list do
  562. temp2 = list[x]
  563. if (temp2.className == "Model") and (temp2.Name~="Vanta") and temp2.Name~="Crystal" then
  564. temp = temp2:findFirstChild("Torso")
  565. human = temp2:findFirstChild("Humanoid")
  566. if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then
  567. if (temp.Position - pos).magnitude < dist then
  568. torso = temp
  569. dist = (temp.Position - pos).magnitude
  570. end
  571. end
  572. end
  573. end
  574. return torso,dist
  575. end
  576. function findRandomTorso(pos)
  577. local list = game.Workspace:children()
  578. local torso = nil
  579. local dist = 1000
  580. local temp = nil
  581. local human = nil
  582. local temp2 = nil
  583. local list2 = {}
  584. for x = 1, #list do
  585. temp2 = list[x]
  586. if (temp2.className == "Model") and (temp2.Name~="Vanta") and temp2.Name~="Crystal" then
  587. temp = temp2:findFirstChild("Torso")
  588. human = temp2:findFirstChild("Humanoid")
  589. if (temp ~= nil) and (human ~= nil) and (human.Health > 0) then
  590. if pos.magnitude < dist then
  591. torso = temp
  592. table.insert(list2,temp)
  593. end
  594. end
  595. end
  596. end
  597. if #list2>0 then
  598. rand=math.random(1,#list2)
  599. return list2[rand],dist
  600. else
  601. return nil,dist
  602. end
  603. end
  604. Damagefunc=function(hit,minim,maxim,knockback,Type,Property,Delay)
  605. if hit.Parent==nil then
  606. return
  607. end
  608. CPlayer=Bin
  609. h=hit.Parent:FindFirstChild("Humanoid")
  610. for _,v in pairs(hit.Parent:children()) do
  611. if v:IsA("Humanoid") then
  612. h=v
  613. end
  614. end
  615. if h~=nil and hit.Parent.Name~=Character.Name and hit.Parent.Name~="Crystal" and hit.Parent:FindFirstChild("Torso")~=nil then
  616. if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
  617. --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
  618. return
  619. end]]
  620. -- hs(hit,1.2)
  621. c=Instance.new("ObjectValue")
  622. c.Name="creator"
  623. c.Value=game:service("Players").LocalPlayer
  624. c.Parent=h
  625. game:GetService("Debris"):AddItem(c,.5)
  626. Damage=math.random(minim,maxim)
  627. -- h:TakeDamage(Damage)
  628. blocked=false
  629. block=hit.Parent:findFirstChild("Block")
  630. if block~=nil then
  631. if block.className=="IntValue" then
  632. if block.Value>0 then
  633. blocked=true
  634. block.Value=block.Value-1
  635. end
  636. end
  637. end
  638. if blocked==false then
  639. -- h:TakeDamage(Damage)
  640. h.Health=h.Health-Damage
  641. showDamage(hit.Parent,Damage,.5,BrickColor:Red())
  642. else
  643. h.Health=h.Health-(Damage/2)
  644. showDamage(hit.Parent,Damage/2,.5,BrickColor.new("Bright blue"))
  645. end
  646. if Type=="Knockdown" then
  647. hum=hit.Parent.Humanoid
  648. hum.PlatformStand=true
  649. coroutine.resume(coroutine.create(function(HHumanoid)
  650. wait(1)
  651. HHumanoid.PlatformStand=false
  652. end),hum)
  653. local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
  654. --hit.CFrame=CFrame.new(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
  655. local bodvol=Instance.new("BodyVelocity")
  656. bodvol.velocity=angle*knockback
  657. bodvol.P=5000
  658. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  659. bodvol.Parent=hit
  660. rl=Instance.new("BodyAngularVelocity")
  661. rl.P=3000
  662. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  663. rl.angularvelocity=Vector3.new(math.random(-10,10),math.random(-10,10),math.random(-10,10))
  664. rl.Parent=hit
  665. game:GetService("Debris"):AddItem(bodvol,.5)
  666. game:GetService("Debris"):AddItem(rl,.5)
  667. elseif Type=="Normal" then
  668. vp=Instance.new("BodyVelocity")
  669. vp.P=500
  670. vp.maxForce=Vector3.new(math.huge,0,math.huge)
  671. -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback
  672. vp.velocity=Property.CFrame.lookVector*knockback+Property.Velocity/1.05
  673. if knockback>0 then
  674. vp.Parent=hit.Parent.Torso
  675. end
  676. game:GetService("Debris"):AddItem(vp,.5)
  677. elseif Type=="Up" then
  678. local bodyVelocity=Instance.new("BodyVelocity")
  679. bodyVelocity.velocity=vt(0,20,0)
  680. bodyVelocity.P=5000
  681. bodyVelocity.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  682. bodyVelocity.Parent=hit
  683. game:GetService("Debris"):AddItem(bodyVelocity,.5)
  684. elseif Type=="Snare" then
  685. bp=Instance.new("BodyPosition")
  686. bp.P=2000
  687. bp.D=100
  688. bp.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  689. bp.position=hit.Parent.Torso.Position
  690. bp.Parent=hit.Parent.Torso
  691. game:GetService("Debris"):AddItem(bp,1)
  692. elseif Type=="Freeze" then
  693. BodPos2=Instance.new("BodyPosition")
  694. BodPos2.P=50000
  695. BodPos2.D=1000
  696. BodPos2.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  697. BodPos2.position=hit.Parent.Torso.Position
  698. BodPos2.Parent=hit.Parent.Torso
  699. BodGy2 = it("BodyGyro")
  700. BodGy2.maxTorque = Vector3.new(4e+005,4e+005,4e+005)*math.huge
  701. BodGy2.P = 20e+003
  702. BodGy2.Parent=hit.Parent.Torso
  703. BodGy2.cframe = hit.Parent.Torso.CFrame
  704. hit.Parent.Torso.Anchored=true
  705. coroutine.resume(coroutine.create(function(Part)
  706. wait(1.5)
  707. Part.Anchored=false
  708. end),hit.Parent.Torso)
  709. game:GetService("Debris"):AddItem(BodPos2,3)
  710. game:GetService("Debris"):AddItem(BodGy2,3)
  711. end
  712. debounce=Instance.new("BoolValue")
  713. debounce.Name="DebounceHit"
  714. debounce.Parent=hit.Parent
  715. debounce.Value=true
  716. game:GetService("Debris"):AddItem(debounce,Delay)
  717. c=Instance.new("ObjectValue")
  718. c.Name="creator"
  719. c.Value=Player
  720. c.Parent=h
  721. game:GetService("Debris"):AddItem(c,.5)
  722. CRIT=false
  723. hitDeb=true
  724. AttackPos=6
  725. end
  726. end
  727. showDamage=function(Char,Dealt,du,Color)
  728. m=Instance.new("Model")
  729. m.Name=tostring(Dealt)
  730. h=Instance.new("Humanoid")
  731. h.Health=0
  732. h.MaxHealth=0
  733. h.Parent=m
  734. c=Instance.new("Part")
  735. c.Transparency=0
  736. c.BrickColor=Color
  737. c.Name="Head"
  738. c.TopSurface=0
  739. c.BottomSurface=0
  740. c.formFactor="Plate"
  741. c.Size=Vector3.new(1,.4,1)
  742. ms=Instance.new("CylinderMesh")
  743. ms.Scale=Vector3.new(.8,.8,.8)
  744. if CRIT==true then
  745. ms.Scale=Vector3.new(1,1.25,1)
  746. end
  747. ms.Parent=c
  748. c.Reflectance=0
  749. Instance.new("BodyGyro").Parent=c
  750. c.Parent=m
  751. if Char:findFirstChild("Head")~=nil then
  752. c.CFrame=CFrame.new(Char["Head"].CFrame.p+Vector3.new(0,1.5,0))
  753. else
  754. c.CFrame=CFrame.new(Char["Torso"].CFrame.p+Vector3.new(0,1.5,0))
  755. end
  756. f=Instance.new("BodyPosition")
  757. f.P=2000
  758. f.D=100
  759. f.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  760. f.position=c.Position+Vector3.new(0,3,0)
  761. f.Parent=c
  762. game:GetService("Debris"):AddItem(m,.5+du)
  763. c.CanCollide=false
  764. m.Parent=workspace
  765. c.CanCollide=false
  766. end
  767. function MagniDamage(Part,magni,mindam,maxdam,knock,Type,Baseplate)
  768. for _,c in pairs(workspace:children()) do
  769. local hum=c:findFirstChild("Humanoid")
  770. if hum~=nil then
  771. local head=c:findFirstChild("Torso")
  772. if head~=nil then
  773. local targ=head.Position-Part.Position
  774. local mag=targ.magnitude
  775. if mag<=magni and c.Name~=Character.Name then
  776. Damagefunc(head,mindam,maxdam,knock,Type,Baseplate,0)
  777. end
  778. end
  779. end
  780. end
  781. end
  782. local HealtVal=Instance.new("IntValue")
  783. HealtVal.Name="Max Health Value"
  784. HealtVal.Parent=Character
  785. HealtVal.Value=5000
  786. local HealtVal2=Instance.new("IntValue")
  787. HealtVal2.Name="Current Health Value"
  788. HealtVal2.Parent=Character
  789. HealtVal2.Value=5000
  790. local HealthNum=Instance.new("IntValue")
  791. HealthNum.Name="Divis Numb"
  792. HealthNum.Parent=Character
  793. HealthNum.Value=HealtVal2.Value/3
  794. local HealthNumber=1666
  795. Anim=Instance.new("StringValue")
  796. Anim.Name="Animation"
  797. Anim.Parent=Character
  798. Anim.Value="Walking"
  799. mode=Mode
  800. local target,distance=nil,nil
  801. local attacking=false
  802. while Humanoid.Health>0 do
  803. wait()
  804. while mode.Value==2 do
  805. Humanoid.PlatformStand=false
  806. Humanoid.Sit=false
  807. if Torso.Parent==nil or Humanoid.Health<=0 then
  808. Humanoid.Parent=nil
  809. RootPart.Parent=Character
  810. BPRef.CFrame=workspace.Baseplate.CFrame*cf(0,100,0)*euler(0,1.57,0)
  811. BodPos.position=BPRef.Position
  812. BodPos.Parent=RootPart
  813. RootPart.CFrame=BPRef.CFrame
  814. BodPos.position=BPRef.Position
  815. Torso.Parent=Character
  816. Head.Parent=Character
  817. LeftArm.Parent=Character
  818. RightArm.Parent=Character
  819. LeftLeg.Parent=Character
  820. RightLeg.Parent=Character
  821. Neck.Parent=Torso
  822. RootJoint.Parent=Torso
  823. RW.Parent=Torso
  824. LW.Parent=Torso
  825. RH.Parent=Torso
  826. LH.Parent=Torso
  827. wait(.1)
  828. Humanoid.MaxHealth=math.huge
  829. Humanoid.Health=math.huge
  830. coroutine.resume(coroutine.create(function()
  831. for i=1,20 do
  832. Humanoid.Health=math.huge
  833. Neck.Parent=Torso
  834. RootJoint.Parent=Torso
  835. RW.Parent=Torso
  836. LW.Parent=Torso
  837. RH.Parent=Torso
  838. LH.Parent=Torso
  839. end
  840. Humanoid:TakeDamage(1)
  841. end))
  842. end
  843. RH.C0=cf(0.5,-1,0)*euler(-0.3,0,0.2)
  844. RH.C1=cf(0,1,0)
  845. LH.C0=cf(-0.5,-1,0)*euler(-0.3,0,-0.2)
  846. LH.C1=cf(0,1,0)
  847. BodPos.maxForce=vt(math.huge,math.huge,math.huge)
  848. local move=1
  849. if math.random(1,2)==1 then
  850. move=1
  851. target,distance=findRandomTorso(Torso.Position)
  852. else
  853. move=2
  854. target,distance=findNearestTorso(Torso.Position)
  855. end
  856. if target~=nil then
  857. if math.random(1,5)==1 then
  858. MagicBlock(BrickColor.new("Really black"),Torso.CFrame,15,15,15,6,6,6,0.1)
  859. local pos=cf(math.random(-10,10),math.random(50,70),math.random(-10,10))
  860. BPRef.CFrame=cf(target.Position)*pos
  861. Torso.CFrame=BPRef.CFrame
  862. BodPos.position=BPRef.Position
  863. MagicBlock(BrickColor.new("Really black"),Torso.CFrame,15,15,15,6,6,6,0.1)
  864. end
  865. BodGy.cframe=CF*euler(0,math.random(-50,50),0)
  866. local pos=cf(math.random(-10,10),math.random(50,70),math.random(-10,10))
  867. --BPRef.CFrame=cf(target.Position)*pos
  868. --BodPos.position=BPRef.Position
  869. attack=math.random(1,3)
  870. attacking=true
  871. if attack==1 then --Dark Rain
  872. coroutine.resume(coroutine.create(function()
  873. while attacking==true do
  874. wait()
  875. BPRef.CFrame=cf(target.Position)*pos
  876. BodPos.position=BPRef.Position
  877. end
  878. end))
  879. n=2
  880. for i=0,1,0.1 do
  881. wait()
  882. Neck.C0=cf(0,1,0)*euler(-0.2+0.6*i*n,0,0)
  883. RW.C0=cf(1.5,0.5,0)*euler(3.14*i*n,0,0.2-0.2*i*n)
  884. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-0.2-0.2*i*n)
  885. n=n-0.1
  886. end
  887. for i=1,math.random(10,20) do
  888. local orb=part(3,Character,0,1,BrickColor.new("Really black"),"Orb",vt())
  889. so("http://roblox.com/asset/?id=183763498",orb,1,1.2)
  890. local omsh=mesh("SpecialMesh",orb,"Sphere","",vt(0,0,0),vt(10,10,10))
  891. local owld=weld(orb,orb,Torso,cf(0,-5,0))
  892. MagicCircle(BrickColor.new("Really black"),orb.CFrame,10,10,10,1,1,1,0.1)
  893. coroutine.resume(coroutine.create(function(Part,Mesh,Weld)
  894. local ceef1=math.random(-50,50)
  895. local ceef2=math.random(-2,8)
  896. local ceef3=math.random(100,200)/100
  897. local n=2
  898. for i=0,1,0.1 do
  899. wait()
  900. Part.Transparency=Part.Transparency-0.07
  901. owld.C0=cf(ceef2*i*n,-5,0)*euler(ceef3*i*n,ceef1,0)
  902. n=n-0.1
  903. end
  904. wait(1)
  905. Part.Parent=nil
  906. local spread=vt((math.random(-1,0)+math.random())*16,(math.random(-1,0)+math.random())*16,(math.random(-1,0)+math.random())*16)*(Part.Position-(Part.Position+vt(0,-1,0))).magnitude/100
  907. local TheHit=Part.Position+vt(0,-1,0)
  908. local MouseLook=cf((Part.Position+TheHit)/2,TheHit+spread)
  909. local hit,pos = rayCast(Part.Position,MouseLook.lookVector,999,Character)
  910. local mag=(Part.Position-pos).magnitude
  911. MagicCylinder(BrickColor.new("Really black"),CFrame.new((Part.Position+pos)/2,pos)*angles(1.57,0,0) ,1,mag*5,1,0.5,0,0.5,0.05)
  912. MagicBlock(BrickColor.new("Really black"),Part.CFrame,8,8,8,0.5,0.5,0.5,0.1)
  913. MagicBlock(BrickColor.new("Really black"),cf(pos),15,15,15,6,6,6,0.1)
  914. MagicRing(BrickColor.new("Really black"),cf(pos)*euler(1.57,math.random(-100,100)/100,math.random(-100,100)/100),1,1,1,2,2,2,0.05)
  915. local ref=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  916. ref.CFrame=cf(pos)
  917. so("http://roblox.com/asset/?id=183763487",ref,1,1)
  918. coroutine.resume(coroutine.create(function(Part)
  919. wait(1)
  920. Part.Parent=nil
  921. end),ref)
  922. MagniDamage(ref,15,5,10,0,"Normal",RootPart)
  923. if hit~=nil then
  924. Damagefunc(hit,20,40,1,"Knockdown",RootPart,0)
  925. end
  926. end),orb,omsh,owld)
  927. wait(0.2)
  928. end
  929. n=2
  930. for i=0,1,0.1 do
  931. wait()
  932. Neck.C0=cf(0,1,0)*euler(0.4-0.6*i*n,0,0)
  933. RW.C0=cf(1.5,0.5,0)*euler(3.14-3.14*i*n,0,0.2*i*n)
  934. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-0.4+0.2*i*n)
  935. n=n-0.1
  936. end
  937. attacking=false
  938. wait(2)
  939. elseif attack==2 then --Nocturne
  940. coroutine.resume(coroutine.create(function()
  941. while attacking==true do
  942. wait()
  943. Pos=target.Position
  944. BodGy.cframe=cf(Torso.Position,Pos)
  945. end
  946. end))
  947. n=2
  948. for i=0,1,0.1 do
  949. wait()
  950. Neck.C0=cf(0,1,0)*euler(-0.2+0.2*i*n,0,0)
  951. RW.C0=cf(1.5,0.5,0)*euler(1.57*i*n,0,0.2-0.6*i*n)
  952. LW.C0=cf(-1.5,0.5,0)*euler(1.57*i*n,0,-0.2+0.6*i*n)
  953. n=n-0.1
  954. end
  955. local orb=part(3,Character,0,1,BrickColor.new("Really black"),"Orb",vt())
  956. local omsh=mesh("SpecialMesh",orb,"Sphere","",vt(0,0,0),vt(10,10,10))
  957. local owld=weld(orb,orb,Torso,cf(0,-0.5,3))
  958. so("http://roblox.com/asset/?id=137463716",orb,1,0.6)
  959. for i=1,0.3,-0.01 do
  960. wait()
  961. orb.Transparency=i
  962. omsh.Scale=omsh.Scale+vt(0.2,0.2,0.2)
  963. MagicBlock(BrickColor.new("Really black"),orb.CFrame,8,8,8,0.5,0.5,0.5,0.1)
  964. local ef=part(3,workspace,0,0,BrickColor.new("Really black"),"Effect",vt())
  965. ef.Anchored=true
  966. local emsh=mesh("SpecialMesh",ef,"Sphere","",vt(0,0,0),vt(2,math.random(1000,1500)/100,2))
  967. local ceef=euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))*cf(0,math.random(5,10),0)
  968. ef.CFrame=orb.CFrame*ceef
  969. game:GetService("Debris"):AddItem(ef,2)
  970. coroutine.resume(coroutine.create(function(Part,Mesh)
  971. for i=0,1,0.1 do
  972. wait()
  973. Part.Transparency=i
  974. Part.CFrame=Part.CFrame*cf(0,-1,0)
  975. end
  976. Part.Parent=nil
  977. end),ef,emsh)
  978. end
  979. attacking=false
  980. wait(1)
  981. orb.Parent=nil
  982. local hit,pos = rayCast(orb.Position,Head.CFrame.lookVector,999,Character)
  983. print(hit)
  984. local mag=(orb.Position-pos).magnitude
  985. MagicCircle(BrickColor.new("Really black"),cf(pos),15,15,15,8,8,8,0.02)
  986. MagicBlock(BrickColor.new("Really black"),cf(pos),15,15,15,8,8,8,0.02)
  987. MagicCylinder(BrickColor.new("Really black"),CFrame.new((orb.Position+pos)/2,pos)*euler(1.57,0,0),10,mag*5,10,0.5,0,0.5,0.01)
  988. for i=1,2 do
  989. MagicRing(BrickColor.new("Really black"),cf(pos)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)),3,3,3,1,1,1,0.04)
  990. end
  991. for i=1,5 do
  992. tehcf=CFrame.new((orb.Position+pos)/2,pos)*euler(1.57,0,0)*cf(0,(mag/5)*(i/2),0)
  993. MagicRing(BrickColor.new("Really black"),tehcf*euler(1.57,0,0),1,1,1,0.5,0.5,0.5,0.01)
  994. end
  995. for i=0,5 do
  996. tehcf=CFrame.new((orb.Position+pos)/2,pos)*euler(1.57,0,0)*cf(0,(-mag/5)*(i/2),0)
  997. MagicRing(BrickColor.new("Really black"),tehcf*euler(1.57,0,0),1,1,1,0.5,0.5,0.5,0.01)
  998. end
  999. local ref=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1000. ref.CFrame=cf(pos)
  1001. so("http://roblox.com/asset/?id=183763506",Torso,1,0.6)
  1002. so("http://roblox.com/asset/?id=178452221",Torso,1,0.6)
  1003. so("http://www.roblox.com/Asset?ID=87767777",Torso,1,1)
  1004. so("http://roblox.com/asset/?id=183763506",ref,1,0.6)
  1005. so("http://roblox.com/asset/?id=178452221",ref,1,0.6)
  1006. so("http://www.roblox.com/Asset?ID=87767777",ref,1,1)
  1007. coroutine.resume(coroutine.create(function(Part)
  1008. wait(1)
  1009. Part.Parent=nil
  1010. end),ref)
  1011. MagniDamage(ref,20,10,30,40,"Knockdown",ref)
  1012. if hit~=nil then
  1013. Damagefunc(hit,30,70,50,"Knockdown",RootPart,0)
  1014. end
  1015. wait(1)
  1016. n=2
  1017. for i=0,1,0.1 do
  1018. wait()
  1019. Neck.C0=cf(0,1,0)*euler(-0.2*i*n,0,0)
  1020. RW.C0=cf(1.5,0.5,0)*euler(1.57-1.57*i*n,0,0.2-0.6+0.6*i*n)
  1021. LW.C0=cf(-1.5,0.5,0)*euler(1.57-1.57*i*n,0,-0.2+0.6-0.6*i*n)
  1022. n=n-0.1
  1023. end
  1024. elseif attack==3 then --Terror blast
  1025. n=2
  1026. for i=0,1,0.1 do
  1027. wait()
  1028. Neck.C0=cf(0,1,0)*euler(-0.2-0.2*i*n,0,0)
  1029. RW.C0=cf(1.5-0.5*i*n,0.5,-0.5*i*n)*euler(1.4*i*n,0,0.2-1.4*i*n)
  1030. LW.C0=cf(-1.5+0.5*i*n,0.5,-0.5*i*n)*euler(1.6*i*n,0,-0.2+1.6*i*n)
  1031. n=n-0.1
  1032. end
  1033. so("http://roblox.com/asset/?id=160772554",Torso,1,0.6)
  1034. so("http://roblox.com/asset/?id=161006069",Torso,1,0.6)
  1035. local charging=true
  1036. for _,c in pairs(workspace:children()) do
  1037. if c.className=="Model" then
  1038. if c:findFirstChild("Torso")~=nil and c:findFirstChild("Humanoid")~=nil and c.Name~="Vanta" then
  1039. print(c)
  1040. local Tors=c:findFirstChild("Torso")
  1041. coroutine.resume(coroutine.create(function(Part)
  1042. local ef=part(3,Character,0,0.5,BrickColor.new("Really black"),"Laser",vt(0.2,0.2,0.2))
  1043. ef.Anchored=true
  1044. local emsh=mesh("SpecialMesh",ef,"Head","",vt(0,0,0),vt(1,1,1))
  1045. game:GetService("Debris"):AddItem(ef,5)
  1046. while charging==true do
  1047. wait()
  1048. local TheHit=Part.Position
  1049. local MouseLook=cf((Torso.Position+TheHit)/2,TheHit)
  1050. local hit,pos = rayCast(Torso.Position,MouseLook.lookVector,999,Character)
  1051. local mag=(Torso.Position-pos).magnitude
  1052. ef.CFrame=CFrame.new((Torso.Position+pos)/2,pos)*euler(1.57,0,0)
  1053. emsh.Scale=vt(1,mag*5,1)
  1054. end
  1055. ef.Parent=nil
  1056. local TheHit=Part.Position
  1057. local MouseLook=cf((Torso.Position+TheHit)/2,TheHit)
  1058. wait()
  1059. local hit,pos = rayCast(Torso.Position,MouseLook.lookVector,999,Character)
  1060. local mag=(Torso.Position-pos).magnitude
  1061. if hit~=nil then
  1062. Damagefunc(hit,20,40,50,"Knockdown",RootPart,0)
  1063. MagicCircle(BrickColor.new("Really black"),cf(pos),5,5,5,6,6,6,0.02)
  1064. MagicBlock(BrickColor.new("Really black"),cf(pos),5,5,5,7,7,7,0.02)
  1065. MagicCylinder(BrickColor.new("Really black"),CFrame.new((Torso.Position+pos)/2,pos)*euler(1.57,0,0),5,mag*5,5,0.5,0,0.5,0.01)
  1066. so("http://roblox.com/asset/?id=183763515",hit,1,1)
  1067. so("http://roblox.com/asset/?id=183763512",hit,1,1)
  1068. end
  1069. end),Tors)
  1070. end
  1071. end
  1072. end
  1073. wait(1)
  1074. n=2
  1075. for i=0,1,0.2 do
  1076. wait()
  1077. Neck.C0=cf(0,1,0)*euler(-0.4+0.2*i*n,0,0)
  1078. RW.C0=cf(1+0.5*i*n,0.5,-0.5+0.5*i*n)*euler(1.4+0.17*i*n,0,-1.2+2.77*i*n)
  1079. LW.C0=cf(-1-0.5*i*n,0.5,-0.5+0.5*i*n)*euler(1.6-0.03*i*n,0,1.4-2.97*i*n)
  1080. n=n-0.2
  1081. end
  1082. charging=false
  1083. wait(1)
  1084. n=2
  1085. for i=0,1,0.1 do
  1086. wait()
  1087. Neck.C0=cf(0,1,0)*euler(-0.2,0,0)
  1088. RW.C0=cf(1.5,0.5,0)*euler(1.57-1.57*i*n,0,1.57-1.37*i*n)
  1089. LW.C0=cf(-1.5,0.5,0)*euler(1.57-1.57*i*n,0,-1.57+1.37*i*n)
  1090. n=n-0.1
  1091. end
  1092. wait(2)
  1093. end
  1094. attacking=false
  1095. else
  1096. print("CAN'T FIND TARGET")
  1097. end
  1098. wait(1)
  1099. end
  1100. Humanoid.MaxHealth=HealtVal.Value
  1101. Humanoid.Health=HealtVal2.Value
  1102. coroutine.resume(coroutine.create(function()
  1103. for i=1,20 do
  1104. Humanoid.Health=HealtVal2.Value
  1105. end
  1106. Humanoid:TakeDamage(1)
  1107. end))
  1108. MagicBlock(BrickColor.new("Really black"),Torso.CFrame,15,15,15,6,6,6,0.1)
  1109. BPRef.CFrame=MainPosition
  1110. Torso.CFrame=BPRef.CFrame
  1111. BodPos.position=BPRef.Position
  1112. MagicBlock(BrickColor.new("Really black"),Torso.CFrame,15,15,15,6,6,6,0.1)
  1113. BodGy.cframe=CF
  1114. wait(0.5)
  1115. n=2
  1116. for i=0,1,0.05 do
  1117. wait()
  1118. BPRef.CFrame=MainPosition*cf(0,-60*i,0)
  1119. BodPos.position=BPRef.Position
  1120. Neck.C0=cf(0,1,0)*euler(-0.2-0.2*i*n,0,0)
  1121. RW.C0=cf(1.5-0.5*i*n,0.5,-0.5*i*n)*euler(1.4*i*n,0,0.2-1.4*i*n)
  1122. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1123. LW.C0=cf(-1.5+0.5*i*n,0.5,-0.5*i*n)*euler(1.6*i*n,0,-0.2+1.6*i*n)
  1124. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1125. RH.C0=cf(0.5,-1,0)*euler(-0.3+0.3*i*n,0,0.2)
  1126. RH.C1=cf(0,1,0)
  1127. LH.C0=cf(-0.5,-1,0)*euler(-0.3+0.3*i*n,0,-0.2)
  1128. LH.C1=cf(0,1,0)
  1129. n=n-0.05
  1130. end
  1131. wait(1)
  1132. DarkLegEffect=false
  1133. local Head2=part(0,Character,0,1,BrickColor.new("Really black"),"Shade Head",vt(10,5,5))
  1134. local Torso2=part(0,Character,0,1,BrickColor.new("Really black"),"Shade Torso",vt(10,10,5))
  1135. local LeftArm2=part(0,Character,0,1,BrickColor.new("Really black"),"Shade Left Arm",vt(5,10,5))
  1136. local RightArm2=part(0,Character,0,1,BrickColor.new("Really black"),"Shade Right Arm",vt(5,10,5))
  1137. local LeftLeg2=part(0,Character,0,1,BrickColor.new("Really black"),"Shade Left Leg",vt(5,10,5))
  1138. local RightLeg2=part(0,Character,0,1,BrickColor.new("Really black"),"Shade Right Leg",vt(5,10,5))
  1139. Head2.CFrame=Head.CFrame
  1140. Torso2.CFrame=Head.CFrame
  1141. LeftArm2.CFrame=Head.CFrame
  1142. RightArm2.CFrame=Head.CFrame
  1143. LeftLeg2.CFrame=Head.CFrame
  1144. RightLeg2.CFrame=Head.CFrame
  1145. local HMesh2=mesh("SpecialMesh",Head2,"Head","",vt(0,0,0),vt(1.25,1.25,1.25))
  1146. local Neck2=weld(Torso2,Torso2,Head2,cf(0,5,0))
  1147. Neck2.C1=cf(0,-2.5,0)
  1148. local RW2=weld(Torso2,Torso2,RightArm2,cf(7.5,2.5,0))
  1149. RW2.C1=cf(0,2.5,0)
  1150. local LW2=weld(Torso2,Torso2,LeftArm2,cf(-7.5,2.5,0))
  1151. LW2.C1=cf(0,2.5,0)
  1152. local RH2=weld(Torso2,Torso2,RightLeg2,cf(2.5,-5,0))
  1153. RH2.C1=cf(0,5,0)
  1154. local LH2=weld(Torso2,Torso2,LeftLeg2,cf(-2.5,-5,0))
  1155. LH2.C1=cf(0,5,0)
  1156. local RootJoint2=weld(Torso2,Torso2,Torso,cf(0,2.5,0))
  1157. local DarkBody=true
  1158. local cf1=0
  1159. local cf2=4
  1160. local cf3=0
  1161. local cf4=6
  1162. local cf5=2
  1163. local cf6=0
  1164. local cf7=-6
  1165. local cf8=2
  1166. local cf9=0
  1167. local cf10=2
  1168. local cf11=-4
  1169. local cf12=0
  1170. local cf13=-2
  1171. local cf14=-4
  1172. local cf15=0
  1173. coroutine.resume(coroutine.create(function()
  1174. --Destroy all CC, Dark body assume angles of normal body
  1175. while DarkBody==true do
  1176. wait()
  1177. for _,c in pairs(Character:children()) do
  1178. for _,v in pairs(c:children()) do
  1179. if v.className=="BodyGyro" or v.className=="BodyPosition" or v.className=="BodyVelocity" or v.className=="BodyAngularVelocity" then
  1180. if v.Name~="VantaGyro" and v.Name~="VantaPos" then
  1181. print("dai")
  1182. v.Parent=nil
  1183. end
  1184. end
  1185. end
  1186. end
  1187. Neck2.C0=cf(cf1,cf2,cf3)*Neck.C0
  1188. RW2.C0=cf(cf4,cf5,cf6)*RW.C0
  1189. LW2.C0=cf(cf7,cf8,cf9)*LW.C0
  1190. RH2.C0=cf(cf10,cf11,cf12)*RH.C0
  1191. LH2.C0=cf(cf13,cf14,cf15)*LH.C0
  1192. end
  1193. end))
  1194. n=2
  1195. n2=1
  1196. for i=0,1,0.1 do
  1197. wait()
  1198. Neck.C0=cf(0,1,0)*euler(-0.4+0.4*i*n,0,0)
  1199. RW.C0=cf(1+0.5*i*n,0.5,-0.5+0.5*i*n)*euler(1.4+0.17*i*n,0,-1.2+2.77*i*n)
  1200. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1201. LW.C0=cf(-1-0.5*i*n,0.5,-0.5+0.5*i*n)*euler(1.6-0.03*i*n,0,1.4-2.97*i*n)
  1202. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1203. RH.C0=cf(0.5,-1,0)*euler(0,0,0.2+0.2*i*n)
  1204. RH.C1=cf(0,1,0)
  1205. LH.C0=cf(-0.5,-1,0)*euler(0,0,-0.2-0.2*i*n)
  1206. LH.C1=cf(0,1,0)
  1207. Head2.Transparency=n2
  1208. Torso2.Transparency=n2
  1209. LeftArm2.Transparency=n2
  1210. RightArm2.Transparency=n2
  1211. LeftLeg2.Transparency=n2
  1212. RightLeg2.Transparency=n2
  1213. n=n-0.1
  1214. n2=n2-0.05
  1215. end
  1216. wait(0.5)
  1217. RootJoint.C0=cf(0,-14.5,0)*euler(0,0,0)
  1218. BodPos.Parent=nil
  1219. Humanoid.WalkSpeed=25
  1220. n=2
  1221. for i=0,1,0.1 do
  1222. wait()
  1223. Neck.C0=cf(0,1,0)*euler(-0.2*i*n,0,0)
  1224. RW.C0=cf(1.5,0.5,0)*euler(1.57-1.57*i*n,0,1.57-1.27*i*n)
  1225. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1226. LW.C0=cf(-1.5,0.5,0)*euler(1.57-1.57*i*n,0,-1.57+1.27*i*n)
  1227. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1228. RH.C0=cf(0.5,-1,0)*euler(0,0,0.4-0.4*i*n)
  1229. RH.C1=cf(0,1,0)
  1230. LH.C0=cf(-0.5,-1,0)*euler(0,0,-0.4+0.4*i*n)
  1231. LH.C1=cf(0,1,0)
  1232. n=n-0.1
  1233. end
  1234. BodGy.maxTorque=Vector3.new(40000000,400000000,40000000)
  1235. BodGy.P=2000
  1236. BodGy.D=100
  1237. --BodGy.cframe=CF*euler(0,0,0)
  1238. coroutine.resume(coroutine.create(function()
  1239. --Movement function
  1240. local flying=false
  1241. while DarkBody==true do
  1242. wait()
  1243. --[[print(RootPart.Velocity.z)
  1244. if RootPart.Velocity.x>=6 or RootPart.Velocity.x<=-6 or RootPart.Velocity.z>=6 or RootPart.Velocity.z<=6 then
  1245. Anim.Value="Walking"
  1246. else
  1247. Anim.Value="Standing"
  1248. end]]
  1249. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1250. if flying==true then
  1251. Anim.Value="Flying"
  1252. elseif torvel<1 then
  1253. Anim.Value="Standing"
  1254. elseif torvel<30 then
  1255. Anim.Value="Walking"
  1256. end
  1257. target=findNearestTorso(RootPart.Position)
  1258. local hit,pos=rayCast(RootPart.Position,cf(RootPart.Position,RootPart.Position-vt(0,1,0)).lookVector,50,Character)
  1259. if hit==nil and flying==false then
  1260. flying=true
  1261. BodPos.maxForce=vt(0,math.huge,0)
  1262. if target~=nil then
  1263. BodPos.position=target.Position
  1264. else
  1265. BodPos.position=Torso2.Position
  1266. end
  1267. BodPos.Parent=RootPart
  1268. coroutine.resume(coroutine.create(function()
  1269. local ground=false
  1270. while ground==false do
  1271. wait()
  1272. if target~=nil then
  1273. BodPos.position=target.Position
  1274. end
  1275. local hit,pos=rayCast(RootPart.Position,cf(RootPart.Position,RootPart.Position-vt(0,1,0)).lookVector,50,Character)
  1276. if hit~=nil then
  1277. ground=true
  1278. flying=false
  1279. end
  1280. end
  1281. BodPos.Parent=nil
  1282. end))
  1283. end
  1284. if target~=nil then
  1285. local pos=Vector3.new(target.Parent.Torso.Position.x,RootPart.Position.Y,target.Parent.Torso.Position.z)
  1286. BodGy.cframe=cf(RootPart.Position,pos)
  1287. Humanoid:MoveTo(target.Position)
  1288. end
  1289. end
  1290. end))
  1291. coroutine.resume(coroutine.create(function()
  1292. --Movement animations
  1293. --[[function onRunning(speed)
  1294. if speed>1 then
  1295. Anim.Value="Walking"
  1296. else
  1297. Anim.Value="Standing"
  1298. end
  1299. end
  1300. Humanoid.Running:connect(onRunning)]]
  1301. local con1=nil
  1302. local con2=nil
  1303. while DarkBody==true do
  1304. wait()
  1305. local walkingoffset1=0
  1306. local walkingoffset2=0
  1307. if attacking==false then
  1308. if Anim.Value=="Standing" then
  1309. RH.C0=cf(0.5,-1,0)*euler(0,0,0)
  1310. RH.C1=cf(0,1,0)
  1311. LH.C0=cf(-0.5,-1,0)*euler(0,0,0)
  1312. LH.C1=cf(0,1,0)
  1313. elseif Anim.Value=="Walking" then
  1314. n=2
  1315. for i=0,1,0.1 do
  1316. if Anim.Value=="Walking" then
  1317. --con1=LeftLeg2.Touched:connect(function(hit) Damagefunc(hit,5,10,math.random(5,10),"Normal",RootPart,.5) end)
  1318. --con2=RightLeg2.Touched:connect(function(hit) Damagefunc(hit,5,10,math.random(5,10),"Normal",RootPart,.5) end)
  1319. wait()
  1320. walkingoffset1=1.2*i*n
  1321. walkingoffset2=-1.2*i*n
  1322. end
  1323. RH.C0=cf(0.5,-1,0)*euler(walkingoffset1,0,0)
  1324. RH.C1=cf(0,1,0)
  1325. LH.C0=cf(-0.5,-1,0)*euler(walkingoffset2,0,0)
  1326. LH.C1=cf(0,1,0)
  1327. n=n-0.1
  1328. end
  1329. while Anim.Value=="Walking" and DarkBody==true do
  1330. wait()
  1331. n=2
  1332. for i=0,1,0.05 do
  1333. if Anim.Value=="Walking" then
  1334. wait()
  1335. walkingoffset1=1.2-2.4*i*n
  1336. walkingoffset2=-1.2+2.4*i*n
  1337. end
  1338. RH.C0=cf(0.5,-1,0)*euler(walkingoffset1,0,0)
  1339. RH.C1=cf(0,1,0)
  1340. LH.C0=cf(-0.5,-1,0)*euler(walkingoffset2,0,0)
  1341. LH.C1=cf(0,1,0)
  1342. n=n-0.05
  1343. end
  1344. n=2
  1345. for i=0,1,0.05 do
  1346. if Anim.Value=="Walking" then
  1347. wait()
  1348. walkingoffset1=-1.2+2.4*i*n
  1349. walkingoffset2=1.2-2.4*i*n
  1350. end
  1351. RH.C0=cf(0.5,-1,0)*euler(walkingoffset1,0,0)
  1352. RH.C1=cf(0,1,0)
  1353. LH.C0=cf(-0.5,-1,0)*euler(walkingoffset2,0,0)
  1354. LH.C1=cf(0,1,0)
  1355. n=n-0.05
  1356. end
  1357. end
  1358. if Anim.Value=="Standing" then
  1359. n=2
  1360. for i=0,1,0.1 do
  1361. wait()
  1362. RH.C0=cf(0.5,-1,0)*euler(walkingoffset1-walkingoffset1*i*n,0,0)
  1363. RH.C1=cf(0,1,0)
  1364. LH.C0=cf(-0.5,-1,0)*euler(walkingoffset2-walkingoffset2*i*n,0,0)
  1365. LH.C1=cf(0,1,0)
  1366. n=n-0.1
  1367. end
  1368. end
  1369. elseif Anim.Value=="Flying" then
  1370. while Anim.Value=="Flying" and DarkBody==true do
  1371. wait(.1)
  1372. RH.C0=cf(0.5,-1,0)*euler(-0.2,0,0.2)
  1373. RH.C1=cf(0,1,0)
  1374. LH.C0=cf(-0.5,-1,0)*euler(-0.2,0,-0.2)
  1375. LH.C1=cf(0,1,0)
  1376. MagicBlock(BrickColor.new("Really black"),LeftLeg2.CFrame*cf(0,-5,0),30,30,30,2,2,2,0.1)
  1377. MagicBlock(BrickColor.new("Really black"),RightLeg2.CFrame*cf(0,-5,0),30,30,30,2,2,2,0.1)
  1378. end
  1379. end
  1380. end
  1381. end
  1382. end))
  1383. coroutine.resume(coroutine.create(function()
  1384. while Humanoid.Health>=HealtVal.Value-HealthNum.Value do
  1385. wait()
  1386. end
  1387. HealthNum.Value=HealthNum.Value+HealthNumber
  1388. mode.Value=2
  1389. end))
  1390. while mode.Value==3 do
  1391. Humanoid.PlatformStand=false
  1392. Humanoid.Sit=false
  1393. Humanoid.Parent=Character
  1394. if Torso.Parent==nil then
  1395. Humanoid.Parent=Character
  1396. RootPart.Parent=Character
  1397. BodPos.position=workspace["Map"].ReferenceMiddle.Position+vt(0,50,0)
  1398. BodPos.Parent=RootPart
  1399. RootPart.CFrame=BPRef.CFrame
  1400. BPRef.CFrame=Torso.CFrame
  1401. BodPos.position=BPRef.Position
  1402. Torso.Parent=Character
  1403. Head.Parent=Character
  1404. LeftArm.Parent=Character
  1405. RightArm.Parent=Character
  1406. LeftLeg.Parent=Character
  1407. RightLeg.Parent=Character
  1408. Neck.Parent=Torso
  1409. RootJoint.Parent=Torso
  1410. RW.Parent=Torso
  1411. LW.Parent=Torso
  1412. RH.Parent=Torso
  1413. LH.Parent=Torso
  1414. wait(.1)
  1415. Humanoid.MaxHealth=HealtVal.Value
  1416. Humanoid.Health=HealtVal2.Value
  1417. coroutine.resume(coroutine.create(function()
  1418. for i=1,20 do
  1419. Humanoid.Health=HealtVal2.Value
  1420. Neck.Parent=Torso
  1421. RootJoint.Parent=Torso
  1422. RW.Parent=Torso
  1423. LW.Parent=Torso
  1424. RH.Parent=Torso
  1425. LH.Parent=Torso
  1426. end
  1427. Humanoid:TakeDamage(1)
  1428. end))
  1429. end
  1430. Neck.C0=cf(0,1,0)*euler(-0.2,0,0)
  1431. RW.C0=cf(1.5,0.5,0)*euler(0,0,0.3)
  1432. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1433. LW.C0=cf(-1.5,0.5,0)*euler(0,0,-0.3)
  1434. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1435. wait(1)
  1436. local targetting=false
  1437. if target~=nil then
  1438. targetting=true
  1439. local dist=(RootPart.Position - target.Position).magnitude
  1440. if Anim.Value=="Floating" then
  1441. dist=500
  1442. end
  1443. coroutine.resume(coroutine.create(function()
  1444. while targetting==true do
  1445. target=findNearestTorso(RootPart.Position)
  1446. if target==nil then
  1447. target=Torso2
  1448. end
  1449. wait(0)
  1450. end
  1451. end))
  1452. if dist>=50 then
  1453. attack=math.random(1,2)
  1454. if attack==1 then --Dark Rain
  1455. local n=2
  1456. for i=0,1,0.1 do
  1457. wait()
  1458. Neck.C0=cf(0,1,0)*euler(-0.2+0.6*i*n,0,0)
  1459. RW.C0=cf(1.5,0.5,0)*euler(3.14*i*n,0,0.3-0.3*i*n)
  1460. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1461. LW.C0=cf(-1.5,0.5,0)*euler(-0.2*i*n,0,-0.3)
  1462. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1463. n=n-0.1
  1464. end
  1465. for i=1,math.random(20,40) do
  1466. wait(.05)
  1467. MagicBlock(BrickColor.new("Really black"),RightArm2.CFrame*cf(0,-5,0),30,30,30,2,2,2,0.1)
  1468. local orb=part(3,Character,0,0.5,BrickColor.new("Really black"),"Orb",vt())
  1469. orb.Anchored=true
  1470. so("http://roblox.com/asset/?id=183763498",orb,1,1.2)
  1471. local omsh=mesh("SpecialMesh",orb,"Sphere","",vt(0,0,0),vt(10,10,10))
  1472. orb.CFrame=cf(target.Position+vt(math.random(-10,10),math.random(50,100),math.random(-10,10)))
  1473. MagicCircle(BrickColor.new("Really black"),orb.CFrame,10,10,10,1,1,1,0.1)
  1474. coroutine.resume(coroutine.create(function(Part,Mesh,Weld)
  1475. wait(1)
  1476. Part.Parent=nil
  1477. local spread=vt((math.random(-1,0)+math.random())*16,(math.random(-1,0)+math.random())*16,(math.random(-1,0)+math.random())*16)*(Part.Position-(Part.Position+vt(0,-1,0))).magnitude/100
  1478. local TheHit=Part.Position+vt(0,-1,0)
  1479. local MouseLook=cf((Part.Position+TheHit)/2,TheHit+spread)
  1480. local hit,pos = rayCast(Part.Position,MouseLook.lookVector,999,Character)
  1481. local mag=(Part.Position-pos).magnitude
  1482. MagicCylinder(BrickColor.new("Really black"),CFrame.new((Part.Position+pos)/2,pos)*angles(1.57,0,0) ,1,mag*5,1,0.5,0,0.5,0.05)
  1483. MagicBlock(BrickColor.new("Really black"),Part.CFrame,8,8,8,0.5,0.5,0.5,0.1)
  1484. MagicBlock(BrickColor.new("Really black"),cf(pos),15,15,15,6,6,6,0.1)
  1485. MagicRing(BrickColor.new("Really black"),cf(pos)*euler(1.57,math.random(-100,100)/100,math.random(-100,100)/100),1,1,1,2,2,2,0.05)
  1486. local ref=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1487. ref.CFrame=cf(pos)
  1488. so("http://roblox.com/asset/?id=183763487",ref,1,1)
  1489. coroutine.resume(coroutine.create(function(Part)
  1490. wait(1)
  1491. Part.Parent=nil
  1492. end),ref)
  1493. MagniDamage(ref,15,5,10,0,"Normal",RootPart)
  1494. if hit~=nil then
  1495. Damagefunc(hit,20,40,1,"Knockdown",RootPart,0)
  1496. end
  1497. end),orb,omsh,owld)
  1498. end
  1499. wait(0.5)
  1500. local n=2
  1501. for i=0,1,0.1 do
  1502. wait()
  1503. Neck.C0=cf(0,1,0)*euler(0.4-0.6*i*n,0,0)
  1504. RW.C0=cf(1.5,0.5,0)*euler(3.14-3.14*i*n,0,0.3*i*n)
  1505. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1506. LW.C0=cf(-1.5,0.5,0)*euler(-0.2+0.2*i*n,0,-0.3)
  1507. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1508. n=n-0.1
  1509. end
  1510. wait(1)
  1511. elseif attack==2 then --Nocturne
  1512. local n=2
  1513. for i=0,1,0.1 do
  1514. wait()
  1515. Neck.C0=cf(0,1,0)*euler(-0.2+0.6*i*n,0,0)
  1516. RW.C0=cf(1.5,0.5,0)*euler(3.14*i*n,0,0.3-0.9*i*n)
  1517. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1518. LW.C0=cf(-1.5,0.5,0)*euler(3.14*i*n,0,-0.3+0.9*i*n)
  1519. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1520. n=n-0.1
  1521. end
  1522. local orb=part(3,Character,0,1,BrickColor.new("Really black"),"Orb",vt())
  1523. local omsh=mesh("SpecialMesh",orb,"Sphere","",vt(0,0,0),vt(15,15,15))
  1524. local owld=weld(orb,orb,Torso,cf(0,-10,0))
  1525. so("http://roblox.com/asset/?id=137463716",orb,1,0.6)
  1526. for i=1,0.3,-0.01 do
  1527. wait()
  1528. orb.Transparency=i
  1529. omsh.Scale=omsh.Scale+vt(0.5,0.5,0.5)
  1530. MagicBlock(BrickColor.new("Really black"),orb.CFrame,15,15,15,2,2,2,0.1)
  1531. local ef=part(3,workspace,0,0,BrickColor.new("Really black"),"Effect",vt())
  1532. ef.Anchored=true
  1533. local emsh=mesh("SpecialMesh",ef,"Sphere","",vt(0,0,0),vt(2,math.random(1000,1500)/100,2))
  1534. local ceef=euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))*cf(0,math.random(10,20),0)
  1535. ef.CFrame=orb.CFrame*ceef
  1536. game:GetService("Debris"):AddItem(ef,2)
  1537. coroutine.resume(coroutine.create(function(Part,Mesh)
  1538. for i=0,1,0.1 do
  1539. wait()
  1540. Part.Transparency=i
  1541. Part.CFrame=Part.CFrame*cf(0,-1,0)
  1542. end
  1543. Part.Parent=nil
  1544. end),ef,emsh)
  1545. end
  1546. local Pos=cf(orb.Position,target.Position).lookVector
  1547. wait(.5)
  1548. orb.Parent=nil
  1549. local hit,pos = rayCast(orb.Position,Pos,999,Character)
  1550. local mag=(orb.Position-pos).magnitude
  1551. MagicCircle(BrickColor.new("Really black"),cf(pos),15,15,15,8,8,8,0.02)
  1552. MagicBlock(BrickColor.new("Really black"),cf(pos),15,15,15,8,8,8,0.02)
  1553. MagicCylinder(BrickColor.new("Really black"),CFrame.new((orb.Position+pos)/2,pos)*euler(1.57,0,0),10,mag*5,10,0.5,0,0.5,0.01)
  1554. for i=1,2 do
  1555. MagicRing(BrickColor.new("Really black"),cf(pos)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)),3,3,3,1,1,1,0.04)
  1556. end
  1557. for i=1,5 do
  1558. tehcf=CFrame.new((orb.Position+pos)/2,pos)*euler(1.57,0,0)*cf(0,(mag/5)*(i/2),0)
  1559. MagicRing(BrickColor.new("Really black"),tehcf*euler(1.57,0,0),1,1,1,0.5,0.5,0.5,0.01)
  1560. end
  1561. for i=0,5 do
  1562. tehcf=CFrame.new((orb.Position+pos)/2,pos)*euler(1.57,0,0)*cf(0,(-mag/5)*(i/2),0)
  1563. MagicRing(BrickColor.new("Really black"),tehcf*euler(1.57,0,0),1,1,1,0.5,0.5,0.5,0.01)
  1564. end
  1565. local ref=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1566. ref.CFrame=cf(pos)
  1567. so("http://roblox.com/asset/?id=183763506",Torso,1,0.6)
  1568. so("http://roblox.com/asset/?id=178452221",Torso,1,0.6)
  1569. so("http://www.roblox.com/Asset?ID=87767777",Torso,1,1)
  1570. so("http://roblox.com/asset/?id=183763506",ref,1,0.6)
  1571. so("http://roblox.com/asset/?id=178452221",ref,1,0.6)
  1572. so("http://www.roblox.com/Asset?ID=87767777",ref,1,1)
  1573. coroutine.resume(coroutine.create(function(Part)
  1574. wait(1)
  1575. Part.Parent=nil
  1576. end),ref)
  1577. MagniDamage(ref,20,10,30,40,"Knockdown",ref)
  1578. if hit~=nil then
  1579. Damagefunc(hit,30,70,50,"Knockdown",RootPart,0)
  1580. end
  1581. wait(1)
  1582. local n=2
  1583. for i=0,1,0.1 do
  1584. wait()
  1585. Neck.C0=cf(0,1,0)*euler(0.4-0.6*i*n,0,0)
  1586. RW.C0=cf(1.5,0.5,0)*euler(3.14-3.14*i*n,0,-0.6+0.9*i*n)
  1587. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1588. LW.C0=cf(-1.5,0.5,0)*euler(3.14-3.14*i*n,0,0.6-0.9*i*n)
  1589. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1590. n=n-0.1
  1591. end
  1592. end
  1593. else
  1594. attack=math.random(1,2)
  1595. if attack==1 then --Titan Fall
  1596. attacking=true
  1597. Humanoid.WalkSpeed=0
  1598. local n=2
  1599. for i=0,1,0.05 do
  1600. wait()
  1601. cf4=6-2*i*n
  1602. cf5=2+2*i*n
  1603. cf6=-2*i*n
  1604. cf7=-6+2*i*n
  1605. cf8=2+2*i*n
  1606. cf9=-2*i*n
  1607. Neck.C0=cf(0,1,0)*euler(-0.2+0.8*i*n,0,0)
  1608. RW.C0=cf(1.5-0.5*i*n,0.5+0.5*i*n,-0.5*i*n)*euler(3.14*i*n,0,0.3-0.9*i*n)
  1609. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1610. LW.C0=cf(-1.5+0.5*i*n,0.5+0.5*i*n,-0.5*i*n)*euler(3.14*i*n,0,-0.3+0.9*i*n)
  1611. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1612. n=n-0.05
  1613. end
  1614. wait(0.3)
  1615. so("http://www.roblox.com/asset/?id=169445121",Torso2,1,0.6)
  1616. n=2
  1617. for i=0,1,0.2 do
  1618. wait()
  1619. MagicBlock(BrickColor.new("Really black"),RightArm2.CFrame*cf(0,-5,0),30,30,30,2,2,2,0.1)
  1620. MagicBlock(BrickColor.new("Really black"),LeftArm2.CFrame*cf(0,-5,0),30,30,30,2,2,2,0.1)
  1621. cf11=-4+2*i*n
  1622. cf12=-2*i*n
  1623. cf5=4-4*i*n
  1624. cf8=4-4*i*n
  1625. RootJoint.C0=cf(0,-14.5+3*i*n,0)*euler(0,0,0)
  1626. Neck.C0=cf(0,1,0)*euler(0.6-1*i*n,0,0)
  1627. RW.C0=cf(1,1-1*i*n,-0.5)*euler(3.14-2.64*i*n,0,-0.6)
  1628. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1629. LW.C0=cf(-1,1-1*i*n,-0.5)*euler(3.14-2.64*i*n,0,0.6)
  1630. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1631. RH.C0=cf(0.5,-1+0.5*i*n,-0.5*i*n)*euler(-0.1*i*n,0,0)
  1632. RH.C1=cf(0,1,0)
  1633. LH.C0=cf(-0.5,-1,0)*euler(-0.6*i*n,0,0)
  1634. LH.C1=cf(0,1,0)
  1635. n=n-0.2
  1636. end
  1637. local cf2=RootPart.CFrame*cf(0,500,-20)
  1638. local ref=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1639. ref.CFrame=cf2
  1640. ref.Anchored=true
  1641. local TheHit=ref.Position+vt(0,-1,0)
  1642. local MouseLook=cf((ref.Position+TheHit)/2,TheHit)
  1643. local hit,pos = rayCast(ref.Position,MouseLook.lookVector,999,Character)
  1644. local ref2=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1645. ref2.CFrame=cf(pos)
  1646. ref2.Anchored=true
  1647. local mag=(ref.Position-pos).magnitude
  1648. MagicCylinder(BrickColor.new("Really black"),CFrame.new((ref.Position+pos)/2,pos)*angles(1.57,0,0),5,mag*5,5,1,0,1,0.05)
  1649. MagicCircle(BrickColor.new("Really black"),ref2.CFrame,15,15,15,8,8,8,0.02)
  1650. MagicBlock(BrickColor.new("Really black"),ref2.CFrame,15,15,15,3,3,3,0.02)
  1651. WaveEffect2(BrickColor.new("Really black"),ref2.CFrame,5,5,5,2,3,2,0.05)
  1652. MagicRing(BrickColor.new("Really black"),cf(ref2.Position)*euler(1.57,0,0),5,5,5,4,4,4,0.05)
  1653. MagniDamage(ref2,25,20,50,math.random(10,30),"Knockdown",ref2)
  1654. --so("http://roblox.com/asset/?id=144844438",ref2,1,0.8)
  1655. so("http://roblox.com/asset/?id=87784452",ref2,1,0.8)
  1656. so("http://roblox.com/asset/?id=183763515",ref2,1,0.8)
  1657. game:GetService("Debris"):AddItem(ref,2)
  1658. game:GetService("Debris"):AddItem(ref2,2)
  1659. wait(1)
  1660. n=2
  1661. for i=0,1,0.1 do
  1662. wait()
  1663. cf4=4+2*i*n
  1664. cf5=2*i*n
  1665. cf6=-2+2*i*n
  1666. cf7=-4-2*i*n
  1667. cf8=2*i*n
  1668. cf9=-2+2*i*n
  1669. cf11=-4+2-2*i*n
  1670. cf12=-2+2*i*n
  1671. RootJoint.C0=cf(0,-14.5+3-3*i*n,0)*euler(0,0,0)
  1672. Neck.C0=cf(0,1,0)*euler(-0.4+0.2*i*n,0,0)
  1673. RW.C0=cf(1+0.5*i*n,0.5*i*n,-0.5+0.5*i*n)*euler(0.5-0.5*i*n,0,-0.6+0.9*i*n)
  1674. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1675. LW.C0=cf(-1-0.5*i*n,0.5*i*n,-0.5+0.5*i*n)*euler(0.5-0.5*i*n,0,0.6-0.9*i*n)
  1676. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1677. RH.C0=cf(0.5,-0.5-0.5*i*n,-0.5+0.5*i*n)*euler(-0.1+0.1*i*n,0,0)
  1678. RH.C1=cf(0,1,0)
  1679. LH.C0=cf(-0.5,-1,0)*euler(-0.6+0.6*i*n,0,0)
  1680. LH.C1=cf(0,1,0)
  1681. n=n-0.1
  1682. end
  1683. wait(1)
  1684. Humanoid.WalkSpeed=25
  1685. attacking=false
  1686. elseif attack==2 then --Dark Stomp
  1687. attacking=true
  1688. Humanoid.WalkSpeed=0
  1689. local n=2
  1690. for i=0,1,0.1 do
  1691. wait()
  1692. cf11=-4+2*i*n
  1693. cf12=-2*i*n
  1694. --cf13=-2
  1695. --cf14=-4
  1696. --cf15=0
  1697. RootJoint.C0=cf(0,-14.5,0)*euler(0.2*i*n,0,0)
  1698. Neck.C0=cf(0,1,0)*euler(-0.2-0.4*i*n,0,0)
  1699. RW.C0=cf(1.5,0.5,0)*euler(-0.2*i*n,0,0.3)
  1700. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1701. LW.C0=cf(-1.5,0.5,0)*euler(-0.2*i*n,0,-0.3)
  1702. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1703. RH.C0=cf(0.5,-1+0.5*i*n,-0.5*i*n)*euler(0.2*i*n,0,0)
  1704. RH.C1=cf(0,1,0)
  1705. LH.C0=cf(-0.5,-1,0)*euler(-0.2*i*n,0,0)
  1706. LH.C1=cf(0,1,0)
  1707. n=n-0.1
  1708. end
  1709. so("http://www.roblox.com/asset/?id=169445046",RightLeg2,1,0.6)
  1710. local n=2
  1711. for i=0,1,0.2 do
  1712. wait()
  1713. cf11=-2-2*i*n
  1714. RH.C0=cf(0.5,-0.5-0.5*i*n,-0.5)*euler(0.2+0.1*i*n,0,0)
  1715. RH.C1=cf(0,1,0)
  1716. n=n-0.2
  1717. end
  1718. MagicCylinder(BrickColor.new("Really black"),cf(RightLeg2.Position+vt(0,-4,0)),10,4,10,5,3,5,0.05)
  1719. local numb=-8
  1720. local basecf=RootPart.CFrame
  1721. for i=1,4 do
  1722. local cf2=basecf*cf(0,0,numb)
  1723. local ref=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1724. ref.CFrame=cf2
  1725. ref.Anchored=true
  1726. local TheHit=ref.Position+vt(0,-1,0)
  1727. local MouseLook=cf((ref.Position+TheHit)/2,TheHit)
  1728. local hit,pos = rayCast(ref.Position,MouseLook.lookVector,999,Character)
  1729. local ref2=part(3,workspace,0,1,BrickColor.new("Really black"),"Effect",vt())
  1730. ref2.CFrame=cf(pos)
  1731. ref2.Anchored=true
  1732. MagicCircle(BrickColor.new("Really black"),ref2.CFrame,15,15,15,8,8,8,0.02)
  1733. MagicWaveThing(BrickColor.new("Really black"),ref2.CFrame,5,5,5,2,2,2,0.05)
  1734. MagniDamage(ref2,20,20,30,math.random(5,20),"Normal",RootPart)
  1735. so("http://www.roblox.com/asset/?id=161006093",ref2,1,0.6)
  1736. game:GetService("Debris"):AddItem(ref,2)
  1737. game:GetService("Debris"):AddItem(ref2,2)
  1738. numb=numb-15
  1739. wait(0.4)
  1740. end
  1741. --wait(1)
  1742. local n=2
  1743. for i=0,1,0.1 do
  1744. wait()
  1745. cf12=-2+2*i*n
  1746. RootJoint.C0=cf(0,-14.5,0)*euler(0.2-0.2*i*n,0,0)
  1747. Neck.C0=cf(0,1,0)*euler(-0.6+0.4*i*n,0,0)
  1748. RW.C0=cf(1.5,0.5,0)*euler(-0.2+0.2*i*n,0,0.3)
  1749. RW.C1=cf(0,0.5,0)*euler(0,0,0)
  1750. LW.C0=cf(-1.5,0.5,0)*euler(-0.2+0.2*i*n,0,-0.3)
  1751. LW.C1=cf(0,0.5,0)*euler(0,0,0)
  1752. RH.C0=cf(0.5,-1,-0.5+0.5*i*n)*euler(0.3-0.3*i*n,0,0)
  1753. RH.C1=cf(0,1,0)
  1754. LH.C0=cf(-0.5,-1,0)*euler(-0.2+0.2*i*n,0,0)
  1755. LH.C1=cf(0,1,0)
  1756. n=n-0.1
  1757. end
  1758. Humanoid.WalkSpeed=25
  1759. attacking=false
  1760. wait(1)
  1761. elseif attack==3 then
  1762. end
  1763. end
  1764. targetting=false
  1765. end
  1766. end
  1767. --Destroy body
  1768. DarkBody=false
  1769. HealtVal2.Value=Humanoid.Health
  1770. Head2.Anchored=true
  1771. Torso2.Anchored=true
  1772. LeftArm2.Anchored=true
  1773. RightArm2.Anchored=true
  1774. LeftLeg2.Anchored=true
  1775. RightLeg2.Anchored=true
  1776. Neck2.Parent=nil
  1777. RW2.Parent=nil
  1778. LW2.Parent=nil
  1779. RH2.Parent=nil
  1780. LH2.Parent=nil
  1781. RootJoint2.Parent=nil
  1782. coroutine.resume(coroutine.create(function()
  1783. for i=0.5,1,0.05 do
  1784. wait()
  1785. Head2.Transparency=i
  1786. Torso2.Transparency=i
  1787. LeftArm2.Transparency=i
  1788. RightArm2.Transparency=i
  1789. LeftLeg2.Transparency=i
  1790. RightLeg2.Transparency=i
  1791. end
  1792. Head2.Parent=nil
  1793. Torso2.Parent=nil
  1794. LeftArm2.Parent=nil
  1795. RightArm2.Parent=nil
  1796. LeftLeg2.Parent=nil
  1797. RightLeg2.Parent=nil
  1798. end))
  1799. DarkLegEffect=true
  1800. coroutine.resume(coroutine.create(function(Leg1,Leg2)
  1801. while DarkLegEffect==true do
  1802. wait(0.1)
  1803. MagicBlock(BrickColor.new("Really black"),Leg1.CFrame*cf(0,-1,0),5,5,5,0.5,0.5,0.5,0.1)
  1804. MagicBlock(BrickColor.new("Really black"),Leg2.CFrame*cf(0,-1,0),5,5,5,0.5,0.5,0.5,0.1)
  1805. end
  1806. end),RightLeg,LeftLeg)
  1807. Humanoid.MaxHealth=math.huge
  1808. Humanoid.Health=math.huge
  1809. coroutine.resume(coroutine.create(function()
  1810. for i=1,20 do
  1811. Humanoid.Health=Humanoid.MaxHealth
  1812. end
  1813. Humanoid:TakeDamage(1)
  1814. end))
  1815. RootJoint.C0=cf(0,0,0)
  1816. MagicBlock(BrickColor.new("Really black"),Torso.CFrame,15,15,15,6,6,6,0.1)
  1817. BPRef.CFrame=MainPosition
  1818. Torso.CFrame=BPRef.CFrame
  1819. BodPos.position=BPRef.Position
  1820. BodGy.Parent=Torso
  1821. MagicBlock(BrickColor.new("Really black"),Torso.CFrame,15,15,15,6,6,6,0.1)
  1822. BodGy.cframe=CF*euler(0,1.57,0)
  1823. BodPos.Parent=RootPart
  1824. BodPos.maxForce=vt(math.huge,math.huge,math.huge)
  1825. coroutine.resume(coroutine.create(function()
  1826. for i=0,40 do
  1827. wait()
  1828. BodPos.Parent=RootPart
  1829. end
  1830. end))
  1831. for i=0,1,0.1 do
  1832. wait()
  1833. RH.C0=cf(0.5,-1,0)*euler(-0.3*i,0,0.2*i)
  1834. RH.C1=cf(0,1,0)
  1835. LH.C0=cf(-0.5,-1,0)*euler(-0.3*i,0,-0.2*i)
  1836. LH.C1=cf(0,1,0)
  1837. end
  1838. if Humanoid.Health>0 then
  1839. SummonCrystals()
  1840. end
  1841. wait(1)
  1842. end
  1843. DarkLegEffect=false
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement