Advertisement
KHSora455

Cyber Stratosphere

Jul 16th, 2015
520
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 49.32 KB | None | 0 0
  1.  
  2. --[[
  3. Cyber Stratosphere Class Made by Fenrier.
  4. ]]
  5. Player=game:GetService("Players").LocalPlayer
  6. Character=Player.Character
  7. PlayerGui=Player.PlayerGui
  8. Backpack=Player.Backpack
  9. Torso=Character.Torso
  10. Head=Character.Head
  11. Humanoid=Character.Humanoid
  12. LeftArm=Character["Left Arm"]
  13. LeftLeg=Character["Left Leg"]
  14. RightArm=Character["Right Arm"]
  15. RightLeg=Character["Right Leg"]
  16. LS=Torso["Left Shoulder"]
  17. LH=Torso["Left Hip"]
  18. RS=Torso["Right Shoulder"]
  19. RH=Torso["Right Hip"]
  20. Neck=Torso.Neck
  21. it=Instance.new
  22. vt=Vector3.new
  23. cf=CFrame.new
  24. euler=CFrame.fromEulerAnglesXYZ
  25. angles=CFrame.Angles
  26. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  27. necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  28. LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
  29. LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
  30. RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
  31. RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
  32. RootPart=Character.HumanoidRootPart
  33. RootJoint=RootPart.RootJoint
  34. RootCF=euler(-1.57,0,3.14)
  35. attack = false
  36. attackdebounce = false
  37. MMouse=nil
  38. combo=0
  39. mana=100
  40. local idle=0
  41. local Anim="Idle"
  42. local Effects={}
  43. --player
  44. player=nil
  45. --save shoulders
  46. RSH, LSH=nil, nil
  47. --welds
  48. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  49. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  50. LH=Torso["Left Hip"]
  51. RH=Torso["Right Hip"]
  52. Charge=0
  53. TorsoColor=Torso.BrickColor
  54.  
  55. function swait(num)
  56. if num==0 or num==nil then
  57. game:service'RunService'.RenderStepped:wait()
  58. else
  59. for i=0,num do
  60. game:service'RunService'.RenderStepped:wait()
  61. end
  62. end
  63. end
  64.  
  65. if Character:findFirstChild("Aero Board",true) ~= nil then
  66. Character:findFirstChild("Aero Board",true).Parent = nil
  67. end
  68. if Player.PlayerGui:findFirstChild("WeaponGUI",true) ~= nil then
  69. Player.PlayerGui:findFirstChild("WeaponGUI",true).Parent = nil
  70. end
  71.  
  72.  
  73. function NoOutline(Part)
  74. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  75. end
  76.  
  77. function part(formfactor,parent,reflectance,transparency,brickcolor,name,size)
  78. local fp=it("Part")
  79. fp.formFactor=formfactor
  80. fp.Parent=parent
  81. fp.Reflectance=reflectance
  82. fp.Transparency=transparency
  83. fp.CanCollide=false
  84. fp.Locked=true
  85. fp.BrickColor=brickcolor
  86. fp.Name=name
  87. fp.Size=size
  88. fp.Position=Torso.Position
  89. NoOutline(fp)
  90. fp.Material="SmoothPlastic"
  91. fp:BreakJoints()
  92. return fp
  93. end
  94.  
  95. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  96. local mesh=it(Mesh)
  97. mesh.Parent=part
  98. if Mesh=="SpecialMesh" then
  99. mesh.MeshType=meshtype
  100. mesh.MeshId=meshid
  101. end
  102. mesh.Offset=offset
  103. mesh.Scale=scale
  104. return mesh
  105. end
  106.  
  107. function weld(parent,part0,part1,c0)
  108. local weld=it("Weld")
  109. weld.Parent=parent
  110. weld.Part0=part0
  111. weld.Part1=part1
  112. weld.C0=c0
  113. return weld
  114. end
  115.  
  116. local Color1=Torso.BrickColor
  117.  
  118. local fengui=it("GuiMain")
  119. fengui.Parent=Player.PlayerGui
  120. fengui.Name="WeaponGUI"
  121. local fenframe=it("Frame")
  122. fenframe.Parent=fengui
  123. fenframe.BackgroundColor3=Color3.new(255,255,255)
  124. fenframe.BackgroundTransparency=1
  125. fenframe.BorderColor3=Color3.new(17,17,17)
  126. fenframe.Size=UDim2.new(0.0500000007, 0, 0.100000001, 0)
  127. fenframe.Position=UDim2.new(0.4,0,0.1,0)
  128. local fenbarmana1=it("TextLabel")
  129. fenbarmana1.Parent=fenframe
  130. fenbarmana1.Text=" "
  131. fenbarmana1.BackgroundTransparency=0
  132. fenbarmana1.BackgroundColor3=Color3.new(0,0,0)
  133. fenbarmana1.SizeConstraint="RelativeXY"
  134. fenbarmana1.TextXAlignment="Center"
  135. fenbarmana1.TextYAlignment="Center"
  136. fenbarmana1.Position=UDim2.new(0,0,0,0)
  137. fenbarmana1.Size=UDim2.new(4,0,0.2,0)
  138. local fenbarmana2=it("TextLabel")
  139. fenbarmana2.Parent=fenframe
  140. fenbarmana2.Text=" "
  141. fenbarmana2.BackgroundTransparency=0
  142. fenbarmana2.BackgroundColor3=Torso.Color
  143. fenbarmana2.SizeConstraint="RelativeXY"
  144. fenbarmana2.TextXAlignment="Center"
  145. fenbarmana2.TextYAlignment="Center"
  146. fenbarmana2.Position=UDim2.new(0,0,0,0)
  147. fenbarmana2.Size=UDim2.new(4*mana/100,0,0.2,0)
  148. local fenbarmana3=it("TextLabel")
  149. fenbarmana3.Parent=fenframe
  150. fenbarmana3.Text=" "
  151. fenbarmana3.BackgroundTransparency=0
  152. fenbarmana3.BackgroundColor3=Color3.new(Col1,Col2,Col3)
  153. fenbarmana3.SizeConstraint="RelativeXY"
  154. fenbarmana3.TextXAlignment="Center"
  155. fenbarmana3.TextYAlignment="Center"
  156. fenbarmana3.Position=UDim2.new(0,0,0,0)
  157. fenbarmana3.Size=UDim2.new(0,0,0.2,0)
  158. local fenbarmana4=it("TextLabel")
  159. fenbarmana4.Parent=fenframe
  160. fenbarmana4.Text="Energy("..mana..")"
  161. fenbarmana4.BackgroundTransparency=1
  162. fenbarmana4.BackgroundColor3=Color3.new(0,0,0)
  163. fenbarmana4.SizeConstraint="RelativeXY"
  164. fenbarmana4.TextXAlignment="Center"
  165. fenbarmana4.TextYAlignment="Center"
  166. fenbarmana4.Position=UDim2.new(0,0,-0.3,0)
  167. fenbarmana4.Size=UDim2.new(4,0,0.2,0)
  168. fenbarmana4.FontSize="Size9"
  169. fenbarmana4.TextStrokeTransparency=0
  170. fenbarmana4.TextColor=BrickColor.new("White")
  171.  
  172. local modelzorz=Instance.new("Model")
  173. modelzorz.Parent=Character
  174. modelzorz.Name="Aero Board"
  175.  
  176. local handle=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Handle1",vt())
  177. local hprt2=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Handle2",vt())
  178. local hprt3=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Handle3",vt())
  179. local prt1=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part1",vt())
  180. local prt2=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part2",vt())
  181. local prt3=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part3",vt())
  182. local prt4=part(3,modelzorz,0,0,TorsoColor,"Part4",vt())
  183. local prt5=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part5",vt())
  184. local prt6=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part6",vt())
  185. local prt7=part(3,modelzorz,0,0,TorsoColor,"Part7",vt())
  186. local prt8=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part8",vt())
  187. local prt9=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part9",vt())
  188. local prt10=part(3,modelzorz,0,0,TorsoColor,"Part10",vt())
  189. local prt11=part(3,modelzorz,0,0,TorsoColor,"Part11",vt())
  190. local prt12=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part12",vt())
  191. local prt13=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part13",vt())
  192. local prt14=part(3,modelzorz,0,0,BrickColor.new("Really black"),"Part14",vt())
  193. local prt15=part(3,modelzorz,0,0,TorsoColor,"Part15",vt())
  194. local prt16=part(3,modelzorz,0,0,TorsoColor,"Part16",vt())
  195. local prt17=part(3,modelzorz,0,0,TorsoColor,"Part17",vt())
  196. local prt18=part(3,modelzorz,0,0,TorsoColor,"Part18",vt())
  197. local prt19=part(3,modelzorz,0,0,TorsoColor,"Part19",vt())
  198. local prt20=part(3,modelzorz,0,0,TorsoColor,"Part20",vt())
  199. local prt21=part(3,modelzorz,0,0,TorsoColor,"Part21",vt())
  200. local prt22=part(3,modelzorz,0,0,BrickColor.new("White"),"Part22",vt())
  201. local prt23=part(3,modelzorz,0,0,BrickColor.new("White"),"Part23",vt())
  202. local prt24=part(3,modelzorz,0,0,TorsoColor,"Part24",vt())
  203. local prt25=part(3,modelzorz,0,0,TorsoColor,"Part25",vt())
  204.  
  205. local hmsh=mesh("BlockMesh",handle,"","",vt(0,0,0),vt(1,1,5))
  206. local hmsh2=mesh("BlockMesh",hprt2,"","",vt(0,0,0),vt(1,1,2))
  207. local hmsh3=mesh("BlockMesh",hprt3,"","",vt(0,0,0),vt(1,1,2))
  208. local msh1=mesh("BlockMesh",prt1,"","",vt(0,0,0),vt(2,30,12))
  209. local msh2=mesh("CylinderMesh",prt2,"","",vt(0,0,0),vt(5,1.99,5))
  210. local msh3=mesh("SpecialMesh",prt3,"Wedge","",vt(0,0,0),vt(2,3,2.3))
  211. local msh4=mesh("SpecialMesh",prt4,"Wedge","",vt(0,0,0),vt(2.1,1.5,1.15))
  212. local msh5=mesh("CylinderMesh",prt5,"","",vt(0,0,0),vt(5,1.99,5))
  213. local msh6=mesh("SpecialMesh",prt6,"Wedge","",vt(0,0,0),vt(2,3,2.3))
  214. local msh7=mesh("SpecialMesh",prt7,"Wedge","",vt(0,0,0),vt(2.1,1.5,1.15))
  215. local msh8=mesh("SpecialMesh",prt8,"Torso","",vt(0,0,0),vt(6,1,1.98))
  216. local msh9=mesh("SpecialMesh",prt9,"Torso","",vt(0,0,0),vt(6,1,1.98))
  217. local msh10=mesh("SpecialMesh",prt10,"Wedge","",vt(0,0,0),vt(2,1,8))
  218. local msh11=mesh("SpecialMesh",prt11,"Wedge","",vt(0,0,0),vt(2,1,8))
  219. local msh12=mesh("SpecialMesh",prt12,"Torso","",vt(0,0,0),vt(10,3,2.05))
  220. local msh13=mesh("SpecialMesh",prt13,"Torso","",vt(0,0,0),vt(10,3,2.05))
  221. local msh14=mesh("BlockMesh",prt14,"","",vt(0,0,0),vt(10,10,2.05))
  222. local msh15=mesh("SpecialMesh",prt15,"Torso","",vt(0,0,0),vt(8,2,2.1))
  223. local msh16=mesh("SpecialMesh",prt16,"Torso","",vt(0,0,0),vt(8,2,2.1))
  224. local msh17=mesh("BlockMesh",prt17,"","",vt(0,0,0),vt(8,.5,2.1))
  225. local msh18=mesh("BlockMesh",prt18,"","",vt(0,0,0),vt(8,.5,2.1))
  226. local msh19=mesh("BlockMesh",prt19,"","",vt(0,0,0),vt(2.1,5,6))
  227. local msh20=mesh("SpecialMesh",prt20,"Wedge","",vt(0,0,0),vt(2.1,3,2))
  228. local msh21=mesh("SpecialMesh",prt21,"Wedge","",vt(0,0,0),vt(2.1,3,2))
  229. local msh22=mesh("SpecialMesh",prt22,"Sphere","",vt(0,0,0),vt(1,6,5))
  230. local msh23=mesh("SpecialMesh",prt23,"Sphere","",vt(0,0,0),vt(1,8,5))
  231. local msh24=mesh("BlockMesh",prt24,"","",vt(0,0,0),vt(2.1,16,5))
  232. local msh25=mesh("SpecialMesh",prt25,"Torso","",vt(0,0,0),vt(5,5,2.1))
  233.  
  234. local hwld=weld(handle,handle,Torso,euler(1,1.57,0)*cf(-1,-1,-1))
  235. --local hwld=weld(handle,handle,RightArm,euler(0,0,0)*cf(0,1,0))
  236. --local hwld=weld(handle,handle,Torso,euler(0,0,-1.57)*cf(1,2.5,0))
  237. local hwld2=weld(hprt2,hprt2,handle,euler(0,1.57,0)*cf(.2,0,.4))
  238. local hwld3=weld(hprt3,hprt3,handle,euler(0,1.57,0)*cf(.2,0,-.4))
  239. local wld1=weld(prt1,prt1,handle,euler(0,0,0)*cf(.5,1,0))
  240. local wld2=weld(prt2,prt2,prt1,euler(0,0,1.57)*cf(0,-2.5,1.2))
  241. local wld3=weld(prt3,prt3,prt2,euler(0,0,1.57)*cf(-.5,0,.23))
  242. local wld4=weld(prt4,prt4,prt3,euler(0,0,0)*cf(0,0,-0.1))
  243. local wld5=weld(prt5,prt5,prt1,euler(0,0,1.57)*cf(0,-2.5,-1.2))
  244. local wld6=weld(prt6,prt6,prt5,euler(0,3.14,1.57)*cf(-.5,0,-.23))
  245. local wld7=weld(prt7,prt7,prt6,euler(0,0,0)*cf(0,0,-0.1))
  246. local wld8=weld(prt8,prt8,prt1,euler(1.57,0,1.57)*cf(0,-1.4,1.3))
  247. local wld9=weld(prt9,prt9,prt1,euler(-1.57,0,1.57)*cf(0,-1.4,-1.3))
  248. local wld10=weld(prt10,prt10,prt1,euler(1.57,0,0)*cf(0,-.1,1.3))
  249. local wld11=weld(prt11,prt11,prt1,euler(1.57,3.14,0)*cf(0,-.1,-1.3))
  250. local wld12=weld(prt12,prt12,prt1,euler(1.57,0,1.57)*cf(0,3,1.3))
  251. local wld13=weld(prt13,prt13,prt1,euler(-1.57,0,1.57)*cf(0,3,-1.3))
  252. local wld14=weld(prt14,prt14,prt1,euler(1.57,0,1.57)*cf(0,3,0))
  253. local wld15=weld(prt15,prt15,prt12,euler(0,0,0)*cf(0,.2,0))
  254. local wld16=weld(prt16,prt16,prt13,euler(0,0,0)*cf(0,.2,0))
  255. local wld17=weld(prt17,prt17,prt12,euler(0,0,0)*cf(0,.6,0))
  256. local wld18=weld(prt18,prt18,prt13,euler(0,0,0)*cf(0,.6,0))
  257. local wld19=weld(prt19,prt19,prt1,euler(0,0,0)*cf(0,-2,0))
  258. local wld20=weld(prt20,prt20,prt1,euler(3.14,0,0)*cf(0,-1.2,.4))
  259. local wld21=weld(prt21,prt21,prt1,euler(0,0,3.14)*cf(0,-1.2,-.4))
  260. local wld22=weld(prt22,prt22,prt1,euler(0,0,0)*cf(.2,-.5,0))
  261. local wld23=weld(prt23,prt23,prt1,euler(0,0,0)*cf(.2,1.7,0))
  262. local wld24=weld(prt24,prt24,prt1,euler(0,0,0)*cf(0,2.39,0))
  263. local wld25=weld(prt25,prt25,prt1,euler(0,1.57,0)*cf(0,.29,0))
  264.  
  265. local bprt1=part(3,modelzorz,0,1,TorsoColor,"Boomerang1",vt())
  266. local bmsh1=mesh("CylinderMesh",bprt1,"","",vt(0,0,0),vt(40,1,40))
  267. local bwld1=weld(bprt1,bprt1,prt1,euler(0,0,1.57)*cf(0,.5,0))
  268. eul=0
  269. for i=1,4 do
  270. local bprt2=part(3,modelzorz,0,1,TorsoColor,"Boomerang2",vt())
  271. local bmsh2=mesh("BlockMesh",bprt2,"","",vt(0,0,0),vt(45,1,10))
  272. local bwld2=weld(bprt2,bprt2,bprt1,euler(0,eul,0)*cf(0,0,0))
  273. eul=eul+0.785
  274. end
  275.  
  276. local hitbox=part(3,nil,0,1,BrickColor.new("Really black"),"Hitbox",vt(1,1,1))
  277. hitbox.Anchored=false
  278.  
  279. if (script.Parent.className~="HopperBin") then
  280. Tool=Instance.new("HopperBin")
  281. Tool.Parent=Backpack
  282. Tool.Name="Aero Board"
  283. script.Parent=Tool
  284. end
  285. Bin=script.Parent
  286.  
  287. local bodvel=Instance.new("BodyVelocity")
  288. local bg=Instance.new("BodyGyro")
  289.  
  290. so = function(id,par,vol,pit)
  291. coroutine.resume(coroutine.create(function()
  292. local sou = Instance.new("Sound",par or workspace)
  293. sou.Volume=vol
  294. sou.Pitch=pit or 1
  295. sou.SoundId=id
  296. swait()
  297. sou:play()
  298. game:GetService("Debris"):AddItem(sou,6)
  299. end))
  300. end
  301.  
  302. function clerp(a,b,t)
  303. local qa = {QuaternionFromCFrame(a)}
  304. local qb = {QuaternionFromCFrame(b)}
  305. local ax, ay, az = a.x, a.y, a.z
  306. local bx, by, bz = b.x, b.y, b.z
  307. local _t = 1-t
  308. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  309. end
  310.  
  311. function QuaternionFromCFrame(cf)
  312. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  313. local trace = m00 + m11 + m22
  314. if trace > 0 then
  315. local s = math.sqrt(1 + trace)
  316. local recip = 0.5/s
  317. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  318. else
  319. local i = 0
  320. if m11 > m00 then
  321. i = 1
  322. end
  323. if m22 > (i == 0 and m00 or m11) then
  324. i = 2
  325. end
  326. if i == 0 then
  327. local s = math.sqrt(m00-m11-m22+1)
  328. local recip = 0.5/s
  329. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  330. elseif i == 1 then
  331. local s = math.sqrt(m11-m22-m00+1)
  332. local recip = 0.5/s
  333. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  334. elseif i == 2 then
  335. local s = math.sqrt(m22-m00-m11+1)
  336. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  337. end
  338. end
  339. end
  340.  
  341. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  342. local xs, ys, zs = x + x, y + y, z + z
  343. local wx, wy, wz = w*xs, w*ys, w*zs
  344. local xx = x*xs
  345. local xy = x*ys
  346. local xz = x*zs
  347. local yy = y*ys
  348. local yz = y*zs
  349. local zz = z*zs
  350. 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))
  351. end
  352.  
  353. function QuaternionSlerp(a, b, t)
  354. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  355. local startInterp, finishInterp;
  356. if cosTheta >= 0.0001 then
  357. if (1 - cosTheta) > 0.0001 then
  358. local theta = math.acos(cosTheta)
  359. local invSinTheta = 1/math.sin(theta)
  360. startInterp = math.sin((1-t)*theta)*invSinTheta
  361. finishInterp = math.sin(t*theta)*invSinTheta
  362. else
  363. startInterp = 1-t
  364. finishInterp = t
  365. end
  366. else
  367. if (1+cosTheta) > 0.0001 then
  368. local theta = math.acos(-cosTheta)
  369. local invSinTheta = 1/math.sin(theta)
  370. startInterp = math.sin((t-1)*theta)*invSinTheta
  371. finishInterp = math.sin(t*theta)*invSinTheta
  372. else
  373. startInterp = t-1
  374. finishInterp = t
  375. end
  376. end
  377. 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
  378. end
  379.  
  380. function hideanim()
  381. equipped=false
  382. for i=0,1,0.1 do
  383. swait()
  384. hwld.C0=clerp(hwld.C0,euler(1.57,-1.57,3.5)*cf(.6,.4,1),.3)
  385. Neck.C0=clerp(Neck.C0,necko*euler(-.2,0,-.8),.3)
  386. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,-0.5),.3)
  387. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(3.3,0,-0.1),.3)
  388. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  389. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.2),.3)
  390. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  391. end
  392. hwld.Part1=Torso
  393. hwld.C0=euler(1,1.57,0)*cf(-1,-1,-1)
  394. for i=0,1,0.1 do
  395. swait()
  396. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,0),.4)
  397. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*euler(0,0,0),.4)
  398. Torso.Neck.C1=clerp(Torso.Neck.C1,necko2*euler(0,0,0),.4)
  399. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(0,0,0),.4)
  400. RW.C1=clerp(RW.C1,cf(0,0.5,0)*euler(0,0,0),.4)
  401. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,0),.4)
  402. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.4)
  403. RH.C0=clerp(RH.C0,RHC0,.3)
  404. RH.C1=clerp(RH.C1,RHC1,.3)
  405. LH.C0=clerp(LH.C0,LHC0,.3)
  406. LH.C1=clerp(LH.C1,LHC1,.3)
  407. end
  408. end
  409.  
  410. function equipanim()
  411. equipped=true
  412. for i=0,1,0.1 do
  413. swait()
  414. Neck.C0=clerp(Neck.C0,necko*euler(-.2,0,-.8),.3)
  415. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,-0.5),.3)
  416. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(3.3,0,-0.1),.3)
  417. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  418. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.2),.3)
  419. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  420. end
  421. hwld.Part1=RightArm
  422. hwld.C0=euler(1.57,-1.57,3.5)*cf(.6,.4,1)
  423. so("http://roblox.com/asset/?id=161006212",prt1,1,.6)
  424. for i=0,1,0.1 do
  425. swait()
  426. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  427. Neck.C0=clerp(Neck.C0,necko*euler(.2,0,-.3),.3)
  428. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,.3),.3)
  429. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(1.3,0,-.3),.3)
  430. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  431. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.2),.3)
  432. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  433. end
  434. end
  435.  
  436. function attackone()
  437. attack=true
  438. so("http://roblox.com/asset/?id=2101137",prt1,1,1.4)
  439. for i=0,1,0.1 do
  440. swait()
  441. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  442. Neck.C0=clerp(Neck.C0,necko*euler(0,0,.8),.3)
  443. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,-.8),.3)
  444. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(2,0,.5),.3)
  445. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  446. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(1.57,0,-.8),.3)
  447. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  448. end
  449. Torso.Velocity=RootPart.CFrame.lookVector*100
  450. so("http://roblox.com/asset/?id=161006195",prt1,1,.6)
  451. so("http://roblox.com/asset/?id=2248511",prt1,1,1.4)
  452. MagicCircle(TorsoColor,prt1.CFrame,1,1,1,5,5,5,.05)
  453. hitbox.Parent=modelzorz
  454. hitbox.Size=vt(2,7,4)
  455. hitbox.Transparency=1
  456. hitbox.CFrame=prt1.CFrame
  457. con1=hitbox.Touched:connect(function(hit) Damagefunc(hit,5,10,math.random(1,5),"Normal",RootPart,.5,1) end)
  458. num=0
  459. for i=0,1,0.1 do
  460. swait()
  461. hitbox.CFrame=prt1.CFrame
  462. if num>=3 then
  463. MagicWave(TorsoColor,prt1.CFrame*cf(0,1,0)*euler(3.14,0,0),1,1,1,.5,1,.5,.1)
  464. num=0
  465. end
  466. num=num+1
  467. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1.2)*euler(.2,0,0),.3)
  468. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1.2),.3)
  469. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(1,0,.5),.3)
  470. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  471. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.8),.3)
  472. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  473. RH.C0=clerp(RH.C0,cf(.5,-1,1)*euler(0,1.57,0)*euler(0,-1.2,0),.3)
  474. LH.C0=clerp(LH.C0,cf(-.5,-1,-1)*euler(0,-1.57,0)*euler(0,-1.2,0),.3)
  475. end
  476. con1:disconnect()
  477. hitbox.Parent=nil
  478. swait(10)
  479. attack=false
  480. end
  481.  
  482. function attacktwo()
  483. attack=true
  484. so("http://roblox.com/asset/?id=147722227",prt1,1,.6)
  485. for i=0,1,0.1 do
  486. swait()
  487. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1.2)*euler(.2,0,0),.3)
  488. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1.2),.3)
  489. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(1,0,-.8)*euler(0,1.57,0),.3)
  490. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  491. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.2,0,-.2),.3)
  492. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  493. end
  494. so("http://www.roblox.com/asset/?id=153092348",prt1,1,1.2)
  495. Torso.Velocity=RootPart.CFrame.lookVector*50
  496. hitbox.Parent=modelzorz
  497. hitbox.Size=vt(2,7,4)
  498. hitbox.Transparency=1
  499. hitbox.CFrame=prt1.CFrame
  500. con1=hitbox.Touched:connect(function(hit) Damagefunc(hit,10,20,math.random(1,5),"Normal",RootPart,1,1) end)
  501. for i=0,1,0.1 do
  502. swait()
  503. Torso.Velocity=RootPart.CFrame.lookVector*50
  504. MagicCircle(TorsoColor,prt1.CFrame*cf(0,3,0),1,1,1,5,5,5,.1)
  505. hitbox.CFrame=prt1.CFrame
  506. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-.5),.3)
  507. --RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,.8),.3)
  508. RootJoint.C0=RootCF*euler(0,0,1.2-6.28*i)
  509. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(1.57,0,1)*euler(0,1.57,0),.3)
  510. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  511. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.2,0,-1),.3)
  512. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  513. end
  514. for i=0,1,0.1 do
  515. swait()
  516. hitbox.CFrame=prt1.CFrame
  517. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1),.3)
  518. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1),.3)
  519. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(2,0,1)*euler(0,1.57,0),.3)
  520. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  521. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.4,0,-1),.3)
  522. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  523. end
  524. con1:disconnect()
  525. hitbox.Parent=nil
  526. swait(5)
  527. attack=false
  528. end
  529.  
  530. function attackthree()
  531. attack=true
  532. so("http://roblox.com/asset/?id=147722227",prt1,1,.6)
  533. for i=0,1,0.1 do
  534. swait()
  535. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  536. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1)*euler(.2,0,0),.3)
  537. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1),.3)
  538. RW.C0=clerp(RW.C0,cf(1,0.5,-.5)*euler(1.57,0,-.6),.3)
  539. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  540. LW.C0=clerp(LW.C0,cf(-1,0.5,-.5)*euler(1.57,0,.8),.3)
  541. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  542. RH.C0=clerp(RH.C0,cf(.5,-1,.5)*euler(0,1.57,0)*euler(0,-1,0),.3)
  543. LH.C0=clerp(LH.C0,cf(-.5,-1,-.5)*euler(0,-1.57,0)*euler(0,-1,0),.3)
  544. end
  545. so("http://roblox.com/asset/?id=161006212",prt1,1,.5)
  546. vel=Instance.new("BodyVelocity")
  547. vel.Parent=RootPart
  548. vel.maxForce=Vector3.new(4e+005,4e+005,4e+005)*2
  549. vel.velocity=RootPart.CFrame.lookVector*70
  550. gairo=Instance.new("BodyGyro")
  551. gairo.Parent=RootPart
  552. gairo.maxTorque=Vector3.new(4e+005,4e+005,4e+005)*math.huge
  553. gairo.P=20e+003
  554. gairo.cframe=RootPart.CFrame
  555. hitbox.Parent=modelzorz
  556. hitbox.Size=vt(2,7,4)
  557. hitbox.Transparency=1
  558. hitbox.CFrame=prt1.CFrame
  559. con1=hitbox.Touched:connect(function(hit) Damagefunc(hit,10,15,math.random(30,40),"Knockdown2",RootPart,.5,2) end)
  560. num=0
  561. for i=0,2,0.1 do
  562. swait()
  563. hitbox.CFrame=prt1.CFrame
  564. if num>=3 then
  565. MagicWave(TorsoColor,prt1.CFrame*euler(0,0,-1.57),1,1,1,.8,.7,.8,.1)
  566. num=0
  567. end
  568. num=num+1
  569. end
  570. vel.Parent=nil
  571. gairo.Parent=nil
  572. con1:disconnect()
  573. hitbox.Parent=nil
  574. swait(10)
  575. attack=false
  576. end
  577.  
  578. function OverDrive()
  579. attack=true
  580. for i=0,1,0.1 do
  581. swait()
  582. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  583. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,-.6)*euler(.2,0,-.5),.3)
  584. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*euler(0,0,.5),.4)
  585. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(2,0,.6)*euler(0,1,0),.4)
  586. RW.C1=clerp(RW.C1,cf(0,0.5,0)*euler(0,0,0),.4)
  587. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.8),.4)
  588. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.4)
  589. RH.C0=clerp(RH.C0,cf(1,-1,-.2)*euler(0,1.57,0)*euler(-.1,.5,-.6),.3)
  590. LH.C0=clerp(LH.C0,cf(-1.1,-.4,-.1)*euler(0,-1.57,0)*euler(.1,.5,-.2),.3)
  591. end
  592. Humanoid.WalkSpeed=5
  593. for i=1,2 do
  594. so("http://roblox.com/asset/?id=2101137",RootPart,1,1.2)
  595. num=0
  596. for i=0,4,0.1 do
  597. swait()
  598. hit,pos=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,50,Character)
  599. if hit~=nil then
  600. if num>=10 then
  601. MagicWave(TorsoColor,cf(pos),1,1,1,.6,.2,.6,.05)
  602. num=0
  603. end
  604. num=num+1
  605. end
  606. end
  607. MagicBlock(TorsoColor,cf(prt1.Position)*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)),1,1,1,6,6,6,.1,2)
  608. so("http://roblox.com/asset/?id=2248511",prt1,1,2)
  609. mana=mana-5
  610. end
  611. swait(5)
  612. so("http://roblox.com/asset/?id=161006093",prt1,1,1)
  613. so("http://roblox.com/asset/?id=169380505",prt1,1,1)
  614. vel=Instance.new("BodyVelocity")
  615. vel.Parent=RootPart
  616. vel.maxForce=Vector3.new(4e+005,4e+005,4e+005)*2
  617. vel.velocity=RootPart.CFrame.lookVector*50
  618. hitbox.Parent=modelzorz
  619. hitbox.Size=vt(2,7,4)
  620. hitbox.Transparency=1
  621. hitbox.CFrame=prt1.CFrame
  622. con1=hitbox.Touched:connect(function(hit) Damagefunc(hit,10,15,math.random(1,5),"OrbBlast",RootPart,1,1,1) end)
  623. for i=0,1,0.1 do
  624. swait()
  625. if num>=5 then
  626. MagicWave(TorsoColor,prt1.CFrame*cf(0,1,0)*euler(3.14,0,0),1,1,1,.5,1,.5,.1)
  627. num=0
  628. end
  629. num=num+1
  630. hitbox.CFrame=prt1.CFrame
  631. vel.velocity=RootPart.CFrame.lookVector*50
  632. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1.2)*euler(.2,0,0),.3)
  633. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1.2),.3)
  634. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(1.57,0,1.2),.3)
  635. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  636. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.2,0,-.8),.3)
  637. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  638. RH.C0=clerp(RH.C0,cf(.5,-1,1)*euler(0,1.57,0)*euler(0,-1.2,0),.3)
  639. LH.C0=clerp(LH.C0,cf(-.5,-1,-1)*euler(0,-1.57,0)*euler(0,-1.2,0),.3)
  640. end
  641. for i=1,7,0.1 do
  642. swait()
  643. hitbox.CFrame=prt1.CFrame
  644. if num>=5 then
  645. MagicWave(TorsoColor,prt1.CFrame*cf(0,1,0)*euler(3.14,0,0),1,1,1,.5,1,.5,.1)
  646. num=0
  647. end
  648. num=num+1
  649. vel.velocity=RootPart.CFrame.lookVector*50
  650. end
  651. con1:disconnect()
  652. hitbox.Parent=nil
  653. Humanoid.WalkSpeed=0
  654. for i=0,1,0.02 do
  655. swait()
  656. vel.velocity=RootPart.CFrame.lookVector*(50-50*i)
  657. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,-.6)*euler(.2,0,.5),.2)
  658. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*euler(0,0,-.5)*euler(.2,0,0),.2)
  659. RW.C0=clerp(RW.C0,cf(1,0.5,-.5)*euler(1,0,-.4)*euler(0,.5,0),.2)
  660. RW.C1=clerp(RW.C1,cf(0,0.5,0)*euler(0,0,0),.2)
  661. LW.C0=clerp(LW.C0,cf(-1,0.5,-.5)*euler(.5,0,.8),.2)
  662. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.2)
  663. RH.C0=clerp(RH.C0,cf(1.1,-.4,-.1)*euler(0,1.57,0)*euler(-.1,-.5,.2),.2)
  664. LH.C0=clerp(LH.C0,cf(-1,-.8,-.2)*euler(0,-1.57,0)*euler(-.1,-.5,.4),.2)
  665. end
  666. vel.Parent=nil
  667. Humanoid.WalkSpeed=16
  668. attack=false
  669. end
  670.  
  671. function Boomerang()
  672. attack=true
  673. mana=mana-20
  674. Humanoid.WalkSpeed=5
  675. so("http://roblox.com/asset/?id=10209296",prt1,1,1.2)
  676. so("http://roblox.com/asset/?id=2101144",prt1,1,1)
  677. for _,c in pairs(modelzorz:children()) do
  678. if c.Name=="Boomerang1" or c.Name=="Boomerang2" then
  679. coroutine.resume(coroutine.create(function(Part)
  680. for i=1,.2,-0.1 do
  681. swait()
  682. Part.Transparency=i
  683. end
  684. end),c)
  685. end
  686. end
  687. for i=0,1,0.1 do
  688. swait()
  689. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  690. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,-.6)*euler(.2,0,-.5),.3)
  691. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*euler(0,0,.5),.3)
  692. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(2,0,1)*euler(0,1.5,0),.3)
  693. RW.C1=clerp(RW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  694. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.6),.3)
  695. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  696. RH.C0=clerp(RH.C0,cf(1,-1,-.2)*euler(0,1.57,0)*euler(-.1,.5,-.6),.3)
  697. LH.C0=clerp(LH.C0,cf(-1.1,-.4,-.1)*euler(0,-1.57,0)*euler(.1,.5,-.2),.3)
  698. end
  699. hitbox.Parent=modelzorz
  700. hitbox.Size=vt(1,10,10)
  701. hitbox.Transparency=1
  702. hitbox.CFrame=prt1.CFrame
  703. con1=hitbox.Touched:connect(function(hit) Damagefunc(hit,10,20,math.random(30,40),"Knockdown2",prt1,.5,2) end)
  704. so("http://roblox.com/asset/?id=10209640",prt1,1,.6)
  705. for i=0,1,0.03 do
  706. so("rbxasset://sounds\\swordslash.wav",prt1,1,1.5)
  707. swait()
  708. hitbox.CFrame=prt1.CFrame
  709. --hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  710. hwld.C0=euler(3.14+6.28*i,3.14,0)*cf(0,1+40*i,0)
  711. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*euler(0,0,1),.3)
  712. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*euler(0,0,-1),.3)
  713. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(1.57,0,1)*euler(0,1.5,0),.3)
  714. RW.C1=clerp(RW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  715. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.6),.3)
  716. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  717. RH.C0=clerp(RH.C0,cf(.5,-1,.5)*euler(0,1.57,0)*euler(0,-1,0),.3)
  718. LH.C0=clerp(LH.C0,cf(-.5,-1,-.5)*euler(0,-1.57,0)*euler(0,-1,0),.3)
  719. end
  720. for i=0,1,0.03 do
  721. so("rbxasset://sounds\\swordslash.wav",prt1,1,1.5)
  722. swait()
  723. hitbox.CFrame=prt1.CFrame
  724. hwld.C0=euler(3.14+6.28+6.28*i,3.14,0)*cf(0,1+40-40*i,0)
  725. end
  726. con1:disconnect()
  727. hitbox.Parent=nil
  728. for _,c in pairs(modelzorz:children()) do
  729. if c.Name=="Boomerang1" or c.Name=="Boomerang2" then
  730. coroutine.resume(coroutine.create(function(Part)
  731. for i=.2,1,0.1 do
  732. swait()
  733. Part.Transparency=i
  734. end
  735. end),c)
  736. end
  737. end
  738. for i=0,1,0.05 do
  739. swait()
  740. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.2)
  741. RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*euler(0,0,-1),.2)
  742. Torso.Neck.C0=clerp(Torso.Neck.C0,necko*euler(0,0,1)*euler(.2,0,0),.2)
  743. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(1,0,1)*euler(0,.5,0),.2)
  744. RW.C1=clerp(RW.C1,cf(0,0.5,0)*euler(0,0,0),.2)
  745. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-1),.2)
  746. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.2)
  747. RH.C0=clerp(RH.C0,cf(1,-1,0)*euler(0,1.57,0)*euler(0,0,0),.3)
  748. LH.C0=clerp(LH.C0,cf(-1,-1,0)*euler(0,-1.57,0)*euler(0,0,0),.3)
  749. end
  750. swait(10)
  751. Humanoid.WalkSpeed=16
  752. attack=false
  753. end
  754.  
  755. function EnergyBlades()
  756. attack=true
  757. for i=0,1,0.1 do
  758. swait()
  759. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  760. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1),.3)
  761. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1),.3)
  762. RW.C0=clerp(RW.C0,cf(1.3,1,-.2)*euler(3.14,0,-.3)*euler(0,-.5,0),.3)
  763. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  764. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.2),.3)
  765. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  766. end
  767. Humanoid.WalkSpeed=0
  768. for i=0,1,0.15 do
  769. swait()
  770. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  771. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-1),.3)
  772. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,1),.3)
  773. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(3.14,0,0)*euler(0,-.5,0),.3)
  774. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  775. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.5),.3)
  776. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  777. end
  778. MagicCircle(TorsoColor,prt1.CFrame*cf(0,-4.5,0),1,1,1,5,.5,5,.05)
  779. so("http://roblox.com/asset/?id=169445602",prt1,1,.8)
  780. mana=mana-20
  781. for i=100,300,50 do
  782. local sord=part(3,modelzorz,0,0.5,TorsoColor,"Sord",vt(1,1,5))
  783. local smsh=mesh("SpecialMesh",sord,"FileMesh","rbxasset://fonts/sword.mesh",vt(0,0,0),vt(1,1,1))
  784. sord.Anchored=true
  785. newCF=cf(math.random(-600,600)/100,math.random(500,1000)/100,math.random(-600,600)/100)
  786. sord.CFrame=cf(RootPart.Position)*newCF
  787. sord.CFrame=cf(sord.Position,MMouse.Hit.p)*euler(3.14,0,0)
  788. MagicCircle(TorsoColor,sord.CFrame,5,5,10,1,1,3,.05)
  789. so("http://roblox.com/asset/?id=2101144",sord,.6,.7)
  790. game:GetService("Debris"):AddItem(sord,10)
  791. local hitt=false
  792. con=sord.Touched:connect(function(hit)
  793. if hitt==true then return end
  794. hitt=true
  795. --if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
  796. if hit.Name~="Sord" then
  797. sord.Parent=nil
  798. print("hit")
  799. local ref=part(3,workspace,0,1,hit.BrickColor,"Effect",vt())
  800. ref.Anchored=true
  801. ref.CFrame=cf(sord.Position)
  802. so("http://roblox.com/asset/?id=161006093",ref,1,1)
  803. so("http://roblox.com/asset/?id=10209303",ref,1,1)
  804. MagicCircle(TorsoColor,cf(ref.Position),1,1,1,2,2,2,.01)
  805. for i=0,10 do
  806. MagicBlock(TorsoColor,cf(ref.Position),1,1,1,1,1,1,.05,3)
  807. end
  808. game:GetService("Debris"):AddItem(ref,1)
  809. MagniDamage(ref,15,10,20,math.random(10,30),"Knockdown2")
  810. end
  811. debounce=Instance.new("BoolValue")
  812. debounce.Name="DebounceHit"
  813. debounce.Parent=hit.Parent
  814. debounce.Value=true
  815. game:GetService("Debris"):AddItem(debounce,.5)
  816. end)
  817. coroutine.resume(coroutine.create(function(Part,Cframe,numb)
  818. while Part.Parent~=nil do
  819. swait()
  820. numb=numb-1
  821. if numb<=0 then
  822. Part.CFrame=Part.CFrame*cf(0,0,2)
  823. local prt=Part:clone()
  824. prt.Size=vt()
  825. prt.Parent=workspace
  826. prt.CFrame=Part.CFrame
  827. table.insert(Effects,{prt,"Disappear",.1})
  828. else
  829. Part.CFrame=cf(RootPart.Position)*Cframe
  830. Part.CFrame=cf(Part.Position,MMouse.Hit.p)*euler(3.14,0,0)
  831. end
  832. end
  833. end),sord,newCF,i)
  834. end
  835.  
  836. swait(100)
  837. Humanoid.WalkSpeed=16
  838. attack=false
  839. end
  840.  
  841. function MagniDamage(Part,magni,mindam,maxdam,knock,Type)
  842. for _,c in pairs(workspace:children()) do
  843. local hum=c:findFirstChild("Humanoid")
  844. if hum~=nil then
  845. local head=c:findFirstChild("Torso")
  846. if head~=nil then
  847. local targ=head.Position-Part.Position
  848. local mag=targ.magnitude
  849. if mag<=magni and c.Name~=Player.Name then
  850. Damagefunc(head,mindam,maxdam,knock,Type,Part,.2,1,3,1)
  851. end
  852. end
  853. end
  854. end
  855. end
  856.  
  857. function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  858. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  859. end
  860.  
  861. local Point=Torso.CFrame*cf(0,Torso.Size.Y,0)
  862. LastPoint=Point
  863. function effect(Color,Ref,LP,P1,returnn)
  864. local effectsmsh=Instance.new("CylinderMesh")
  865. effectsmsh.Scale=Vector3.new(0.2,1,0.2)
  866. effectsmsh.Name="Mesh"
  867. local effectsg=Instance.new("Part")
  868. effectsg.formFactor=3
  869. effectsg.CanCollide=false
  870. effectsg.Name="Eff"
  871. effectsg.Locked=true
  872. effectsg.Anchored=true
  873. effectsg.Size=Vector3.new(0.5,1,0.5)
  874. effectsg.Parent=workspace
  875. effectsmsh.Parent=effectsg
  876. effectsg.BrickColor=Color1
  877. effectsg.Reflectance=Ref
  878. local point1=P1
  879. local mg=(LP.p - point1.p).magnitude
  880. effectsg.Size=Vector3.new(0.5,mg,0.5)
  881. effectsg.CFrame=cf((LP.p+point1.p)/2,point1.p) * CFrame.Angles(math.rad(90),0,0)
  882. effectsmsh.Scale=Vector3.new(0.4,1,0.4)
  883. game:GetService("Debris"):AddItem(effectsg,2)
  884. if returnn then return effectsg end
  885. if not returnn then
  886. table.insert(Effects,{effectsg,"Cylinder",0.05,0.01,0,0.01,effectsmsh})
  887. end
  888. end
  889.  
  890. function MagicBlock(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay,Type)
  891. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  892. prt.Anchored=true
  893. prt.CFrame=cframe
  894. msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  895. game:GetService("Debris"):AddItem(prt,5)
  896. if Type==1 or Type==nil then
  897. table.insert(Effects,{prt,"Block1",delay,x3,y3,z3,msh})
  898. elseif Type==2 then
  899. table.insert(Effects,{prt,"Block2",delay,x3,y3,z3,msh})
  900. elseif Type==3 then
  901. table.insert(Effects,{prt,"Block3",delay,x3,y3,z3,msh,vt(math.random(-10,10)/10,math.random(-10,10)/10,math.random(-10,10)/10)})
  902. end
  903. end
  904.  
  905. function MagicCircle(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  906. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  907. prt.Anchored=true
  908. prt.CFrame=cframe
  909. local msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
  910. game:GetService("Debris"):AddItem(prt,2)
  911. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  912. end
  913.  
  914. function MagicWave(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  915. local prt=part(3,workspace,0,0,brickcolor,"Effect",vt())
  916. prt.Anchored=true
  917. prt.CFrame=cframe
  918. local msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=20329976",vt(0,0,0),vt(x1,y1,z1))
  919. game:GetService("Debris"):AddItem(prt,5)
  920. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  921. end
  922.  
  923. function Lightning(p0,p1,tym,ofs,col,th,tra,last)
  924. --[[p0=pos1
  925. p1=pos2
  926. tym=times
  927. ofs=offset
  928. col=color
  929. th=size
  930. tra=transparency
  931. last=lastingtime]]
  932. local magz = (p0 - p1).magnitude local curpos = p0 local trz = {-ofs,ofs}
  933. for i=1,tym do
  934. local li = Instance.new("Part",workspace) li.TopSurface =0 li.BottomSurface = 0 li.Anchored = true li.Transparency = tra or 0.4 li.BrickColor = BrickColor.new(col)
  935. li.formFactor = "Custom" li.CanCollide = false li.Size = Vector3.new(th,th,magz/tym) local ofz = Vector3.new(trz[math.random(1,2)],trz[math.random(1,2)],trz[math.random(1,2)])
  936. local trolpos = CFrame.new(curpos,p1)*CFrame.new(0,0,magz/tym).p+ofz
  937. if tym == i then
  938. local magz2 = (curpos - p1).magnitude li.Size = Vector3.new(th,th,magz2)
  939. li.CFrame = CFrame.new(curpos,p1)*CFrame.new(0,0,-magz2/2)
  940. else
  941. li.CFrame = CFrame.new(curpos,trolpos)*CFrame.new(0,0,magz/tym/2)
  942. end
  943. curpos = li.CFrame*CFrame.new(0,0,magz/tym/2).p game.Debris:AddItem(li,last)
  944. end
  945. end
  946.  
  947. Damagefunc=function(hit,minim,maxim,knockback,Type,Property,Delay,KnockbackType,decreaseblock)
  948. if hit.Parent==nil then
  949. return
  950. end
  951. h=hit.Parent:FindFirstChild("Humanoid")
  952. for _,v in pairs(hit.Parent:children()) do
  953. if v:IsA("Humanoid") then
  954. h=v
  955. end
  956. end
  957. if hit.Parent.Parent:FindFirstChild("Torso")~=nil then
  958. h=hit.Parent.Parent:FindFirstChild("Humanoid")
  959. end
  960. if hit.Parent.className=="Hat" then
  961. hit=hit.Parent.Parent:findFirstChild("Head")
  962. end
  963. if h~=nil and hit.Parent.Name~=Character.Name and hit.Parent:FindFirstChild("Torso")~=nil then
  964. if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
  965. --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
  966. return
  967. end]]
  968. -- hs(hit,1.2)
  969. c=Instance.new("ObjectValue")
  970. c.Name="creator"
  971. c.Value=game:service("Players").LocalPlayer
  972. c.Parent=h
  973. game:GetService("Debris"):AddItem(c,.5)
  974. Damage=math.random(minim,maxim)
  975. -- h:TakeDamage(Damage)
  976. blocked=false
  977. block=hit.Parent:findFirstChild("Block")
  978. if block~=nil then
  979. print(block.className)
  980. if block.className=="NumberValue" then
  981. if block.Value>0 then
  982. blocked=true
  983. if decreaseblock~=nil then
  984. block.Value=block.Value-decreaseblock
  985. end
  986. end
  987. end
  988. if block.className=="IntValue" then
  989. if block.Value>0 then
  990. blocked=true
  991. if decreaseblock~=nil then
  992. block.Value=block.Value-decreaseblock
  993. end
  994. end
  995. end
  996. end
  997. if blocked==false then
  998. -- h:TakeDamage(Damage)
  999. h.Health=h.Health-Damage
  1000. showDamage(hit.Parent,Damage,.5,BrickColor:Red())
  1001. else
  1002. h.Health=h.Health-(Damage/2)
  1003. showDamage(hit.Parent,Damage/2,.5,BrickColor.new("Bright blue"))
  1004. end
  1005. if Type=="Knockdown" then
  1006. hum=hit.Parent.Humanoid
  1007. hum.PlatformStand=true
  1008. coroutine.resume(coroutine.create(function(HHumanoid)
  1009. swait(1)
  1010. HHumanoid.PlatformStand=false
  1011. end),hum)
  1012. local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
  1013. --hit.CFrame=cf(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
  1014. local bodvol=Instance.new("BodyVelocity")
  1015. bodvol.velocity=angle*knockback
  1016. bodvol.P=5000
  1017. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  1018. bodvol.Parent=hit
  1019. rl=Instance.new("BodyAngularVelocity")
  1020. rl.P=3000
  1021. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  1022. rl.angularvelocity=Vector3.new(math.random(-10,10),math.random(-10,10),math.random(-10,10))
  1023. rl.Parent=hit
  1024. game:GetService("Debris"):AddItem(bodvol,.5)
  1025. game:GetService("Debris"):AddItem(rl,.5)
  1026. elseif Type=="Knockdown2" then
  1027. hum=hit.Parent.Humanoid
  1028. local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
  1029. --hit.CFrame=cf(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
  1030. local bodvol=Instance.new("BodyVelocity")
  1031. bodvol.velocity=angle*knockback
  1032. bodvol.P=5000
  1033. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  1034. bodvol.Parent=hit
  1035. game:GetService("Debris"):AddItem(bodvol,.5)
  1036. --game:GetService("Debris"):AddItem(rl,.5)
  1037. elseif Type=="Normal" then
  1038. vp=Instance.new("BodyVelocity")
  1039. vp.P=500
  1040. vp.maxForce=Vector3.new(math.huge,0,math.huge)
  1041. -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback
  1042. if KnockbackType==1 then
  1043. vp.velocity=Property.CFrame.lookVector*knockback+Property.Velocity/1.05
  1044. elseif KnockbackType==2 then
  1045. vp.velocity=Property.CFrame.lookVector*knockback
  1046. end
  1047. if knockback>0 then
  1048. vp.Parent=hit.Parent.Torso
  1049. end
  1050. game:GetService("Debris"):AddItem(vp,.5)
  1051. elseif Type=="Up" then
  1052. local bodyVelocity=Instance.new("BodyVelocity")
  1053. bodyVelocity.velocity=vt(0,30,0)
  1054. bodyVelocity.P=5000
  1055. bodyVelocity.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  1056. bodyVelocity.Parent=hit
  1057. game:GetService("Debris"):AddItem(bodyVelocity,1)
  1058. rl=Instance.new("BodyAngularVelocity")
  1059. rl.P=3000
  1060. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  1061. rl.angularvelocity=Vector3.new(math.random(-2,2),math.random(-2,2),math.random(-2,2))
  1062. rl.Parent=hit
  1063. game:GetService("Debris"):AddItem(rl,.5)
  1064. elseif Type=="OrbBlast" then
  1065. if mana>=15 then
  1066. mana=mana-15
  1067. so("http://roblox.com/asset/?id=161006093",hit,1,1)
  1068. so("http://roblox.com/asset/?id=10209303",hit,1,1)
  1069. MagicCircle(TorsoColor,cf(hit.Position),1,1,1,2,2,2,.01)
  1070. coroutine.resume(coroutine.create(function(Part)
  1071. for i=0,30 do
  1072. swait()
  1073. MagicBlock(TorsoColor,cf(Part.Position),1,1,1,1,1,1,.05,3)
  1074. end
  1075. end),hit)
  1076. local ref=part(3,workspace,0,1,hit.BrickColor,"Effect",vt())
  1077. ref.Anchored=true
  1078. ref.CFrame=cf(hit.Position)*cf(math.random(-10,10)/100,-.1,math.random(-10,10)/100)
  1079. game:GetService("Debris"):AddItem(ref,1)
  1080. MagniDamage(ref,15,20,30,math.random(20,40),"Knockdown2")
  1081. end
  1082. elseif Type=="Snare" then
  1083. bp=Instance.new("BodyPosition")
  1084. bp.P=2000
  1085. bp.D=100
  1086. bp.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  1087. bp.position=hit.Parent.Torso.Position
  1088. bp.Parent=hit.Parent.Torso
  1089. game:GetService("Debris"):AddItem(bp,1)
  1090. end
  1091. debounce=Instance.new("BoolValue")
  1092. debounce.Name="DebounceHit"
  1093. debounce.Parent=hit.Parent
  1094. debounce.Value=true
  1095. game:GetService("Debris"):AddItem(debounce,Delay)
  1096. c=Instance.new("ObjectValue")
  1097. c.Name="creator"
  1098. c.Value=Player
  1099. c.Parent=h
  1100. game:GetService("Debris"):AddItem(c,.5)
  1101. CRIT=false
  1102. end
  1103. end
  1104.  
  1105. showDamage=function(Char,Dealt,du,Color)
  1106. m=Instance.new("Model")
  1107. m.Name=tostring(math.floor(Dealt))
  1108. h=Instance.new("Humanoid")
  1109. h.Health=0
  1110. h.MaxHealth=0
  1111. h.Parent=m
  1112. c=Instance.new("Part")
  1113. c.Transparency=0
  1114. c.BrickColor=Color
  1115. c.Name="Head"
  1116. c.TopSurface=0
  1117. c.BottomSurface=0
  1118. c.formFactor="Plate"
  1119. c.Size=Vector3.new(1,.4,1)
  1120. ms=Instance.new("CylinderMesh")
  1121. ms.Scale=Vector3.new(.8,.8,.8)
  1122. if CRIT==true then
  1123. ms.Scale=Vector3.new(1,1.25,1)
  1124. end
  1125. ms.Parent=c
  1126. c.Reflectance=0
  1127. Instance.new("BodyGyro").Parent=c
  1128. c.Parent=m
  1129. if Char:findFirstChild("Head")~=nil then
  1130. c.CFrame=cf(Char["Head"].CFrame.p+Vector3.new(0,1.5,0))
  1131. elseif Char.Parent:findFirstChild("Head")~=nil then
  1132. c.CFrame=cf(Char.Parent["Head"].CFrame.p+Vector3.new(0,1.5,0))
  1133. end
  1134. f=Instance.new("BodyPosition")
  1135. f.P=2000
  1136. f.D=100
  1137. f.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  1138. f.position=c.Position+Vector3.new(0,3,0)
  1139. f.Parent=c
  1140. game:GetService("Debris"):AddItem(m,.5+du)
  1141. c.CanCollide=false
  1142. m.Parent=workspace
  1143. c.CanCollide=false
  1144. end
  1145.  
  1146. combo=0
  1147. function ob1d(mouse)
  1148. if attack==true or equipped==false then return end
  1149. hold=true
  1150. if combo==0 then
  1151. combo=1
  1152. attackone()
  1153. elseif combo==1 then
  1154. combo=2
  1155. attackthree()
  1156. elseif combo==2 then
  1157. combo=0
  1158. attacktwo()
  1159. end
  1160. coroutine.resume(coroutine.create(function()
  1161. for i=1,50 do
  1162. if attack==false then
  1163. swait()
  1164. end
  1165. end
  1166. if attack==false then
  1167. combo=0
  1168. end
  1169. end))
  1170. end
  1171.  
  1172. function ob1u(mouse)
  1173. hold = false
  1174. end
  1175.  
  1176. buttonhold = false
  1177.  
  1178. eul=0
  1179. size=0
  1180. holdz=false
  1181. equipped=false
  1182. function key(key)
  1183. if attack==true then return end
  1184. if key=="f" then
  1185. attack=true
  1186. if equipped==false then
  1187. equipped=true
  1188. RSH=ch.Torso["Right Shoulder"]
  1189. LSH=ch.Torso["Left Shoulder"]
  1190. --
  1191. RSH.Parent=nil
  1192. LSH.Parent=nil
  1193. --
  1194. RW.Name="Right Shoulder"
  1195. RW.Part0=ch.Torso
  1196. RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
  1197. RW.C1=cf(0, 0.5, 0)
  1198. RW.Part1=ch["Right Arm"]
  1199. RW.Parent=ch.Torso
  1200. --
  1201. LW.Name="Left Shoulder"
  1202. LW.Part0=ch.Torso
  1203. LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  1204. LW.C1=cf(0, 0.5, 0)
  1205. LW.Part1=ch["Left Arm"]
  1206. LW.Parent=ch.Torso
  1207. --
  1208. equipanim()
  1209. else
  1210. equipped=false
  1211. hideanim()
  1212. swait(0)
  1213. RW.Parent=nil
  1214. LW.Parent=nil
  1215. RSH.Parent=player.Character.Torso
  1216. LSH.Parent=player.Character.Torso
  1217. end
  1218. attack=false
  1219. end
  1220. if equipped==false then return end
  1221. if key=="z" and mana>=10 then
  1222. OverDrive()
  1223. end
  1224. if key=="x" and mana>=20 then
  1225. Boomerang()
  1226. end
  1227. if key=="c" and mana>=20 then
  1228. EnergyBlades()
  1229. end
  1230. if key=="h" then
  1231. mana=100
  1232. end
  1233. if key=="e" then
  1234. idle=500
  1235. end
  1236. coroutine.resume(coroutine.create(function()
  1237. for i=1,50 do
  1238. if attack==false then
  1239. swait()
  1240. end
  1241. end
  1242. if attack==false then
  1243. combo=0
  1244. end
  1245. end))
  1246. combo=0
  1247. end
  1248.  
  1249. function key2(key)
  1250. end
  1251.  
  1252. function s(mouse)
  1253. mouse.Button1Down:connect(function() ob1d(mouse) end)
  1254. mouse.Button1Up:connect(function() ob1u(mouse) end)
  1255. mouse.KeyDown:connect(key)
  1256. mouse.KeyUp:connect(key2)
  1257.  
  1258. player=Player
  1259. ch=Character
  1260. MMouse=mouse
  1261. end
  1262.  
  1263. function ds(mouse)
  1264. end
  1265.  
  1266. Bin.Selected:connect(s)
  1267. Bin.Deselected:connect(ds)
  1268. print("Cyber Stratosphere loaded.")
  1269.  
  1270. local mananum=0
  1271. local handidle=false
  1272. local donum=0
  1273. while true do
  1274. swait()
  1275. if donum>=.5 then
  1276. handidle=true
  1277. elseif donum<=0 then
  1278. handidle=false
  1279. end
  1280. if handidle==false then
  1281. donum=donum+0.003
  1282. else
  1283. donum=donum-0.003
  1284. end
  1285. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1286. local velderp=RootPart.Velocity.y
  1287. hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1288. if equipped==true then
  1289. if Anim=="Idle" and attack==false then
  1290. idle=idle+1
  1291. else
  1292. idle=0
  1293. end
  1294. if RootPart.Velocity.y > 1 and hitfloor==nil then
  1295. Anim="Jump"
  1296. if attack==false then
  1297. Neck.C0=clerp(Neck.C0,necko*euler(-0.2,0,0),.2)
  1298. Neck.C1=clerp(Neck.C1,necko2*euler(0,0,0),.2)
  1299. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,0),.2)
  1300. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(1.2,0,-.5),.2)
  1301. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.2)
  1302. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.5,0,-0.5),.2)
  1303. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.2)
  1304. RH.C0=clerp(RH.C0,cf(1,-1,-.3)*euler(-0.5,1.57,0)*euler(-.2,0,0),.2)
  1305. LH.C0=clerp(LH.C0,cf(-1,-1,-.3)*euler(-0.5,-1.57,0)*euler(-.2,0,0),.2)
  1306. end
  1307. elseif RootPart.Velocity.y < -1 and hitfloor==nil then
  1308. Anim="Fall"
  1309. if attack==false then
  1310. Neck.C0=clerp(Neck.C0,necko*euler(0.4,0,0),.1)
  1311. Neck.C1=clerp(Neck.C1,necko2*euler(0,0,0),.1)
  1312. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,0),.1)
  1313. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(1,0,.3),.1)
  1314. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.1)
  1315. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0.3,0,-0.2),.1)
  1316. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.1)
  1317. RH.C0=clerp(RH.C0,cf(1,-1,0)*euler(0.4,1.57,0),.2)
  1318. LH.C0=clerp(LH.C0,cf(-1,-1,0)*euler(-0.2,-1.57,0),.2)
  1319. end
  1320. elseif torvel<1 and hitfloor~=nil then
  1321. Anim="Idle"
  1322. if idle>=300 then
  1323. if attack==false then
  1324. --hwld.C0=clerp(hwld.C0,euler(0,3.14,1.4)*euler(-.5,0,0)*cf(-1.2,.4,-.8),.1)
  1325. hwld.C0=clerp(hwld.C0,euler(-.3,2.8,1.4)*cf(-1.5,0,0.7),.1)
  1326. Neck.C0=clerp(Neck.C0,necko*euler(0,0,0),.1)
  1327. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,0),.1)
  1328. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(0,0,1.3)*euler(.5,0,0),.1)
  1329. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.1)
  1330. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.2),.1)
  1331. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.1)
  1332. end
  1333. else
  1334. if attack==false then
  1335. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  1336. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-.3),.3)
  1337. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,.3),.3)
  1338. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(1.3-(donum/3),0,-.3-(donum/5)),.3)
  1339. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  1340. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0,0,-.2+(donum/5)),.3)
  1341. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  1342. RH.C0=clerp(RH.C0,RHC0,.3)
  1343. LH.C0=clerp(LH.C0,LHC0,.3)
  1344. end
  1345. end
  1346. elseif torvel>2 and torvel<22 and hitfloor~=nil then
  1347. Anim="Walk"
  1348. if attack==false then
  1349. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  1350. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-.5),.3)
  1351. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0.2,0,.5),.3)
  1352. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(1.2,0,-.5),.3)
  1353. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  1354. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.2,0,-.2),.3)
  1355. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  1356. RH.C0=clerp(RH.C0,cf(1,-1,0)*euler(0,1.57,0)*euler(0,-.5,0),.3)
  1357. LH.C0=clerp(LH.C0,cf(-1,-1,0)*euler(0,-1.57,0)*euler(0,-.5,0),.3)
  1358. end
  1359. elseif torvel>=22 and hitfloor~=nil then
  1360. Anim="Run"
  1361. if attack==false then
  1362. hwld.C0=clerp(hwld.C0,euler(3.14,3.14,0)*cf(0,1,0),.3)
  1363. Neck.C0=clerp(Neck.C0,necko*euler(0,0,-.5),.3)
  1364. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0.2,0,.5),.3)
  1365. RW.C0=clerp(RW.C0,cf(1.3,0.5,-.2)*euler(1.2,0,-.5),.3)
  1366. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  1367. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.2,0,-.2),.3)
  1368. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  1369. RH.C0=clerp(RH.C0,cf(1,-1,0)*euler(0,1.57,0)*euler(0,-.5,0),.3)
  1370. LH.C0=clerp(LH.C0,cf(-1,-1,0)*euler(0,-1.57,0)*euler(0,-.5,0),.3)
  1371. end
  1372. end
  1373. end
  1374. if #Effects>0 then
  1375. --table.insert(Effects,{prt,"Block1",delay})
  1376. for e=1,#Effects do
  1377. if Effects[e]~=nil then
  1378. --for j=1,#Effects[e] do
  1379. local Thing=Effects[e]
  1380. if Thing~=nil then
  1381. local Part=Thing[1]
  1382. local Mode=Thing[2]
  1383. local Delay=Thing[3]
  1384. local IncX=Thing[4]
  1385. local IncY=Thing[5]
  1386. local IncZ=Thing[6]
  1387. if Thing[1].Transparency<=1 then
  1388. if Thing[2]=="Block1" then
  1389. Thing[1].CFrame=Thing[1].CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  1390. Mesh=Thing[7]
  1391. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1392. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1393. elseif Thing[2]=="Block2" then
  1394. Thing[1].CFrame=Thing[1].CFrame
  1395. Mesh=Thing[7]
  1396. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1397. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1398. elseif Thing[2]=="Block3" then
  1399. Thing[1].CFrame=Thing[1].CFrame*cf(Thing[8])*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  1400. Mesh=Thing[7]
  1401. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1402. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1403. elseif Thing[2]=="Cylinder" then
  1404. Mesh=Thing[7]
  1405. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1406. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1407. elseif Thing[2]=="Blood" then
  1408. Mesh=Thing[7]
  1409. Thing[1].CFrame=Thing[1].CFrame*cf(0,.5,0)
  1410. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1411. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1412. elseif Thing[2]=="Elec" then
  1413. Mesh=Thing[7]
  1414. Mesh.Scale=Mesh.Scale+vt(Thing[7],Thing[8],Thing[9])
  1415. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1416. elseif Thing[2]=="Disappear" then
  1417. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1418. end
  1419. else
  1420. Part.Parent=nil
  1421. table.remove(Effects,e)
  1422. end
  1423. end
  1424. --end
  1425. end
  1426. end
  1427. end
  1428. if mana>=100 then
  1429. mana=100
  1430. else
  1431. if mananum<=15 then
  1432. mananum=mananum+1
  1433. else
  1434. mananum=0
  1435. mana=mana+1
  1436. end
  1437. end
  1438. fenbarmana2:TweenSize(UDim2.new(4*mana/100,0,0.2,0),nil,1,0.4,true)
  1439. fenbarmana4.Text="Energy("..mana..")"
  1440. end
  1441.  
  1442. --[[
  1443. Copyrighted (C) Fenrier 2014
  1444. ]]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement