minecrafter523

Exia Unit

Jun 29th, 2016
219
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 67.99 KB | None | 0 0
  1. Player=game:GetService("Players").LocalPlayer
  2. Character=Player.Character
  3. PlayerGui=Player.PlayerGui
  4. Backpack=Player.Backpack
  5. Torso=Character.Torso
  6. Head=Character.Head
  7. Humanoid=Character.Humanoid
  8. m=Instance.new('Model',Character)
  9. LeftArm=Character["Left Arm"]
  10. LeftLeg=Character["Left Leg"]
  11. RightArm=Character["Right Arm"]
  12. RightLeg=Character["Right Leg"]
  13. LS=Torso["Left Shoulder"]
  14. LH=Torso["Left Hip"]
  15. RS=Torso["Right Shoulder"]
  16. RH=Torso["Right Hip"]
  17. Face = Head.face
  18. Neck=Torso.Neck
  19. it=Instance.new
  20. attacktype=1
  21. vt=Vector3.new
  22. cf=CFrame.new
  23. euler=CFrame.fromEulerAnglesXYZ
  24. angles=CFrame.Angles
  25. cloaked=false
  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. deb=false
  38. equipped=true
  39. hand=false
  40. MMouse=nil
  41. combo=0
  42. mana=0
  43. trispeed=.2
  44. attackmode='none'
  45. local idle=0
  46. local Anim="Idle"
  47. local Effects={}
  48. local gun=false
  49. local shoot=false
  50. player=nil
  51. mana=0
  52. local Mode="Gun"
  53.  
  54. mouse=Player:GetMouse()
  55. --save shoulders
  56. RSH, LSH=nil, nil
  57. --welds
  58. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  59. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  60. LH=Torso["Left Hip"]
  61. RH=Torso["Right Hip"]
  62. TorsoColor=Torso.BrickColor
  63. function NoOutline(Part)
  64. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  65. end
  66. player=Player
  67. ch=Character
  68. RSH=ch.Torso["Right Shoulder"]
  69. LSH=ch.Torso["Left Shoulder"]
  70. --
  71. RSH.Parent=nil
  72. LSH.Parent=nil
  73. --
  74. RW.Name="Right Shoulder"
  75. RW.Part0=ch.Torso
  76. RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
  77. RW.C1=cf(0, 0.5, 0)
  78. RW.Part1=ch["Right Arm"]
  79. RW.Parent=ch.Torso
  80. --
  81. LW.Name="Left Shoulder"
  82. LW.Part0=ch.Torso
  83. LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  84. LW.C1=cf(0, 0.5, 0)
  85. LW.Part1=ch["Left Arm"]
  86. LW.Parent=ch.Torso
  87.  
  88. Player=game:GetService('Players').LocalPlayer
  89. Character=Player.Character
  90. Mouse=Player:GetMouse()
  91.  
  92.  
  93. local function weldBetween(a, b)
  94. local weldd = Instance.new("ManualWeld")
  95. weldd.Part0 = a
  96. weldd.Part1 = b
  97. weldd.C0 = CFrame.new()
  98. weldd.C1 = b.CFrame:inverse() * a.CFrame
  99. weldd.Parent = a
  100. return weldd
  101. end
  102.  
  103. function swait(num)
  104. if num==0 or num==nil then
  105. game:service'RunService'.Heartbeat:wait(0)
  106. else
  107. for i=0,num do
  108. game:service'RunService'.Heartbeat:wait(0)
  109. end
  110. end
  111. end
  112.  
  113. function nooutline(part)
  114. part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10
  115. end
  116.  
  117. function part(formfactor,parent,material,reflectance,transparency,brickcolor,name,size)
  118. local fp=it("Part")
  119. fp.formFactor=formfactor
  120. fp.Parent=parent
  121. fp.Reflectance=reflectance
  122. fp.Transparency=transparency
  123. fp.CanCollide=false
  124. fp.Locked=true
  125. fp.BrickColor=BrickColor.new(tostring(brickcolor))
  126. fp.Name=name
  127. fp.Size=size
  128. fp.Position=Character.Torso.Position
  129. nooutline(fp)
  130. fp.Material=material
  131. fp:BreakJoints()
  132. return fp
  133. end
  134.  
  135. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  136. local mesh=it(Mesh)
  137. mesh.Parent=part
  138. if Mesh=="SpecialMesh" then
  139. mesh.MeshType=meshtype
  140. mesh.MeshId=meshid
  141. end
  142. mesh.Offset=offset
  143. mesh.Scale=scale
  144. return mesh
  145. end
  146.  
  147. function weld(parent,part0,part1,c0,c1)
  148. local weld=it("Weld")
  149. weld.Parent=parent
  150. weld.Part0=part0
  151. weld.Part1=part1
  152. weld.C0=c0
  153. weld.C1=c1
  154. return weld
  155. end
  156.  
  157.  
  158. local function CFrameFromTopBack(at, top, back)
  159. local right = top:Cross(back)
  160. return CFrame.new(at.x, at.y, at.z,
  161. right.x, top.x, back.x,
  162. right.y, top.y, back.y,
  163. right.z, top.z, back.z)
  164. end
  165.  
  166. function Triangle(a, b, c)
  167. local edg1 = (c-a):Dot((b-a).unit)
  168. local edg2 = (a-b):Dot((c-b).unit)
  169. local edg3 = (b-c):Dot((a-c).unit)
  170. if edg1 <= (b-a).magnitude and edg1 >= 0 then
  171. a, b, c = a, b, c
  172. elseif edg2 <= (c-b).magnitude and edg2 >= 0 then
  173. a, b, c = b, c, a
  174. elseif edg3 <= (a-c).magnitude and edg3 >= 0 then
  175. a, b, c = c, a, b
  176. else
  177. assert(false, "unreachable")
  178. end
  179.  
  180. local len1 = (c-a):Dot((b-a).unit)
  181. local len2 = (b-a).magnitude - len1
  182. local width = (a + (b-a).unit*len1 - c).magnitude
  183.  
  184. local maincf = CFrameFromTopBack(a, (b-a):Cross(c-b).unit, -(b-a).unit)
  185.  
  186. local list = {}
  187.  
  188. local TrailColor = ("Lime green")
  189.  
  190. if len1 > 0.01 then
  191. local w1 = Instance.new('WedgePart', m)
  192. game:GetService("Debris"):AddItem(w1,5)
  193. w1.Material = "SmoothPlastic"
  194. w1.FormFactor = 'Custom'
  195. w1.BrickColor = BrickColor.new(TrailColor)
  196. w1.Transparency = 0
  197. w1.Reflectance = 0
  198. w1.Material = "SmoothPlastic"
  199. w1.CanCollide = false
  200. NoOutline(w1)
  201. local sz = Vector3.new(0.2, width, len1)
  202. w1.Size = sz
  203. local sp = Instance.new("SpecialMesh",w1)
  204. sp.MeshType = "Wedge"
  205. sp.Scale = Vector3.new(0,1,1) * sz/w1.Size
  206. w1:BreakJoints()
  207. w1.Anchored = true
  208. w1.Parent = workspace
  209. w1.Transparency = 0.7
  210. table.insert(Effects,{w1,"Disappear",.01})
  211. w1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2)
  212. table.insert(list,w1)
  213. end
  214.  
  215. if len2 > 0.01 then
  216. local w2 = Instance.new('WedgePart', m)
  217. game:GetService("Debris"):AddItem(w2,5)
  218. w2.Material = "SmoothPlastic"
  219. w2.FormFactor = 'Custom'
  220. w2.BrickColor = BrickColor.new(TrailColor)
  221. w2.Transparency = 0
  222. w2.Reflectance = 0
  223. w2.Material = "SmoothPlastic"
  224. w2.CanCollide = false
  225. NoOutline(w2)
  226. local sz = Vector3.new(0.2, width, len2)
  227. w2.Size = sz
  228. local sp = Instance.new("SpecialMesh",w2)
  229. sp.MeshType = "Wedge"
  230. sp.Scale = Vector3.new(0,1,1) * sz/w2.Size
  231. w2:BreakJoints()
  232. w2.Anchored = true
  233. w2.Parent = workspace
  234. w2.Transparency = 0.7
  235. table.insert(Effects,{w2,"Disappear",.01})
  236. w2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2)
  237. table.insert(list,w2)
  238. end
  239. return unpack(list)
  240. end
  241.  
  242.  
  243. so = function(id,par,vol,pit)
  244. coroutine.resume(coroutine.create(function()
  245. local sou = Instance.new("Sound",par or workspace)
  246. sou.Volume=vol
  247. sou.Pitch=pit or 1
  248. sou.SoundId=id
  249. swait()
  250. sou:play()
  251. game:GetService("Debris"):AddItem(sou,6)
  252. end))
  253. end
  254.  
  255. function clerp(a,b,t)
  256. local qa = {QuaternionFromCFrame(a)}
  257. local qb = {QuaternionFromCFrame(b)}
  258. local ax, ay, az = a.x, a.y, a.z
  259. local bx, by, bz = b.x, b.y, b.z
  260. local _t = 1-t
  261. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  262. end
  263.  
  264. function QuaternionFromCFrame(cf)
  265. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  266. local trace = m00 + m11 + m22
  267. if trace > 0 then
  268. local s = math.sqrt(1 + trace)
  269. local recip = 0.5/s
  270. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  271. else
  272. local i = 0
  273. if m11 > m00 then
  274. i = 1
  275. end
  276. if m22 > (i == 0 and m00 or m11) then
  277. i = 2
  278. end
  279. if i == 0 then
  280. local s = math.sqrt(m00-m11-m22+1)
  281. local recip = 0.5/s
  282. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  283. elseif i == 1 then
  284. local s = math.sqrt(m11-m22-m00+1)
  285. local recip = 0.5/s
  286. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  287. elseif i == 2 then
  288. local s = math.sqrt(m22-m00-m11+1)
  289. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  290. end
  291. end
  292. end
  293.  
  294. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  295. local xs, ys, zs = x + x, y + y, z + z
  296. local wx, wy, wz = w*xs, w*ys, w*zs
  297. local xx = x*xs
  298. local xy = x*ys
  299. local xz = x*zs
  300. local yy = y*ys
  301. local yz = y*zs
  302. local zz = z*zs
  303. 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))
  304. end
  305.  
  306. function QuaternionSlerp(a, b, t)
  307. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  308. local startInterp, finishInterp;
  309. if cosTheta >= 0.0001 then
  310. if (1 - cosTheta) > 0.0001 then
  311. local theta = math.acos(cosTheta)
  312. local invSinTheta = 1/math.sin(theta)
  313. startInterp = math.sin((1-t)*theta)*invSinTheta
  314. finishInterp = math.sin(t*theta)*invSinTheta
  315. else
  316. startInterp = 1-t
  317. finishInterp = t
  318. end
  319. else
  320. if (1+cosTheta) > 0.0001 then
  321. local theta = math.acos(-cosTheta)
  322. local invSinTheta = 1/math.sin(theta)
  323. startInterp = math.sin((t-1)*theta)*invSinTheta
  324. finishInterp = math.sin(t*theta)*invSinTheta
  325. else
  326. startInterp = t-1
  327. finishInterp = t
  328. end
  329. end
  330. 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
  331. end
  332.  
  333. --Example: Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  334.  
  335.  
  336. function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  337. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  338. end
  339.  
  340. Damagefunc=function(Part,hit,minim,maxim,knockback,Type,Property,Delay,KnockbackType,decreaseblock)
  341. if hit.Parent==nil then
  342. return
  343. end
  344. local h=hit.Parent:FindFirstChild("Humanoid")
  345. for _,v in pairs(hit.Parent:children()) do
  346. if v:IsA("Humanoid") then
  347. h=v
  348. end
  349. end
  350. if hit.Parent.Parent:FindFirstChild("Torso")~=nil then
  351. h=hit.Parent.Parent:FindFirstChild("Humanoid")
  352. end
  353. if hit.Parent.className=="Hat" then
  354. hit=hit.Parent.Parent:findFirstChild("Head")
  355. end
  356. if h~=nil and hit.Parent.Name~=Character.Name and hit.Parent:FindFirstChild("Torso")~=nil then
  357. if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
  358. --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
  359. return
  360. end]]
  361. -- hs(hit,1.2)
  362. local c=Instance.new("ObjectValue")
  363. c.Name="creator"
  364. c.Value=game:service("Players").LocalPlayer
  365. c.Parent=h
  366. game:GetService("Debris"):AddItem(c,.5)
  367. local Damage=math.random(minim,maxim)
  368. -- h:TakeDamage(Damage)
  369. local blocked=false
  370. local block=hit.Parent:findFirstChild("Block")
  371. if block~=nil then
  372. print(block.className)
  373. if block.className=="NumberValue" then
  374. if block.Value>0 then
  375. blocked=true
  376. if decreaseblock==nil then
  377. block.Value=block.Value-1
  378. end
  379. end
  380. end
  381. if block.className=="IntValue" then
  382. if block.Value>0 then
  383. blocked=true
  384. if decreaseblock~=nil then
  385. block.Value=block.Value-1
  386. end
  387. end
  388. end
  389. end
  390. if blocked==false then
  391. -- h:TakeDamage(Damage)
  392. h.Health=h.Health-Damage
  393. ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, Part.BrickColor.Color)
  394. else
  395. h.Health=h.Health-(Damage/2)
  396. ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, BrickColor.new("Bright blue").Color)
  397. end
  398. if Type=="Knockdown" then
  399. local hum=hit.Parent.Humanoid
  400. hum.PlatformStand=true
  401. coroutine.resume(coroutine.create(function(HHumanoid)
  402. swait(1)
  403. HHumanoid.PlatformStand=false
  404. end),hum)
  405. local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
  406. --hit.CFrame=CFrame.new(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
  407. local bodvol=Instance.new("BodyVelocity")
  408. bodvol.velocity=angle*knockback
  409. bodvol.P=5000
  410. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  411. bodvol.Parent=hit
  412. local rl=Instance.new("BodyAngularVelocity")
  413. rl.P=3000
  414. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  415. rl.angularvelocity=Vector3.new(math.random(-10,10),math.random(-10,10),math.random(-10,10))
  416. rl.Parent=hit
  417. game:GetService("Debris"):AddItem(bodvol,.5)
  418. game:GetService("Debris"):AddItem(rl,.5)
  419. elseif Type=="Normal" then
  420. local vp=Instance.new("BodyVelocity")
  421. vp.P=500
  422. vp.maxForce=Vector3.new(math.huge,0,math.huge)
  423. -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback
  424. if KnockbackType==1 then
  425. vp.velocity=Property.CFrame.lookVector*knockback+Property.Velocity/1.05
  426. elseif KnockbackType==2 then
  427. vp.velocity=Property.CFrame.lookVector*knockback
  428. end
  429. if knockback>0 then
  430. vp.Parent=hit.Parent.Torso
  431. end
  432. game:GetService("Debris"):AddItem(vp,.5)
  433. elseif Type=="Up" then
  434. local bodyVelocity=Instance.new("BodyVelocity")
  435. bodyVelocity.velocity=vt(0,60,0)
  436. bodyVelocity.P=5000
  437. bodyVelocity.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  438. bodyVelocity.Parent=hit
  439. game:GetService("Debris"):AddItem(bodyVelocity,1)
  440. local rl=Instance.new("BodyAngularVelocity")
  441. rl.P=3000
  442. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  443. rl.angularvelocity=Vector3.new(math.random(-30,30),math.random(-30,30),math.random(-30,30))
  444. rl.Parent=hit
  445. game:GetService("Debris"):AddItem(rl,.5)
  446. elseif Type=="Snare" then
  447. local bp=Instance.new("BodyPosition")
  448. bp.P=2000
  449. bp.D=100
  450. bp.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  451. bp.position=hit.Parent.Torso.Position
  452. bp.Parent=hit.Parent.Torso
  453. game:GetService("Debris"):AddItem(bp,1)
  454. elseif Type=="Target" then
  455. local Targetting = false
  456. if Targetting==false then
  457. ZTarget=hit.Parent.Torso
  458. coroutine.resume(coroutine.create(function(Part)
  459. so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  460. swait(5)
  461. so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  462. end),ZTarget)
  463. local TargHum=ZTarget.Parent:findFirstChild("Humanoid")
  464. local targetgui=Instance.new("BillboardGui")
  465. targetgui.Parent=ZTarget
  466. targetgui.Size=UDim2.new(10,100,10,100)
  467. local targ=Instance.new("ImageLabel")
  468. targ.Parent=targetgui
  469. targ.BackgroundTransparency=1
  470. targ.Image="rbxassetid://4834067"
  471. targ.Size=UDim2.new(1,0,1,0)
  472. cam.CameraType="Scriptable"
  473. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  474. local dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  475. workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  476. Targetting=true
  477. RocketTarget=ZTarget
  478. for i=1,Property do
  479. --while Targetting==true and Humanoid.Health>0 and Character.Parent~=nil do
  480. if Humanoid.Health>0 and Character.Parent~=nil and TargHum.Health>0 and TargHum.Parent~=nil and Targetting==true then
  481. swait()
  482. end
  483. --workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,Head.CFrame.p+rmdir*100)
  484. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  485. dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  486. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)*cf(0,5,10)*euler(-0.3,0,0)
  487. end
  488. Targetting=false
  489. RocketTarget=nil
  490. targetgui.Parent=nil
  491. cam.CameraType="Custom"
  492. end
  493. end
  494. local debounce=Instance.new("BoolValue")
  495. debounce.Name="DebounceHit"
  496. debounce.Parent=hit.Parent
  497. debounce.Value=true
  498. game:GetService("Debris"):AddItem(debounce,Delay)
  499. c=Instance.new("ObjectValue")
  500. c.Name="creator"
  501. c.Value=Player
  502. c.Parent=h
  503. game:GetService("Debris"):AddItem(c,.5)
  504. end
  505. end
  506.  
  507.  
  508. function ShowDamage(Pos, Text, Time, Color)
  509. local Rate = (1 / 30)
  510. local Pos = (Pos or Vector3.new(0, 0, 0))
  511. local Text = (Text or "")
  512. local Time = (Time or 2)
  513. local Color = (Color or Color3.new(1, 0, 0))
  514. local EffectPart = part("Custom",workspace,"SmoothPlastic",0,1,BrickColor.new(Color),"Effect",vt(0,0,0))
  515. EffectPart.Anchored = true
  516. local BillboardGui = Instance.new("BillboardGui")
  517. BillboardGui.Size = UDim2.new(3, 0, 3, 0)
  518. BillboardGui.Adornee = EffectPart
  519. local TextLabel = Instance.new("TextLabel")
  520. TextLabel.BackgroundTransparency = 1
  521. TextLabel.Size = UDim2.new(1, 0, 1, 0)
  522. TextLabel.Text = Text
  523. TextLabel.TextColor3 = Color
  524. TextLabel.TextScaled = true
  525. TextLabel.Font = Enum.Font.ArialBold
  526. TextLabel.Parent = BillboardGui
  527. BillboardGui.Parent = EffectPart
  528. game.Debris:AddItem(EffectPart, (Time + 0.1))
  529. EffectPart.Parent = game:GetService("Workspace")
  530. Delay(0, function()
  531. local Frames = (Time / Rate)
  532. for Frame = 1, Frames do
  533. wait(Rate)
  534. local Percent = (Frame / Frames)
  535. EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0)
  536. TextLabel.TextTransparency = Percent
  537. end
  538. if EffectPart and EffectPart.Parent then
  539. EffectPart:Destroy()
  540. end
  541. end)
  542. end
  543.  
  544. handle=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Handle",Vector3.new(0.800000012, 0.600000024, 0.400000036))
  545. handleweld=weld(m,Character["Right Arm"],handle,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0999984741, 0.00293731689, -0.997625113, 0.999999762, 0, 0, -0, -2.98023224e-008, 1, 0, -0.999999642, -2.98023206e-008))
  546. mesh("CylinderMesh",handle,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  547. BarrelA=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,1,"Really black","BarrelA",Vector3.new(0.400000006, 0.400000036, 0.200000003))
  548. BarrelAweld=weld(m,handle,BarrelA,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.81469727e-006, -0.501502991, 0.70533812, 0.999999762, 8.9397489e-013, -4.26325811e-014, 8.93974673e-013, -1, -7.63833441e-014, -4.2632554e-014, 7.81597009e-014, -0.999999762))
  549. mesh("BlockMesh",BarrelA,"","",Vector3.new(0, 0, 0),Vector3.new(0.170000017, 1, 2))
  550. BarrelB=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,1,"Really black","BarrelB",Vector3.new(0.400000006, 0.400000036, 0.200000003))
  551. BarrelBweld=weld(m,handle,BarrelB,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.81469727e-006, 0.498413086, 0.705340028, 0.999999762, 8.93975215e-013, -4.26325811e-014, 8.93974998e-013, -1, -7.99360578e-014, -4.2632554e-014, 8.17124146e-014, -0.999999762))
  552. mesh("BlockMesh",BarrelB,"","",Vector3.new(0, 0, 0),Vector3.new(0.170000017, 1, 2))
  553. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000024, 2.60000038))
  554. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.701442719, -0.600021362, 2.49932575, 0.999998927, 1.87752244e-006, -0.000799447123, -1.84774353e-006, 0.999999166, -1.93715053e-007, 0.000799283211, 2.23561045e-007, 0.999998808))
  555. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  556. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.400000006, 0.800000012, 0.200000003))
  557. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.81469727e-006, 0.405347705, 0.497962952, 0.999999285, -0, 0, 0, 1.49011647e-008, -0.999999046, -0, 0.999999762, 1.49011594e-008))
  558. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  559. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.400000006, 0.800000012, 0.200000003))
  560. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.81469727e-006, 0.405347705, 0.501495361, 0.999999285, -0, 0, 0, 1.49011647e-008, -0.999999046, -0, 0.999999762, 1.49011594e-008))
  561. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.170000017, 1, 2))
  562. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 1.00000012, 1.20000029))
  563. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.700000763, -3.05175781e-005, -3.76701355e-005, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  564. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 2.20000005, 0.599999964))
  565. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.700000763, -3.05175781e-005, 0.899943829, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  566. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1.20000005, 0.200000003, 1.20000005))
  567. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.599975586, 3.38554382e-005, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  568. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  569. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 1.79999995, 0.599999964))
  570. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.709243774, -2.28881836e-005, 0.899943829, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  571. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.800000012, 0.200000003, 0.400000036))
  572. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.399993896, -5.96046448e-006, 0.999999762, -0, 0, -0, 1, -1.77635684e-015, 0, 0, 0.999999762))
  573. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  574. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.800000012, 0.99999994))
  575. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.713443756, -0.500030518, 1.69926405, 0.999998927, -2.26500038e-006, -0.000799596135, 2.27987721e-006, 0.999999225, 1.93017172e-007, 0.000799476926, -2.231682e-007, 0.999998927))
  576. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  577. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 1.20000017))
  578. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.700153351, -0.700019836, 0.000669956207, -0.999999106, 1.87757018e-006, 0.000799469941, 1.84774353e-006, 0.999999166, 1.34110437e-007, -0.000799469592, 1.63956443e-007, -0.999999166))
  579. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  580. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000083, 2.60000038))
  581. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.698387146, -0.599975586, 2.50042844, -0.999998689, -1.90737251e-006, -0.000799447123, 1.90734818e-006, -0.999998927, -1.34110465e-007, -0.000799282978, -1.64014665e-007, 0.999998808))
  582. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  583. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.600000024, 2.5999999))
  584. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.709453583, -0.399978638, 2.50040436, -0.999999166, 2.30715773e-006, -0.000799596135, -2.33717014e-006, -0.999999523, 2.5262176e-007, -0.000799476926, 2.82754144e-007, 0.999998927))
  585. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  586. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000024, 0.600000024))
  587. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.700153351, -0.80002594, -0.2993083, -0.999999106, 1.87757018e-006, 0.000799469941, 1.84774353e-006, 0.999999166, 1.34110437e-007, -0.000799469592, 1.63956443e-007, -0.999999166))
  588. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  589. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000024, 0.599999964))
  590. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.70142746, -0.80002594, 1.49932528, 0.999998927, 1.87752244e-006, -0.000799447123, -1.84774353e-006, 0.999999166, -1.93715053e-007, 0.000799283211, 2.23561045e-007, 0.999998808))
  591. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  592. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000036, 1.20000005))
  593. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.699836731, -0.69997406, -0.000449538231, 0.999999344, -1.89480204e-006, 0.000799469941, -1.92476682e-006, -0.999999523, 1.93715039e-007, 0.000799469766, -2.23517404e-007, -0.999999166))
  594. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  595. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.99999994, 0.200000003, 2))
  596. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0999984741, 0.599975586, 0.999940634, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  597. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1.40000045, 0.200000003, 1.20000005))
  598. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(3.05175781e-005, -0.000755310059, 5.96046448e-005, -1.48553302e-013, -0.999995828, 2.98021838e-008, -0.999999762, -1.503297e-013, -2.98021909e-008, 2.98023295e-008, -2.9802214e-008, -0.999995589))
  599. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.285999984, 1.01199996))
  600. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000024, 0.599999964))
  601. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.698394775, -0.799972534, 1.50044394, -0.999998689, -1.90737251e-006, -0.000799447123, 1.90734818e-006, -0.999998927, -1.34110465e-007, -0.000799282978, -1.64014665e-007, 0.999998808))
  602. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  603. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.400000006, 0.800000012, 0.200000003))
  604. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.81469727e-006, 0.405347705, -0.502029419, 0.999999285, -0, 0, 0, 1.49011647e-008, -0.999999046, -0, 0.999999762, 1.49011594e-008))
  605. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  606. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1.20000005, 0.400000006, 0.200000003))
  607. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.39996767, 0.599975586, 0.999999762, -0, 0, 0, 1.49011647e-008, -0.999999523, -0, 0.999999762, 1.49011594e-008))
  608. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  609. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000024, 0.600000024))
  610. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.699840546, -0.799964905, -0.300427675, 0.999999344, -1.89480204e-006, 0.000799469941, -1.92476682e-006, -0.999999523, 1.93715039e-007, 0.000799469766, -2.23517404e-007, -0.999999166))
  611. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  612. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 1.80000019))
  613. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.195159912, -0.900024414, 0.899938345, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  614. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 0.400000036))
  615. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.194999695, -0.900024414, 0.200763583, -0.999999106, 1.87757018e-006, 0.000799469941, 1.84774353e-006, 0.999999166, 1.34110437e-007, -0.000799469592, 1.63956443e-007, -0.999999166))
  616. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  617. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(1.20000005, 0.800000012, 0.400000006))
  618. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.39996767, 0.499969482, 0.999999642, -0, 0, 0, 1.49011647e-008, -0.999999404, -0, 0.999999762, 1.49011594e-008))
  619. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  620. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 0.200000003))
  621. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.203845978, -0.899963379, 1.90046763, 0.99999851, -1.38333075e-006, 0.000811993901, 1.25192548e-006, 0.999998987, 9.15403871e-006, -0.00081211311, -9.18428123e-006, 0.999998808))
  622. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  623. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.800000012, 0.999999881))
  624. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.709457397, -0.499977112, 1.70040178, -0.999999166, 2.30715773e-006, -0.000799596135, -2.33717014e-006, -0.999999523, 2.5262176e-007, -0.000799476926, 2.82754144e-007, 0.999998927))
  625. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  626. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.400000006, 0.800000012, 0.200000003))
  627. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.405341506, -0.502037048, 0.999999285, -0, 0, 0, 1.49011647e-008, -0.999999046, -0, 0.999999762, 1.49011594e-008))
  628. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.170000017, 1, 2))
  629. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.600000143, 1.21000028))
  630. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.708374023, -3.05175781e-005, -0.00504338741, 0.999999523, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999523))
  631. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.400000006, 1.20000005))
  632. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.709457397, -0.500030518, 0.000697374344, -0.999999166, 1.89247135e-006, 0.000799469941, 1.86264469e-006, 0.999999225, 1.34110437e-007, -0.000799469533, 1.63927339e-007, -0.999999166))
  633. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  634. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1.20000005, 0.400000006, 0.200000003))
  635. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.39996767, -0.600021362, 0.999999762, -0, 0, 0, 1.49011647e-008, -0.999999523, -0, 0.999999762, 1.49011594e-008))
  636. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  637. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 0.200000003))
  638. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.196155548, -0.899963379, 1.90047097, 0.99999851, -1.38333075e-006, 0.000811993901, 1.25192548e-006, 0.999998987, 9.15403871e-006, -0.00081211311, -9.18428123e-006, 0.999998808))
  639. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  640. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.600000024, 2.5999999))
  641. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.713447571, -0.400032043, 2.49926639, 0.999998927, -2.26500038e-006, -0.000799596135, 2.27987721e-006, 0.999999225, 1.93017172e-007, 0.000799476926, -2.231682e-007, 0.999998927))
  642. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  643. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 1.4000001, 2))
  644. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.5, -3.05175781e-005, 0.999940634, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  645. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.400000006, 1.20000005))
  646. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.709461212, -0.499969482, -0.000437021255, 0.999999344, -1.89480204e-006, 0.000799469941, -1.92476682e-006, -0.999999523, 1.93715039e-007, 0.000799469766, -2.23517404e-007, -0.999999166))
  647. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  648. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1.20000005, 0.200000003, 1.20000005))
  649. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, -0.600028992, 3.38554382e-005, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  650. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  651. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(1.20000005, 0.800000012, 0.400000006))
  652. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.39996767, -0.500030518, 0.999999642, -0, 0, 0, 1.49011647e-008, -0.999999404, -0, 0.999999762, 1.49011594e-008))
  653. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  654. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(1.40000045, 0.200000018, 1.20000005))
  655. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.52587891e-005, -0.000755310059, 6.81877136e-005, 8.88178631e-016, -1, 2.98023206e-008, -0.999999762, -1.77635769e-015, -2.98023224e-008, 2.98023224e-008, -2.98023259e-008, -0.999999762))
  656. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  657. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 1.80000019))
  658. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.190341949, -0.900024414, 0.899938345, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  659. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.800000012, 0.200000003, 0.400000036))
  660. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, -0.400001526, -5.96046448e-006, 0.999999762, -0, 0, -0, 1, -1.77635684e-015, 0, 0, 0.999999762))
  661. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  662. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.400000006, 0.400000036))
  663. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.190494537, -0.900024414, 0.200588226, -0.999999106, 1.87757018e-006, 0.000799469941, 1.84774353e-006, 0.999999166, 1.34110437e-007, -0.000799469592, 1.63956443e-007, -0.999999166))
  664. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  665. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.600000024, 0.600000024))
  666. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.709449768, -0.600021362, -0.299300909, -0.999999166, 1.89247135e-006, 0.000799469941, 1.86264469e-006, 0.999999225, 1.34110437e-007, -0.000799469533, 1.63927339e-007, -0.999999166))
  667. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  668. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.200000152, 2.61000037))
  669. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.708377838, 2.28881836e-005, -2.50490212, 0.999999642, -0, 0, 0, -0.999999702, -4.470348e-008, 0, 2.98023295e-008, -0.999999344))
  670. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","Part",Vector3.new(0.200000003, 0.600000024, 0.600000024))
  671. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.709445953, -0.599967957, -0.300435305, 0.999999344, -1.89480204e-006, 0.000799469941, -1.92476682e-006, -0.999999523, 1.93715039e-007, 0.000799469766, -2.23517404e-007, -0.999999166))
  672. mesh("SpecialMesh",Part,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  673. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1, 0.200000003, 2))
  674. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0999984741, -0.600021362, 0.999940634, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  675. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Navy blue","Part",Vector3.new(0.200000003, 0.600000143, 2.60000014))
  676. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.700000763, -3.05175781e-005, 2.49992704, 0.999999762, -0, 0, -0, 1, 1.77635684e-015, 0, -3.55271368e-015, 0.999999762))
  677.  
  678. BladeHandle=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","BladeHandle",Vector3.new(0.200000003, 1, 3.39999986))
  679. BladeHandleweld=weld(m,Character["Right Arm"],BladeHandle,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0872383118, -1.20300293, 0.302297354, 1, -2.21671375e-008, 7.04762897e-008, -7.04762684e-008, 2.98023188e-008, 0.999999404, -2.2167157e-008, -0.999999285, 2.98023224e-008))
  680. Hitbox=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,1,"Lime green","Hitbox",Vector3.new(0.200000003, 4.79999971, 1))
  681. Hitboxweld=weld(m,BladeHandle,Hitbox,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.699994326, 0, 1, -9.99836402e-007, 1.80018773e-007, -1.80019143e-007, 1.49011647e-008, 0.999998808, -9.99837425e-007, -0.999998808, 1.49011719e-008))
  682. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Lime green","BladePart",Vector3.new(0.220000014, 0.200000003, 3.4000001))
  683. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00135803223, -0.393920898, -0.000129699707, -0.999998927, 2.05645279e-006, 0.000802798022, -2.0555824e-006, -0.999997914, 3.17394552e-006, 0.000802962692, 3.11428425e-006, 0.999998093))
  684. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Lime green","BladePart",Vector3.new(0.200000003, 0.220000014, 0.800000072))
  685. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.399986267, -5.7220459e-006, 1.70002365, 1.42108547e-014, -0.999998808, -1.77635684e-015, -1, 2.13162821e-014, -2.98022744e-008, 2.98023828e-008, -3.55271368e-015, -0.999998808))
  686. mesh("CylinderMesh",BladePart,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  687. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Lime green","BladePart",Vector3.new(0.200000003, 0.220000014, 0.800000072))
  688. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.400005341, -5.7220459e-006, 1.70001566, 4.33431069e-013, -0.999998093, 1.63424829e-013, -1, -9.23705556e-014, -2.98015639e-008, 2.98019547e-008, 2.14939178e-013, -0.999998093))
  689. mesh("CylinderMesh",BladePart,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  690. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Lime green","BladePart",Vector3.new(0.220000014, 0.200000003, 0.399999976))
  691. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.00168228149, -0.399024963, 1.89990211, 0.999998748, -2.1309047e-006, 0.000802797964, 2.13086582e-006, 0.999997854, 3.29315458e-006, -0.000802962575, -3.21859238e-006, 0.999998093))
  692. mesh("SpecialMesh",BladePart,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  693. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Lime green","BladePart",Vector3.new(0.220000014, 0.200000003, 3.4000001))
  694. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.00168037415, -0.399391174, -0.000123500824, 0.999998748, -2.1309047e-006, 0.000802797964, 2.13086582e-006, 0.999997854, 3.29315458e-006, -0.000802962575, -3.21859238e-006, 0.999998093))
  695. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Lime green","BladePart",Vector3.new(0.220000014, 0.200000003, 0.399999976))
  696. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00135612488, -0.39358139, 1.89990449, -0.999998927, 2.05645279e-006, 0.000802798022, -2.0555824e-006, -0.999997914, 3.17394552e-006, 0.000802962692, 3.11428425e-006, 0.999998093))
  697. mesh("SpecialMesh",BladePart,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  698. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","BladePart",Vector3.new(0.200000003, 0.520000041, 1.39999998))
  699. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.00136566162, -0.239994049, 2.3998909, 0.999999166, -1.95434222e-006, -0.000799282745, 1.92285847e-006, 0.999998212, -1.86264401e-006, 0.000799447356, 2.07120365e-006, 0.999998033))
  700. mesh("SpecialMesh",BladePart,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  701. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","BladePart",Vector3.new(1.00000012, 0.200000003, 1.00000012))
  702. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-7.62939453e-006, -5.7220459e-006, 1.60001981, 3.26849658e-013, -0.999999404, -3.01980663e-014, -1, -3.05533376e-013, -2.98017593e-008, 2.98018055e-008, 2.84217094e-014, -0.999999404))
  703. mesh("CylinderMesh",BladePart,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  704. BladePart=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0.20000000298023,0,"Really black","BladePart",Vector3.new(0.200000003, 0.479999989, 1.39999998))
  705. BladePartweld=weld(m,BladeHandle,BladePart,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00135612488, -0.260002136, 2.39991736, -0.999998927, 2.05645279e-006, 0.000802798022, -2.0555824e-006, -0.999997914, 3.17394552e-006, 0.000802962692, 3.11428425e-006, 0.999998093))
  706. mesh("SpecialMesh",BladePart,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  707.  
  708. function effect(Color,Ref,LP,P1,returnn)
  709. if LP==nil or P1==nil then return end
  710. local effectsmsh=Instance.new("CylinderMesh")
  711. effectsmsh.Scale=Vector3.new(0.2,1,0.2)
  712. effectsmsh.Name="Mesh"
  713. local effectsg=Instance.new("Part")
  714. NoOutline(effectsg)
  715. effectsg.formFactor=3
  716. effectsg.CanCollide=false
  717. effectsg.Name="Eff"
  718. effectsg.Locked=true
  719. effectsg.Anchored=true
  720. effectsg.Size=Vector3.new(0.5,1,0.5)
  721. effectsg.Parent=workspace
  722. effectsmsh.Parent=effectsg
  723. effectsg.BrickColor=BrickColor.new(Color)
  724. effectsg.Reflectance=Ref
  725. local point1=P1
  726. local mg=(LP.p - point1.p).magnitude
  727. effectsg.Size=Vector3.new(0.5,mg,0.5)
  728. effectsg.CFrame=cf((LP.p+point1.p)/2,point1.p) * CFrame.Angles(math.rad(90),0,0)
  729. effectsmsh.Scale=Vector3.new(0.2,1,0.2)
  730. game:GetService("Debris"):AddItem(effectsg,2)
  731. if returnn then return effectsg end
  732. if not returnn then
  733. table.insert(Effects,{effectsg,"Cylinder",0.2,0.01,0,0.01,effectsmsh})
  734. end
  735. end
  736.  
  737. function MagicCircle(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  738. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  739. prt.Anchored=true
  740. prt.CFrame=cframe
  741. local msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
  742. game:GetService("Debris"):AddItem(prt,2)
  743. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  744. end
  745.  
  746. function MagicCylinder(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  747. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  748. prt.Anchored=true
  749. prt.CFrame=cframe
  750. local msh=mesh("CylinderMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  751. game:GetService("Debris"):AddItem(prt,2)
  752. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  753. end
  754.  
  755. function MagicHead(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  756. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  757. prt.Anchored=true
  758. prt.CFrame=cframe
  759. local msh=mesh("SpecialMesh",prt,"Head","",vt(0,0,0),vt(x1,y1,z1))
  760. game:GetService("Debris"):AddItem(prt,2)
  761. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  762. end
  763.  
  764. function Shootcombo()
  765. attack = true
  766. for i = 0,1,0.1 do
  767. swait()
  768. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(50)),.3)
  769. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(-50)),.3)
  770. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(50)), 0.3)
  771. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-10)), 0.3)
  772. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(50),math.rad(0)),.3)
  773. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-120),math.rad(10)),.3)
  774. end
  775. so("http://www.roblox.com/asset/?id=169445602",BarrelA,.7,1.5)
  776. so("http://www.roblox.com/asset/?id=169445602",BarrelB,.7,1.5)
  777. so("http://www.roblox.com/asset/?id=169380505",BarrelA,.7,1.1)
  778. so("http://www.roblox.com/asset/?id=169380505",BarrelB,.7,1.1)
  779. table.insert(Effects,{BarrelA.CFrame.lookVector,"Shoot",10,BarrelA.Position,5,10,0,1})
  780. table.insert(Effects,{BarrelB.CFrame.lookVector,"Shoot",10,BarrelB.Position,5,10,0,1})
  781. for i = 0,1,0.2 do
  782. swait()
  783. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(50)),.3)
  784. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-5),math.rad(5),math.rad(-50)),.3)
  785. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(130), math.rad(30), math.rad(50)), 0.3)
  786. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-10)), 0.3)
  787. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(50),math.rad(0)),.3)
  788. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-120),math.rad(10)),.3)
  789. end
  790. attack = false
  791. end
  792.  
  793. function BladeAttackOne()
  794. attack = true
  795. local con=Hitbox.Touched:connect(function(hit) Damagefunc(Hitbox,hit,20,30,math.random(5,5),"Normal",RootPart,.2,1) end)
  796. for i = 0,1,0.1 do
  797. swait()
  798. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-70)),0.4)
  799. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(70)),0.4)
  800. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(30), math.rad(100)),0.4)
  801. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-80)),0.4)
  802. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(120),math.rad(0)),0.4)
  803. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-50),math.rad(0)),0.4)
  804. end
  805. --so("http://roblox.com/asset/?id=206083107",handle,1,1)
  806. so("http://www.roblox.com/asset/?id=200633148",handle,1,.9)
  807. for i = 0,1,0.1 do
  808. swait()
  809. local blcf = Hitbox.CFrame*CFrame.new(0,.5,0)
  810. if scfr and (Hitbox.Position-scfr.p).magnitude > .1 then
  811. local h = 5
  812. local a,b = Triangle((scfr*CFrame.new(0,h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p,(blcf*CFrame.new(0,h/2,0)).p)
  813. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  814. local a,b = Triangle((blcf*CFrame.new(0,h/2,0)).p,(blcf*CFrame.new(0,-h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p)
  815. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  816. scfr = blcf
  817. elseif not scfr then
  818. scfr = blcf
  819. end
  820. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(80)),0.4)
  821. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(-10),math.rad(-80)),0.4)
  822. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(120), math.rad(90)),0.4)
  823. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-30)),0.4)
  824. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(50),math.rad(0)),0.4)
  825. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-120),math.rad(-10)),0.4)
  826. end
  827. attack = false
  828. con:disconnect()
  829. end
  830.  
  831. function BladeAttackTwo()
  832. attack = true
  833. local con=Hitbox.Touched:connect(function(hit) Damagefunc(Hitbox,hit,20,30,math.random(5,5),"Normal",RootPart,.2,1) end)
  834. for i = 0,1,0.1 do
  835. swait()
  836. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(70)),0.4)
  837. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(-10),math.rad(-70)),0.4)
  838. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(120), math.rad(90)),0.4)
  839. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-30)),0.4)
  840. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(40),math.rad(0)),0.4)
  841. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-140),math.rad(-10)),0.4)
  842. end
  843. --so("http://roblox.com/asset/?id=206083107",handle,1,.9)
  844. so("http://www.roblox.com/asset/?id=200633196",handle,1,1)
  845. for i = 0,1,0.1 do
  846. swait()
  847. local blcf = Hitbox.CFrame*CFrame.new(0,.5,0)
  848. if scfr and (Hitbox.Position-scfr.p).magnitude > .1 then
  849. local h = 5
  850. local a,b = Triangle((scfr*CFrame.new(0,h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p,(blcf*CFrame.new(0,h/2,0)).p)
  851. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  852. local a,b = Triangle((blcf*CFrame.new(0,h/2,0)).p,(blcf*CFrame.new(0,-h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p)
  853. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  854. scfr = blcf
  855. elseif not scfr then
  856. scfr = blcf
  857. end
  858. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-80)),0.4)
  859. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(80)),0.4)
  860. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(10), math.rad(90)),0.4)
  861. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-90)),0.4)
  862. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(140),math.rad(0)),0.4)
  863. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-40),math.rad(-10)),0.4)
  864. end
  865. attack = false
  866. con:disconnect()
  867. end
  868.  
  869. function BladeAttackThree()
  870. attack = true
  871. local con=Hitbox.Touched:connect(function(hit) Damagefunc(Hitbox,hit,20,30,math.random(5,5),"Normal",RootPart,.2,1) end)
  872. for i = 0,1,0.1 do
  873. swait()
  874. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(20)),0.4)
  875. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(-20)),.3)
  876. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(170), math.rad(0), math.rad(20)),0.4)
  877. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-30)),0.4)
  878. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),0.4)
  879. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-10)),0.4)
  880. end
  881. --so("http://roblox.com/asset/?id=206083107",handle,1,1.1)
  882. so("http://www.roblox.com/asset/?id=200633196",handle,1,.9)
  883. for i = 0,1,0.1 do
  884. swait()
  885. local blcf = Hitbox.CFrame*CFrame.new(0,.5,0)
  886. if scfr and (Hitbox.Position-scfr.p).magnitude > .1 then
  887. local h = 5
  888. local a,b = Triangle((scfr*CFrame.new(0,h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p,(blcf*CFrame.new(0,h/2,0)).p)
  889. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  890. local a,b = Triangle((blcf*CFrame.new(0,h/2,0)).p,(blcf*CFrame.new(0,-h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p)
  891. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  892. scfr = blcf
  893. elseif not scfr then
  894. scfr = blcf
  895. end
  896. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(40)),0.4)
  897. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(-40)),.3)
  898. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(10), math.rad(0), math.rad(-10)),0.4)
  899. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-10)),0.4)
  900. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),0.4)
  901. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-10)),0.4)
  902. end
  903. attack = false
  904. con:disconnect()
  905. end
  906.  
  907. function BladeAttackFour()
  908. attack = true
  909. local con=Hitbox.Touched:connect(function(hit) Damagefunc(Hitbox,hit,20,30,math.random(5,5),"Normal",RootPart,.2,1) end)
  910. for i = 0,1,0.1 do
  911. swait()
  912. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(70)),0.4)
  913. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(-70)),.4)
  914. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(120), math.rad(90)),0.4)
  915. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-30)),0.4)
  916. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),0.4)
  917. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-10)),0.4)
  918. end
  919. so("http://www.roblox.com/asset/?id=200633148",handle,1,.8)
  920. Torso.Velocity=Head.CFrame.lookVector*100
  921. for i = 0,1,0.05 do
  922. swait()
  923. local blcf = Hitbox.CFrame*CFrame.new(0,.5,0)
  924. if scfr and (Hitbox.Position-scfr.p).magnitude > .1 then
  925. local h = 5
  926. local a,b = Triangle((scfr*CFrame.new(0,h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p,(blcf*CFrame.new(0,h/2,0)).p)
  927. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  928. local a,b = Triangle((blcf*CFrame.new(0,h/2,0)).p,(blcf*CFrame.new(0,-h/2,0)).p,(scfr*CFrame.new(0,-h/2,0)).p)
  929. if a then game.Debris:AddItem(a,1) end if b then game.Debris:AddItem(b,1) end
  930. scfr = blcf
  931. elseif not scfr then
  932. scfr = blcf
  933. end
  934. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,-1)* angles(math.rad(40),math.rad(0),math.rad(-70)),0.3)
  935. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-20),math.rad(-30),math.rad(70)),.3)
  936. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(20), math.rad(90)),0.3)
  937. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(30), math.rad(0), math.rad(-60)),0.3)
  938. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(60),math.rad(-30)),0.3)
  939. LH.C0=clerp(LH.C0,cf(-1,.2,0)*angles(math.rad(0),math.rad(-40),math.rad(-60)),0.3)
  940. end
  941. con:disconnect()
  942. attack = false
  943. end
  944.  
  945. function ElecEffect(cff,x,y,z)
  946. local prt=part(3,workspace,"SmoothPlastic",0,0,BrickColor.new("Lime green"),"Part",vt(1,1,1))
  947. prt.Anchored=true
  948. prt.CFrame=cff*cf(math.random(-x,x),math.random(-y,y),math.random(-z,z))
  949. prt.CFrame=cf(prt.Position)
  950. --prt.CFrame=cf(cff)*cf(math.random(-x,x),math.random(-y,y),math.random(-z,z))
  951. game:GetService("Debris"):AddItem(prt,2)
  952. xval=math.random()/2
  953. yval=math.random()/2
  954. zval=math.random()/2
  955. msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(xval,yval,zval))
  956. Effects[#Effects+1]={prt,"Elec",0.1,x,y,z,xval,yval,zval} --part, type, delay
  957. end
  958.  
  959. function Test()
  960. ElecEffect(Hitbox.CFrame,2,4,2)
  961. end
  962.  
  963. attacktype1 = 1
  964. mouse.Button1Down:connect(function()
  965. if Mode == "Gun" then
  966. if attack==false then
  967. if attacktype1==1 then
  968. attack=true
  969. attacktype1=1
  970. Shootcombo()
  971. end
  972. end
  973. end
  974. if Mode == "Blade" then
  975. if attack==false then
  976. if attacktype==1 then
  977. attack=true
  978. attacktype=2
  979. BladeAttackOne()
  980. elseif attacktype==2 then
  981. attack=true
  982. attacktype=3
  983. BladeAttackTwo()
  984. elseif attacktype==3 then
  985. attack=true
  986. attacktype=4
  987. BladeAttackThree()
  988. elseif attacktype==4 then
  989. attack=true
  990. attacktype=1
  991. BladeAttackFour()
  992. end
  993. end
  994. end
  995. end)
  996.  
  997. mouse.KeyDown:connect(function(k)
  998. k=k:lower()
  999. if k=='f' then
  1000. if Mode == "Gun" then
  1001. Mode = "Blade"
  1002. so("http://www.roblox.com/asset/?id=152052659",handle,1,1)
  1003. elseif Mode == "Blade" then
  1004. Mode = "Gun"
  1005. so("http://www.roblox.com/asset/?id=211134014",handle,1,1)
  1006. end
  1007. elseif k=='q' then
  1008. Test()
  1009. end
  1010. end)
  1011.  
  1012.  
  1013.  
  1014. local sine = 0
  1015. local change = 1
  1016. local val = 0
  1017.  
  1018. while true do
  1019. swait()
  1020. sine = sine + change
  1021. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1022. local velderp=RootPart.Velocity.y
  1023. hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1024. if equipped==true or equipped==false then
  1025. if attack==false then
  1026. idle=idle+1
  1027. else
  1028. idle=0
  1029. end
  1030. if idle>=500 then
  1031. if attack==false then
  1032. --Sheath()
  1033. end
  1034. end
  1035. if RootPart.Velocity.y > 1 and hitfloor==nil then
  1036. Anim="Jump"
  1037. if attack==false and Mode == "Gun" then
  1038. change=3
  1039. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1040. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
  1041. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.3)
  1042. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-10)), 0.3)
  1043. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-10)),.3)
  1044. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(20)),.3)
  1045. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1046. end
  1047. if attack==false and Mode == "Blade" then
  1048. change=3
  1049. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1050. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
  1051. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.3)
  1052. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-10)), 0.3)
  1053. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-10)),.3)
  1054. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(20)),.3)
  1055. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, -3, 1.2) * angles(math.rad(180), math.rad(0), math.rad(0)), 0.3)
  1056. end
  1057. elseif RootPart.Velocity.y < -1 and hitfloor==nil then
  1058. Anim="Fall"
  1059. if attack==false and Mode == "Gun" then
  1060. change=3
  1061. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1062. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(0)),.3)
  1063. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.3)
  1064. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-30)), 0.3)
  1065. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(10)),.3)
  1066. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20)),.3)
  1067. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1068. end
  1069. if attack==false and Mode == "Blade" then
  1070. change=3
  1071. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.3)
  1072. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(0)),.3)
  1073. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.3)
  1074. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-30)), 0.3)
  1075. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(10)),.3)
  1076. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20)),.3)
  1077. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, -3, 1.2) * angles(math.rad(180), math.rad(0), math.rad(0)), 0.3)
  1078. end
  1079. elseif torvel<1 and hitfloor~=nil then
  1080. Anim="Idle"
  1081. if attack==false and Mode == "Gun" then
  1082. change=3
  1083. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(20)),.3)
  1084. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(-20)),.3)
  1085. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.3)
  1086. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-10)), 0.3)
  1087. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(70),math.rad(0)),.3)
  1088. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-80),math.rad(10)),.3)
  1089. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1090. end
  1091. if attack==false and Mode == "Blade" then
  1092. change=3
  1093. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-40)),.3)
  1094. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(40)),.3)
  1095. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(60), math.rad(0), math.rad(20)), 0.3)
  1096. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(20), math.rad(0), math.rad(-30)), 0.3)
  1097. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(80),math.rad(0)),.3)
  1098. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-60),math.rad(-5)),.3)
  1099. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, -3, 1.2) * angles(math.rad(180), math.rad(0), math.rad(0)), 0.3)
  1100. end
  1101. elseif torvel>2 and hitfloor~=nil then
  1102. Anim="Walk"
  1103. if attack==false and Mode == "Gun" then
  1104. change=3
  1105. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(20),math.rad(0),math.rad(0)),.3)
  1106. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(-0)),.3)
  1107. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(40), math.rad(0), math.rad(20)), 0.3)
  1108. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-20), math.rad(0), math.rad(-10)), 0.3)
  1109. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(10)),.3)
  1110. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(10)),.3)
  1111. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, 0, 0) * angles(math.rad(0), math.rad(0), math.rad(0)), 0.3)
  1112. end
  1113. if attack==false and Mode == "Blade" then
  1114. change=3
  1115. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(20),math.rad(0),math.rad(10)),.3)
  1116. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-20),math.rad(1),math.rad(-10)),.3)
  1117. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(80), math.rad(5), math.rad(20)), 0.3)
  1118. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(10), math.rad(0), math.rad(-20)), 0.3)
  1119. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),.3)
  1120. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0)),.3)
  1121. BladeHandleweld.C0=clerp(BladeHandleweld.C0, CFrame.new(0, -3, 1.2) * angles(math.rad(180), math.rad(0), math.rad(0)), 0.3)
  1122. end
  1123. end
  1124. end
  1125. if #Effects>0 then
  1126. --table.insert(Effects,{prt,"Block1",delay})
  1127. for e=1,#Effects do
  1128. if Effects[e]~=nil then
  1129. --for j=1,#Effects[e] do
  1130. local Thing=Effects[e]
  1131. if Thing~=nil then
  1132. local Part=Thing[1]
  1133. local Mode=Thing[2]
  1134. local Delay=Thing[3]
  1135. local IncX=Thing[4]
  1136. local IncY=Thing[5]
  1137. local IncZ=Thing[6]
  1138. if Thing[2]=="DecreaseStat" then
  1139. Thing[5]=Thing[5]-1
  1140. if Thing[5]<=0 then
  1141. if Thing[1]:findFirstChild("Stats")~=nil then
  1142. Thing[1].Stats[Thing[3]].Value=Thing[1].Stats[Thing[3]].Value+Thing[4]
  1143. end
  1144. table.remove(Effects,e)
  1145. end
  1146. end
  1147. if Thing[2]=="Shoot" then
  1148. local Look=Thing[1]
  1149. local hit,pos = rayCast(Thing[4],Look,20,m)
  1150. local mag=(Thing[4]-pos).magnitude
  1151. MagicHead(BrickColor.new("Lime green"),CFrame.new((Thing[4]+pos)/2,pos)*angles(1.57,0,0),1,mag*5,1,.5,0,.5,0.1)
  1152. Thing[4]=Thing[4]+(Look*20)
  1153. Thing[3]=Thing[3]-1
  1154. if hit~=nil then
  1155. Thing[3]=0
  1156. if Thing[8]==1 then
  1157. Damagefunc(Hitbox,hit,Thing[5],Thing[6],Thing[7],"Normal",RootPart,0,2,math.random(1,5),nil,nil,true)
  1158. elseif Thing[8]==2 then
  1159. Damagefunc(Hitbox,hit,Thing[5],Thing[6],Thing[7],"NormalDecreaseMvmt1",RootPart,0,2,math.random(1,5),nil,nil,true)
  1160. end
  1161. ref=part(3,workspace,"SmoothPlastic",0,1,BrickColor.new("Lime green"),"Reference",vt())
  1162. ref.Anchored=true
  1163. ref.CFrame=cf(pos)
  1164. MagicCircle(BrickColor.new("Lime green"),cf(pos),5,5,5,1,1,1,0.03)
  1165. game:GetService("Debris"):AddItem(ref,1)
  1166. end
  1167. if Thing[3]<=0 then
  1168. table.remove(Effects,e)
  1169. end
  1170. end
  1171. if Thing[2]=="CylinderClang" then
  1172. if Thing[3]<=1 then
  1173. Thing[1].CFrame=Thing[1].CFrame*CFrame.new(0,2.5*Thing[5],0)*CFrame.fromEulerAnglesXYZ(Thing[6],0,0)
  1174. Thing[7]=Thing[1].CFrame
  1175. effect("New Yeller",0,Thing[8],Thing[7])
  1176. Thing[8]=Thing[7]
  1177. Thing[3]=Thing[3]+Thing[4]
  1178. else
  1179. Part.Parent=nil
  1180. table.remove(Effects,e)
  1181. end
  1182. --[[Mesh=Thing[7]
  1183. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1184. Thing[1].Transparency=Thing[1].Transparency+Thing[3]]
  1185. end
  1186. if Thing[2]~="Shoot" and Thing[2]~="DecreaseStat" then
  1187. if Thing[1].Transparency<=1 then
  1188. if Thing[2]=="Block1" then
  1189. Thing[1].CFrame=Thing[1].CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  1190. Mesh=Thing[7]
  1191. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1192. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1193. elseif Thing[2]=="Block2" then
  1194. Thing[1].CFrame=Thing[1].CFrame
  1195. Mesh=Thing[7]
  1196. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1197. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1198. elseif Thing[2]=="Cylinder" then
  1199. Mesh=Thing[7]
  1200. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1201. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1202. elseif Thing[2]=="Blood" then
  1203. Mesh=Thing[7]
  1204. Thing[1].CFrame=Thing[1].CFrame*cf(0,.5,0)
  1205. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1206. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1207. elseif Thing[2]=="Elec" then
  1208. Mesh=Thing[1].Mesh
  1209. Mesh.Scale=Mesh.Scale+vt(Thing[7],Thing[8],Thing[9])
  1210. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1211. elseif Thing[2]=="Disappear" then
  1212. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1213. end
  1214. else
  1215. Part.Parent=nil
  1216. table.remove(Effects,e)
  1217. end
  1218. end
  1219. end
  1220. --end
  1221. end
  1222. end
  1223. end
  1224. end
Add Comment
Please, Sign In to add comment